A full-featured download manager.
feat(appearance): add glass icons and adaptive sidebar colors (#2206)
Dr_rOot9a6d5c312d7f
diff --git a/.claude/rules/icons.md b/.claude/rules/icons.mdnew file mode 100644index 00000000..3116e443--- /dev/null+++ b/.claude/rules/icons.md@@ -0,0 +1,43 @@+---+description: Semantic icon imports, library isolation, and tree shaking+paths: ["src/renderer/**/*.ts", "src/renderer/**/*.tsx", "src/renderer/**/*.css", "scripts/check-boundaries.mjs", "tests/scripts/icon-*.test.ts"]+---++# Icons++## Use the semantic interface++- Import icons and their types from `@renderer/components/icons`. Use the+ exported semantic names directly, such as `SpeedUnlimitedIcon` and+ `MotrixIcon`; do not alias them back to `Rabbit` or `LucideIcon`.+- Within the renderer, only files inside `src/renderer/components/icons/`,+ including its adapter tests, may reference `lucide-react` or its subpaths.+ This covers value/type+ imports, re-exports, side-effect imports, `require()` and dynamic imports.+ Renderer consumers and their tests must use the semantic interface.+- If an icon is missing, add a semantic module and export it from the icon+ barrel before using it. Choose the name for the action or state it represents;+ keep distinct roles independently replaceable even if they share a glyph.+- Keep vendor-specific types, props and classes inside the icon implementation.+ Consumers must not depend on `.lucide-*` classes or SVG path geometry. Use+ accessible names or semantic `data-icon` identifiers when testing consumers.++## Maintain the adapter contract++- Keep `MotrixIconProps` and `createIcon` independent of icon-library types.+ Adapt a new library or custom SVG inside the icon directory. Preserve the+ SVG ref, caller props/children and the glyph's native viewBox and defaults.+- Use static glyph imports and retain `/* @__PURE__ */` on every module-level+ `createIcon(...)` call. Keep that factory free of external side effects.+ Do not import an entire icon namespace to build a runtime lookup table.+- Export wrapped semantic components from the barrel, not raw vendor glyphs.+ Keep decorative icons hidden from assistive technology; standalone meaningful+ icons need a translated accessible name.++## Validation++`pnpm run check:boundaries` rejects Lucide module references outside the icon+directory and runs in CI. When changing the adapter or its mappings, run the+focused icon component tests and `tests/scripts/icon-tree-shaking.test.ts`,+plus type checking.+When changing the import guard, run `tests/scripts/icon-import-boundary.test.ts`.diff --git a/.claude/rules/renderer.md b/.claude/rules/renderer.mdindex eb92f150..94a2d43e 100644--- a/.claude/rules/renderer.md+++ b/.claude/rules/renderer.md@@ -18,6 +18,9 @@ Use the existing three layers:Feature-specific composition stays with its route. Do not move domain behaviorinto `ui/`, and do not bypass an existing desktop/settings wrapper by cloning it.+Use the semantic icon interface in `@renderer/components/icons`; follow+`icons.md` for library isolation and adding or replacing glyphs.+## State and transport- Renderer code never imports `@core/`, `@main/`, or `@server/`. Use thediff --git a/.github/workflows/ci.yml b/.github/workflows/ci.ymlindex 30ae1e35..6fa9f9ad 100644--- a/.github/workflows/ci.yml+++ b/.github/workflows/ci.yml@@ -146,6 +146,9 @@ jobs:- name: File naming conventionsrun: pnpm run check:file-names+ - name: Architecture and icon import boundaries+ run: pnpm run check:boundaries+# Fingerprint the resolved Biome first: lint verdicts have disagreed# between runs with identical inputs before, and the version line is# the fastest way to tell a toolchain drift from a real finding.diff --git a/CLAUDE.md b/CLAUDE.mdindex 549ef9dd..2ca8e348 100644--- a/CLAUDE.md+++ b/CLAUDE.md@@ -51,6 +51,7 @@ their patterns match the files under inspection or modification.| `electron-vite.md` | Build, packaging, native ABI, and pnpm || `code-style.md` | TypeScript, React, CSS, and file naming || `renderer.md` | Renderer state, components, forms, and transport |+| `icons.md` | Semantic icon imports, library isolation, and tree shaking || `panel-layout.md` | Viewport height and scrolling layout || `i18n.md` | Locale catalogs and user-visible strings || `domain-model.md` | Shared domain types, validation, and errors |diff --git a/THIRD_PARTY_NOTICES.md b/THIRD_PARTY_NOTICES.mdindex 494d2e54..a314734a 100644--- a/THIRD_PARTY_NOTICES.md+++ b/THIRD_PARTY_NOTICES.md@@ -12,50 +12,35 @@ distribute.----## Settings page icons (Iconly Pro — UI8)--- **Author / Designer:** Iconly Pro-- **Source:** UI8 marketplace — <https://ui8.net>-- **License:** Proprietary. Licensed per the UI8 Standard License- (<https://ui8.net/licensing>). **Not MIT.** Not covered by the project's- LICENSE / `package.json` license field.-- **Usage in this project:** Used as settings navigation icons, rendered by- `src/renderer/routes/settings/cards` and related components.--### Affected files--```-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-```--### What this means for downstream users--- The MIT license on the Motrix source code **does not** grant you the- right to redistribute these PNG files.-- If you build and ship a derivative (a fork, a private build, a- repackaging), you must either:- 1. Hold your own valid UI8 / Iconly Pro license that covers the- redistribution, **or**- 2. Replace these files with icons you are licensed to distribute (for- example, a set under an SPDX-compatible open-source license such as- `CC-BY-4.0` or `Apache-2.0`).-- Embedding them inside an Electron `asar` bundle still counts as- redistribution.+## Glassmorphism settings icons++The settings cards use Home, Setting and Star from the supplied Glassmorphism+collection, recolored Download and Transfer derivatives, and newly modeled+color-wheel, globe and puzzle derivatives using the collection's glass+materials and studio lighting. The eight icons are rendered at 52px and 104px+and encoded as lossless WebP in+`src/renderer/routes/settings/icons/icon-*@1x.webp` and `icon-*@2x.webp`.++The supplied collection does not include an author attribution or license+statement. Its license is recorded as `NOASSERTION`; these assets are not+relicensed under Motrix’s MIT license.++## Glassmorphism speed mode icons++The Dashboard speed mode tile uses newly modeled rabbit, turtle and squirrel+geometry rendered with glass/satin materials and studio lighting derived from+the supplied Glassmorphism collection's `Add File.blend`. The six lossless WebP+assets are stored in `src/renderer/routes/dashboard/icons/speed-*@1x.webp` and+`speed-*@2x.webp` at 52px and 104px. The supplied source has no verified author+or license declaration; inherited materials and lighting remain `NOASSERTION`+and are not relicensed under Motrix’s MIT license.++The round curled-tail squirrel silhouette follows a user-supplied reference+image whose external author and license have not been verified.++The previous Iconly Pro settings PNG assets have been removed from this+version. Earlier versions containing those assets remain subject to their+original UI8 license terms.---diff --git a/THIRD_PARTY_NOTICES.zh-CN.md b/THIRD_PARTY_NOTICES.zh-CN.mdindex 542d8527..1d097655 100644--- a/THIRD_PARTY_NOTICES.zh-CN.md+++ b/THIRD_PARTY_NOTICES.zh-CN.md@@ -9,45 +9,30 @@ Motrix 采用 MIT 许可证发布(详见 `package.json` 与 `LICENSE`)。本----## 设置页图标(Iconly Pro — UI8)--- **作者 / 设计师:** Iconly Pro-- **来源:** UI8 素材市场 — <https://ui8.net>-- **许可:** 专有授权,遵循 UI8 标准许可协议- (<https://ui8.net/licensing>)。**非 MIT。** 不受本项目的 `LICENSE` /- `package.json` 中的 license 字段覆盖。-- **在项目中的用途:** 作为设置页的分类图标使用,在- `src/renderer/routes/settings/cards` 及相关组件中渲染。--### 涉及文件--```-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-src/renderer/routes/settings/icons/[email protected]-```--### 对下游用户的影响--- Motrix 源代码上的 MIT 许可证**不授予**你分发上述 PNG 文件的权利。-- 如果你构建并发布衍生版本(fork、私有构建、二次打包等),你必须:- 1. 自行拥有有效的 UI8 / Iconly Pro 授权以覆盖该分发场景;**或**- 2. 将这些文件替换为你有权分发的图标素材(例如以 `CC-BY-4.0`、- `Apache-2.0` 等 SPDX 兼容开源协议发布的资源)。-- 将它们打包进 Electron `asar` 内部同样属于"分发",不豁免此限制。+## 玻璃质感设置图标(Glassmorphism settings icons)++设置卡片使用所提供 Glassmorphism 素材集的 Home、Setting、Star,以及+重新配色的 Download、Transfer 和新建的色环、地球、拼图衍生图标。+衍生图标沿用素材集的玻璃材质和摄影棚灯光。八个图标以 52px 和 104px+无损 WebP 保存于+`src/renderer/routes/settings/icons/icon-*@1x.webp` 和 `icon-*@2x.webp`。++所提供的素材集未包含作者署名或许可证声明,因此许可证记录为 `NOASSERTION`;+这些素材并未重新授权为 Motrix 的 MIT 许可。++## 玻璃质感速度模式图标(Glassmorphism speed mode icons)++Dashboard 速度模式卡片使用新建的兔子、乌龟和松鼠几何模型,玻璃、缎面材质+和摄影棚灯光衍生自所提供 Glassmorphism 素材集的 `Add File.blend`。+六个无损 WebP 资源以 52px 和 104px 保存于+`src/renderer/routes/dashboard/icons/speed-*@1x.webp` 和 `speed-*@2x.webp`。+所提供的源文件没有可确认的作者或许可证声明,继承的材质和灯光许可记录为+`NOASSERTION`,未重新授权为 Motrix 的 MIT 许可。++圆卷尾松鼠的轮廓依据用户提供的参考图重建,该参考图的外部作者和许可尚未确认。++本版本已移除旧版 Iconly Pro 设置图标 PNG。包含这些资源的历史版本仍遵循+其原有的 UI8 许可条款。---diff --git a/e2e/downloads-speed-limit.spec.ts b/e2e/downloads-speed-limit.spec.tsindex 3fbf0af8..2ed9c0a8 100644--- a/e2e/downloads-speed-limit.spec.ts+++ b/e2e/downloads-speed-limit.spec.ts@@ -84,7 +84,7 @@ test('Downloads speed badge changes the existing mode and preserves its limits',const badge = mainWindow.locator('[data-slot="downloads-speed-limit"]')const rates = mainWindow.locator('[data-slot="downloads-transfer-rates"]')await expect(badge).toHaveAccessibleName('Speed mode: Standard')- await expect(badge.locator('.lucide-rabbit')).toHaveCount(1)+ await expect(badge.locator('[data-icon="speed-unlimited"]')).toHaveCount(1)await expect(badge).toHaveCSS('height', '20px')await expect(rates.getByRole('term')).toHaveText(['Upload speed',@@ -115,7 +115,7 @@ test('Downloads speed badge changes the existing mode and preserves its limits',await menu.getByRole('menuitemradio', { name: 'Low-speed mode' }).click()await expect(menu).toHaveCount(0)await expect(badge).toHaveAccessibleName('Speed mode: Low speed')- await expect(badge.locator('.lucide-turtle')).toHaveCount(1)+ await expect(badge.locator('[data-icon="speed-limited"]')).toHaveCount(1)await expect(badge).toHaveAttribute('data-reduced', 'true')const readSettings = () =>mainWindow.evaluate(async (channel) => {@@ -144,7 +144,7 @@ test('Downloads speed badge changes the existing mode and preserves its limits',await badge.click()await menu.getByRole('menuitemradio', { name: 'Automatic mode' }).click()await expect(badge).toHaveAccessibleName('Speed mode: Automatic')- await expect(badge.locator('.lucide-squirrel')).toHaveCount(1)+ await expect(badge.locator('[data-icon="speed-auto"]')).toHaveCount(1)await expect(badge).toHaveAttribute('data-reduced', 'false')await expect.poll(readSettings).toMatchObject({ turtle: 'auto' })diff --git a/e2e/downloads-visibility.spec.ts b/e2e/downloads-visibility.spec.tsindex b496cd8e..6d23cb1a 100644--- a/e2e/downloads-visibility.spec.ts+++ b/e2e/downloads-visibility.spec.ts@@ -1530,7 +1530,7 @@ test('compact search filters the table and explains active query and type filterawait expect(input).toBeFocused()await expect(root).toHaveAttribute('data-filter-active', 'false')const filter = mainWindow.getByRole('button', { name: /^Filters/ })- await expect(filter.locator('svg')).toHaveClass(/lucide-list-filter/)+ await expect(filter.locator('svg')).toHaveAttribute('data-icon', 'filter')await input.fill('alpha')await expect(mainWindow.locator('[data-task-id]')).toHaveCount(2)await expect(root).toHaveAttribute('data-filter-active', 'true')diff --git a/e2e/settings-persistence.spec.ts b/e2e/settings-persistence.spec.tsindex 80e929a6..7050ec2b 100644--- a/e2e/settings-persistence.spec.ts+++ b/e2e/settings-persistence.spec.ts@@ -217,3 +217,70 @@ test.describe('settings persistence', () => {await app.close()})})++test('sidebar glass color previews, cancels, and survives restart after save', async ({+ userDataDir,+ rpcPort,+}, testInfo) => {+ let app = await launchMotrix({ userDataDir, rpcPort })+ const openAppearance = async (main: Page) => {+ await main.getByRole('link', { name: 'Settings', exact: true }).click()+ await main.getByText('Appearance', { exact: true }).first().click()+ await expect(main.getByRole('radio', { name: 'Gray' })).toBeVisible()+ }+ try {+ let main = await openMain(app)+ await openAppearance(main)+ await main.getByRole('radio', { name: 'Cyan' }).check()+ await expect(main.locator('html')).toHaveAttribute(+ 'data-sidebar-color',+ 'cyan'+ )+ await main.getByRole('button', { name: 'Cancel', exact: true }).click()+ await expect(main.locator('html')).toHaveAttribute(+ 'data-sidebar-color',+ 'gray'+ )+ await openAppearance(main)+ await main.getByRole('radio', { name: 'Violet' }).check()+ const swatch = main.locator('.sidebar-color-swatch[data-color="violet"]')+ await expect(swatch).toHaveCSS('width', '24px')+ await expect(swatch).toHaveCSS('height', '24px')+ await main.getByRole('radio', { name: 'Violet' }).hover()+ await expect(+ main+ .locator('.sidebar-color-picker label')+ .filter({ has: main.getByRole('radio', { name: 'Violet' }) })+ .locator('span')+ .last()+ ).toHaveCSS('opacity', '1')+ await main.screenshot({+ path: testInfo.outputPath('sidebar-color-selected.png'),+ })+ await main.getByRole('button', { name: 'Save', exact: true }).click()+ await expect(main.getByRole('radio', { name: 'Violet' })).toBeHidden()+ await expect(main.locator('html')).toHaveAttribute(+ 'data-sidebar-color',+ 'violet'+ )+ await app.close()+ app = await launchMotrix({ userDataDir, rpcPort })+ main = await openMain(app)+ await expect(main.locator('html')).toHaveAttribute(+ 'data-sidebar-color',+ 'violet'+ )+ await openAppearance(main)+ await expect(main.getByRole('radio', { name: 'Violet' })).toBeChecked()+ await main.getByRole('radio', { name: 'Auto' }).check()+ await main.getByRole('button', { name: 'Save', exact: true }).click()+ await expect(main.getByRole('radio', { name: 'Auto' })).toBeHidden()+ await app.close()+ app = await launchMotrix({ userDataDir, rpcPort })+ main = await openMain(app)+ await openAppearance(main)+ await expect(main.getByRole('radio', { name: 'Auto' })).toBeChecked()+ } finally {+ await app.close().catch(() => {})+ }+})diff --git a/scripts/check-boundaries.mjs b/scripts/check-boundaries.mjsindex dad2d9b3..4d3bd39f 100644--- a/scripts/check-boundaries.mjs+++ b/scripts/check-boundaries.mjs@@ -22,6 +22,12 @@ const rules = [pattern: `from ['"][^'"]*(core|main)/`,dir: 'src/renderer/',},+ {+ label: 'renderer must use semantic icons outside components/icons',+ pattern: '[\'"`]lucide-react(/[^\'"`]*)?[\'"`]',+ dir: 'src/renderer/',+ exceptDirectories: ['src/renderer/components/icons/'],+ },{label: 'server must not import electron',pattern: `from ['"]electron['"]`,@@ -52,12 +58,15 @@ const rules = []// grep -rn output lines are "path:line:content" — take the path prefix.-function filterOutExceptions(stdout, except) {- if (!except || except.length === 0) return stdout+function filterOutExceptions(stdout, except = [], exceptDirectories = []) {+ if (except.length === 0 && exceptDirectories.length === 0) return stdoutconst lines = stdout.split('\n').filter(Boolean)const kept = lines.filter((line) => {const filePath = line.split(':', 1)[0]- return !except.some((suffix) => filePath.endsWith(suffix))+ return (+ !except.some((suffix) => filePath.endsWith(suffix)) &&+ !exceptDirectories.some((directory) => filePath.startsWith(directory))+ )})return kept.length > 0 ? `${kept.join('\n')}\n` : ''}@@ -77,7 +86,11 @@ for (const rule of rules) {continue}if (res.status === 0) {- const filtered = filterOutExceptions(res.stdout, rule.except)+ const filtered = filterOutExceptions(+ res.stdout,+ rule.except,+ rule.exceptDirectories+ )if (filtered === '') {console.log(`[PASS] ${rule.label}`)continuediff --git a/scripts/third-party-notices.config.json b/scripts/third-party-notices.config.jsonindex 6c62cb55..55e0c4ac 100644--- a/scripts/third-party-notices.config.json+++ b/scripts/third-party-notices.config.json@@ -164,28 +164,43 @@]},{- "id": "iconly-pro-settings-icons",- "name": "Iconly Pro settings icons",- "scope": "renderer assets",- "licenseDeclared": "LicenseRef-UI8-Standard-License",- "noticeMarker": "Iconly Pro",+ "id": "glassmorphism-settings-icons",+ "name": "Glassmorphism settings icons",+ "scope": "renderer settings cards",+ "licenseDeclared": "NOASSERTION",+ "noticeMarker": "Glassmorphism settings icons",+ "paths": [+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]",+ "src/renderer/routes/settings/icons/[email protected]"+ ]+ },+ {+ "id": "glassmorphism-speed-mode-icons",+ "name": "Glassmorphism speed mode icons",+ "scope": "renderer dashboard speed mode tile",+ "licenseDeclared": "NOASSERTION",+ "noticeMarker": "Glassmorphism speed mode icons","paths": [- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]",- "src/renderer/routes/settings/icons/[email protected]"+ "src/renderer/routes/dashboard/icons/[email protected]",+ "src/renderer/routes/dashboard/icons/[email protected]",+ "src/renderer/routes/dashboard/icons/[email protected]",+ "src/renderer/routes/dashboard/icons/[email protected]",+ "src/renderer/routes/dashboard/icons/[email protected]",+ "src/renderer/routes/dashboard/icons/[email protected]"]},{diff --git a/src/main/index.ts b/src/main/index.tsindex 03cfd661..c0ccb065 100644--- a/src/main/index.ts+++ b/src/main/index.ts@@ -195,6 +195,7 @@ import { setupNativeThemeSync } from './platform/native-theme-sync'import { setupPowerManager } from './platform/power-manager'import { createProtocolManager } from './platform/protocol-manager'import { createElectronPlatformServices } from './platform/services'+import { setupSystemAccentColorSync } from './platform/system-accent-color'import { removeTaskPath } from './platform/task-file-remover'import { setupTray } from './platform/tray'import { createElectronCapabilityHost } from './plugin/capability-host'@@ -344,6 +345,11 @@ const settingsManager = new SettingsManager(settingsPath, {...defaultSaveDirOptions,onChange: (old, updated) => {eventBus.emit(Events.SettingsChanged, { old, updated })+ if (old.app.sidebarColor !== updated.app.sidebarColor) {+ eventBus.emit(Events.SidebarColorChanged, {+ sidebarColor: updated.app.sidebarColor,+ })+ }if (old.app.liquidGlassEffect !== updated.app.liquidGlassEffect) {eventBus.emit(Events.LiquidGlassChanged, {liquidGlassEffect: updated.app.liquidGlassEffect,@@ -1650,6 +1656,8 @@ async function initializeMainProcess(): Promise<void> {// Apply the persisted theme before opening windows. Renderer-drawn Windows// controls inherit the same theme through CSS without native overlay sync.setupNativeThemeSync(eventBus, settingsManager)+ const systemAccentSync = setupSystemAccentColorSync(eventBus)+ app.once('will-quit', () => systemAccentSync.destroy())// Install forwarding before the onboarding window becomes interactive.// SetDisclaimerLanguage persists before its asynchronous locale transaction// completes; an immediate AcceptDisclaimer can open the main window in thatdiff --git a/src/main/ipc/queries.ts b/src/main/ipc/queries.tsindex 6f86a10f..7ffa42c0 100644--- a/src/main/ipc/queries.ts+++ b/src/main/ipc/queries.ts@@ -51,6 +51,7 @@ import type { CliToolService } from '../cli/cli-tool-service'import type { UpdateManager } from '../core/update-manager'import { getAppImageIntegrationView } from '../platform/appimage-integration-host'import { getLinuxDefaultAssociations } from '../platform/linux-default-apps'+import { getSystemAccentColor } from '../platform/system-accent-color'import { getWindowsDefaultAssociations } from '../platform/windows-default-apps'import { makeElectronFfmpegDetect } from '../plugin/ffmpeg-detect-electron'import { createGetEngineTaskOptionsHandler } from './queries/get-engine-task-options'@@ -170,6 +171,7 @@ export function buildQueryHandlers(ctx: QueryContext): QueryHandlerMap {[Queries.GetDirectoryPreferences]:createDirectoryPreferencesHandlers(settingsManager).get,+ [Queries.GetSystemAccentColor]: async () => getSystemAccentColor(),[Queries.GetSettings]: async () => {return settingsManager.get()},diff --git a/src/main/platform/system-accent-color.test.ts b/src/main/platform/system-accent-color.test.tsnew file mode 100644index 00000000..dc9f6b43--- /dev/null+++ b/src/main/platform/system-accent-color.test.ts@@ -0,0 +1,112 @@+import { EventBus } from '@core/events/event-bus'+import { Events } from '@shared/protocol/events'+import { beforeEach, expect, it, vi } from 'vitest'++const { prefs, app, nativeTheme } = vi.hoisted(() => ({+ prefs: {+ getAccentColor: vi.fn(),+ on: vi.fn(),+ off: vi.fn(),+ subscribeLocalNotification: vi.fn<+ (_event: string, _callback: () => void) => number+ >(() => 7),+ unsubscribeLocalNotification: vi.fn(),+ },+ app: { on: vi.fn(), off: vi.fn() },+ nativeTheme: { on: vi.fn(), off: vi.fn() },+}))+vi.mock('electron', () => ({ systemPreferences: prefs, app, nativeTheme }))++import {+ getSystemAccentColor,+ setupSystemAccentColorSync,+} from './system-accent-color'++beforeEach(() => {+ vi.resetAllMocks()+ prefs.subscribeLocalNotification.mockReturnValue(7)+ prefs.getAccentColor.mockReturnValue('ff8800ff')+})+it('reads native RGB on desktop and falls back for unavailable or invalid accents', () => {+ expect(getSystemAccentColor('darwin')).toBe('#ff8800')+ expect(getSystemAccentColor('win32')).toBe('#ff8800')+ expect(getSystemAccentColor('linux')).toBe('#ff8800')+ expect(getSystemAccentColor('freebsd')).toBeNull()+ prefs.getAccentColor.mockReturnValue('invalid')+ expect(getSystemAccentColor('darwin')).toBeNull()+ prefs.getAccentColor.mockImplementation(() => {+ throw new Error('unavailable')+ })+ expect(getSystemAccentColor('win32')).toBeNull()+})+it.each(['darwin', 'win32', 'linux'] as const)(+ 'broadcasts color changes and releases native listeners on %s',+ (platform) => {+ const bus = new EventBus()+ const changed = vi.fn()+ bus.on(Events.SystemAccentColorChanged, changed)+ const handle = setupSystemAccentColorSync(bus, platform)+ const refresh =+ platform === 'darwin'+ ? prefs.subscribeLocalNotification.mock.calls[0]?.[1]+ : prefs.on.mock.calls[0]?.[1]+ prefs.getAccentColor.mockReturnValue('007affff')+ refresh?.()+ expect(changed).toHaveBeenCalledWith({ color: '#007aff' })+ refresh?.()+ expect(changed).toHaveBeenCalledOnce()+ handle.destroy()+ expect(nativeTheme.off).toHaveBeenCalled()+ expect(app.off).toHaveBeenCalled()+ if (platform === 'darwin')+ expect(prefs.unsubscribeLocalNotification).toHaveBeenCalledWith(7)+ else expect(prefs.off).toHaveBeenCalledWith('accent-color-changed', refresh)+ }+)++it.each(['', 'invalid', '123456', 'gg8800ff'])(+ 'falls back when the Linux desktop returns an unavailable accent (%j)',+ (color) => {+ prefs.getAccentColor.mockReturnValue(color)+ expect(getSystemAccentColor('linux')).toBeNull()+ }+)++it('recovers from an unavailable Linux accent and clears it when support disappears', () => {+ prefs.getAccentColor.mockImplementation(() => {+ throw new Error('unavailable')+ })+ const bus = new EventBus()+ const changed = vi.fn()+ bus.on(Events.SystemAccentColorChanged, changed)+ const handle = setupSystemAccentColorSync(bus, 'linux')+ const accentChanged = prefs.on.mock.calls.find(+ ([event]) => event === 'accent-color-changed'+ )?.[1]+ const focused = app.on.mock.calls.find(+ ([event]) => event === 'browser-window-focus'+ )?.[1]+ const themeUpdated = nativeTheme.on.mock.calls.find(+ ([event]) => event === 'updated'+ )?.[1]++ prefs.getAccentColor.mockReturnValue('3584E4ff')+ focused?.()+ expect(changed).toHaveBeenLastCalledWith({ color: '#3584E4' })+ accentChanged?.()+ expect(changed).toHaveBeenCalledOnce()++ prefs.getAccentColor.mockReturnValue('')+ accentChanged?.()+ expect(changed).toHaveBeenLastCalledWith({ color: null })+ expect(changed).toHaveBeenCalledTimes(2)++ prefs.getAccentColor.mockReturnValue('26a269ff')+ themeUpdated?.()+ expect(changed).toHaveBeenLastCalledWith({ color: '#26a269' })+ expect(changed).toHaveBeenCalledTimes(3)+ handle.destroy()+ expect(prefs.off).toHaveBeenCalledWith('accent-color-changed', accentChanged)+ expect(app.off).toHaveBeenCalledWith('browser-window-focus', focused)+ expect(nativeTheme.off).toHaveBeenCalledWith('updated', themeUpdated)+})diff --git a/src/main/platform/system-accent-color.ts b/src/main/platform/system-accent-color.tsnew file mode 100644index 00000000..99d6d26f--- /dev/null+++ b/src/main/platform/system-accent-color.ts@@ -0,0 +1,53 @@+import type { EventBus } from '@core/events/event-bus'+import { Events } from '@shared/protocol/events'+import { app, nativeTheme, systemPreferences } from 'electron'++export function getSystemAccentColor(+ platform = process.platform+): string | null {+ if (platform !== 'darwin' && platform !== 'win32' && platform !== 'linux')+ return null+ try {+ const color = systemPreferences.getAccentColor()+ // Linux can return an empty string when the desktop has no accent color.+ return /^[\da-f]{8}$/i.test(color) ? `#${color.slice(0, 6)}` : null+ } catch {+ return null+ }+}++export function setupSystemAccentColorSync(+ eventBus: EventBus,+ platform = process.platform+) {+ let previous = getSystemAccentColor(platform)+ const refresh = () => {+ const color = getSystemAccentColor(platform)+ if (previous === color) return+ previous = color+ eventBus.emit(Events.SystemAccentColorChanged, { color })+ }+ // macOS has no Electron accent-color-changed event. Listen to AppKit's+ // local color notification, and refresh on focus as a recovery path.+ const subscription =+ platform === 'darwin'+ ? systemPreferences.subscribeLocalNotification(+ 'NSSystemColorsDidChangeNotification',+ refresh+ )+ : null+ if (platform === 'win32' || platform === 'linux')+ systemPreferences.on('accent-color-changed', refresh)+ nativeTheme.on('updated', refresh)+ app.on('browser-window-focus', refresh)+ return {+ destroy() {+ if (subscription !== null)+ systemPreferences.unsubscribeLocalNotification(subscription)+ if (platform === 'win32' || platform === 'linux')+ systemPreferences.off('accent-color-changed', refresh)+ nativeTheme.off('updated', refresh)+ app.off('browser-window-focus', refresh)+ },+ }+}diff --git a/src/renderer/components/add-task/advanced-panel.tsx b/src/renderer/components/add-task/advanced-panel.tsxindex 70656ff9..f7b8f675 100644--- a/src/renderer/components/add-task/advanced-panel.tsx+++ b/src/renderer/components/add-task/advanced-panel.tsx@@ -1,3 +1,4 @@+import { ChevronRightIcon, HelpIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {Collapsible,@@ -16,7 +17,6 @@ import { useByteFormat } from '@renderer/hooks/use-byte-format'import { cn } from '@renderer/lib/utils'import { EXTERNAL_URLS } from '@shared/external-urls'import type { AddTaskFormValues } from '@shared/schemas/add-task'-import { ChevronRight, CircleQuestionMark } from 'lucide-react'import { type ReactNode, useLayoutEffect, useState } from 'react'import { useFormContext, useWatch } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -44,7 +44,7 @@ export function AdvancedPanel() {/>}>- <ChevronRight+ <ChevronRightIconclassName={cn('h-3.5 w-3.5 transition-transform duration-150',open && 'rotate-90'@@ -112,7 +112,7 @@ function LinksAdvancedFields() {target="_blank"rel="noopener noreferrer">- <CircleQuestionMark className="size-4 hover:text-foreground" />+ <HelpIcon className="size-4 hover:text-foreground" /></a></>}diff --git a/src/renderer/components/add-task/drop-zone.tsx b/src/renderer/components/add-task/drop-zone.tsxindex 74322eeb..c355b784 100644--- a/src/renderer/components/add-task/drop-zone.tsx+++ b/src/renderer/components/add-task/drop-zone.tsx@@ -1,3 +1,4 @@+import { ImportFileIcon } from '@renderer/components/icons'import {type ParsedTorrentFile,readTorrentFile,@@ -5,7 +6,6 @@ import {import { cn } from '@renderer/lib/utils'import { usePlatformServices } from '@renderer/platform/services'import type { AddTaskFormValues } from '@shared/schemas/add-task'-import { Upload } from 'lucide-react'import { useCallback, useRef, useState } from 'react'import { useFormContext } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -73,7 +73,10 @@ export function DropZone({dragOver ? 'border-ring bg-muted' : 'border-border hover:border-ring')}>- <Upload className="h-6 w-6 text-muted-foreground" aria-hidden="true" />+ <ImportFileIcon+ className="h-6 w-6 text-muted-foreground"+ aria-hidden="true"+ /><span className="text-sm text-muted-foreground">{t('task.add.dropTorrent')}{' '}<span className="font-medium text-foreground underline">diff --git a/src/renderer/components/add-task/file-type-filters.tsx b/src/renderer/components/add-task/file-type-filters.tsxindex 4290f3e6..d387d9f2 100644--- a/src/renderer/components/add-task/file-type-filters.tsx+++ b/src/renderer/components/add-task/file-type-filters.tsx@@ -1,3 +1,9 @@+import {+ AudioIcon,+ DocumentIcon,+ ImageIcon,+ VideoIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {Tooltip,@@ -7,7 +13,6 @@ import {} from '@renderer/components/ui/tooltip'import { VIDEO_FILE_EXTENSIONS } from '@shared/constants/file-types'import type { AddTaskFormValues } from '@shared/schemas/add-task'-import { FileText, Film, Image, Music } from 'lucide-react'import type { ReactNode } from 'react'import { useFormContext, useWatch } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -19,22 +24,22 @@ const FILTERS: Array<{}> = [{id: 'video',- icon: <Film className="h-3.5 w-3.5" />,+ icon: <VideoIcon className="h-3.5 w-3.5" />,exts: [...VIDEO_FILE_EXTENSIONS],},{id: 'audio',- icon: <Music className="h-3.5 w-3.5" />,+ icon: <AudioIcon className="h-3.5 w-3.5" />,exts: ['.mp3', '.flac', '.aac', '.ogg', '.wav', '.wma', '.m4a', '.opus'],},{id: 'image',- icon: <Image className="h-3.5 w-3.5" />,+ icon: <ImageIcon className="h-3.5 w-3.5" />,exts: ['.jpg', '.jpeg', '.png', '.gif', '.bmp', '.webp', '.svg', '.ico'],},{id: 'doc',- icon: <FileText className="h-3.5 w-3.5" />,+ icon: <DocumentIcon className="h-3.5 w-3.5" />,exts: ['.pdf', '.doc', '.docx', '.txt', '.epub', '.mobi', '.rtf', '.md'],},]diff --git a/src/renderer/components/add-task/torrent-info-header.tsx b/src/renderer/components/add-task/torrent-info-header.tsxindex b62d999c..941d1983 100644--- a/src/renderer/components/add-task/torrent-info-header.tsx+++ b/src/renderer/components/add-task/torrent-info-header.tsx@@ -1,7 +1,7 @@+import { CloseIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { useByteFormat } from '@renderer/hooks/use-byte-format'import type { AddTaskFormValues } from '@shared/schemas/add-task'-import { X } from 'lucide-react'import { useWatch } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -40,7 +40,7 @@ export function TorrentInfoHeader({ onClear }: TorrentInfoHeaderProps) {aria-label={t('task.add.clearSelection')}className="h-6 w-6">- <X className="h-3.5 w-3.5" aria-hidden="true" />+ <CloseIcon className="h-3.5 w-3.5" aria-hidden="true" /></Button></div>)diff --git a/src/renderer/components/add-task/url-diagnostic.tsx b/src/renderer/components/add-task/url-diagnostic.tsxindex 8838fbca..c6e5adc6 100644--- a/src/renderer/components/add-task/url-diagnostic.tsx+++ b/src/renderer/components/add-task/url-diagnostic.tsx@@ -1,3 +1,4 @@+import { StatusErrorIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {Popover,@@ -11,7 +12,6 @@ import {} from '@renderer/components/ui/tooltip'import type { DownloadInputLine } from '@shared/lib/download-source-input'import type { SourceCorrection } from '@shared/schemas/download-source'-import { CircleAlert } from 'lucide-react'import { useState } from 'react'import { useTranslation } from 'react-i18next'@@ -63,7 +63,7 @@ export function UrlDiagnostic({}onClick={corrections.length ? undefined : () => onEdit(line)}>- <CircleAlert className="size-3.5" aria-hidden="true" />+ <StatusErrorIcon className="size-3.5" aria-hidden="true" /></TooltipTrigger><TooltipContentside={wrapped ? 'bottom' : 'top'}diff --git a/src/renderer/components/desktop-kit/copy-button.tsx b/src/renderer/components/desktop-kit/copy-button.tsxindex 80858b10..ade5d534 100644--- a/src/renderer/components/desktop-kit/copy-button.tsx+++ b/src/renderer/components/desktop-kit/copy-button.tsx@@ -1,5 +1,5 @@+import { CheckIcon, CopyIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'-import { Check, Copy } from 'lucide-react'import {type ComponentProps,type ReactNode,@@ -63,7 +63,7 @@ export function CopyButton({}, resetMs)}, [content, onClick, onCopyError, resetMs])- const Icon = copied ? Check : Copy+ const Icon = copied ? CheckIcon : CopyIconreturn (<Button type="button" onClick={handleClick} {...rest}>diff --git a/src/renderer/components/desktop-kit/cubic-glass/cubic-glass-motion-lab.tsx b/src/renderer/components/desktop-kit/cubic-glass/cubic-glass-motion-lab.tsxindex 083c873d..f2f77494 100644--- a/src/renderer/components/desktop-kit/cubic-glass/cubic-glass-motion-lab.tsx+++ b/src/renderer/components/desktop-kit/cubic-glass/cubic-glass-motion-lab.tsx@@ -1,3 +1,4 @@+import { AdjustIcon, ResetIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { Label } from '@renderer/components/ui/label'import {@@ -8,7 +9,6 @@ import {import { Separator } from '@renderer/components/ui/separator'import { Slider } from '@renderer/components/ui/slider'import { Switch } from '@renderer/components/ui/switch'-import { RotateCcw, SlidersHorizontal } from 'lucide-react'import { useId } from 'react'import { useTranslation } from 'react-i18next'import { DEFAULT_CUBIC_GLASS_EFFECTS } from './config'@@ -83,7 +83,7 @@ export function CubicGlassMotionLab({/>}>- <SlidersHorizontal aria-hidden className="size-3.5" />+ <AdjustIcon aria-hidden className="size-3.5" /></PopoverTrigger><PopoverContentalign="end"@@ -109,7 +109,7 @@ export function CubicGlassMotionLab({onEffectsChange({ ...DEFAULT_CUBIC_GLASS_EFFECTS })}>- <RotateCcw aria-hidden />+ <ResetIcon aria-hidden /></Button></div>diff --git a/src/renderer/components/desktop-kit/directory-history-menu.tsx b/src/renderer/components/desktop-kit/directory-history-menu.tsxindex 43a4857d..97e6626f 100644--- a/src/renderer/components/desktop-kit/directory-history-menu.tsx+++ b/src/renderer/components/desktop-kit/directory-history-menu.tsx@@ -1,3 +1,8 @@+import {+ CheckIcon,+ DirectoryPreferencesIcon,+ HistoryIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {DropdownMenu,@@ -14,7 +19,6 @@ import {useServerDirectoryLocations,} from '@renderer/lib/directory-preferences'import { usePlatformServices } from '@renderer/platform/services'-import { Check, History, Settings2 } from 'lucide-react'import {type KeyboardEvent,type RefObject,@@ -81,7 +85,7 @@ export function DirectoryHistoryMenu({title={t('directoryPreferences.history')}className="h-auto min-h-8 shrink-0">- <History aria-hidden="true" className="size-4" />+ <HistoryIcon aria-hidden="true" className="size-4" /></DropdownMenuTrigger><DropdownMenuContentref={popup}@@ -109,7 +113,7 @@ export function DirectoryHistoryMenu({)}<DropdownMenuSeparator /><DropdownMenuItem onClick={openManager}>- <Settings2 aria-hidden="true" />+ <DirectoryPreferencesIcon aria-hidden="true" />{t('directoryPreferences.manage')}</DropdownMenuItem></>@@ -203,7 +207,7 @@ function HistoryItems({className="items-start text-xs"><span className="size-4 shrink-0">- {path === currentPath && <Check aria-hidden="true" />}+ {path === currentPath && <CheckIcon aria-hidden="true" />}</span><span className="min-w-0 whitespace-pre-wrap break-all">{path}diff --git a/src/renderer/components/desktop-kit/directory-picker.tsx b/src/renderer/components/desktop-kit/directory-picker.tsxindex cdb7c3a7..03ff19b4 100644--- a/src/renderer/components/desktop-kit/directory-picker.tsx+++ b/src/renderer/components/desktop-kit/directory-picker.tsx@@ -1,8 +1,8 @@+import { FolderIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { Input } from '@renderer/components/ui/input'import { recordRecentDirectory } from '@renderer/lib/directory-preferences'import { usePlatformServices } from '@renderer/platform/services'-import { Folder } from 'lucide-react'import { type ComponentProps, useEffect, useRef, useState } from 'react'import {type FieldPath,@@ -123,7 +123,7 @@ export function DirectoryPicker<TFields extends FieldValues>({{placeholder ?? t('settings.common.directoryEmpty')}</span>)}- <Folder+ <FolderIconclassName="h-4 w-4 shrink-0 text-muted-foreground"aria-hidden="true"/>@@ -153,7 +153,7 @@ export function DirectoryPicker<TFields extends FieldValues>({onClick={handlePick}disabled={pickerDisabled}>- <Folder className="mr-1 h-3 w-3" />+ <FolderIcon className="mr-1 h-3 w-3" />{t('settings.common.browse')}</Button>{history}diff --git a/src/renderer/components/desktop-kit/panel/header-action-button.test.tsx b/src/renderer/components/desktop-kit/panel/header-action-button.test.tsxindex c226cf68..5087817c 100644--- a/src/renderer/components/desktop-kit/panel/header-action-button.test.tsx+++ b/src/renderer/components/desktop-kit/panel/header-action-button.test.tsx@@ -1,7 +1,7 @@import '@testing-library/jest-dom/vitest'+import { AddIcon } from '@renderer/components/icons'import { SidebarProvider } from '@renderer/components/ui/sidebar'import { fireEvent, render, screen } from '@testing-library/react'-import { Plus } from 'lucide-react'import { afterEach, describe, expect, it, vi } from 'vitest'import { HeaderActionButton } from './header-action-button'@@ -36,7 +36,7 @@ describe('HeaderActionButton', () => {const onClick = vi.fn()render(<HeaderActionButton label="Install" onClick={onClick}>- <Plus aria-hidden />+ <AddIcon aria-hidden /></HeaderActionButton>)@@ -54,7 +54,7 @@ describe('HeaderActionButton', () => {visibleLabel="Custom"onClick={() => {}}>- <Plus aria-hidden />+ <AddIcon aria-hidden /></HeaderActionButton>)@@ -69,7 +69,7 @@ describe('HeaderActionButton', () => {label="Add"wrapTrigger={(button) => <div data-testid="trigger-slot">{button}</div>}>- <Plus aria-hidden />+ <AddIcon aria-hidden /></HeaderActionButton>)@@ -83,7 +83,7 @@ describe('HeaderActionButton', () => {render(<SidebarProvider defaultOpen={false}><HeaderActionButton label="Install" onClick={() => {}}>- <Plus aria-hidden />+ <AddIcon aria-hidden /></HeaderActionButton></SidebarProvider>)diff --git a/src/renderer/components/desktop-kit/sidebar/app-sidebar.tsx b/src/renderer/components/desktop-kit/sidebar/app-sidebar.tsxindex 3c67d1ce..217c7716 100644--- a/src/renderer/components/desktop-kit/sidebar/app-sidebar.tsx+++ b/src/renderer/components/desktop-kit/sidebar/app-sidebar.tsx@@ -1,3 +1,11 @@+import type { MotrixIcon } from '@renderer/components/icons'+import {+ DashboardIcon,+ DownloadLibraryIcon,+ PluginIcon,+ SettingsIcon,+ TrackerIcon,+} from '@renderer/components/icons'import { NotificationsNavItem } from '@renderer/components/notification-center/notifications-nav-item'import {Sidebar,@@ -11,33 +19,25 @@ import {SidebarMenuItem,SidebarSeparator,} from '@renderer/components/ui/sidebar'-import type { LucideIcon } from 'lucide-react'-import {- Download,- LayoutDashboard,- RadioTower,- Settings,- ToyBrick,-} from 'lucide-react'import { useTranslation } from 'react-i18next'import { NavLink } from 'react-router'interface NavItem {to: string- icon: LucideIcon+ icon: MotrixIconlabelKey: stringend?: boolean}const NAV_ITEMS: readonly NavItem[] = [- { to: '/', icon: LayoutDashboard, labelKey: 'nav.dashboard', end: true },- { to: '/downloads', icon: Download, labelKey: 'nav.downloads' },- { to: '/trackers', icon: RadioTower, labelKey: 'nav.trackers' },- { to: '/plugins', icon: ToyBrick, labelKey: 'nav.plugins' },+ { to: '/', icon: DashboardIcon, labelKey: 'nav.dashboard', end: true },+ { to: '/downloads', icon: DownloadLibraryIcon, labelKey: 'nav.downloads' },+ { to: '/trackers', icon: TrackerIcon, labelKey: 'nav.trackers' },+ { to: '/plugins', icon: PluginIcon, labelKey: 'nav.plugins' },] as constconst FOOTER_NAV_ITEMS: readonly NavItem[] = [- { to: '/settings', icon: Settings, labelKey: 'nav.settings' },+ { to: '/settings', icon: SettingsIcon, labelKey: 'nav.settings' },] as constexport function AppSidebar({ ...props }: React.ComponentProps<typeof Sidebar>) {diff --git a/src/renderer/components/desktop-kit/sidebar/nav-main.tsx b/src/renderer/components/desktop-kit/sidebar/nav-main.tsxindex 19fc396a..380f0590 100644--- a/src/renderer/components/desktop-kit/sidebar/nav-main.tsx+++ b/src/renderer/components/desktop-kit/sidebar/nav-main.tsx@@ -1,3 +1,4 @@+import { ChevronRightIcon, type MotrixIcon } from '@renderer/components/icons'import {Collapsible,CollapsibleContent,@@ -14,7 +15,6 @@ import {SidebarMenuSubButton,SidebarMenuSubItem,} from '@renderer/components/ui/sidebar'-import { ChevronRight, type LucideIcon } from 'lucide-react'export function NavMain({items,@@ -22,7 +22,7 @@ export function NavMain({items: {title: stringurl: string- icon: LucideIcon+ icon: MotrixIconisActive?: booleanitems?: {title: string@@ -54,7 +54,7 @@ export function NavMain({<SidebarMenuAction className="data-panel-open:rotate-90" />}>- <ChevronRight />+ <ChevronRightIcon /><span className="sr-only">Toggle</span></CollapsibleTrigger><CollapsibleContent>diff --git a/src/renderer/components/desktop-kit/sidebar/nav-projects.tsx b/src/renderer/components/desktop-kit/sidebar/nav-projects.tsxindex a7fbfeb0..2fb92afb 100644--- a/src/renderer/components/desktop-kit/sidebar/nav-projects.tsx+++ b/src/renderer/components/desktop-kit/sidebar/nav-projects.tsx@@ -1,5 +1,12 @@'use client'+import {+ FolderIcon,+ MoreIcon,+ type MotrixIcon,+ RemoveIcon,+ ShareIcon,+} from '@renderer/components/icons'import {DropdownMenu,DropdownMenuContent,@@ -16,13 +23,6 @@ import {SidebarMenuItem,useSidebar,} from '@renderer/components/ui/sidebar'-import {- Folder,- type LucideIcon,- MoreHorizontal,- Share,- Trash2,-} from 'lucide-react'export function NavProjects({projects,@@ -30,7 +30,7 @@ export function NavProjects({projects: {name: stringurl: string- icon: LucideIcon+ icon: MotrixIcon}[]}) {const { isMobile } = useSidebar()@@ -47,7 +47,7 @@ export function NavProjects({</SidebarMenuButton><DropdownMenu><DropdownMenuTrigger render={<SidebarMenuAction showOnHover />}>- <MoreHorizontal />+ <MoreIcon /><span className="sr-only">More</span></DropdownMenuTrigger><DropdownMenuContent@@ -56,16 +56,16 @@ export function NavProjects({align={isMobile ? 'end' : 'start'}><DropdownMenuItem>- <Folder className="text-muted-foreground" />+ <FolderIcon className="text-muted-foreground" /><span>View Project</span></DropdownMenuItem><DropdownMenuItem>- <Share className="text-muted-foreground" />+ <ShareIcon className="text-muted-foreground" /><span>Share Project</span></DropdownMenuItem><DropdownMenuSeparator /><DropdownMenuItem>- <Trash2 className="text-muted-foreground" />+ <RemoveIcon className="text-muted-foreground" /><span>Delete Project</span></DropdownMenuItem></DropdownMenuContent>@@ -74,7 +74,7 @@ export function NavProjects({))}<SidebarMenuItem><SidebarMenuButton>- <MoreHorizontal />+ <MoreIcon /><span>More</span></SidebarMenuButton></SidebarMenuItem>diff --git a/src/renderer/components/desktop-kit/sidebar/nav-secondary.tsx b/src/renderer/components/desktop-kit/sidebar/nav-secondary.tsxindex 2d5882e6..e6fefe14 100644--- a/src/renderer/components/desktop-kit/sidebar/nav-secondary.tsx+++ b/src/renderer/components/desktop-kit/sidebar/nav-secondary.tsx@@ -1,3 +1,4 @@+import type { MotrixIcon } from '@renderer/components/icons'import {SidebarGroup,SidebarGroupContent,@@ -5,7 +6,6 @@ import {SidebarMenuButton,SidebarMenuItem,} from '@renderer/components/ui/sidebar'-import type { LucideIcon } from 'lucide-react'import type * as React from 'react'export function NavSecondary({@@ -15,7 +15,7 @@ export function NavSecondary({items: {title: stringurl: string- icon: LucideIcon+ icon: MotrixIcon}[]} & React.ComponentPropsWithoutRef<typeof SidebarGroup>) {return (diff --git a/src/renderer/components/desktop-kit/sidebar/nav-user.tsx b/src/renderer/components/desktop-kit/sidebar/nav-user.tsxindex 8a3d76a5..ef6d0128 100644--- a/src/renderer/components/desktop-kit/sidebar/nav-user.tsx+++ b/src/renderer/components/desktop-kit/sidebar/nav-user.tsx@@ -1,3 +1,11 @@+import {+ BillingIcon,+ ChevronsUpDownIcon,+ NotificationsIcon,+ SignOutIcon,+ UpgradeIcon,+ VerifiedToolIcon,+} from '@renderer/components/icons'import {Avatar,AvatarFallback,@@ -18,14 +26,6 @@ import {SidebarMenuItem,useSidebar,} from '@renderer/components/ui/sidebar'-import {- BadgeCheck,- Bell,- ChevronsUpDown,- CreditCard,- LogOut,- Sparkles,-} from 'lucide-react'export function NavUser({user,@@ -58,7 +58,7 @@ export function NavUser({<span className="truncate font-medium">{user.name}</span><span className="truncate text-xs">{user.email}</span></div>- <ChevronsUpDown className="ml-auto size-4" />+ <ChevronsUpDownIcon className="ml-auto size-4" /></DropdownMenuTrigger><DropdownMenuContentclassName="w-(--anchor-width) min-w-56 rounded-lg"@@ -81,28 +81,28 @@ export function NavUser({</DropdownMenuLabel><DropdownMenuSeparator /><DropdownMenuItem>- <Sparkles />+ <UpgradeIcon />Upgrade to Pro</DropdownMenuItem></DropdownMenuGroup><DropdownMenuSeparator /><DropdownMenuGroup><DropdownMenuItem>- <BadgeCheck />+ <VerifiedToolIcon />Account</DropdownMenuItem><DropdownMenuItem>- <CreditCard />+ <BillingIcon />Billing</DropdownMenuItem><DropdownMenuItem>- <Bell />+ <NotificationsIcon />Notifications</DropdownMenuItem></DropdownMenuGroup><DropdownMenuSeparator /><DropdownMenuItem>- <LogOut />+ <SignOutIcon />Log out</DropdownMenuItem></DropdownMenuContent>diff --git a/src/renderer/components/desktop-kit/toolbar/toolbar-search.tsx b/src/renderer/components/desktop-kit/toolbar/toolbar-search.tsxindex 56cf1719..a012d0cd 100644--- a/src/renderer/components/desktop-kit/toolbar/toolbar-search.tsx+++ b/src/renderer/components/desktop-kit/toolbar/toolbar-search.tsx@@ -1,6 +1,6 @@import { Toolbar as ToolbarPrimitive } from '@base-ui/react/toolbar'+import { SearchIcon, StatusFailedIcon } from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'-import { CircleX, Search } from 'lucide-react'import {type ReactNode,type RefObject,@@ -116,7 +116,7 @@ export function ToolbarSearch({{leading ? (leading({ anchorRef: rootRef, collapseIfIdle })) : (- <Search+ <SearchIconaria-hidden="true"className="mx-2 size-4 shrink-0 text-muted-foreground"/>@@ -154,7 +154,7 @@ export function ToolbarSearch({inputRef.current?.focus()}}>- <CircleX aria-hidden="true" />+ <StatusFailedIcon aria-hidden="true" /></ToolbarButton>)}</>@@ -168,7 +168,7 @@ export function ToolbarSearch({requestExpanded(true)}}>- <Search aria-hidden="true" />+ <SearchIcon aria-hidden="true" /></ToolbarButton>)}</ToolbarGroup>diff --git a/src/renderer/components/icons/README.md b/src/renderer/components/icons/README.mdnew file mode 100644index 00000000..2e6bfc10--- /dev/null+++ b/src/renderer/components/icons/README.md@@ -0,0 +1,11 @@+# Motrix icons++Import semantic components and the `MotrixIcon` / `MotrixIconProps` types from this directory. Use those names directly in consumers, such as `SpeedUnlimitedIcon`, instead of aliases tied to a particular glyph or library. Domain roles may share a drawing while remaining independently replaceable: download navigation, active downloads and installation all currently use Lucide's Download.++`MotrixIconProps` belongs to Motrix: standard SVG attributes plus `size` and an accessible `title`. `create-icon.tsx` has no icon-library dependency. It accepts a ref-capable glyph component and its set identifier. The glyph handles `size` and retains its own viewBox, geometry, color and stroke defaults. Library-specific options belong inside its adapter, not in the shared public type. Lucide mappings currently preserve native defaults and provider settings; speed modes use Rabbit, Turtle and Squirrel.++To replace an icon, change its semantic module to import the new glyph and pass it to `createIcon`. For a raw SVG, provide a component that forwards its SVG ref/props/children, maps `size` to width and height, and preserves its native viewBox. A different library may need a small adapter to match that contract. Business components and tests continue to use the semantic name. There is no runtime registry or size observer.++Every module uses a static import and marks the `createIcon(...)` call with `/* @__PURE__ */`. Keep the factory free of external side effects and retain that annotation so bundlers can remove unused mappings and glyphs from the barrel. `tests/scripts/icon-tree-shaking.test.ts` uses the renderer's Vite configuration to verify that importing DownloadIcon includes only its Lucide glyph.++Icons are decorative by default. Supply a translated `title`, `aria-label` or `aria-labelledby` for a standalone meaningful image. SVG props, classes, children and refs are forwarded. `data-icon` identifies the semantic role; callers may override it for existing slot styling. `data-icon-set` identifies the implementation. The SVG keeps the `motrix-icon` class and the underlying library's classes, but consumers should not depend on library-specific classes or SVG paths.diff --git a/src/renderer/components/icons/activity.tsx b/src/renderer/components/icons/activity.tsxnew file mode 100644index 00000000..057589f2--- /dev/null+++ b/src/renderer/components/icons/activity.tsx@@ -0,0 +1,8 @@+import { SquareActivity } from 'lucide-react'+import { createIcon } from './create-icon'++export const ActivityIcon = /* @__PURE__ */ createIcon(+ 'activity',+ SquareActivity,+ 'lucide'+)diff --git a/src/renderer/components/icons/add.tsx b/src/renderer/components/icons/add.tsxnew file mode 100644index 00000000..7b07032c--- /dev/null+++ b/src/renderer/components/icons/add.tsx@@ -0,0 +1,4 @@+import { Plus } from 'lucide-react'+import { createIcon } from './create-icon'++export const AddIcon = /* @__PURE__ */ createIcon('add', Plus, 'lucide')diff --git a/src/renderer/components/icons/adjust.tsx b/src/renderer/components/icons/adjust.tsxnew file mode 100644index 00000000..be620219--- /dev/null+++ b/src/renderer/components/icons/adjust.tsx@@ -0,0 +1,8 @@+import { SlidersHorizontal } from 'lucide-react'+import { createIcon } from './create-icon'++export const AdjustIcon = /* @__PURE__ */ createIcon(+ 'adjust',+ SlidersHorizontal,+ 'lucide'+)diff --git a/src/renderer/components/icons/arrow-down-left.tsx b/src/renderer/components/icons/arrow-down-left.tsxnew file mode 100644index 00000000..19be8cf9--- /dev/null+++ b/src/renderer/components/icons/arrow-down-left.tsx@@ -0,0 +1,8 @@+import { ArrowDownLeft } from 'lucide-react'+import { createIcon } from './create-icon'++export const ArrowDownLeftIcon = /* @__PURE__ */ createIcon(+ 'arrow-down-left',+ ArrowDownLeft,+ 'lucide'+)diff --git a/src/renderer/components/icons/arrow-left.tsx b/src/renderer/components/icons/arrow-left.tsxnew file mode 100644index 00000000..ec0f16f5--- /dev/null+++ b/src/renderer/components/icons/arrow-left.tsx@@ -0,0 +1,8 @@+import { ArrowLeft } from 'lucide-react'+import { createIcon } from './create-icon'++export const ArrowLeftIcon = /* @__PURE__ */ createIcon(+ 'arrow-left',+ ArrowLeft,+ 'lucide'+)diff --git a/src/renderer/components/icons/arrow-right.tsx b/src/renderer/components/icons/arrow-right.tsxnew file mode 100644index 00000000..4ee69afb--- /dev/null+++ b/src/renderer/components/icons/arrow-right.tsx@@ -0,0 +1,8 @@+import { ArrowRight } from 'lucide-react'+import { createIcon } from './create-icon'++export const ArrowRightIcon = /* @__PURE__ */ createIcon(+ 'arrow-right',+ ArrowRight,+ 'lucide'+)diff --git a/src/renderer/components/icons/arrow-up-right.tsx b/src/renderer/components/icons/arrow-up-right.tsxnew file mode 100644index 00000000..8de85353--- /dev/null+++ b/src/renderer/components/icons/arrow-up-right.tsx@@ -0,0 +1,8 @@+import { ArrowUpRight } from 'lucide-react'+import { createIcon } from './create-icon'++export const ArrowUpRightIcon = /* @__PURE__ */ createIcon(+ 'arrow-up-right',+ ArrowUpRight,+ 'lucide'+)diff --git a/src/renderer/components/icons/attach.tsx b/src/renderer/components/icons/attach.tsxnew file mode 100644index 00000000..ad75cb1e--- /dev/null+++ b/src/renderer/components/icons/attach.tsx@@ -0,0 +1,8 @@+import { Paperclip } from 'lucide-react'+import { createIcon } from './create-icon'++export const AttachIcon = /* @__PURE__ */ createIcon(+ 'attach',+ Paperclip,+ 'lucide'+)diff --git a/src/renderer/components/icons/audio.tsx b/src/renderer/components/icons/audio.tsxnew file mode 100644index 00000000..d940c330--- /dev/null+++ b/src/renderer/components/icons/audio.tsx@@ -0,0 +1,4 @@+import { Music } from 'lucide-react'+import { createIcon } from './create-icon'++export const AudioIcon = /* @__PURE__ */ createIcon('audio', Music, 'lucide')diff --git a/src/renderer/components/icons/billing.tsx b/src/renderer/components/icons/billing.tsxnew file mode 100644index 00000000..be413d6d--- /dev/null+++ b/src/renderer/components/icons/billing.tsx@@ -0,0 +1,8 @@+import { CreditCard } from 'lucide-react'+import { createIcon } from './create-icon'++export const BillingIcon = /* @__PURE__ */ createIcon(+ 'billing',+ CreditCard,+ 'lucide'+)diff --git a/src/renderer/components/icons/call-graph.tsx b/src/renderer/components/icons/call-graph.tsxnew file mode 100644index 00000000..f3e744a2--- /dev/null+++ b/src/renderer/components/icons/call-graph.tsx@@ -0,0 +1,8 @@+import { Workflow } from 'lucide-react'+import { createIcon } from './create-icon'++export const CallGraphIcon = /* @__PURE__ */ createIcon(+ 'call-graph',+ Workflow,+ 'lucide'+)diff --git a/src/renderer/components/icons/changelog.tsx b/src/renderer/components/icons/changelog.tsxnew file mode 100644index 00000000..58899446--- /dev/null+++ b/src/renderer/components/icons/changelog.tsx@@ -0,0 +1,8 @@+import { ScrollText } from 'lucide-react'+import { createIcon } from './create-icon'++export const ChangelogIcon = /* @__PURE__ */ createIcon(+ 'changelog',+ ScrollText,+ 'lucide'+)diff --git a/src/renderer/components/icons/check.tsx b/src/renderer/components/icons/check.tsxnew file mode 100644index 00000000..e146f2c9--- /dev/null+++ b/src/renderer/components/icons/check.tsx@@ -0,0 +1,4 @@+import { Check } from 'lucide-react'+import { createIcon } from './create-icon'++export const CheckIcon = /* @__PURE__ */ createIcon('check', Check, 'lucide')diff --git a/src/renderer/components/icons/chevron-down.tsx b/src/renderer/components/icons/chevron-down.tsxnew file mode 100644index 00000000..08b24cfc--- /dev/null+++ b/src/renderer/components/icons/chevron-down.tsx@@ -0,0 +1,8 @@+import { ChevronDown } from 'lucide-react'+import { createIcon } from './create-icon'++export const ChevronDownIcon = /* @__PURE__ */ createIcon(+ 'chevron-down',+ ChevronDown,+ 'lucide'+)diff --git a/src/renderer/components/icons/chevron-left.tsx b/src/renderer/components/icons/chevron-left.tsxnew file mode 100644index 00000000..438fb728--- /dev/null+++ b/src/renderer/components/icons/chevron-left.tsx@@ -0,0 +1,8 @@+import { ChevronLeft } from 'lucide-react'+import { createIcon } from './create-icon'++export const ChevronLeftIcon = /* @__PURE__ */ createIcon(+ 'chevron-left',+ ChevronLeft,+ 'lucide'+)diff --git a/src/renderer/components/icons/chevron-right.tsx b/src/renderer/components/icons/chevron-right.tsxnew file mode 100644index 00000000..506d1f8c--- /dev/null+++ b/src/renderer/components/icons/chevron-right.tsx@@ -0,0 +1,8 @@+import { ChevronRight } from 'lucide-react'+import { createIcon } from './create-icon'++export const ChevronRightIcon = /* @__PURE__ */ createIcon(+ 'chevron-right',+ ChevronRight,+ 'lucide'+)diff --git a/src/renderer/components/icons/chevron-up.tsx b/src/renderer/components/icons/chevron-up.tsxnew file mode 100644index 00000000..69918e3c--- /dev/null+++ b/src/renderer/components/icons/chevron-up.tsx@@ -0,0 +1,8 @@+import { ChevronUp } from 'lucide-react'+import { createIcon } from './create-icon'++export const ChevronUpIcon = /* @__PURE__ */ createIcon(+ 'chevron-up',+ ChevronUp,+ 'lucide'+)diff --git a/src/renderer/components/icons/chevrons-up-down.tsx b/src/renderer/components/icons/chevrons-up-down.tsxnew file mode 100644index 00000000..fc2eeca3--- /dev/null+++ b/src/renderer/components/icons/chevrons-up-down.tsx@@ -0,0 +1,8 @@+import { ChevronsUpDown } from 'lucide-react'+import { createIcon } from './create-icon'++export const ChevronsUpDownIcon = /* @__PURE__ */ createIcon(+ 'chevrons-up-down',+ ChevronsUpDown,+ 'lucide'+)diff --git a/src/renderer/components/icons/close.tsx b/src/renderer/components/icons/close.tsxnew file mode 100644index 00000000..16429870--- /dev/null+++ b/src/renderer/components/icons/close.tsx@@ -0,0 +1,4 @@+import { X } from 'lucide-react'+import { createIcon } from './create-icon'++export const CloseIcon = /* @__PURE__ */ createIcon('close', X, 'lucide')diff --git a/src/renderer/components/icons/columns.tsx b/src/renderer/components/icons/columns.tsxnew file mode 100644index 00000000..0e2db141--- /dev/null+++ b/src/renderer/components/icons/columns.tsx@@ -0,0 +1,8 @@+import { Columns3 } from 'lucide-react'+import { createIcon } from './create-icon'++export const ColumnsIcon = /* @__PURE__ */ createIcon(+ 'columns',+ Columns3,+ 'lucide'+)diff --git a/src/renderer/components/icons/conceal.tsx b/src/renderer/components/icons/conceal.tsxnew file mode 100644index 00000000..d52590a4--- /dev/null+++ b/src/renderer/components/icons/conceal.tsx@@ -0,0 +1,8 @@+import { EyeOff } from 'lucide-react'+import { createIcon } from './create-icon'++export const ConcealIcon = /* @__PURE__ */ createIcon(+ 'conceal',+ EyeOff,+ 'lucide'+)diff --git a/src/renderer/components/icons/connections.tsx b/src/renderer/components/icons/connections.tsxnew file mode 100644index 00000000..21493998--- /dev/null+++ b/src/renderer/components/icons/connections.tsx@@ -0,0 +1,8 @@+import { Split } from 'lucide-react'+import { createIcon } from './create-icon'++export const ConnectionsIcon = /* @__PURE__ */ createIcon(+ 'connections',+ Split,+ 'lucide'+)diff --git a/src/renderer/components/icons/copy-link.tsx b/src/renderer/components/icons/copy-link.tsxnew file mode 100644index 00000000..9dc8d2b7--- /dev/null+++ b/src/renderer/components/icons/copy-link.tsx@@ -0,0 +1,8 @@+import { Link } from 'lucide-react'+import { createIcon } from './create-icon'++export const CopyLinkIcon = /* @__PURE__ */ createIcon(+ 'copy-link',+ Link,+ 'lucide'+)diff --git a/src/renderer/components/icons/copy.tsx b/src/renderer/components/icons/copy.tsxnew file mode 100644index 00000000..4e91171d--- /dev/null+++ b/src/renderer/components/icons/copy.tsx@@ -0,0 +1,4 @@+import { Copy } from 'lucide-react'+import { createIcon } from './create-icon'++export const CopyIcon = /* @__PURE__ */ createIcon('copy', Copy, 'lucide')diff --git a/src/renderer/components/icons/create-icon.test.tsx b/src/renderer/components/icons/create-icon.test.tsxnew file mode 100644index 00000000..9a78ea51--- /dev/null+++ b/src/renderer/components/icons/create-icon.test.tsx@@ -0,0 +1,122 @@+import '@testing-library/jest-dom/vitest'+import { cleanup, render, screen } from '@testing-library/react'+import { LucideProvider } from 'lucide-react'+import { createRef, forwardRef } from 'react'+import { afterEach, describe, expect, it } from 'vitest'+import { createIcon, type MotrixIconProps } from './create-icon'+import { DownloadIcon } from './download'+import { SpeedAutoIcon } from './speed-auto'++afterEach(cleanup)++describe('Motrix Lucide icons', () => {+ it('keeps the Lucide drawing and stroke when displayed at a compact size', () => {+ const { container } = render(+ <SpeedAutoIcon size={12} style={{ width: 12, height: 12 }} />+ )+ const svg = container.querySelector('svg')+ expect(svg).toHaveAttribute('viewBox', '0 0 24 24')+ expect(svg).toHaveAttribute('width', '12')+ expect(svg).toHaveAttribute('stroke-width', '2')+ expect(svg).toHaveClass('lucide-squirrel', 'motrix-icon')+ expect(svg).toHaveAttribute('data-icon', 'speed-auto')+ expect(svg).toHaveAttribute('data-icon-set', 'lucide')+ })++ it('preserves Lucide provider defaults and caller overrides', () => {+ const { container, rerender } = render(+ <LucideProvider size={20} color="red" strokeWidth={1.5}>+ <DownloadIcon />+ </LucideProvider>+ )+ const svg = container.querySelector('svg')!+ expect(svg).toHaveAttribute('width', '20')+ expect(svg).toHaveAttribute('stroke', 'red')+ expect(svg).toHaveAttribute('stroke-width', '1.5')++ rerender(+ <LucideProvider size={20} color="red" strokeWidth={1.5}>+ <DownloadIcon+ size={16}+ color="currentColor"+ strokeWidth={1.75}+ focusable="false"+ data-icon="inline-start"+ />+ </LucideProvider>+ )+ expect(svg).toHaveAttribute('width', '16')+ expect(svg).toHaveAttribute('stroke', 'currentColor')+ expect(svg).toHaveAttribute('stroke-width', '1.75')+ expect(svg).toHaveAttribute('data-icon', 'inline-start')+ expect(svg).toHaveAttribute('focusable', 'false')+ })++ it('accepts a custom SVG glyph without a Lucide contract', () => {+ const Glyph = forwardRef<SVGSVGElement, MotrixIconProps>(function Glyph(+ { size = 24, ...props },+ ref+ ) {+ return (+ // biome-ignore lint/a11y/noSvgWithoutTitle: The icon wrapper supplies the accessible name.+ <svg+ ref={ref}+ width={size}+ height={size}+ viewBox="0 0 20 20"+ fill="currentColor"+ {...props}+ >+ <circle cx="10" cy="10" r="6" />+ {props.children}+ </svg>+ )+ })+ const CustomIcon = createIcon('status-dot', Glyph, 'custom')+ const ref = createRef<SVGSVGElement>()+ render(<CustomIcon ref={ref} size={16} title="Custom status" />)+ expect(screen.getByRole('img', { name: 'Custom status' })).toBe(ref.current)+ expect(ref.current).toHaveAttribute('viewBox', '0 0 20 20')+ expect(ref.current).toHaveAttribute('width', '16')+ expect(ref.current).toHaveAttribute('data-icon', 'status-dot')+ expect(ref.current).toHaveAttribute('data-icon-set', 'custom')+ expect(ref.current).toHaveAttribute('fill', 'currentColor')+ expect(ref.current).not.toHaveClass('lucide')+ })++ it('exposes translated titles and forwards refs and SVG attributes', () => {+ const ref = createRef<SVGSVGElement>()+ render(+ <DownloadIcon+ ref={ref}+ title="Download"+ size={20}+ data-testid="download-icon"+ className="animate-spin"+ />+ )+ expect(screen.getByRole('img', { name: 'Download' })).toBe(ref.current)+ expect(ref.current).toHaveAttribute('viewBox', '0 0 24 24')+ expect(ref.current).toHaveAttribute('width', '20')+ expect(ref.current).toHaveClass('animate-spin', 'motrix-icon', 'lucide')+ expect(ref.current).not.toHaveAttribute('aria-hidden')+ })++ it('hides decorative symbols and accepts explicit accessible labels', () => {+ const { rerender } = render(<DownloadIcon data-testid="icon" />)+ expect(screen.getByTestId('icon')).toHaveAttribute('aria-hidden', 'true')+ rerender(<DownloadIcon aria-label="Download" />)+ expect(screen.getByRole('img', { name: 'Download' })).not.toHaveAttribute(+ 'aria-hidden'+ )+ rerender(+ <>+ <span id="download-label">Download file</span>+ <DownloadIcon aria-labelledby="download-label" />+ </>+ )+ expect(+ screen.getByRole('img', { name: 'Download file' })+ ).not.toHaveAttribute('aria-hidden')+ })+})diff --git a/src/renderer/components/icons/create-icon.tsx b/src/renderer/components/icons/create-icon.tsxnew file mode 100644index 00000000..5a1751a0--- /dev/null+++ b/src/renderer/components/icons/create-icon.tsx@@ -0,0 +1,53 @@+import { cn } from '@renderer/lib/utils'+import {+ type ComponentPropsWithoutRef,+ type ComponentType,+ type ForwardRefExoticComponent,+ forwardRef,+ type RefAttributes,+ useId,+} from 'react'++export type MotrixIconProps = ComponentPropsWithoutRef<'svg'> & {+ size?: number | string+ title?: string+}+export type MotrixIcon = ForwardRefExoticComponent<+ MotrixIconProps & RefAttributes<SVGSVGElement>+>+type IconGlyph = ComponentType<MotrixIconProps & RefAttributes<SVGSVGElement>>++// Keep creation free of side effects: callers mark it pure for tree shaking.+export function createIcon(+ name: string,+ Glyph: IconGlyph,+ iconSet: string+): MotrixIcon {+ const Icon = forwardRef<SVGSVGElement, MotrixIconProps>(function Icon(+ { title, className, children, ...props },+ ref+ ) {+ const id = useId()+ const named = Boolean(+ title || props['aria-label'] || props['aria-labelledby']+ )++ return (+ <Glyph+ ref={ref}+ className={cn('motrix-icon', className)}+ data-icon={name}+ data-icon-set={iconSet}+ aria-hidden={named ? undefined : true}+ role={named ? 'img' : undefined}+ aria-labelledby={title ? id : undefined}+ {...props}+ >+ {title ? <title id={id}>{title}</title> : null}+ {children}+ </Glyph>+ )+ })+ Icon.displayName = `MotrixIcon(${name})`+ return Icon+}diff --git a/src/renderer/components/icons/dashboard.tsx b/src/renderer/components/icons/dashboard.tsxnew file mode 100644index 00000000..73ec9908--- /dev/null+++ b/src/renderer/components/icons/dashboard.tsx@@ -0,0 +1,8 @@+import { LayoutDashboard } from 'lucide-react'+import { createIcon } from './create-icon'++export const DashboardIcon = /* @__PURE__ */ createIcon(+ 'dashboard',+ LayoutDashboard,+ 'lucide'+)diff --git a/src/renderer/components/icons/diagnostic-report.tsx b/src/renderer/components/icons/diagnostic-report.tsxnew file mode 100644index 00000000..c7da94f2--- /dev/null+++ b/src/renderer/components/icons/diagnostic-report.tsx@@ -0,0 +1,8 @@+import { FileText } from 'lucide-react'+import { createIcon } from './create-icon'++export const DiagnosticReportIcon = /* @__PURE__ */ createIcon(+ 'diagnostic-report',+ FileText,+ 'lucide'+)diff --git a/src/renderer/components/icons/diagnostics.tsx b/src/renderer/components/icons/diagnostics.tsxnew file mode 100644index 00000000..1aab6212--- /dev/null+++ b/src/renderer/components/icons/diagnostics.tsx@@ -0,0 +1,8 @@+import { Bug } from 'lucide-react'+import { createIcon } from './create-icon'++export const DiagnosticsIcon = /* @__PURE__ */ createIcon(+ 'diagnostics',+ Bug,+ 'lucide'+)diff --git a/src/renderer/components/icons/directory-preferences.tsx b/src/renderer/components/icons/directory-preferences.tsxnew file mode 100644index 00000000..8cd694e4--- /dev/null+++ b/src/renderer/components/icons/directory-preferences.tsx@@ -0,0 +1,8 @@+import { Settings2 } from 'lucide-react'+import { createIcon } from './create-icon'++export const DirectoryPreferencesIcon = /* @__PURE__ */ createIcon(+ 'directory-preferences',+ Settings2,+ 'lucide'+)diff --git a/src/renderer/components/icons/disk-cache.tsx b/src/renderer/components/icons/disk-cache.tsxnew file mode 100644index 00000000..514f0d22--- /dev/null+++ b/src/renderer/components/icons/disk-cache.tsx@@ -0,0 +1,8 @@+import { Database } from 'lucide-react'+import { createIcon } from './create-icon'++export const DiskCacheIcon = /* @__PURE__ */ createIcon(+ 'disk-cache',+ Database,+ 'lucide'+)diff --git a/src/renderer/components/icons/disk.tsx b/src/renderer/components/icons/disk.tsxnew file mode 100644index 00000000..33a912c6--- /dev/null+++ b/src/renderer/components/icons/disk.tsx@@ -0,0 +1,4 @@+import { HardDrive } from 'lucide-react'+import { createIcon } from './create-icon'++export const DiskIcon = /* @__PURE__ */ createIcon('disk', HardDrive, 'lucide')diff --git a/src/renderer/components/icons/document.tsx b/src/renderer/components/icons/document.tsxnew file mode 100644index 00000000..b065dcf3--- /dev/null+++ b/src/renderer/components/icons/document.tsx@@ -0,0 +1,8 @@+import { FileText } from 'lucide-react'+import { createIcon } from './create-icon'++export const DocumentIcon = /* @__PURE__ */ createIcon(+ 'document',+ FileText,+ 'lucide'+)diff --git a/src/renderer/components/icons/download-active.tsx b/src/renderer/components/icons/download-active.tsxnew file mode 100644index 00000000..217c3338--- /dev/null+++ b/src/renderer/components/icons/download-active.tsx@@ -0,0 +1,8 @@+import { Download } from 'lucide-react'+import { createIcon } from './create-icon'++export const DownloadActiveIcon = /* @__PURE__ */ createIcon(+ 'download-active',+ Download,+ 'lucide'+)diff --git a/src/renderer/components/icons/download-library.tsx b/src/renderer/components/icons/download-library.tsxnew file mode 100644index 00000000..ca6b6e11--- /dev/null+++ b/src/renderer/components/icons/download-library.tsx@@ -0,0 +1,8 @@+import { Download } from 'lucide-react'+import { createIcon } from './create-icon'++export const DownloadLibraryIcon = /* @__PURE__ */ createIcon(+ 'download-library',+ Download,+ 'lucide'+)diff --git a/src/renderer/components/icons/download.tsx b/src/renderer/components/icons/download.tsxnew file mode 100644index 00000000..567ad002--- /dev/null+++ b/src/renderer/components/icons/download.tsx@@ -0,0 +1,8 @@+import { Download } from 'lucide-react'+import { createIcon } from './create-icon'++export const DownloadIcon = /* @__PURE__ */ createIcon(+ 'download',+ Download,+ 'lucide'+)diff --git a/src/renderer/components/icons/drag.tsx b/src/renderer/components/icons/drag.tsxnew file mode 100644index 00000000..d9f8c9ef--- /dev/null+++ b/src/renderer/components/icons/drag.tsx@@ -0,0 +1,8 @@+import { GripVertical } from 'lucide-react'+import { createIcon } from './create-icon'++export const DragIcon = /* @__PURE__ */ createIcon(+ 'drag',+ GripVertical,+ 'lucide'+)diff --git a/src/renderer/components/icons/duration.tsx b/src/renderer/components/icons/duration.tsxnew file mode 100644index 00000000..b04c7ad5--- /dev/null+++ b/src/renderer/components/icons/duration.tsx@@ -0,0 +1,8 @@+import { Clock3 } from 'lucide-react'+import { createIcon } from './create-icon'++export const DurationIcon = /* @__PURE__ */ createIcon(+ 'duration',+ Clock3,+ 'lucide'+)diff --git a/src/renderer/components/icons/edit.tsx b/src/renderer/components/icons/edit.tsxnew file mode 100644index 00000000..888124f6--- /dev/null+++ b/src/renderer/components/icons/edit.tsx@@ -0,0 +1,4 @@+import { Pencil } from 'lucide-react'+import { createIcon } from './create-icon'++export const EditIcon = /* @__PURE__ */ createIcon('edit', Pencil, 'lucide')diff --git a/src/renderer/components/icons/external-link.tsx b/src/renderer/components/icons/external-link.tsxnew file mode 100644index 00000000..46fbf696--- /dev/null+++ b/src/renderer/components/icons/external-link.tsx@@ -0,0 +1,8 @@+import { ExternalLink } from 'lucide-react'+import { createIcon } from './create-icon'++export const ExternalLinkIcon = /* @__PURE__ */ createIcon(+ 'external-link',+ ExternalLink,+ 'lucide'+)diff --git a/src/renderer/components/icons/favorite.tsx b/src/renderer/components/icons/favorite.tsxnew file mode 100644index 00000000..f59f2ba2--- /dev/null+++ b/src/renderer/components/icons/favorite.tsx@@ -0,0 +1,8 @@+import { Star } from 'lucide-react'+import { createIcon } from './create-icon'++export const FavoriteIcon = /* @__PURE__ */ createIcon(+ 'favorite',+ Star,+ 'lucide'+)diff --git a/src/renderer/components/icons/files-ready.tsx b/src/renderer/components/icons/files-ready.tsxnew file mode 100644index 00000000..b22de296--- /dev/null+++ b/src/renderer/components/icons/files-ready.tsx@@ -0,0 +1,8 @@+import { FileCheckCorner } from 'lucide-react'+import { createIcon } from './create-icon'++export const FilesReadyIcon = /* @__PURE__ */ createIcon(+ 'files-ready',+ FileCheckCorner,+ 'lucide'+)diff --git a/src/renderer/components/icons/files.tsx b/src/renderer/components/icons/files.tsxnew file mode 100644index 00000000..d5e2a3f9--- /dev/null+++ b/src/renderer/components/icons/files.tsx@@ -0,0 +1,4 @@+import { Files } from 'lucide-react'+import { createIcon } from './create-icon'++export const FilesIcon = /* @__PURE__ */ createIcon('files', Files, 'lucide')diff --git a/src/renderer/components/icons/filter.tsx b/src/renderer/components/icons/filter.tsxnew file mode 100644index 00000000..084eaa92--- /dev/null+++ b/src/renderer/components/icons/filter.tsx@@ -0,0 +1,8 @@+import { ListFilter } from 'lucide-react'+import { createIcon } from './create-icon'++export const FilterIcon = /* @__PURE__ */ createIcon(+ 'filter',+ ListFilter,+ 'lucide'+)diff --git a/src/renderer/components/icons/folder-add.tsx b/src/renderer/components/icons/folder-add.tsxnew file mode 100644index 00000000..0e24a18f--- /dev/null+++ b/src/renderer/components/icons/folder-add.tsx@@ -0,0 +1,8 @@+import { FolderPlus } from 'lucide-react'+import { createIcon } from './create-icon'++export const FolderAddIcon = /* @__PURE__ */ createIcon(+ 'folder-add',+ FolderPlus,+ 'lucide'+)diff --git a/src/renderer/components/icons/folder.tsx b/src/renderer/components/icons/folder.tsxnew file mode 100644index 00000000..0ea04587--- /dev/null+++ b/src/renderer/components/icons/folder.tsx@@ -0,0 +1,4 @@+import { Folder } from 'lucide-react'+import { createIcon } from './create-icon'++export const FolderIcon = /* @__PURE__ */ createIcon('folder', Folder, 'lucide')diff --git a/src/renderer/components/icons/help.tsx b/src/renderer/components/icons/help.tsxnew file mode 100644index 00000000..73512712--- /dev/null+++ b/src/renderer/components/icons/help.tsx@@ -0,0 +1,8 @@+import { CircleQuestionMark } from 'lucide-react'+import { createIcon } from './create-icon'++export const HelpIcon = /* @__PURE__ */ createIcon(+ 'help',+ CircleQuestionMark,+ 'lucide'+)diff --git a/src/renderer/components/icons/history.tsx b/src/renderer/components/icons/history.tsxnew file mode 100644index 00000000..633fb777--- /dev/null+++ b/src/renderer/components/icons/history.tsx@@ -0,0 +1,8 @@+import { RotateCcwClock } from 'lucide-react'+import { createIcon } from './create-icon'++export const HistoryIcon = /* @__PURE__ */ createIcon(+ 'history',+ RotateCcwClock,+ 'lucide'+)diff --git a/src/renderer/components/icons/http.tsx b/src/renderer/components/icons/http.tsxnew file mode 100644index 00000000..7bd4c38e--- /dev/null+++ b/src/renderer/components/icons/http.tsx@@ -0,0 +1,4 @@+import { Globe } from 'lucide-react'+import { createIcon } from './create-icon'++export const HttpIcon = /* @__PURE__ */ createIcon('http', Globe, 'lucide')diff --git a/src/renderer/components/icons/image.tsx b/src/renderer/components/icons/image.tsxnew file mode 100644index 00000000..33b82b99--- /dev/null+++ b/src/renderer/components/icons/image.tsx@@ -0,0 +1,4 @@+import { Image } from 'lucide-react'+import { createIcon } from './create-icon'++export const ImageIcon = /* @__PURE__ */ createIcon('image', Image, 'lucide')diff --git a/src/renderer/components/icons/import-file.tsx b/src/renderer/components/icons/import-file.tsxnew file mode 100644index 00000000..c176ba6d--- /dev/null+++ b/src/renderer/components/icons/import-file.tsx@@ -0,0 +1,8 @@+import { Upload } from 'lucide-react'+import { createIcon } from './create-icon'++export const ImportFileIcon = /* @__PURE__ */ createIcon(+ 'import-file',+ Upload,+ 'lucide'+)diff --git a/src/renderer/components/icons/index.ts b/src/renderer/components/icons/index.tsnew file mode 100644index 00000000..d11fddee--- /dev/null+++ b/src/renderer/components/icons/index.ts@@ -0,0 +1,121 @@+export { ActivityIcon } from './activity'+export { AddIcon } from './add'+export { AdjustIcon } from './adjust'+export { ArrowDownLeftIcon } from './arrow-down-left'+export { ArrowLeftIcon } from './arrow-left'+export { ArrowRightIcon } from './arrow-right'+export { ArrowUpRightIcon } from './arrow-up-right'+export { AttachIcon } from './attach'+export { AudioIcon } from './audio'+export { BillingIcon } from './billing'+export { CallGraphIcon } from './call-graph'+export { ChangelogIcon } from './changelog'+export { CheckIcon } from './check'+export { ChevronDownIcon } from './chevron-down'+export { ChevronLeftIcon } from './chevron-left'+export { ChevronRightIcon } from './chevron-right'+export { ChevronUpIcon } from './chevron-up'+export { ChevronsUpDownIcon } from './chevrons-up-down'+export { CloseIcon } from './close'+export { ColumnsIcon } from './columns'+export { ConcealIcon } from './conceal'+export { ConnectionsIcon } from './connections'+export { CopyIcon } from './copy'+export { CopyLinkIcon } from './copy-link'+export type { MotrixIcon, MotrixIconProps } from './create-icon'+export { DashboardIcon } from './dashboard'+export { DiagnosticReportIcon } from './diagnostic-report'+export { DiagnosticsIcon } from './diagnostics'+export { DirectoryPreferencesIcon } from './directory-preferences'+export { DiskIcon } from './disk'+export { DiskCacheIcon } from './disk-cache'+export { DocumentIcon } from './document'+export { DownloadIcon } from './download'+export { DownloadActiveIcon } from './download-active'+export { DownloadLibraryIcon } from './download-library'+export { DragIcon } from './drag'+export { DurationIcon } from './duration'+export { EditIcon } from './edit'+export { ExternalLinkIcon } from './external-link'+export { FavoriteIcon } from './favorite'+export { FilesIcon } from './files'+export { FilesReadyIcon } from './files-ready'+export { FilterIcon } from './filter'+export { FolderIcon } from './folder'+export { FolderAddIcon } from './folder-add'+export { HelpIcon } from './help'+export { HistoryIcon } from './history'+export { HttpIcon } from './http'+export { ImageIcon } from './image'+export { ImportFileIcon } from './import-file'+export { InfoIcon } from './info'+export { InstallIcon } from './install'+export { LayoutTemplateIcon } from './layout-template'+export { LoadingIcon } from './loading'+export { LockedIcon } from './locked'+export { MagnetIcon } from './magnet'+export { MarkAllReadIcon } from './mark-all-read'+export { MetalinkIcon } from './metalink'+export { MoreIcon } from './more'+export { NotificationsIcon } from './notifications'+export { OpenFileIcon } from './open-file'+export { PanelCompactIcon } from './panel-compact'+export { PanelHeaderIcon } from './panel-header'+export { PanelWideIcon } from './panel-wide'+export { ParentFolderIcon } from './parent-folder'+export { PauseIcon } from './pause'+export { PeersIcon } from './peers'+export { PieceSizeIcon } from './piece-size'+export { PiecesIcon } from './pieces'+export { PluginIcon } from './plugin'+export { PluginStoreIcon } from './plugin-store'+export { PluginUnavailableIcon } from './plugin-unavailable'+export { PluginUpdateIcon } from './plugin-update'+export { QueuedIcon } from './queued'+export { RandomizeIcon } from './randomize'+export { RefreshIcon } from './refresh'+export { RemoveIcon } from './remove'+export { ResetIcon } from './reset'+export { ResizeIcon } from './resize'+export { RestartIcon } from './restart'+export { ResumeIcon } from './resume'+export { RetryIcon } from './retry'+export { RevealIcon } from './reveal'+export { RevealFolderIcon } from './reveal-folder'+export { RouterIcon } from './router'+export { SearchIcon } from './search'+export { SecurityWarningIcon } from './security-warning'+export { SeedStartIcon } from './seed-start'+export { SeedStatusIcon } from './seed-status'+export { SelectFilesIcon } from './select-files'+export { ServerIcon } from './server'+export { ServerConnectionsIcon } from './server-connections'+export { SettingsIcon } from './settings'+export { ShareIcon } from './share'+export { SidebarIcon } from './sidebar'+export { SignOutIcon } from './sign-out'+export { SpeedAutoIcon } from './speed-auto'+export { SpeedControlIcon } from './speed-control'+export { SpeedLimitedIcon } from './speed-limited'+export { SpeedUnlimitedIcon } from './speed-unlimited'+export { StatusBlockedIcon } from './status-blocked'+export { StatusCompleteIcon } from './status-complete'+export { StatusDotIcon } from './status-dot'+export { StatusErrorIcon } from './status-error'+export { StatusFailedIcon } from './status-failed'+export { StopIcon } from './stop'+export { SubtractIcon } from './subtract'+export { TableIcon } from './table'+export { TerminalIcon } from './terminal'+export { TorrentFileIcon } from './torrent-file'+export { TrackerIcon } from './tracker'+export { TransferDownIcon } from './transfer-down'+export { TransferUpIcon } from './transfer-up'+export { UndoIcon } from './undo'+export { UnlimitedIcon } from './unlimited'+export { UpgradeIcon } from './upgrade'+export { UploadIcon } from './upload'+export { VerifiedIcon } from './verified'+export { VerifiedToolIcon } from './verified-tool'+export { VideoIcon } from './video'+export { WarningIcon } from './warning'diff --git a/src/renderer/components/icons/info.tsx b/src/renderer/components/icons/info.tsxnew file mode 100644index 00000000..e5e2d04e--- /dev/null+++ b/src/renderer/components/icons/info.tsx@@ -0,0 +1,4 @@+import { Info } from 'lucide-react'+import { createIcon } from './create-icon'++export const InfoIcon = /* @__PURE__ */ createIcon('info', Info, 'lucide')diff --git a/src/renderer/components/icons/install.tsx b/src/renderer/components/icons/install.tsxnew file mode 100644index 00000000..5f97e2b4--- /dev/null+++ b/src/renderer/components/icons/install.tsx@@ -0,0 +1,8 @@+import { Download } from 'lucide-react'+import { createIcon } from './create-icon'++export const InstallIcon = /* @__PURE__ */ createIcon(+ 'install',+ Download,+ 'lucide'+)diff --git a/src/renderer/components/icons/layout-template.tsx b/src/renderer/components/icons/layout-template.tsxnew file mode 100644index 00000000..ac67db79--- /dev/null+++ b/src/renderer/components/icons/layout-template.tsx@@ -0,0 +1,8 @@+import { LayoutTemplate } from 'lucide-react'+import { createIcon } from './create-icon'++export const LayoutTemplateIcon = /* @__PURE__ */ createIcon(+ 'layout-template',+ LayoutTemplate,+ 'lucide'+)diff --git a/src/renderer/components/icons/loading.tsx b/src/renderer/components/icons/loading.tsxnew file mode 100644index 00000000..fcaa564b--- /dev/null+++ b/src/renderer/components/icons/loading.tsx@@ -0,0 +1,8 @@+import { LoaderCircle } from 'lucide-react'+import { createIcon } from './create-icon'++export const LoadingIcon = /* @__PURE__ */ createIcon(+ 'loading',+ LoaderCircle,+ 'lucide'+)diff --git a/src/renderer/components/icons/locked.tsx b/src/renderer/components/icons/locked.tsxnew file mode 100644index 00000000..de726375--- /dev/null+++ b/src/renderer/components/icons/locked.tsx@@ -0,0 +1,4 @@+import { Lock } from 'lucide-react'+import { createIcon } from './create-icon'++export const LockedIcon = /* @__PURE__ */ createIcon('locked', Lock, 'lucide')diff --git a/src/renderer/components/icons/magnet.tsx b/src/renderer/components/icons/magnet.tsxnew file mode 100644index 00000000..f43b2e37--- /dev/null+++ b/src/renderer/components/icons/magnet.tsx@@ -0,0 +1,4 @@+import { Magnet } from 'lucide-react'+import { createIcon } from './create-icon'++export const MagnetIcon = /* @__PURE__ */ createIcon('magnet', Magnet, 'lucide')diff --git a/src/renderer/components/icons/mark-all-read.tsx b/src/renderer/components/icons/mark-all-read.tsxnew file mode 100644index 00000000..e9714115--- /dev/null+++ b/src/renderer/components/icons/mark-all-read.tsx@@ -0,0 +1,8 @@+import { CheckCheck } from 'lucide-react'+import { createIcon } from './create-icon'++export const MarkAllReadIcon = /* @__PURE__ */ createIcon(+ 'mark-all-read',+ CheckCheck,+ 'lucide'+)diff --git a/src/renderer/components/icons/metalink.tsx b/src/renderer/components/icons/metalink.tsxnew file mode 100644index 00000000..543956c3--- /dev/null+++ b/src/renderer/components/icons/metalink.tsx@@ -0,0 +1,8 @@+import { Package } from 'lucide-react'+import { createIcon } from './create-icon'++export const MetalinkIcon = /* @__PURE__ */ createIcon(+ 'metalink',+ Package,+ 'lucide'+)diff --git a/src/renderer/components/icons/more.tsx b/src/renderer/components/icons/more.tsxnew file mode 100644index 00000000..4577a046--- /dev/null+++ b/src/renderer/components/icons/more.tsx@@ -0,0 +1,4 @@+import { Ellipsis } from 'lucide-react'+import { createIcon } from './create-icon'++export const MoreIcon = /* @__PURE__ */ createIcon('more', Ellipsis, 'lucide')diff --git a/src/renderer/components/icons/notifications.tsx b/src/renderer/components/icons/notifications.tsxnew file mode 100644index 00000000..779bcc06--- /dev/null+++ b/src/renderer/components/icons/notifications.tsx@@ -0,0 +1,8 @@+import { Bell } from 'lucide-react'+import { createIcon } from './create-icon'++export const NotificationsIcon = /* @__PURE__ */ createIcon(+ 'notifications',+ Bell,+ 'lucide'+)diff --git a/src/renderer/components/icons/open-file.tsx b/src/renderer/components/icons/open-file.tsxnew file mode 100644index 00000000..0f913e46--- /dev/null+++ b/src/renderer/components/icons/open-file.tsx@@ -0,0 +1,8 @@+import { File } from 'lucide-react'+import { createIcon } from './create-icon'++export const OpenFileIcon = /* @__PURE__ */ createIcon(+ 'open-file',+ File,+ 'lucide'+)diff --git a/src/renderer/components/icons/panel-compact.tsx b/src/renderer/components/icons/panel-compact.tsxnew file mode 100644index 00000000..9616b80d--- /dev/null+++ b/src/renderer/components/icons/panel-compact.tsx@@ -0,0 +1,8 @@+import { Square } from 'lucide-react'+import { createIcon } from './create-icon'++export const PanelCompactIcon = /* @__PURE__ */ createIcon(+ 'panel-compact',+ Square,+ 'lucide'+)diff --git a/src/renderer/components/icons/panel-header.tsx b/src/renderer/components/icons/panel-header.tsxnew file mode 100644index 00000000..2c404b25--- /dev/null+++ b/src/renderer/components/icons/panel-header.tsx@@ -0,0 +1,8 @@+import { PanelTop } from 'lucide-react'+import { createIcon } from './create-icon'++export const PanelHeaderIcon = /* @__PURE__ */ createIcon(+ 'panel-header',+ PanelTop,+ 'lucide'+)diff --git a/src/renderer/components/icons/panel-wide.tsx b/src/renderer/components/icons/panel-wide.tsxnew file mode 100644index 00000000..a3192a91--- /dev/null+++ b/src/renderer/components/icons/panel-wide.tsx@@ -0,0 +1,8 @@+import { StretchHorizontal } from 'lucide-react'+import { createIcon } from './create-icon'++export const PanelWideIcon = /* @__PURE__ */ createIcon(+ 'panel-wide',+ StretchHorizontal,+ 'lucide'+)diff --git a/src/renderer/components/icons/parent-folder.tsx b/src/renderer/components/icons/parent-folder.tsxnew file mode 100644index 00000000..ee397d76--- /dev/null+++ b/src/renderer/components/icons/parent-folder.tsx@@ -0,0 +1,8 @@+import { ArrowUp } from 'lucide-react'+import { createIcon } from './create-icon'++export const ParentFolderIcon = /* @__PURE__ */ createIcon(+ 'parent-folder',+ ArrowUp,+ 'lucide'+)diff --git a/src/renderer/components/icons/pause.tsx b/src/renderer/components/icons/pause.tsxnew file mode 100644index 00000000..3bca53bd--- /dev/null+++ b/src/renderer/components/icons/pause.tsx@@ -0,0 +1,4 @@+import { Pause } from 'lucide-react'+import { createIcon } from './create-icon'++export const PauseIcon = /* @__PURE__ */ createIcon('pause', Pause, 'lucide')diff --git a/src/renderer/components/icons/peers.tsx b/src/renderer/components/icons/peers.tsxnew file mode 100644index 00000000..afd624d7--- /dev/null+++ b/src/renderer/components/icons/peers.tsx@@ -0,0 +1,8 @@+import { UsersRound } from 'lucide-react'+import { createIcon } from './create-icon'++export const PeersIcon = /* @__PURE__ */ createIcon(+ 'peers',+ UsersRound,+ 'lucide'+)diff --git a/src/renderer/components/icons/piece-size.tsx b/src/renderer/components/icons/piece-size.tsxnew file mode 100644index 00000000..760e38f0--- /dev/null+++ b/src/renderer/components/icons/piece-size.tsx@@ -0,0 +1,8 @@+import { Ruler } from 'lucide-react'+import { createIcon } from './create-icon'++export const PieceSizeIcon = /* @__PURE__ */ createIcon(+ 'piece-size',+ Ruler,+ 'lucide'+)diff --git a/src/renderer/components/icons/pieces.tsx b/src/renderer/components/icons/pieces.tsxnew file mode 100644index 00000000..0ead0bf0--- /dev/null+++ b/src/renderer/components/icons/pieces.tsx@@ -0,0 +1,8 @@+import { Grid3x3 } from 'lucide-react'+import { createIcon } from './create-icon'++export const PiecesIcon = /* @__PURE__ */ createIcon(+ 'pieces',+ Grid3x3,+ 'lucide'+)diff --git a/src/renderer/components/icons/plugin-store.tsx b/src/renderer/components/icons/plugin-store.tsxnew file mode 100644index 00000000..c4c409ea--- /dev/null+++ b/src/renderer/components/icons/plugin-store.tsx@@ -0,0 +1,8 @@+import { Store } from 'lucide-react'+import { createIcon } from './create-icon'++export const PluginStoreIcon = /* @__PURE__ */ createIcon(+ 'plugin-store',+ Store,+ 'lucide'+)diff --git a/src/renderer/components/icons/plugin-unavailable.tsx b/src/renderer/components/icons/plugin-unavailable.tsxnew file mode 100644index 00000000..09f4fbfa--- /dev/null+++ b/src/renderer/components/icons/plugin-unavailable.tsx@@ -0,0 +1,8 @@+import { PackageX } from 'lucide-react'+import { createIcon } from './create-icon'++export const PluginUnavailableIcon = /* @__PURE__ */ createIcon(+ 'plugin-unavailable',+ PackageX,+ 'lucide'+)diff --git a/src/renderer/components/icons/plugin-update.tsx b/src/renderer/components/icons/plugin-update.tsxnew file mode 100644index 00000000..c5bb210d--- /dev/null+++ b/src/renderer/components/icons/plugin-update.tsx@@ -0,0 +1,8 @@+import { CircleFadingArrowUp } from 'lucide-react'+import { createIcon } from './create-icon'++export const PluginUpdateIcon = /* @__PURE__ */ createIcon(+ 'plugin-update',+ CircleFadingArrowUp,+ 'lucide'+)diff --git a/src/renderer/components/icons/plugin.tsx b/src/renderer/components/icons/plugin.tsxnew file mode 100644index 00000000..64adb722--- /dev/null+++ b/src/renderer/components/icons/plugin.tsx@@ -0,0 +1,8 @@+import { ToyBrick } from 'lucide-react'+import { createIcon } from './create-icon'++export const PluginIcon = /* @__PURE__ */ createIcon(+ 'plugin',+ ToyBrick,+ 'lucide'+)diff --git a/src/renderer/components/icons/queued.tsx b/src/renderer/components/icons/queued.tsxnew file mode 100644index 00000000..e8ee3b1b--- /dev/null+++ b/src/renderer/components/icons/queued.tsx@@ -0,0 +1,4 @@+import { Clock } from 'lucide-react'+import { createIcon } from './create-icon'++export const QueuedIcon = /* @__PURE__ */ createIcon('queued', Clock, 'lucide')diff --git a/src/renderer/components/icons/randomize.tsx b/src/renderer/components/icons/randomize.tsxnew file mode 100644index 00000000..78b46527--- /dev/null+++ b/src/renderer/components/icons/randomize.tsx@@ -0,0 +1,8 @@+import { Dices } from 'lucide-react'+import { createIcon } from './create-icon'++export const RandomizeIcon = /* @__PURE__ */ createIcon(+ 'randomize',+ Dices,+ 'lucide'+)diff --git a/src/renderer/components/icons/refresh.tsx b/src/renderer/components/icons/refresh.tsxnew file mode 100644index 00000000..d93ad087--- /dev/null+++ b/src/renderer/components/icons/refresh.tsx@@ -0,0 +1,8 @@+import { RefreshCw } from 'lucide-react'+import { createIcon } from './create-icon'++export const RefreshIcon = /* @__PURE__ */ createIcon(+ 'refresh',+ RefreshCw,+ 'lucide'+)diff --git a/src/renderer/components/icons/remove.tsx b/src/renderer/components/icons/remove.tsxnew file mode 100644index 00000000..23dfdf4a--- /dev/null+++ b/src/renderer/components/icons/remove.tsx@@ -0,0 +1,4 @@+import { Trash } from 'lucide-react'+import { createIcon } from './create-icon'++export const RemoveIcon = /* @__PURE__ */ createIcon('remove', Trash, 'lucide')diff --git a/src/renderer/components/icons/reset.tsx b/src/renderer/components/icons/reset.tsxnew file mode 100644index 00000000..6a1ce901--- /dev/null+++ b/src/renderer/components/icons/reset.tsx@@ -0,0 +1,8 @@+import { RotateCcw } from 'lucide-react'+import { createIcon } from './create-icon'++export const ResetIcon = /* @__PURE__ */ createIcon(+ 'reset',+ RotateCcw,+ 'lucide'+)diff --git a/src/renderer/components/icons/resize.tsx b/src/renderer/components/icons/resize.tsxnew file mode 100644index 00000000..bcdff1a1--- /dev/null+++ b/src/renderer/components/icons/resize.tsx@@ -0,0 +1,8 @@+import { MoveDiagonal2 } from 'lucide-react'+import { createIcon } from './create-icon'++export const ResizeIcon = /* @__PURE__ */ createIcon(+ 'resize',+ MoveDiagonal2,+ 'lucide'+)diff --git a/src/renderer/components/icons/restart.tsx b/src/renderer/components/icons/restart.tsxnew file mode 100644index 00000000..4a97ff8d--- /dev/null+++ b/src/renderer/components/icons/restart.tsx@@ -0,0 +1,8 @@+import { RotateCw } from 'lucide-react'+import { createIcon } from './create-icon'++export const RestartIcon = /* @__PURE__ */ createIcon(+ 'restart',+ RotateCw,+ 'lucide'+)diff --git a/src/renderer/components/icons/resume.tsx b/src/renderer/components/icons/resume.tsxnew file mode 100644index 00000000..60e6bd66--- /dev/null+++ b/src/renderer/components/icons/resume.tsx@@ -0,0 +1,4 @@+import { Play } from 'lucide-react'+import { createIcon } from './create-icon'++export const ResumeIcon = /* @__PURE__ */ createIcon('resume', Play, 'lucide')diff --git a/src/renderer/components/icons/retry.tsx b/src/renderer/components/icons/retry.tsxnew file mode 100644index 00000000..cb1a5d43--- /dev/null+++ b/src/renderer/components/icons/retry.tsx@@ -0,0 +1,4 @@+import { Repeat2 } from 'lucide-react'+import { createIcon } from './create-icon'++export const RetryIcon = /* @__PURE__ */ createIcon('retry', Repeat2, 'lucide')diff --git a/src/renderer/components/icons/reveal-folder.tsx b/src/renderer/components/icons/reveal-folder.tsxnew file mode 100644index 00000000..68fcad60--- /dev/null+++ b/src/renderer/components/icons/reveal-folder.tsx@@ -0,0 +1,8 @@+import { FolderOpen } from 'lucide-react'+import { createIcon } from './create-icon'++export const RevealFolderIcon = /* @__PURE__ */ createIcon(+ 'reveal-folder',+ FolderOpen,+ 'lucide'+)diff --git a/src/renderer/components/icons/reveal.tsx b/src/renderer/components/icons/reveal.tsxnew file mode 100644index 00000000..e5b9b650--- /dev/null+++ b/src/renderer/components/icons/reveal.tsx@@ -0,0 +1,4 @@+import { Eye } from 'lucide-react'+import { createIcon } from './create-icon'++export const RevealIcon = /* @__PURE__ */ createIcon('reveal', Eye, 'lucide')diff --git a/src/renderer/components/icons/router.tsx b/src/renderer/components/icons/router.tsxnew file mode 100644index 00000000..0c4b4653--- /dev/null+++ b/src/renderer/components/icons/router.tsx@@ -0,0 +1,4 @@+import { Router } from 'lucide-react'+import { createIcon } from './create-icon'++export const RouterIcon = /* @__PURE__ */ createIcon('router', Router, 'lucide')diff --git a/src/renderer/components/icons/search.tsx b/src/renderer/components/icons/search.tsxnew file mode 100644index 00000000..9803edec--- /dev/null+++ b/src/renderer/components/icons/search.tsx@@ -0,0 +1,4 @@+import { Search } from 'lucide-react'+import { createIcon } from './create-icon'++export const SearchIcon = /* @__PURE__ */ createIcon('search', Search, 'lucide')diff --git a/src/renderer/components/icons/security-warning.tsx b/src/renderer/components/icons/security-warning.tsxnew file mode 100644index 00000000..25855afb--- /dev/null+++ b/src/renderer/components/icons/security-warning.tsx@@ -0,0 +1,8 @@+import { ShieldAlert } from 'lucide-react'+import { createIcon } from './create-icon'++export const SecurityWarningIcon = /* @__PURE__ */ createIcon(+ 'security-warning',+ ShieldAlert,+ 'lucide'+)diff --git a/src/renderer/components/icons/seed-start.tsx b/src/renderer/components/icons/seed-start.tsxnew file mode 100644index 00000000..6f6631ee--- /dev/null+++ b/src/renderer/components/icons/seed-start.tsx@@ -0,0 +1,8 @@+import { Sprout } from 'lucide-react'+import { createIcon } from './create-icon'++export const SeedStartIcon = /* @__PURE__ */ createIcon(+ 'seed-start',+ Sprout,+ 'lucide'+)diff --git a/src/renderer/components/icons/seed-status.tsx b/src/renderer/components/icons/seed-status.tsxnew file mode 100644index 00000000..347c3c3a--- /dev/null+++ b/src/renderer/components/icons/seed-status.tsx@@ -0,0 +1,8 @@+import { Upload } from 'lucide-react'+import { createIcon } from './create-icon'++export const SeedStatusIcon = /* @__PURE__ */ createIcon(+ 'seed-status',+ Upload,+ 'lucide'+)diff --git a/src/renderer/components/icons/select-files.tsx b/src/renderer/components/icons/select-files.tsxnew file mode 100644index 00000000..ed851112--- /dev/null+++ b/src/renderer/components/icons/select-files.tsx@@ -0,0 +1,8 @@+import { ListChecks } from 'lucide-react'+import { createIcon } from './create-icon'++export const SelectFilesIcon = /* @__PURE__ */ createIcon(+ 'select-files',+ ListChecks,+ 'lucide'+)diff --git a/src/renderer/components/icons/server-connections.tsx b/src/renderer/components/icons/server-connections.tsxnew file mode 100644index 00000000..74b99ac8--- /dev/null+++ b/src/renderer/components/icons/server-connections.tsx@@ -0,0 +1,8 @@+import { Server } from 'lucide-react'+import { createIcon } from './create-icon'++export const ServerConnectionsIcon = /* @__PURE__ */ createIcon(+ 'server-connections',+ Server,+ 'lucide'+)diff --git a/src/renderer/components/icons/server.tsx b/src/renderer/components/icons/server.tsxnew file mode 100644index 00000000..f18b8baa--- /dev/null+++ b/src/renderer/components/icons/server.tsx@@ -0,0 +1,4 @@+import { Server } from 'lucide-react'+import { createIcon } from './create-icon'++export const ServerIcon = /* @__PURE__ */ createIcon('server', Server, 'lucide')diff --git a/src/renderer/components/icons/settings.tsx b/src/renderer/components/icons/settings.tsxnew file mode 100644index 00000000..9eebac9c--- /dev/null+++ b/src/renderer/components/icons/settings.tsx@@ -0,0 +1,8 @@+import { Settings } from 'lucide-react'+import { createIcon } from './create-icon'++export const SettingsIcon = /* @__PURE__ */ createIcon(+ 'settings',+ Settings,+ 'lucide'+)diff --git a/src/renderer/components/icons/share.tsx b/src/renderer/components/icons/share.tsxnew file mode 100644index 00000000..e6826bd9--- /dev/null+++ b/src/renderer/components/icons/share.tsx@@ -0,0 +1,4 @@+import { Share } from 'lucide-react'+import { createIcon } from './create-icon'++export const ShareIcon = /* @__PURE__ */ createIcon('share', Share, 'lucide')diff --git a/src/renderer/components/icons/sidebar.tsx b/src/renderer/components/icons/sidebar.tsxnew file mode 100644index 00000000..15099e2a--- /dev/null+++ b/src/renderer/components/icons/sidebar.tsx@@ -0,0 +1,8 @@+import { PanelLeft } from 'lucide-react'+import { createIcon } from './create-icon'++export const SidebarIcon = /* @__PURE__ */ createIcon(+ 'sidebar',+ PanelLeft,+ 'lucide'+)diff --git a/src/renderer/components/icons/sign-out.tsx b/src/renderer/components/icons/sign-out.tsxnew file mode 100644index 00000000..d968187a--- /dev/null+++ b/src/renderer/components/icons/sign-out.tsx@@ -0,0 +1,8 @@+import { LogOut } from 'lucide-react'+import { createIcon } from './create-icon'++export const SignOutIcon = /* @__PURE__ */ createIcon(+ 'sign-out',+ LogOut,+ 'lucide'+)diff --git a/src/renderer/components/icons/speed-auto.tsx b/src/renderer/components/icons/speed-auto.tsxnew file mode 100644index 00000000..027107e8--- /dev/null+++ b/src/renderer/components/icons/speed-auto.tsx@@ -0,0 +1,8 @@+import { Squirrel } from 'lucide-react'+import { createIcon } from './create-icon'++export const SpeedAutoIcon = /* @__PURE__ */ createIcon(+ 'speed-auto',+ Squirrel,+ 'lucide'+)diff --git a/src/renderer/components/icons/speed-control.tsx b/src/renderer/components/icons/speed-control.tsxnew file mode 100644index 00000000..e31b3f7d--- /dev/null+++ b/src/renderer/components/icons/speed-control.tsx@@ -0,0 +1,8 @@+import { Bolt } from 'lucide-react'+import { createIcon } from './create-icon'++export const SpeedControlIcon = /* @__PURE__ */ createIcon(+ 'speed-control',+ Bolt,+ 'lucide'+)diff --git a/src/renderer/components/icons/speed-limited.tsx b/src/renderer/components/icons/speed-limited.tsxnew file mode 100644index 00000000..d04e8b5a--- /dev/null+++ b/src/renderer/components/icons/speed-limited.tsx@@ -0,0 +1,8 @@+import { Turtle } from 'lucide-react'+import { createIcon } from './create-icon'++export const SpeedLimitedIcon = /* @__PURE__ */ createIcon(+ 'speed-limited',+ Turtle,+ 'lucide'+)diff --git a/src/renderer/components/icons/speed-unlimited.tsx b/src/renderer/components/icons/speed-unlimited.tsxnew file mode 100644index 00000000..44dfaf6b--- /dev/null+++ b/src/renderer/components/icons/speed-unlimited.tsx@@ -0,0 +1,8 @@+import { Rabbit } from 'lucide-react'+import { createIcon } from './create-icon'++export const SpeedUnlimitedIcon = /* @__PURE__ */ createIcon(+ 'speed-unlimited',+ Rabbit,+ 'lucide'+)diff --git a/src/renderer/components/icons/status-blocked.tsx b/src/renderer/components/icons/status-blocked.tsxnew file mode 100644index 00000000..3eff392b--- /dev/null+++ b/src/renderer/components/icons/status-blocked.tsx@@ -0,0 +1,8 @@+import { OctagonX } from 'lucide-react'+import { createIcon } from './create-icon'++export const StatusBlockedIcon = /* @__PURE__ */ createIcon(+ 'status-blocked',+ OctagonX,+ 'lucide'+)diff --git a/src/renderer/components/icons/status-complete.tsx b/src/renderer/components/icons/status-complete.tsxnew file mode 100644index 00000000..5580afbc--- /dev/null+++ b/src/renderer/components/icons/status-complete.tsx@@ -0,0 +1,8 @@+import { CircleCheck } from 'lucide-react'+import { createIcon } from './create-icon'++export const StatusCompleteIcon = /* @__PURE__ */ createIcon(+ 'status-complete',+ CircleCheck,+ 'lucide'+)diff --git a/src/renderer/components/icons/status-dot.tsx b/src/renderer/components/icons/status-dot.tsxnew file mode 100644index 00000000..59351620--- /dev/null+++ b/src/renderer/components/icons/status-dot.tsx@@ -0,0 +1,8 @@+import { Circle } from 'lucide-react'+import { createIcon } from './create-icon'++export const StatusDotIcon = /* @__PURE__ */ createIcon(+ 'status-dot',+ Circle,+ 'lucide'+)diff --git a/src/renderer/components/icons/status-error.tsx b/src/renderer/components/icons/status-error.tsxnew file mode 100644index 00000000..27d55ce8--- /dev/null+++ b/src/renderer/components/icons/status-error.tsx@@ -0,0 +1,8 @@+import { CircleAlert } from 'lucide-react'+import { createIcon } from './create-icon'++export const StatusErrorIcon = /* @__PURE__ */ createIcon(+ 'status-error',+ CircleAlert,+ 'lucide'+)diff --git a/src/renderer/components/icons/status-failed.tsx b/src/renderer/components/icons/status-failed.tsxnew file mode 100644index 00000000..7d7a6484--- /dev/null+++ b/src/renderer/components/icons/status-failed.tsx@@ -0,0 +1,8 @@+import { CircleX } from 'lucide-react'+import { createIcon } from './create-icon'++export const StatusFailedIcon = /* @__PURE__ */ createIcon(+ 'status-failed',+ CircleX,+ 'lucide'+)diff --git a/src/renderer/components/icons/stop.tsx b/src/renderer/components/icons/stop.tsxnew file mode 100644index 00000000..eecdd670--- /dev/null+++ b/src/renderer/components/icons/stop.tsx@@ -0,0 +1,4 @@+import { Square } from 'lucide-react'+import { createIcon } from './create-icon'++export const StopIcon = /* @__PURE__ */ createIcon('stop', Square, 'lucide')diff --git a/src/renderer/components/icons/subtract.tsx b/src/renderer/components/icons/subtract.tsxnew file mode 100644index 00000000..dd85609c--- /dev/null+++ b/src/renderer/components/icons/subtract.tsx@@ -0,0 +1,8 @@+import { Minus } from 'lucide-react'+import { createIcon } from './create-icon'++export const SubtractIcon = /* @__PURE__ */ createIcon(+ 'subtract',+ Minus,+ 'lucide'+)diff --git a/src/renderer/components/icons/table.tsx b/src/renderer/components/icons/table.tsxnew file mode 100644index 00000000..1627c65f--- /dev/null+++ b/src/renderer/components/icons/table.tsx@@ -0,0 +1,4 @@+import { Table2 } from 'lucide-react'+import { createIcon } from './create-icon'++export const TableIcon = /* @__PURE__ */ createIcon('table', Table2, 'lucide')diff --git a/src/renderer/components/icons/terminal.tsx b/src/renderer/components/icons/terminal.tsxnew file mode 100644index 00000000..29d8b110--- /dev/null+++ b/src/renderer/components/icons/terminal.tsx@@ -0,0 +1,8 @@+import { SquareTerminal } from 'lucide-react'+import { createIcon } from './create-icon'++export const TerminalIcon = /* @__PURE__ */ createIcon(+ 'terminal',+ SquareTerminal,+ 'lucide'+)diff --git a/src/renderer/components/icons/torrent-file.tsx b/src/renderer/components/icons/torrent-file.tsxnew file mode 100644index 00000000..c5921668--- /dev/null+++ b/src/renderer/components/icons/torrent-file.tsx@@ -0,0 +1,8 @@+import { FileDown } from 'lucide-react'+import { createIcon } from './create-icon'++export const TorrentFileIcon = /* @__PURE__ */ createIcon(+ 'torrent-file',+ FileDown,+ 'lucide'+)diff --git a/src/renderer/components/icons/tracker.tsx b/src/renderer/components/icons/tracker.tsxnew file mode 100644index 00000000..528c56aa--- /dev/null+++ b/src/renderer/components/icons/tracker.tsx@@ -0,0 +1,8 @@+import { RadioTower } from 'lucide-react'+import { createIcon } from './create-icon'++export const TrackerIcon = /* @__PURE__ */ createIcon(+ 'tracker',+ RadioTower,+ 'lucide'+)diff --git a/src/renderer/components/icons/transfer-down.tsx b/src/renderer/components/icons/transfer-down.tsxnew file mode 100644index 00000000..16434367--- /dev/null+++ b/src/renderer/components/icons/transfer-down.tsx@@ -0,0 +1,8 @@+import { ArrowDown } from 'lucide-react'+import { createIcon } from './create-icon'++export const TransferDownIcon = /* @__PURE__ */ createIcon(+ 'transfer-down',+ ArrowDown,+ 'lucide'+)diff --git a/src/renderer/components/icons/transfer-up.tsx b/src/renderer/components/icons/transfer-up.tsxnew file mode 100644index 00000000..9bc92f63--- /dev/null+++ b/src/renderer/components/icons/transfer-up.tsx@@ -0,0 +1,8 @@+import { ArrowUp } from 'lucide-react'+import { createIcon } from './create-icon'++export const TransferUpIcon = /* @__PURE__ */ createIcon(+ 'transfer-up',+ ArrowUp,+ 'lucide'+)diff --git a/src/renderer/components/icons/undo.tsx b/src/renderer/components/icons/undo.tsxnew file mode 100644index 00000000..d0b76031--- /dev/null+++ b/src/renderer/components/icons/undo.tsx@@ -0,0 +1,4 @@+import { Undo2 } from 'lucide-react'+import { createIcon } from './create-icon'++export const UndoIcon = /* @__PURE__ */ createIcon('undo', Undo2, 'lucide')diff --git a/src/renderer/components/icons/unlimited.tsx b/src/renderer/components/icons/unlimited.tsxnew file mode 100644index 00000000..e4c1058d--- /dev/null+++ b/src/renderer/components/icons/unlimited.tsx@@ -0,0 +1,8 @@+import { Infinity as InfinityIcon } from 'lucide-react'+import { createIcon } from './create-icon'++export const UnlimitedIcon = /* @__PURE__ */ createIcon(+ 'unlimited',+ InfinityIcon,+ 'lucide'+)diff --git a/src/renderer/components/icons/upgrade.tsx b/src/renderer/components/icons/upgrade.tsxnew file mode 100644index 00000000..d39c9ee6--- /dev/null+++ b/src/renderer/components/icons/upgrade.tsx@@ -0,0 +1,8 @@+import { Sparkles } from 'lucide-react'+import { createIcon } from './create-icon'++export const UpgradeIcon = /* @__PURE__ */ createIcon(+ 'upgrade',+ Sparkles,+ 'lucide'+)diff --git a/src/renderer/components/icons/upload.tsx b/src/renderer/components/icons/upload.tsxnew file mode 100644index 00000000..e48fe478--- /dev/null+++ b/src/renderer/components/icons/upload.tsx@@ -0,0 +1,4 @@+import { Upload } from 'lucide-react'+import { createIcon } from './create-icon'++export const UploadIcon = /* @__PURE__ */ createIcon('upload', Upload, 'lucide')diff --git a/src/renderer/components/icons/verified-tool.tsx b/src/renderer/components/icons/verified-tool.tsxnew file mode 100644index 00000000..8aa18479--- /dev/null+++ b/src/renderer/components/icons/verified-tool.tsx@@ -0,0 +1,8 @@+import { BadgeCheck } from 'lucide-react'+import { createIcon } from './create-icon'++export const VerifiedToolIcon = /* @__PURE__ */ createIcon(+ 'verified-tool',+ BadgeCheck,+ 'lucide'+)diff --git a/src/renderer/components/icons/verified.tsx b/src/renderer/components/icons/verified.tsxnew file mode 100644index 00000000..65717750--- /dev/null+++ b/src/renderer/components/icons/verified.tsx@@ -0,0 +1,8 @@+import { ShieldCheck } from 'lucide-react'+import { createIcon } from './create-icon'++export const VerifiedIcon = /* @__PURE__ */ createIcon(+ 'verified',+ ShieldCheck,+ 'lucide'+)diff --git a/src/renderer/components/icons/video.tsx b/src/renderer/components/icons/video.tsxnew file mode 100644index 00000000..7d08578f--- /dev/null+++ b/src/renderer/components/icons/video.tsx@@ -0,0 +1,4 @@+import { Film } from 'lucide-react'+import { createIcon } from './create-icon'++export const VideoIcon = /* @__PURE__ */ createIcon('video', Film, 'lucide')diff --git a/src/renderer/components/icons/warning.tsx b/src/renderer/components/icons/warning.tsxnew file mode 100644index 00000000..5778772e--- /dev/null+++ b/src/renderer/components/icons/warning.tsx@@ -0,0 +1,8 @@+import { TriangleAlert } from 'lucide-react'+import { createIcon } from './create-icon'++export const WarningIcon = /* @__PURE__ */ createIcon(+ 'warning',+ TriangleAlert,+ 'lucide'+)diff --git a/src/renderer/components/notification-center/notifications-nav-item.tsx b/src/renderer/components/notification-center/notifications-nav-item.tsxindex 368bcde4..b8be5781 100644--- a/src/renderer/components/notification-center/notifications-nav-item.tsx+++ b/src/renderer/components/notification-center/notifications-nav-item.tsx@@ -1,8 +1,8 @@+import { NotificationsIcon } from '@renderer/components/icons'import {SidebarMenuButton,SidebarMenuItem,} from '@renderer/components/ui/sidebar'-import { Bell } from 'lucide-react'import { useTranslation } from 'react-i18next'import { NavLink } from 'react-router'import { useNotifications } from './use-notifications'@@ -40,7 +40,7 @@ export function NotificationsNavItem() {tooltip={t('nav.notifications')}className="relative cursor-default">- <Bell />+ <NotificationsIcon /><span className="select-none">{t('nav.notifications')}</span>{unreadCount > 0 && (<>diff --git a/src/renderer/components/settings-kit/endpoint-list.tsx b/src/renderer/components/settings-kit/endpoint-list.tsxindex 8b35b060..ee988679 100644--- a/src/renderer/components/settings-kit/endpoint-list.tsx+++ b/src/renderer/components/settings-kit/endpoint-list.tsx@@ -1,3 +1,4 @@+import { CloseIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {FormControl,@@ -7,7 +8,6 @@ import {} from '@renderer/components/ui/form'import { Input } from '@renderer/components/ui/input'import { settingsValidationError } from '@renderer/lib/settings-validation'-import { X } from 'lucide-react'import { useId, useState } from 'react'import { useController, useFormContext } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -92,7 +92,7 @@ export function EndpointList({update(entries.filter((_, position) => position !== index))}>- <X className="h-3 w-3" />+ <CloseIcon className="h-3 w-3" /></Button><FormMessage className="basis-full text-xs" /></FormItem>diff --git a/src/renderer/components/speed-limit-modes.ts b/src/renderer/components/speed-limit-modes.tsindex 235a66c9..a66b84b3 100644--- a/src/renderer/components/speed-limit-modes.ts+++ b/src/renderer/components/speed-limit-modes.ts@@ -1,9 +1,14 @@+import {+ type MotrixIcon,+ SpeedAutoIcon,+ SpeedLimitedIcon,+ SpeedUnlimitedIcon,+} from '@renderer/components/icons'import type { TurtleState } from '@shared/types/settings'-import { type LucideIcon, Rabbit, Squirrel, Turtle } from 'lucide-react'/** Shared mode order and glyphs for the dashboard and Downloads controls. */export const SPEED_LIMIT_MODES = [- { id: 'off', Icon: Rabbit },- { id: 'on', Icon: Turtle },- { id: 'auto', Icon: Squirrel },-] as const satisfies ReadonlyArray<{ id: TurtleState; Icon: LucideIcon }>+ { id: 'off', Icon: SpeedUnlimitedIcon },+ { id: 'on', Icon: SpeedLimitedIcon },+ { id: 'auto', Icon: SpeedAutoIcon },+] as const satisfies ReadonlyArray<{ id: TurtleState; Icon: MotrixIcon }>diff --git a/src/renderer/components/task/magnet-file-selection-button.tsx b/src/renderer/components/task/magnet-file-selection-button.tsxindex f14dd7da..9e954c0a 100644--- a/src/renderer/components/task/magnet-file-selection-button.tsx+++ b/src/renderer/components/task/magnet-file-selection-button.tsx@@ -1,8 +1,8 @@+import { SelectFilesIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { toast } from '@renderer/components/ui/toast'import { openMagnetFileSelection } from '@renderer/lib/open-magnet-file-selection'import type { DownloadTask } from '@shared/types/task'-import { ListChecks } from 'lucide-react'import { useRef, useState } from 'react'import { useTranslation } from 'react-i18next'@@ -42,7 +42,7 @@ export function MagnetFileSelectionButton({ task }: { task: DownloadTask }) {void openSelection()}}>- <ListChecks />+ <SelectFilesIcon /><span className="truncate">{t('panel.downloads.action.selectFiles')}</span>diff --git a/src/renderer/components/task/task-status-badge.tsx b/src/renderer/components/task/task-status-badge.tsxindex 00b4befd..9f6707f1 100644--- a/src/renderer/components/task/task-status-badge.tsx+++ b/src/renderer/components/task/task-status-badge.tsx@@ -1,17 +1,17 @@+import {+ DownloadActiveIcon,+ FilesReadyIcon,+ LoadingIcon,+ PauseIcon,+ QueuedIcon,+ RemoveIcon,+ SeedStatusIcon,+ StatusCompleteIcon,+ StatusErrorIcon,+} from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'import { TaskStatus } from '@shared/types/task'import { cva, type VariantProps } from 'class-variance-authority'-import {- AlertCircle,- CheckCircle2,- Clock,- Download,- FileCheck2,- Loader2,- Pause,- Trash2,- Upload,-} from 'lucide-react'import type { ComponentType, SVGProps } from 'react'import { useTranslation } from 'react-i18next'@@ -42,26 +42,26 @@ interface StatusStyle {}const STATUS_STYLES: Record<TaskStatus, StatusStyle> = {- [TaskStatus.Queued]: { variant: 'outline', icon: Clock },+ [TaskStatus.Queued]: { variant: 'outline', icon: QueuedIcon },[TaskStatus.FetchingMetadata]: {variant: 'secondary',- icon: Loader2,+ icon: LoadingIcon,spin: true,},// Distinct icon (FileCheck2) + non-spinning so the user can tell at// a glance that the row is *waiting on them*, not on the network.- [TaskStatus.MetadataReady]: { variant: 'secondary', icon: FileCheck2 },- [TaskStatus.Downloading]: { variant: 'default', icon: Download },+ [TaskStatus.MetadataReady]: { variant: 'secondary', icon: FilesReadyIcon },+ [TaskStatus.Downloading]: { variant: 'default', icon: DownloadActiveIcon },[TaskStatus.Finalizing]: {variant: 'secondary',- icon: Loader2,+ icon: LoadingIcon,spin: true,},- [TaskStatus.Seeding]: { variant: 'default', icon: Upload },- [TaskStatus.Paused]: { variant: 'outline', icon: Pause },- [TaskStatus.Completed]: { variant: 'secondary', icon: CheckCircle2 },- [TaskStatus.Error]: { variant: 'destructive', icon: AlertCircle },- [TaskStatus.Removed]: { variant: 'outline', icon: Trash2 },+ [TaskStatus.Seeding]: { variant: 'default', icon: SeedStatusIcon },+ [TaskStatus.Paused]: { variant: 'outline', icon: PauseIcon },+ [TaskStatus.Completed]: { variant: 'secondary', icon: StatusCompleteIcon },+ [TaskStatus.Error]: { variant: 'destructive', icon: StatusErrorIcon },+ [TaskStatus.Removed]: { variant: 'outline', icon: RemoveIcon },}export interface TaskStatusBadgeProps {diff --git a/src/renderer/components/ui/autocomplete.tsx b/src/renderer/components/ui/autocomplete.tsxindex 41a3ffb2..3acb8fca 100644--- a/src/renderer/components/ui/autocomplete.tsx+++ b/src/renderer/components/ui/autocomplete.tsx@@ -1,6 +1,7 @@'use client'import { Autocomplete as AutocompletePrimitive } from '@base-ui/react'+import { CloseIcon } from '@renderer/components/icons'import {InputGroup,InputGroupAddon,@@ -8,7 +9,6 @@ import {InputGroupInput,} from '@renderer/components/ui/input-group'import { cn } from '@renderer/lib/utils'-import { XIcon } from 'lucide-react'const Autocomplete = AutocompletePrimitive.Root@@ -28,7 +28,7 @@ function AutocompleteClear({{...props}tabIndex={0}>- <XIcon aria-hidden="true" className="pointer-events-none" />+ <CloseIcon aria-hidden="true" className="pointer-events-none" /></AutocompletePrimitive.Clear>)}diff --git a/src/renderer/components/ui/checkbox.tsx b/src/renderer/components/ui/checkbox.tsxindex d1d4fd1c..95d8d6b6 100644--- a/src/renderer/components/ui/checkbox.tsx+++ b/src/renderer/components/ui/checkbox.tsx@@ -1,6 +1,6 @@import { Checkbox as CheckboxPrimitive } from '@base-ui/react/checkbox'+import { CheckIcon } from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'-import { CheckIcon } from 'lucide-react'function Checkbox({ className, ...props }: CheckboxPrimitive.Root.Props) {return (diff --git a/src/renderer/components/ui/combobox.tsx b/src/renderer/components/ui/combobox.tsxindex 7fecc39d..93b308ae 100644--- a/src/renderer/components/ui/combobox.tsx+++ b/src/renderer/components/ui/combobox.tsx@@ -1,6 +1,11 @@'use client'import { Combobox as ComboboxPrimitive } from '@base-ui/react'+import {+ CheckIcon,+ ChevronDownIcon,+ CloseIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {InputGroup,@@ -8,9 +13,7 @@ import {InputGroupButton,InputGroupInput,} from '@renderer/components/ui/input-group'-import { cn } from '@renderer/lib/utils'-import { CheckIcon, ChevronDownIcon, XIcon } from 'lucide-react'import * as React from 'react'const Combobox = ComboboxPrimitive.Root@@ -47,7 +50,7 @@ function ComboboxClear({ className, ...props }: ComboboxPrimitive.Clear.Props) {className={cn(className)}{...props}>- <XIcon className="pointer-events-none" />+ <CloseIcon className="pointer-events-none" /></ComboboxPrimitive.Clear>)}@@ -263,7 +266,7 @@ function ComboboxChip({className="-ml-1 opacity-50 hover:opacity-100"data-slot="combobox-chip-remove">- <XIcon className="pointer-events-none" />+ <CloseIcon className="pointer-events-none" /></ComboboxPrimitive.ChipRemove>)}</ComboboxPrimitive.Chip>diff --git a/src/renderer/components/ui/command.tsx b/src/renderer/components/ui/command.tsxindex bada6bcf..6e463d27 100644--- a/src/renderer/components/ui/command.tsx+++ b/src/renderer/components/ui/command.tsx@@ -1,6 +1,6 @@+import { SearchIcon } from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'import { Command as CommandPrimitive } from 'cmdk'-import { SearchIcon } from 'lucide-react'import type * as React from 'react'function Command({diff --git a/src/renderer/components/ui/dialog.tsx b/src/renderer/components/ui/dialog.tsxindex f10c9500..f737db6c 100644--- a/src/renderer/components/ui/dialog.tsx+++ b/src/renderer/components/ui/dialog.tsx@@ -1,8 +1,7 @@import { Dialog as DialogPrimitive } from '@base-ui/react/dialog'+import { CloseIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'-import { cn } from '@renderer/lib/utils'-import { XIcon } from 'lucide-react'import type * as React from 'react'function Dialog({ ...props }: DialogPrimitive.Root.Props) {@@ -70,7 +69,7 @@ function DialogContent({/>}>- <XIcon />+ <CloseIcon /><span className="sr-only">Close</span></DialogPrimitive.Close>)}diff --git a/src/renderer/components/ui/dropdown-menu.tsx b/src/renderer/components/ui/dropdown-menu.tsxindex 50f2db60..b9528a9d 100644--- a/src/renderer/components/ui/dropdown-menu.tsx+++ b/src/renderer/components/ui/dropdown-menu.tsx@@ -1,7 +1,11 @@import './menu-density.css'import { Menu as DropdownMenuPrimitive } from '@base-ui/react/menu'+import {+ CheckIcon,+ ChevronRightIcon,+ StatusDotIcon,+} from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'-import { CheckIcon, ChevronRightIcon, CircleIcon } from 'lucide-react'import type * as React from 'react'function DropdownMenu({@@ -153,7 +157,7 @@ function DropdownMenuRadioItem({{showIndicator && (<span className="pointer-events-none absolute left-2 flex size-3.5 items-center justify-center"><DropdownMenuPrimitive.RadioItemIndicator>- <CircleIcon className="size-2 fill-current" />+ <StatusDotIcon className="size-2 fill-current" /></DropdownMenuPrimitive.RadioItemIndicator></span>)}diff --git a/src/renderer/components/ui/native-select.tsx b/src/renderer/components/ui/native-select.tsxindex b6a2ff4e..29661ebb 100644--- a/src/renderer/components/ui/native-select.tsx+++ b/src/renderer/components/ui/native-select.tsx@@ -1,5 +1,5 @@+import { ChevronDownIcon } from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'-import { ChevronDownIcon } from 'lucide-react'import type * as React from 'react'function NativeSelect({diff --git a/src/renderer/components/ui/number-input.tsx b/src/renderer/components/ui/number-input.tsxindex 8ca2eda7..2badd391 100644--- a/src/renderer/components/ui/number-input.tsx+++ b/src/renderer/components/ui/number-input.tsx@@ -1,8 +1,8 @@+import { AddIcon, SubtractIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { ButtonGroup } from '@renderer/components/ui/button-group'import { Input } from '@renderer/components/ui/input'import { cn } from '@renderer/lib/utils'-import { Minus, Plus } from 'lucide-react'export interface NumberInputProps {value: number | undefined@@ -98,7 +98,7 @@ export function NumberInput({onClick={() => adjust(-step)}disabled={disabled || atMin}>- <Minus />+ <SubtractIcon /></Button><Buttonvariant="outline"@@ -108,7 +108,7 @@ export function NumberInput({onClick={() => adjust(step)}disabled={disabled || atMax}>- <Plus />+ <AddIcon /></Button></ButtonGroup>)diff --git a/src/renderer/components/ui/password-input.tsx b/src/renderer/components/ui/password-input.tsxindex f0e7812a..08a82774 100644--- a/src/renderer/components/ui/password-input.tsx+++ b/src/renderer/components/ui/password-input.tsx@@ -1,3 +1,4 @@+import { ConcealIcon, RevealIcon } from '@renderer/components/icons'import {InputGroup,InputGroupAddon,@@ -5,7 +6,6 @@ import {InputGroupInput,} from '@renderer/components/ui/input-group'import { cn } from '@renderer/lib/utils'-import { Eye, EyeOff } from 'lucide-react'import { useState } from 'react'export interface PasswordInputProps {@@ -64,7 +64,7 @@ export function PasswordInput({aria-pressed={revealed}onClick={() => setRevealed((v) => !v)}>- {revealed ? <EyeOff /> : <Eye />}+ {revealed ? <ConcealIcon /> : <RevealIcon />}</InputGroupButton></InputGroupAddon></InputGroup>diff --git a/src/renderer/components/ui/select.tsx b/src/renderer/components/ui/select.tsxindex dd381dd3..9bc8d9ca 100644--- a/src/renderer/components/ui/select.tsx+++ b/src/renderer/components/ui/select.tsx@@ -1,6 +1,10 @@import { Select as SelectPrimitive } from '@base-ui/react/select'+import {+ CheckIcon,+ ChevronDownIcon,+ ChevronUpIcon,+} from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'-import { CheckIcon, ChevronDownIcon, ChevronUpIcon } from 'lucide-react'import type * as React from 'react'const Select = SelectPrimitive.Rootdiff --git a/src/renderer/components/ui/severity-icons.ts b/src/renderer/components/ui/severity-icons.tsindex ef6cd5ef..16d6dbe5 100644--- a/src/renderer/components/ui/severity-icons.ts+++ b/src/renderer/components/ui/severity-icons.ts@@ -1,10 +1,10 @@-import type { LucideIcon } from 'lucide-react'+import type { MotrixIcon } from '@renderer/components/icons'import {- CircleCheckIcon,InfoIcon,- OctagonXIcon,- TriangleAlertIcon,-} from 'lucide-react'+ StatusBlockedIcon,+ StatusCompleteIcon,+ WarningIcon,+} from '@renderer/components/icons'/*** Severity icons and accents for toast feedback. The notification center@@ -15,10 +15,10 @@ export type SeverityIconKind = 'success' | 'info' | 'warning' | 'error'export const SEVERITY_ICONS: Record<SeverityIconKind,- { icon: LucideIcon; iconClassName: string }+ { icon: MotrixIcon; iconClassName: string }> = {- success: { icon: CircleCheckIcon, iconClassName: 'text-emerald-500' },+ success: { icon: StatusCompleteIcon, iconClassName: 'text-emerald-500' },info: { icon: InfoIcon, iconClassName: 'text-sky-500' },- warning: { icon: TriangleAlertIcon, iconClassName: 'text-amber-500' },- error: { icon: OctagonXIcon, iconClassName: 'text-destructive' },+ warning: { icon: WarningIcon, iconClassName: 'text-amber-500' },+ error: { icon: StatusBlockedIcon, iconClassName: 'text-destructive' },}diff --git a/src/renderer/components/ui/sheet.tsx b/src/renderer/components/ui/sheet.tsxindex cf0e63cd..0f75fdb0 100644--- a/src/renderer/components/ui/sheet.tsx+++ b/src/renderer/components/ui/sheet.tsx@@ -1,8 +1,8 @@'use client'import { Dialog as SheetPrimitive } from '@base-ui/react/dialog'+import { CloseIcon } from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'-import { XIcon } from 'lucide-react'import type * as React from 'react'function Sheet({ ...props }: React.ComponentProps<typeof SheetPrimitive.Root>) {@@ -75,7 +75,7 @@ function SheetContent({{children}{showCloseButton && (<SheetPrimitive.Close className="absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:ring-2 focus:ring-ring focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none data-open:bg-secondary">- <XIcon className="size-4" />+ <CloseIcon className="size-4" /><span className="sr-only">Close</span></SheetPrimitive.Close>)}diff --git a/src/renderer/components/ui/sidebar.tsx b/src/renderer/components/ui/sidebar.tsxindex 49f013bd..d8be95b2 100644--- a/src/renderer/components/ui/sidebar.tsx+++ b/src/renderer/components/ui/sidebar.tsx@@ -1,5 +1,6 @@import { mergeProps } from '@base-ui/react/merge-props'import { useRender } from '@base-ui/react/use-render'+import { SidebarIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { Input } from '@renderer/components/ui/input'import { Separator } from '@renderer/components/ui/separator'@@ -19,7 +20,6 @@ import {import { useIsMobile } from '@renderer/hooks/use-mobile'import { cn } from '@renderer/lib/utils'import { cva, type VariantProps } from 'class-variance-authority'-import { PanelLeftIcon } from 'lucide-react'import * as React from 'react'const SIDEBAR_STATE_KEY = 'sidebar_state'@@ -294,7 +294,7 @@ function SidebarTrigger({}}{...props}>- <PanelLeftIcon className="transition-opacity" />+ <SidebarIcon className="transition-opacity" /><span className="sr-only">Toggle Sidebar</span></Button>)diff --git a/src/renderer/components/ui/spinner.tsx b/src/renderer/components/ui/spinner.tsxindex f4049322..1fda3ee3 100644--- a/src/renderer/components/ui/spinner.tsx+++ b/src/renderer/components/ui/spinner.tsx@@ -1,9 +1,9 @@+import { LoadingIcon } from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'-import { Loader2Icon } from 'lucide-react'function Spinner({ className, ...props }: React.ComponentProps<'svg'>) {return (- <Loader2Icon+ <LoadingIconrole="status"aria-label="Loading"className={cn('size-4 animate-spin', className)}diff --git a/src/renderer/components/ui/toast.tsx b/src/renderer/components/ui/toast.tsxindex 99b25ac8..b9e3ca64 100644--- a/src/renderer/components/ui/toast.tsx+++ b/src/renderer/components/ui/toast.tsx@@ -1,5 +1,6 @@import { Toast } from '@base-ui/react/toast'import { CopyButton } from '@renderer/components/desktop-kit/copy-button'+import { CloseIcon } from '@renderer/components/icons'import { Badge } from '@renderer/components/ui/badge'import { Button } from '@renderer/components/ui/button'import { SEVERITY_ICONS } from '@renderer/components/ui/severity-icons'@@ -14,7 +15,6 @@ import type {IdentityTriState,PairRequestPayload,} from '@shared/protocol/bridge'-import { XIcon } from 'lucide-react'import { useTranslation } from 'react-i18next'export type AppToastType = 'success' | 'info' | 'warning' | 'error'@@ -146,7 +146,7 @@ function ToastList() {aria-label={t('common.close')}className="shrink-0 rounded-md p-1 text-muted-foreground hover:bg-accent hover:text-foreground">- <XIcon className="size-3.5" />+ <CloseIcon className="size-3.5" /></Toast.Close>)@@ -281,7 +281,7 @@ function ToastList() {aria-label={t('common.close')}className="shrink-0 rounded-md p-1 text-muted-foreground hover:bg-accent hover:text-foreground">- <XIcon className="size-3.5" />+ <CloseIcon className="size-3.5" /></Toast.Close></Toast.Root>)diff --git a/src/renderer/components/window-chrome/add-task-trigger-button.tsx b/src/renderer/components/window-chrome/add-task-trigger-button.tsxindex 747376f8..e3cbc613 100644--- a/src/renderer/components/window-chrome/add-task-trigger-button.tsx+++ b/src/renderer/components/window-chrome/add-task-trigger-button.tsx@@ -1,3 +1,4 @@+import { AddIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {Tooltip,@@ -6,7 +7,6 @@ import {} from '@renderer/components/ui/tooltip'import { openAddTaskDialog } from '@renderer/lib/open-add-task-dialog'import { cn } from '@renderer/lib/utils'-import { Plus } from 'lucide-react'import type React from 'react'import { useTranslation } from 'react-i18next'@@ -33,7 +33,7 @@ export function AddTaskTriggerButton({/>}>- <Plus className="size-4" />+ <AddIcon className="size-4" /></TooltipTrigger><TooltipContent>{t('chrome.newTask')}</TooltipContent></Tooltip>diff --git a/src/renderer/components/window-chrome/motrix-logo.tsx b/src/renderer/components/window-chrome/motrix-logo.tsxindex 36159c7a..b0a3a23d 100644--- a/src/renderer/components/window-chrome/motrix-logo.tsx+++ b/src/renderer/components/window-chrome/motrix-logo.tsx@@ -1,4 +1,4 @@-import { ChevronDown } from 'lucide-react'+import { ChevronDownIcon } from '@renderer/components/icons'export function MotrixLogo() {return (@@ -18,7 +18,7 @@ export function MotrixLogo() {WebkitMaskSize: 'contain',}}/>- <ChevronDown aria-hidden="true" className="size-3 shrink-0" />+ <ChevronDownIcon aria-hidden="true" className="size-3 shrink-0" /></>)}diff --git a/src/renderer/components/window-chrome/motrix-menu-button.tsx b/src/renderer/components/window-chrome/motrix-menu-button.tsxindex ff53c541..bd873013 100644--- a/src/renderer/components/window-chrome/motrix-menu-button.tsx+++ b/src/renderer/components/window-chrome/motrix-menu-button.tsx@@ -1,3 +1,4 @@+import { ArrowLeftIcon, ChevronRightIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {DropdownMenu,@@ -22,7 +23,6 @@ import type {ApplicationMenuNode,ExecuteApplicationMenuItemRequest,} from '@shared/schemas/application-menu'-import { ArrowLeft, ChevronRight } from 'lucide-react'import {type MouseEvent as ReactMouseEvent,type ReactNode,@@ -170,7 +170,7 @@ function MenuTree({ items, queueExecution, enterSubmenu }: MenuTreeProps) {onClick={() => enterSubmenu(item)}><ItemLabel item={item} />- <ChevronRight className="ms-auto size-3" />+ <ChevronRightIcon className="ms-auto size-3" /></DropdownMenuItem>)continue@@ -419,7 +419,7 @@ function ElectronMotrixMenuButton() {closeOnClick={false}onClick={() => setStack((items) => items.slice(0, -1))}>- <ArrowLeft className="size-3" />+ <ArrowLeftIcon className="size-3" />{t('applicationMenu.back')}</DropdownMenuItem><DropdownMenuSeparator />diff --git a/src/renderer/features/application-menu/web-menu-button.tsx b/src/renderer/features/application-menu/web-menu-button.tsxindex 688dcdf1..abf584c6 100644--- a/src/renderer/features/application-menu/web-menu-button.tsx+++ b/src/renderer/features/application-menu/web-menu-button.tsx@@ -1,5 +1,6 @@import './application-menu.css'import { useAddTaskDialogStore } from '@renderer/components/add-task-dialog/use-add-task-dialog-store'+import { ArrowLeftIcon, ChevronRightIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {DropdownMenu,@@ -31,7 +32,6 @@ import {type BulkTaskCommandResult,isStoppedTaskStatus,} from '@shared/types/task-actions'-import { ArrowLeft, ChevronRight } from 'lucide-react'import {type ReactNode,useCallback,@@ -260,7 +260,7 @@ export function WebMenuButton() {onClick={() => setLevel(section)}>{t(`menu.${section}.title`)}- <ChevronRight className="ms-auto size-3" />+ <ChevronRightIcon className="ms-auto size-3" /></DropdownMenuItem>) : (<DropdownMenuSub key={section}>@@ -372,7 +372,7 @@ export function WebMenuButton() {closeOnClick={false}onClick={() => setLevel(null)}>- <ArrowLeft className="size-3" />+ <ArrowLeftIcon className="size-3" />{t('applicationMenu.back')}</DropdownMenuItem><DropdownMenuSeparator />diff --git a/src/renderer/features/directory-preferences/directory-preferences-section.tsx b/src/renderer/features/directory-preferences/directory-preferences-section.tsxindex 3e7f292b..90536ca5 100644--- a/src/renderer/features/directory-preferences/directory-preferences-section.tsx+++ b/src/renderer/features/directory-preferences/directory-preferences-section.tsx@@ -1,3 +1,10 @@+import {+ ChevronRightIcon,+ FavoriteIcon,+ FolderAddIcon,+ FolderIcon,+ RemoveIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {Collapsible,@@ -11,7 +18,6 @@ import {type DirectoryPreferences,} from '@shared/schemas/directory-preferences'import type { GeneralSettingsErrorCode } from '@shared/schemas/general-settings'-import { ChevronRight, Folder, FolderPlus, Star, Trash2 } from 'lucide-react'import { useEffect, useLayoutEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'@@ -154,7 +160,7 @@ export function DirectoryPreferencesSection({const favorite = preferences.favorites.includes(path)return (<li key={path} className="flex items-center gap-2 px-2 py-1">- <Folder className="size-4 shrink-0 text-muted-foreground" />+ <FolderIcon className="size-4 shrink-0 text-muted-foreground" /><spandir="ltr"title={path}@@ -181,7 +187,9 @@ export function DirectoryPreferencesSection({})}>- <Star className={favorite ? 'fill-current' : undefined} />+ <FavoriteIcon+ className={favorite ? 'fill-current' : undefined}+ /></Button>)}<Button@@ -213,7 +221,7 @@ export function DirectoryPreferencesSection({)}>- <Trash2 />+ <RemoveIcon /></Button></li>)@@ -239,7 +247,7 @@ export function DirectoryPreferencesSection({disabled={busy}className="flex min-w-0 items-center gap-1 text-xs font-medium">- <ChevronRight+ <ChevronRightIconclassName={`size-3.5 shrink-0 ${favoritesOpen ? 'rotate-90' : ''}`}/>{t('directoryPreferences.favorites')}@@ -255,7 +263,7 @@ export function DirectoryPreferencesSection({disabled={busy || full}onClick={() => void addFavorite()}>- <FolderPlus />+ <FolderAddIcon />{t('directoryPreferences.addFavorite')}</Button></div>@@ -276,7 +284,7 @@ export function DirectoryPreferencesSection({disabled={busy}className="flex min-w-0 items-center gap-1 text-xs font-medium">- <ChevronRight+ <ChevronRightIconclassName={`size-3.5 shrink-0 ${recentOpen ? 'rotate-90' : ''}`}/>{t('directoryPreferences.recent')}diff --git a/src/renderer/features/engine-diagnostics/engine-diagnostics-dialog.tsx b/src/renderer/features/engine-diagnostics/engine-diagnostics-dialog.tsxindex 4d4edb84..408c8923 100644--- a/src/renderer/features/engine-diagnostics/engine-diagnostics-dialog.tsx+++ b/src/renderer/features/engine-diagnostics/engine-diagnostics-dialog.tsx@@ -1,4 +1,13 @@import { CopyButton } from '@renderer/components/desktop-kit/copy-button'+import {+ ChevronRightIcon,+ CloseIcon,+ DiagnosticReportIcon,+ LoadingIcon,+ ResetIcon,+ StatusCompleteIcon,+ StatusFailedIcon,+} from '@renderer/components/icons'import {AlertDialog,AlertDialogAction,@@ -50,15 +59,6 @@ import {type EngineRecoveryResult,EngineState,} from '@shared/types/engine'-import {- CheckCircle2,- ChevronRight,- CircleX,- FileText,- LoaderCircle,- RotateCcw,- X,-} from 'lucide-react'import { type ReactNode, useCallback, useEffect, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import {@@ -253,10 +253,10 @@ export function EngineDiagnosticsDialogHost() {}): t(`${key}.runtime.${connection}`)const StatusIcon = healthy- ? CheckCircle2+ ? StatusCompleteIcon: transitioning- ? LoaderCircle- : CircleX+ ? LoadingIcon+ : StatusFailedIconconst version = report?.binary.versionconst engineName = version?.includes('-motrix.')? t(`${key}.motrixEngine`)@@ -314,7 +314,7 @@ export function EngineDiagnosticsDialogHost() {: void recover(EngineRecoveryAction.RestoreDefaultPort)}>- <RotateCcw aria-hidden="true" />+ <ResetIcon aria-hidden="true" /></Button></span>}@@ -373,7 +373,7 @@ export function EngineDiagnosticsDialogHost() {/>}>- <X aria-hidden="true" />+ <CloseIcon aria-hidden="true" /></DialogClose></div></DialogHeader>@@ -397,7 +397,7 @@ export function EngineDiagnosticsDialogHost() {role="status"className="flex items-center justify-center gap-2 py-10 text-sm text-muted-foreground">- <LoaderCircle+ <LoadingIconaria-hidden="true"className="size-4 animate-spin"/>@@ -492,7 +492,7 @@ export function EngineDiagnosticsDialogHost() {className="mt-3 mb-2"><CollapsibleTrigger className="group -mx-3 flex min-h-12 w-[calc(100%+1.5rem)] items-center gap-3 rounded-lg px-3 py-2.5 text-left outline-none focus-visible:ring-2 focus-visible:ring-ring">- <FileText+ <DiagnosticReportIconaria-hidden="true"className="size-4 shrink-0 text-muted-foreground"/>@@ -505,7 +505,7 @@ export function EngineDiagnosticsDialogHost() {{engineName} {version ?? t(`${key}.versionUnknown`)}</span></span>- <ChevronRight+ <ChevronRightIconaria-hidden="true"className="size-3.5 shrink-0 text-muted-foreground transition-transform duration-150 group-data-panel-open:rotate-90 motion-reduce:transition-none"/>@@ -619,7 +619,7 @@ export function EngineDiagnosticsDialogHost() {onClick={load}>{loading && (- <LoaderCircle aria-hidden="true" className="animate-spin" />+ <LoadingIcon aria-hidden="true" className="animate-spin" />)}{t(`${key}.runAgain`)}</Button>@@ -642,7 +642,7 @@ export function EngineDiagnosticsDialogHost() {}>{recovering && (- <LoaderCircle aria-hidden="true" className="animate-spin" />+ <LoadingIcon aria-hidden="true" className="animate-spin" />)}{actionLabel}</Button>diff --git a/src/renderer/features/web-directory-picker/web-directory-picker-dialog.tsx b/src/renderer/features/web-directory-picker/web-directory-picker-dialog.tsxindex eb959fe4..6822e24d 100644--- a/src/renderer/features/web-directory-picker/web-directory-picker-dialog.tsx+++ b/src/renderer/features/web-directory-picker/web-directory-picker-dialog.tsx@@ -1,5 +1,16 @@import type { VirtualListHandle } from '@renderer/components/desktop-kit/virtual-list/types'import { VirtualList } from '@renderer/components/desktop-kit/virtual-list/virtual-list'+import {+ AdjustIcon,+ ChevronLeftIcon,+ ChevronRightIcon,+ CloseIcon,+ EditIcon,+ FavoriteIcon,+ FolderIcon,+ ParentFolderIcon,+ RefreshIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {Dialog,@@ -33,17 +44,6 @@ import {__webPathPickerBus,type PickRequest,} from '@renderer/platform/web-services'-import {- ArrowUp,- ChevronLeft,- ChevronRight,- Folder,- Pencil,- RefreshCw,- SlidersHorizontal,- Star,- X,-} from 'lucide-react'import {type KeyboardEvent,memo,@@ -516,9 +516,9 @@ function PickerSession({ request, controller }: Session) {}>{group.id === 'favorites' ? (- <Star className="size-4 shrink-0 text-muted-foreground" />+ <FavoriteIcon className="size-4 shrink-0 text-muted-foreground" />) : (- <Folder className="size-4 shrink-0 text-muted-foreground" />+ <FolderIcon className="size-4 shrink-0 text-muted-foreground" />)}<span dir="ltr" className="truncate whitespace-pre">{entry.name}@@ -555,7 +555,7 @@ function PickerSession({ request, controller }: Session) {/>}>- <X />+ <CloseIcon /></DialogClose></div><div@@ -571,7 +571,7 @@ function PickerSession({ request, controller }: Session) {disabled={locked || state.historyIndex <= 0}onClick={() => controller.history(-1)}>- <ChevronLeft />+ <ChevronLeftIcon /></Button><Buttonvariant="ghost"@@ -584,7 +584,7 @@ function PickerSession({ request, controller }: Session) {}onClick={() => controller.history(1)}>- <ChevronRight />+ <ChevronRightIcon /></Button><Buttonvariant="ghost"@@ -595,7 +595,7 @@ function PickerSession({ request, controller }: Session) {disabled={locked || !state.listing?.parentPath}onClick={() => controller.up()}>- <ArrowUp />+ <ParentFolderIcon /></Button><div className="flex min-w-0 flex-1 items-center gap-1">{editor?.kind === 'path' ? (@@ -702,7 +702,7 @@ function PickerSession({ request, controller }: Session) {className="size-6 shrink-0"onClick={() => controller.editPath()}>- <Pencil />+ <EditIcon /></Button></InputGroup>)}@@ -735,7 +735,9 @@ function PickerSession({ request, controller }: Session) {aria-busy={state.favoriteBusy}onClick={() => void controller.toggleFavorite()}>- <Star className={favorite ? 'fill-current' : undefined} />+ <FavoriteIcon+ className={favorite ? 'fill-current' : undefined}+ /></Button>)}<Button@@ -747,7 +749,7 @@ function PickerSession({ request, controller }: Session) {disabled={locked}onClick={() => controller.refresh()}>- <RefreshCw+ <RefreshIconclassName={state.busy === 'navigate'? 'animate-spin motion-reduce:animate-none'@@ -780,7 +782,7 @@ function PickerSession({ request, controller }: Session) {aria-label={t('directoryPicker.viewOptions')}title={t('directoryPicker.viewOptions')}>- <SlidersHorizontal />+ <AdjustIcon /></DropdownMenuTrigger><DropdownMenuContentalign="end"@@ -959,7 +961,7 @@ function PickerSession({ request, controller }: Session) {{editor?.kind === 'name' && (<div className="shrink-0 space-y-2 border-b px-3 py-2"><div className="flex items-center gap-2">- <Folder className="size-4 shrink-0 text-muted-foreground" />+ <FolderIcon className="size-4 shrink-0 text-muted-foreground" /><Inputref={editorRef}aria-label={t('directoryPicker.folderName')}@@ -1198,7 +1200,7 @@ const DirectoryEntries = memo(function DirectoryEntries({onClick={() => controller.select(item.path)}onDoubleClick={() => controller.navigate(item.path)}>- <Folder+ <FolderIconaria-hiddenclassName="size-4 shrink-0 text-muted-foreground"/>diff --git a/src/renderer/hooks/use-sidebar-color.test.tsx b/src/renderer/hooks/use-sidebar-color.test.tsxnew file mode 100644index 00000000..5afb87f2--- /dev/null+++ b/src/renderer/hooks/use-sidebar-color.test.tsx@@ -0,0 +1,118 @@+import { refreshRendererSettings } from '@renderer/lib/settings-refresh'+import { useSidebarColorState } from '@renderer/lib/sidebar-color'+import { transport } from '@renderer/lib/transport'+import { Events } from '@shared/protocol/events'+import { act, renderHook, waitFor } from '@testing-library/react'+import { beforeEach, expect, it, vi } from 'vitest'+import { useSidebarColor } from './use-sidebar-color'++vi.mock('@renderer/lib/transport', () => ({+ transport: {+ invoke: vi.fn(),+ on: vi.fn(),+ off: vi.fn(),+ onConnectionChange: vi.fn(() => () => {}),+ },+}))+beforeEach(() => {+ vi.clearAllMocks()+ useSidebarColorState.setState({ saved: 'gray', preview: null, revision: 0 })+})+it('hydrates, previews, restores, and refreshes the saved tint after reconnect', async () => {+ vi.mocked(transport.invoke).mockResolvedValue({+ app: { sidebarColor: 'pink' },+ })+ const { unmount } = renderHook(useSidebarColor)+ await waitFor(() =>+ expect(document.documentElement.dataset.sidebarColor).toBe('pink')+ )+ act(() => useSidebarColorState.setState({ preview: 'cyan' }))+ expect(document.documentElement.dataset.sidebarColor).toBe('cyan')+ vi.mocked(transport.invoke).mockResolvedValue({+ app: { sidebarColor: 'gold' },+ })+ const change = vi+ .mocked(transport.on)+ .mock.calls.find(([event]) => event === Events.SidebarColorChanged)![1]+ await act(async () => change())+ expect(document.documentElement.dataset.sidebarColor).toBe('cyan')+ act(() => useSidebarColorState.setState({ preview: null }))+ expect(document.documentElement.dataset.sidebarColor).toBe('gold')+ vi.mocked(transport.invoke).mockResolvedValue({+ app: { sidebarColor: 'green' },+ })+ await act(async () => {+ for (const [callback] of vi.mocked(transport.onConnectionChange!).mock+ .calls) {+ callback({ state: 'connected' })+ }+ })+ expect(document.documentElement.dataset.sidebarColor).toBe('green')+ unmount()+ expect(transport.off).toHaveBeenCalledWith(Events.SidebarColorChanged, change)+})+it('does not let a delayed snapshot overwrite a just-saved color', async () => {+ let resolve!: (value: unknown) => void+ vi.mocked(transport.invoke).mockImplementation(+ () =>+ new Promise((done) => {+ resolve = done+ })+ )+ renderHook(useSidebarColor)+ act(() => useSidebarColorState.setState({ saved: 'violet', revision: 1 }))+ await act(async () => resolve({ app: { sidebarColor: 'gray' } }))+ expect(document.documentElement.dataset.sidebarColor).toBe('violet')+})++it('refreshes saved colors without a host event after a local settings save', async () => {+ vi.mocked(transport.invoke).mockResolvedValue({+ app: { sidebarColor: 'gray' },+ })+ renderHook(useSidebarColor)+ await waitFor(() =>+ expect(document.documentElement.dataset.sidebarColor).toBe('gray')+ )+ vi.mocked(transport.invoke).mockResolvedValue({+ app: { sidebarColor: 'blue' },+ })+ await act(async () => refreshRendererSettings())+ expect(document.documentElement.dataset.sidebarColor).toBe('blue')+})++it('follows system accent changes in Auto and leaves manual choices independent', async () => {+ const { Queries } = await import('@shared/protocol/queries')+ let accent: string | null = '#ff0000'+ vi.mocked(transport.invoke).mockImplementation(async (channel) =>+ channel === Queries.GetSystemAccentColor+ ? accent+ : { app: { sidebarColor: 'auto' } }+ )+ renderHook(useSidebarColor)+ await waitFor(() =>+ expect(document.documentElement.dataset.sidebarColor).toBe('auto')+ )+ expect(document.documentElement.style.getPropertyValue('--sidebar-hue')).toBe(+ '0'+ )+ const refresh = vi+ .mocked(transport.on)+ .mock.calls.find(([event]) => event === Events.SystemAccentColorChanged)![1]+ accent = '#00ff00'+ await act(async () => refresh())+ expect(document.documentElement.style.getPropertyValue('--sidebar-hue')).toBe(+ '120'+ )+ act(() => useSidebarColorState.setState({ preview: 'pink' }))+ accent = '#0000ff'+ await act(async () => refresh())+ expect(document.documentElement.dataset.sidebarColor).toBe('pink')+ expect(document.documentElement.style.getPropertyValue('--sidebar-hue')).toBe(+ ''+ )+ act(() => useSidebarColorState.setState({ preview: null }))+ expect(document.documentElement.dataset.sidebarColor).toBe('auto')+ accent = null+ await act(async () => refresh())+ expect(document.documentElement.dataset.sidebarColor).toBe('gray')+})diff --git a/src/renderer/hooks/use-sidebar-color.ts b/src/renderer/hooks/use-sidebar-color.tsnew file mode 100644index 00000000..f8708f58--- /dev/null+++ b/src/renderer/hooks/use-sidebar-color.ts@@ -0,0 +1,61 @@+import { useSidebarColorState } from '@renderer/lib/sidebar-color'+import { systemAccentHue } from '@renderer/lib/system-accent-color'+import { transport } from '@renderer/lib/transport'+import { Events } from '@shared/protocol/events'+import { Queries } from '@shared/protocol/queries'+import { sidebarColorSchema } from '@shared/schemas/sidebar-color'+import type { AppSettings } from '@shared/types/settings'+import { useEffect, useState } from 'react'+import { useTransportMirror } from './use-transport-mirror'++export function useSidebarColor() {+ const color = useSidebarColorState((state) => state.preview ?? state.saved)+ const [systemAccent, setSystemAccent] = useState<string | null>(null)+ useTransportMirror({+ events: [Events.SystemAccentColorChanged],+ load: async (stale) => {+ const accent = await transport.invoke(Queries.GetSystemAccentColor)+ if (!stale()) {+ setSystemAccent(+ typeof accent === 'string' && /^#[\da-f]{6}$/i.test(accent)+ ? accent+ : null+ )+ }+ },+ })+ useTransportMirror({+ events: [Events.SidebarColorChanged],+ refreshOnSettingsSave: true,+ load: async (stale, read) => {+ const revision = useSidebarColorState.getState().revision+ const settings = (await read(Queries.GetSettings)) as+ | AppSettings+ | undefined+ if (stale() || revision !== useSidebarColorState.getState().revision)+ return+ useSidebarColorState.setState({+ saved: sidebarColorSchema+ .catch('gray')+ .parse(settings?.app?.sidebarColor),+ })+ },+ })+ useEffect(() => {+ const root = document.documentElement+ const hue = systemAccentHue(systemAccent)+ root.dataset.sidebarColor =+ color === 'auto' && hue === null ? 'gray' : color+ if (color === 'auto' && hue !== null)+ root.style.setProperty('--sidebar-hue', String(hue))+ else root.style.removeProperty('--sidebar-hue')+ if (systemAccent)+ root.style.setProperty('--system-accent-color', systemAccent)+ else root.style.removeProperty('--system-accent-color')+ return () => {+ delete root.dataset.sidebarColor+ root.style.removeProperty('--sidebar-hue')+ root.style.removeProperty('--system-accent-color')+ }+ }, [color, systemAccent])+}diff --git a/src/renderer/layouts/app-layout.tsx b/src/renderer/layouts/app-layout.tsxindex 85aa36ec..4f0a42ac 100644--- a/src/renderer/layouts/app-layout.tsx+++ b/src/renderer/layouts/app-layout.tsx@@ -15,6 +15,7 @@ import { useEngineRestartRequiredToast } from '@renderer/hooks/use-engine-restarimport { useIpcEvent } from '@renderer/hooks/use-ipc-event'import { useMenuContextSync } from '@renderer/hooks/use-menu-context-sync'import { useNotificationToasts } from '@renderer/hooks/use-notification-toasts'+import { useSidebarColor } from '@renderer/hooks/use-sidebar-color'import { useToastEvents } from '@renderer/hooks/use-toast-events'import { cn } from '@renderer/lib/utils'import { electronServices } from '@renderer/platform/electron-services'@@ -38,6 +39,7 @@ function DesktopMenuContext() {}export function AppLayout() {+ useSidebarColor()useToastEvents()usePairRequestPrompts()useEngineRestartRequiredToast()diff --git a/src/renderer/lib/sidebar-color.ts b/src/renderer/lib/sidebar-color.tsnew file mode 100644index 00000000..c34ab96c--- /dev/null+++ b/src/renderer/lib/sidebar-color.ts@@ -0,0 +1,9 @@+import type { SidebarColor } from '@shared/schemas/sidebar-color'+import { create } from 'zustand'++/** Persisted transport mirror plus the appearance dialog's temporary preview. */+export const useSidebarColorState = create<{+ saved: SidebarColor+ preview: SidebarColor | null+ revision: number+}>(() => ({ saved: 'gray', preview: null, revision: 0 }))diff --git a/src/renderer/lib/system-accent-color.test.ts b/src/renderer/lib/system-accent-color.test.tsnew file mode 100644index 00000000..90d35501--- /dev/null+++ b/src/renderer/lib/system-accent-color.test.ts@@ -0,0 +1,11 @@+import { expect, it } from 'vitest'+import { systemAccentHue } from './system-accent-color'++it('uses the real system hue and keeps neutral or unavailable accents gray', () => {+ expect(systemAccentHue('#ff0000')).toBe(0)+ expect(systemAccentHue('#00ff00')).toBe(120)+ expect(systemAccentHue('#0000ff')).toBe(240)+ expect(systemAccentHue('#888888')).toBeNull()+ expect(systemAccentHue(null)).toBeNull()+ expect(systemAccentHue('url(example.com)')).toBeNull()+})diff --git a/src/renderer/lib/system-accent-color.ts b/src/renderer/lib/system-accent-color.tsnew file mode 100644index 00000000..933e6d49--- /dev/null+++ b/src/renderer/lib/system-accent-color.ts@@ -0,0 +1,18 @@+/** Turn a host-provided RGB accent into a quiet glass hue; neutral colors stay gray. */+export function systemAccentHue(color: unknown): number | null {+ if (typeof color !== 'string' || !/^#[\da-f]{6}$/i.test(color)) return null+ const r = Number.parseInt(color.slice(1, 3), 16) / 255+ const g = Number.parseInt(color.slice(3, 5), 16) / 255+ const b = Number.parseInt(color.slice(5, 7), 16) / 255+ const max = Math.max(r, g, b)+ const min = Math.min(r, g, b)+ const delta = max - min+ if (delta < 0.06) return null+ const hue =+ max === r+ ? (g - b) / delta+ : max === g+ ? (b - r) / delta + 2+ : (r - g) / delta + 4+ return (hue * 60 + 360) % 360+}diff --git a/src/renderer/lib/task-type-meta.ts b/src/renderer/lib/task-type-meta.tsindex 3da02082..9883817a 100644--- a/src/renderer/lib/task-type-meta.ts+++ b/src/renderer/lib/task-type-meta.ts@@ -1,25 +1,28 @@-import { TaskType } from '@shared/types/task'import {- FileDown,- Globe,- type LucideIcon,- Magnet,- Package,- Server,-} from 'lucide-react'+ HttpIcon,+ MagnetIcon,+ MetalinkIcon,+ type MotrixIcon,+ ServerIcon,+ TorrentFileIcon,+} from '@renderer/components/icons'+import { TaskType } from '@shared/types/task'export interface TaskTypeMeta {- icon: LucideIcon+ icon: MotrixIconlabelKey: string}export const TASK_TYPE_META: Record<TaskType, TaskTypeMeta> = {- [TaskType.Http]: { icon: Globe, labelKey: 'panel.downloads.type.http' },- [TaskType.Magnet]: { icon: Magnet, labelKey: 'panel.downloads.type.magnet' },- [TaskType.Bt]: { icon: FileDown, labelKey: 'panel.downloads.type.bt' },- [TaskType.Ftp]: { icon: Server, labelKey: 'panel.downloads.type.ftp' },+ [TaskType.Http]: { icon: HttpIcon, labelKey: 'panel.downloads.type.http' },+ [TaskType.Magnet]: {+ icon: MagnetIcon,+ labelKey: 'panel.downloads.type.magnet',+ },+ [TaskType.Bt]: { icon: TorrentFileIcon, labelKey: 'panel.downloads.type.bt' },+ [TaskType.Ftp]: { icon: ServerIcon, labelKey: 'panel.downloads.type.ftp' },[TaskType.Metalink]: {- icon: Package,+ icon: MetalinkIcon,labelKey: 'panel.downloads.type.metalink',},}diff --git a/src/renderer/routes/dashboard/components/dashboard-grid.tsx b/src/renderer/routes/dashboard/components/dashboard-grid.tsxindex c8525bc0..f33590be 100644--- a/src/renderer/routes/dashboard/components/dashboard-grid.tsx+++ b/src/renderer/routes/dashboard/components/dashboard-grid.tsx@@ -3,6 +3,15 @@ import { COMPACT_ACTION_CLASS } from '@renderer/components/desktop-kit/panel/heaimport { Toolbar } from '@renderer/components/desktop-kit/toolbar/toolbar'import { ToolbarButton } from '@renderer/components/desktop-kit/toolbar/toolbar-button'import { ToolbarGroup } from '@renderer/components/desktop-kit/toolbar/toolbar-group'+import {+ AddIcon,+ AdjustIcon,+ CheckIcon,+ CloseIcon,+ LayoutTemplateIcon,+ ResetIcon,+ UndoIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {DropdownMenu,@@ -31,15 +40,6 @@ import type {DashboardTileSpan,DashboardTileWidth,} from '@shared/types/settings'-import {- Check,- LayoutTemplate,- Plus,- RotateCcw,- SlidersHorizontal,- Undo2,- X,-} from 'lucide-react'import type React from 'react'import { useCallback, useEffect, useId, useMemo, useRef, useState } from 'react'import { flushSync } from 'react-dom'@@ -706,7 +706,7 @@ function AddTileMenu({disabled={disabled}render={<DropdownMenuTrigger />}>- <Plus aria-hidden />+ <AddIcon aria-hidden /></ToolbarButton><DropdownMenuContentalign="end"@@ -755,7 +755,7 @@ function AddTileMenu({</span></span>{available ? (- <Plus+ <AddIconaria-hiddenclassName="size-3.5 text-muted-foreground opacity-0 group-data-highlighted/layout-option:opacity-100"/>@@ -808,7 +808,7 @@ function PresetMenu({className="w-auto gap-1.5 px-2.5 compact-header:size-6 compact-header:p-0"render={<DropdownMenuTrigger />}>- <LayoutTemplate aria-hidden />+ <LayoutTemplateIcon aria-hidden /><span className="max-w-32 truncate compact-header:hidden">{currentLabel}</span>@@ -828,7 +828,7 @@ function PresetMenu({{t(preset.titleKey)}</span>{currentPresetId === preset.id ? (- <Check className="size-3.5 shrink-0" aria-hidden />+ <CheckIcon className="size-3.5 shrink-0" aria-hidden />) : null}</DropdownMenuItem>))}@@ -836,7 +836,7 @@ function PresetMenu({<><DropdownMenuSeparator /><DropdownMenuItem className="rounded-lg text-xs" onClick={onUndo}>- <Undo2 aria-hidden />+ <UndoIcon aria-hidden />{undoLabel}</DropdownMenuItem></>@@ -1414,14 +1414,14 @@ export function DashboardGrid({onClick={cancelEditing}disabled={saving}>- <X aria-hidden />+ <CloseIcon aria-hidden /></ToolbarButton><ToolbarButtonlabel={label.reset}onClick={resetDraft}disabled={saving}>- <RotateCcw aria-hidden />+ <ResetIcon aria-hidden /></ToolbarButton><ToolbarButtonlabel={label.apply}@@ -1429,7 +1429,7 @@ export function DashboardGrid({onClick={() => void applyDraft()}disabled={saving}>- <Check aria-hidden />+ <CheckIcon aria-hidden /><span className="compact-header:hidden">{label.apply}</span></ToolbarButton></ToolbarGroup>@@ -1471,7 +1471,7 @@ export function DashboardGrid({/>}>- <SlidersHorizontal aria-hidden className="size-4" />+ <AdjustIcon aria-hidden className="size-4" /></TooltipTrigger>{configurationUnavailable ? (<TooltipContent>{label.expandHint}</TooltipContent>diff --git a/src/renderer/routes/dashboard/components/dashboard-layout-menu.tsx b/src/renderer/routes/dashboard/components/dashboard-layout-menu.tsxindex a0df4cfa..c92e86f1 100644--- a/src/renderer/routes/dashboard/components/dashboard-layout-menu.tsx+++ b/src/renderer/routes/dashboard/components/dashboard-layout-menu.tsx@@ -1,3 +1,4 @@+import { InfoIcon } from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'import {DASHBOARD_COLUMNS,@@ -7,7 +8,6 @@ import type {DashboardTileLayout,DashboardTileSpan,} from '@shared/types/settings'-import { Info } from 'lucide-react'import { useTranslation } from 'react-i18next'import type { DashboardLayoutFailureReason } from '../layout/dashboard-layout'@@ -114,7 +114,7 @@ export function DashboardLayoutHint({const { t } = useTranslation()return (<div className="mt-1 flex shrink-0 items-start gap-1.5 border-t border-border/60 px-2 pt-2 pb-1.5 text-muted-foreground">- <Info aria-hidden className="mt-0.5 size-3 shrink-0" />+ <InfoIcon aria-hidden className="mt-0.5 size-3 shrink-0" /><p id={id} className="text-[11px] leading-4">{t(HINT_KEYS[reason])}</p>diff --git a/src/renderer/routes/dashboard/components/dashboard-tile-frame.tsx b/src/renderer/routes/dashboard/components/dashboard-tile-frame.tsxindex df3056d0..ac897806 100644--- a/src/renderer/routes/dashboard/components/dashboard-tile-frame.tsx+++ b/src/renderer/routes/dashboard/components/dashboard-tile-frame.tsx@@ -1,3 +1,12 @@+import {+ CheckIcon,+ DragIcon,+ PanelCompactIcon,+ PanelHeaderIcon,+ PanelWideIcon,+ RemoveIcon,+ ResizeIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {DropdownMenu,@@ -17,15 +26,6 @@ import type {DashboardTileLayout,DashboardTileSpan,} from '@shared/types/settings'-import {- Check,- GripVertical,- MoveDiagonal2,- PanelTop,- Square,- StretchHorizontal,- Trash2,-} from 'lucide-react'import type React from 'react'import { useId, useState } from 'react'import { useTranslation } from 'react-i18next'@@ -159,7 +159,7 @@ export function DashboardTileFrame({onDragHandlePointerDown?.(tile.id, event)}>- <GripVertical aria-hidden />+ <DragIcon aria-hidden /></Button></ControlTooltip><ControlTooltip label={labels.remove}>@@ -170,7 +170,7 @@ export function DashboardTileFrame({aria-label={labels.remove}onClick={() => onRemove?.(tile.id)}>- <Trash2 aria-hidden />+ <RemoveIcon aria-hidden /></Button></ControlTooltip><DropdownMenu onOpenChange={() => setHintReason(null)}>@@ -264,7 +264,7 @@ export function DashboardTileFrame({</span></span>{selected ? (- <Check+ <CheckIconaria-hiddenclassName="size-3.5 text-foreground"/>@@ -293,7 +293,7 @@ export function DashboardTileFrame({onResizeHandlePointerDown?.(tile.id, event)}>- <MoveDiagonal2 aria-hidden className="size-3" />+ <ResizeIcon aria-hidden className="size-3" /></Button></>) : null}@@ -304,14 +304,14 @@ export function DashboardTileFrame({function SizeIcon({ span }: { span: DashboardTileSpan }) {switch (dashboardTileOrientation(span)) {case 'wide':- return <StretchHorizontal aria-hidden />+ return <PanelWideIcon aria-hidden />case 'tall':- return <PanelTop aria-hidden className="rotate-90" />+ return <PanelHeaderIcon aria-hidden className="rotate-90" />case 'square':return span.w === 1 ? (- <Square aria-hidden />+ <PanelCompactIcon aria-hidden />) : (- <PanelTop aria-hidden className="rotate-180" />+ <PanelHeaderIcon aria-hidden className="rotate-180" />)}}diff --git a/src/renderer/routes/dashboard/icons/[email protected] b/src/renderer/routes/dashboard/icons/[email protected]new file mode 100644index 00000000..83286329Binary files /dev/null and b/src/renderer/routes/dashboard/icons/[email protected] differdiff --git a/src/renderer/routes/dashboard/icons/[email protected] b/src/renderer/routes/dashboard/icons/[email protected]new file mode 100644index 00000000..0238d3c7Binary files /dev/null and b/src/renderer/routes/dashboard/icons/[email protected] differdiff --git a/src/renderer/routes/dashboard/icons/[email protected] b/src/renderer/routes/dashboard/icons/[email protected]new file mode 100644index 00000000..27fc3678Binary files /dev/null and b/src/renderer/routes/dashboard/icons/[email protected] differdiff --git a/src/renderer/routes/dashboard/icons/[email protected] b/src/renderer/routes/dashboard/icons/[email protected]new file mode 100644index 00000000..17e4a14eBinary files /dev/null and b/src/renderer/routes/dashboard/icons/[email protected] differdiff --git a/src/renderer/routes/dashboard/icons/[email protected] b/src/renderer/routes/dashboard/icons/[email protected]new file mode 100644index 00000000..c05fb3f1Binary files /dev/null and b/src/renderer/routes/dashboard/icons/[email protected] differdiff --git a/src/renderer/routes/dashboard/icons/[email protected] b/src/renderer/routes/dashboard/icons/[email protected]new file mode 100644index 00000000..b9ab9147Binary files /dev/null and b/src/renderer/routes/dashboard/icons/[email protected] differdiff --git a/src/renderer/routes/dashboard/tiles/active-tile.tsx b/src/renderer/routes/dashboard/tiles/active-tile.tsxindex 6339582d..a18b4cf7 100644--- a/src/renderer/routes/dashboard/tiles/active-tile.tsx+++ b/src/renderer/routes/dashboard/tiles/active-tile.tsx@@ -1,4 +1,11 @@// src/renderer/routes/dashboard/tiles/active-tile.tsx++import {+ DurationIcon,+ type MotrixIcon,+ TransferDownIcon,+ TransferUpIcon,+} from '@renderer/components/icons'import {Tooltip,TooltipContent,@@ -7,7 +14,6 @@ import {import { useTaskList } from '@renderer/hooks/use-task-list'import { cn } from '@renderer/lib/utils'import { TaskStatus } from '@shared/types/task'-import { ArrowDown, ArrowUp, Clock3, type LucideIcon } from 'lucide-react'import { useMemo } from 'react'import { useTranslation } from 'react-i18next'import { StatusDot } from '../components/status-dot'@@ -95,17 +101,17 @@ export function ActiveTile({className="mt-auto flex min-w-0 items-center justify-between gap-2 text-muted-foreground"><CompactStatus- icon={ArrowDown}+ icon={TransferDownIcon}label={t('panel.dashboard.active.downloading')}count={counts.downloading}/><CompactStatus- icon={Clock3}+ icon={DurationIcon}label={t('panel.dashboard.active.waiting')}count={counts.waiting}/><CompactStatus- icon={ArrowUp}+ icon={TransferUpIcon}label={t('panel.dashboard.active.seeding')}count={counts.seeding}/>@@ -147,7 +153,7 @@ function CompactStatus({label,count,}: {- icon: LucideIcon+ icon: MotrixIconlabel: stringcount: number}) {diff --git a/src/renderer/routes/dashboard/tiles/engine-tile.tsx b/src/renderer/routes/dashboard/tiles/engine-tile.tsxindex 41edbeea..c899d09b 100644--- a/src/renderer/routes/dashboard/tiles/engine-tile.tsx+++ b/src/renderer/routes/dashboard/tiles/engine-tile.tsx@@ -11,7 +11,7 @@ export type {EngineDisplayStatus,} from '@renderer/hooks/use-engine-display-status'-import { Bug } from 'lucide-react'+import { DiagnosticsIcon } from '@renderer/components/icons'import { useTranslation } from 'react-i18next'import { StatusDot } from '../components/status-dot'import { TileShell } from '../components/tile-shell'@@ -88,7 +88,7 @@ export function EngineTile({onClick={onManage}>{compact ? (- <Bug+ <DiagnosticsIconclassName={cn('size-3.5 text-muted-foreground',status.state === 'failed' ? 'text-destructive' : nulldiff --git a/src/renderer/routes/dashboard/tiles/nat-tile.tsx b/src/renderer/routes/dashboard/tiles/nat-tile.tsxindex 92c65d9d..392943f3 100644--- a/src/renderer/routes/dashboard/tiles/nat-tile.tsx+++ b/src/renderer/routes/dashboard/tiles/nat-tile.tsx@@ -1,3 +1,8 @@+import {+ ArrowRightIcon,+ MoreIcon,+ RouterIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { DropdownMenuTrigger } from '@renderer/components/ui/dropdown-menu'import { NatStatusMenu } from '@renderer/features/nat/nat-status-menu'@@ -7,7 +12,6 @@ import { NAT_STATUS_TEXT_KEY, natBucket } from '@renderer/lib/nat-status'import { formatRelativeTime } from '@renderer/lib/relative-time'import { cn } from '@renderer/lib/utils'import { type NatMapping, NatProtocol } from '@shared/types/nat'-import { ArrowRight, Ellipsis, Router } from 'lucide-react'import { useTranslation } from 'react-i18next'import { StatusDot } from '../components/status-dot'import { TileShell } from '../components/tile-shell'@@ -102,7 +106,7 @@ function ElectronNatTile({ viewport, className }: NatTileProps) {/>}>- <Ellipsis className="size-3.5 text-muted-foreground" aria-hidden />+ <MoreIcon className="size-3.5 text-muted-foreground" aria-hidden /></DropdownMenuTrigger></NatStatusMenu>}@@ -135,7 +139,7 @@ function ElectronNatTile({ viewport, className }: NatTileProps) {>{detailed ? (<div className="flex size-12 shrink-0 items-center justify-center rounded-2xl bg-muted/50">- <Router className="size-6 stroke-[1.5]" aria-hidden />+ <RouterIcon className="size-6 stroke-[1.5]" aria-hidden /></div>) : null}<p@@ -329,7 +333,7 @@ function MappingList({ mappings }: { mappings: readonly NatMapping[] }) {})}</span><span aria-hidden>{mapping.internalPort}</span>- <ArrowRight+ <ArrowRightIconclassName="size-3 text-muted-foreground"aria-hidden/>diff --git a/src/renderer/routes/dashboard/tiles/speed-limit-tile.test.tsx b/src/renderer/routes/dashboard/tiles/speed-limit-tile.test.tsxindex a69e5822..f91aa4dc 100644--- a/src/renderer/routes/dashboard/tiles/speed-limit-tile.test.tsx+++ b/src/renderer/routes/dashboard/tiles/speed-limit-tile.test.tsx@@ -71,7 +71,7 @@ describe('SpeedLimitTile', () => {expect(screen.getByTestId('speed-limit-rates')- .querySelectorAll('.lucide-infinity')+ .querySelectorAll('[data-icon="unlimited"]')).toHaveLength(2)expect(container.querySelector('[data-slot="status-dot"]')).toBeNull()})@@ -94,7 +94,7 @@ describe('SpeedLimitTile', () => {)expect(screen.queryByTestId('speed-limit-rates')).not.toBeInTheDocument()expect(screen.getByTestId('speed-limit-selector')).toHaveClass(- 'grid-cols-3',+ 'grid-cols-[repeat(3,36px)]','pt-2')expect(diff --git a/src/renderer/routes/dashboard/tiles/speed-limit-tile.tsx b/src/renderer/routes/dashboard/tiles/speed-limit-tile.tsxindex fe48a3ff..b597d425 100644--- a/src/renderer/routes/dashboard/tiles/speed-limit-tile.tsx+++ b/src/renderer/routes/dashboard/tiles/speed-limit-tile.tsx@@ -1,6 +1,8 @@import { useByteFormat } from '@renderer/hooks/use-byte-format'+// src/renderer/routes/dashboard/tiles/speed-limit-tile.tsx+import { SpeedControlIcon, UnlimitedIcon } from '@renderer/components/icons'import { SPEED_LIMIT_MODES } from '@renderer/components/speed-limit-modes'import { Button } from '@renderer/components/ui/button'import {@@ -10,9 +12,7 @@ import {TooltipTrigger,} from '@renderer/components/ui/tooltip'import type { SpeedLimitStateView } from '@renderer/hooks/use-speed-limit-state'-import { cn } from '@renderer/lib/utils'-import { Bolt, InfinityIcon } from 'lucide-react'import type { ReactElement } from 'react'import { useTranslation } from 'react-i18next'import { Link } from 'react-router'@@ -21,6 +21,21 @@ import type { DashboardTileViewport } from '../layout/dashboard-registry'type TurtleState = SpeedLimitStateView['turtle']+const SPEED_MODE_IMAGES = {+ off: {+ src: new URL('../icons/[email protected]', import.meta.url).href,+ src2x: new URL('../icons/[email protected]', import.meta.url).href,+ },+ on: {+ src: new URL('../icons/[email protected]', import.meta.url).href,+ src2x: new URL('../icons/[email protected]', import.meta.url).href,+ },+ auto: {+ src: new URL('../icons/[email protected]', import.meta.url).href,+ src2x: new URL('../icons/[email protected]', import.meta.url).href,+ },+} satisfies Record<TurtleState, { src: string; src2x: string }>+export interface SpeedLimitTileProps {state: SpeedLimitStateViewviewport: DashboardTileViewport@@ -37,7 +52,7 @@ export function SpeedLimitTile({const { formatSpeedLimit } = useByteFormat()function fmt(v: number): string | ReactElement {- return v <= 0 ? <InfinityIcon className="size-4" /> : formatSpeedLimit(v)+ return v <= 0 ? <UnlimitedIcon className="size-4" /> : formatSpeedLimit(v)}const { t } = useTranslation()const compact = viewport.contentLevel === 'compact'@@ -63,7 +78,10 @@ export function SpeedLimitTile({}nativeButton={false}>- <Bolt className="size-3.5 text-muted-foreground" aria-hidden />+ <SpeedControlIcon+ className="size-3.5 text-muted-foreground"+ aria-hidden+ /></Button>}>@@ -72,12 +90,17 @@ export function SpeedLimitTile({<divdata-testid="speed-limit-selector"className={cn(- 'grid shrink-0 gap-2 pt-2',- tall ? 'grid-cols-1' : 'grid-cols-3'+ 'grid shrink-0 pt-2',+ compact+ ? 'grid-cols-[repeat(3,36px)] justify-between gap-2.5'+ : tall+ ? 'grid-cols-1 gap-2'+ : 'grid-cols-3 gap-2')}>- {SPEED_LIMIT_MODES.map(({ id, Icon }) => {+ {SPEED_LIMIT_MODES.map(({ id }) => {const active = state.turtle === id+ const image = SPEED_MODE_IMAGES[id]return (<Tooltip key={id}><TooltipTrigger@@ -88,16 +111,29 @@ export function SpeedLimitTile({aria-pressed={active}onClick={() => onSelectTurtle(id)}className={cn(- 'flex items-center justify-center rounded-md transition-colors',- tall ? 'h-9 w-full' : 'aspect-square max-h-10 w-full',+ 'flex items-center justify-center rounded-lg transition-colors focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring',+ compact ? 'size-9' : 'h-12 w-full',active- ? 'bg-blue-500 text-primary-foreground dark:text-primary'- : 'text-muted-foreground hover:bg-muted'+ ? 'bg-black/80 ring-1 ring-inset ring-black/80 dark:bg-white/10 dark:ring-white/35'+ : 'hover:bg-muted')}/>}>- <Icon className="size-4 lg:size-5 xl:size-6" />+ <img+ src={image.src}+ srcSet={`${image.src} 1x, ${image.src2x} 2x`}+ width={52}+ height={52}+ alt=""+ aria-hidden+ draggable={false}+ className={cn(+ 'pointer-events-none max-w-full select-none object-contain dark:filter-none',+ !active && 'brightness-90 contrast-[1.12] saturate-[1.2]',+ compact ? 'size-7' : 'size-9'+ )}+ /></TooltipTrigger><TooltipContent>{t(`panel.dashboard.speedLimit.tooltip.${id}`)}diff --git a/src/renderer/routes/dashboard/tiles/transfer-tile.tsx b/src/renderer/routes/dashboard/tiles/transfer-tile.tsxindex e574cd2d..de0e8c0b 100644--- a/src/renderer/routes/dashboard/tiles/transfer-tile.tsx+++ b/src/renderer/routes/dashboard/tiles/transfer-tile.tsx@@ -1,3 +1,4 @@+import { ChevronDownIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {DropdownMenu,@@ -9,11 +10,9 @@ import {import { Skeleton } from '@renderer/components/ui/skeleton'import { useByteFormat } from '@renderer/hooks/use-byte-format'import type { TransferStatsState } from '@renderer/hooks/use-transfer-stats'-import { cn } from '@renderer/lib/utils'import type { TransferRangeStats } from '@shared/types/stats'import { formatBytes as formatByteCount } from '@shared/utils/format-bytes'-import { ChevronDown } from 'lucide-react'import { useState } from 'react'import { useTranslation } from 'react-i18next'import { KpiNumber } from '../components/kpi-number'@@ -56,7 +55,7 @@ function RangeDropdown({ scope, disabled, onScopeChange }: RangeControlProps) {}><span>{selectedLabel}</span>- <ChevronDown aria-hidden className="size-3" />+ <ChevronDownIcon aria-hidden className="size-3" /></DropdownMenuTrigger><DropdownMenuContent align="start" className="min-w-32"><DropdownMenuRadioGroupdiff --git a/src/renderer/routes/downloads/filter-search-command.tsx b/src/renderer/routes/downloads/filter-search-command.tsxindex f26e3850..251999b3 100644--- a/src/renderer/routes/downloads/filter-search-command.tsx+++ b/src/renderer/routes/downloads/filter-search-command.tsx@@ -1,4 +1,5 @@import { ToolbarSearch } from '@renderer/components/desktop-kit/toolbar/toolbar-search'+import { FilterIcon } from '@renderer/components/icons'import {Popover,PopoverContent,@@ -11,7 +12,6 @@ import {} from '@renderer/components/ui/tooltip'import { TASK_TYPE_META, TASK_TYPE_ORDER } from '@renderer/lib/task-type-meta'import { cn } from '@renderer/lib/utils'-import { ListFilter } from 'lucide-react'import { useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { DownloadsToolbarButton } from './downloads-toolbar-button'@@ -118,7 +118,7 @@ export function FilterSearchCommand({/>}>- <ListFilter className="size-4" />+ <FilterIcon className="size-4" /></TooltipTrigger><TooltipContentanchor={anchorRef}diff --git a/src/renderer/routes/downloads/inspector/activity-tab.tsx b/src/renderer/routes/downloads/inspector/activity-tab.tsxindex ab22e099..7ffd3f28 100644--- a/src/renderer/routes/downloads/inspector/activity-tab.tsx+++ b/src/renderer/routes/downloads/inspector/activity-tab.tsx@@ -1,3 +1,4 @@+import { RefreshIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { Skeleton } from '@renderer/components/ui/skeleton'import {@@ -7,7 +8,6 @@ import {import { useTaskSpeedHistory } from '@renderer/hooks/use-task-speed-history'import type { DownloadTask } from '@shared/types/task'import { TaskStatus } from '@shared/types/task'-import { RefreshCw } from 'lucide-react'import {type RefObject,useLayoutEffect,@@ -114,7 +114,7 @@ function StateNotice({className="motion-reduce:transition-none"onClick={onRetry}>- <RefreshCw aria-hidden="true" />+ <RefreshIcon aria-hidden="true" />{t('panel.downloads.inspector.activity.retry')}</Button></div>diff --git a/src/renderer/routes/downloads/inspector/activity-timeline.tsx b/src/renderer/routes/downloads/inspector/activity-timeline.tsxindex 8616bffc..ca2e9ee7 100644--- a/src/renderer/routes/downloads/inspector/activity-timeline.tsx+++ b/src/renderer/routes/downloads/inspector/activity-timeline.tsx@@ -1,3 +1,15 @@+import {+ CheckIcon,+ ChevronLeftIcon,+ ChevronRightIcon,+ HistoryIcon,+ MoreIcon,+ PauseIcon,+ RefreshIcon,+ ResumeIcon,+ StatusDotIcon,+ WarningIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {Popover,@@ -18,18 +30,6 @@ import {type TaskHistoryEvent,TaskHistoryEventKind,} from '@shared/types/task-inspector-activity'-import {- AlertTriangle,- Check,- ChevronLeft,- ChevronRight,- Circle,- Ellipsis,- History,- Pause,- Play,- RefreshCw,-} from 'lucide-react'import { type CSSProperties, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import type {@@ -44,26 +44,26 @@ export interface ActivityTimelineProps {}function nodeIcon(node: ActivityTimelineNode) {- if (node.presentation === 'truncated') return History+ if (node.presentation === 'truncated') return HistoryIconif (node.presentation === 'cluster' || node.presentation === 'repeated') {- return Ellipsis+ return MoreIcon}switch (node.kind) {case TaskHistoryEventKind.Added:case TaskHistoryEventKind.Completed:- return Check+ return CheckIconcase TaskHistoryEventKind.Started:case TaskHistoryEventKind.Resumed:- return Play+ return ResumeIconcase TaskHistoryEventKind.Paused:- return Pause+ return PauseIconcase TaskHistoryEventKind.Failed:- return AlertTriangle+ return WarningIconcase TaskHistoryEventKind.StageChanged:case TaskHistoryEventKind.ObservedState:- return RefreshCw+ return RefreshIcondefault:- return Circle+ return StatusDotIcon}}@@ -375,7 +375,7 @@ export function ActivityTimeline({)}onClick={() => scrollTimeline(-1)}>- <ChevronLeft aria-hidden="true" />+ <ChevronLeftIcon aria-hidden="true" /></Button><Buttontype="button"@@ -385,7 +385,7 @@ export function ActivityTimeline({aria-label={t('panel.downloads.inspector.activity.timeline.next')}onClick={() => scrollTimeline(1)}>- <ChevronRight aria-hidden="true" />+ <ChevronRightIcon aria-hidden="true" /></Button></>)}diff --git a/src/renderer/routes/downloads/inspector/current-summary-card.tsx b/src/renderer/routes/downloads/inspector/current-summary-card.tsxindex e6b348ae..071cf79f 100644--- a/src/renderer/routes/downloads/inspector/current-summary-card.tsx+++ b/src/renderer/routes/downloads/inspector/current-summary-card.tsx@@ -1,10 +1,9 @@+import { TransferDownIcon, TransferUpIcon } from '@renderer/components/icons'import { useByteFormat } from '@renderer/hooks/use-byte-format'import { formatDurationHMS } from '@renderer/lib/format'-import type { DownloadTask } from '@shared/types/task'import { TaskStatus } from '@shared/types/task'import type { TaskInspectorActivitySnapshot } from '@shared/types/task-inspector-activity'-import { ArrowDown, ArrowUp } from 'lucide-react'import { useTranslation } from 'react-i18next'export interface CurrentSummaryCardProps {@@ -35,7 +34,7 @@ function LiveMetric({}) {const { formatSpeed } = useByteFormat()- const Icon = direction === 'download' ? ArrowDown : ArrowUp+ const Icon = direction === 'download' ? TransferDownIcon : TransferUpIconconst color =direction === 'download'? 'text-[hsl(var(--chart-1))]'diff --git a/src/renderer/routes/downloads/inspector/overview-tab.tsx b/src/renderer/routes/downloads/inspector/overview-tab.tsxindex 2736db2c..4d688779 100644--- a/src/renderer/routes/downloads/inspector/overview-tab.tsx+++ b/src/renderer/routes/downloads/inspector/overview-tab.tsx@@ -1,4 +1,5 @@import { CopyButton } from '@renderer/components/desktop-kit/copy-button'+import { ResetIcon, StatusErrorIcon } from '@renderer/components/icons'import {Alert,AlertAction,@@ -25,7 +26,6 @@ import {isMediaTask,mediaProgressPercent,} from '@shared/utils/media-progress'-import { AlertCircleIcon, RotateCcw } from 'lucide-react'import { useTranslation } from 'react-i18next'import { StatusPill } from '../status-pill'import { getTaskEta, getTaskSpeed } from '../task-column-values'@@ -88,7 +88,7 @@ function ErrorPanel({ task }: { task: DownloadTask }) {return (<div className="flex flex-col gap-2"><Alert variant="destructive" className="items-start">- <AlertCircleIcon />+ <StatusErrorIcon /><AlertTitle>{failure.reason}</AlertTitle>{(failure.hint || failure.technicalDetail) && (<AlertDescription className="min-w-0">@@ -108,7 +108,7 @@ function ErrorPanel({ task }: { task: DownloadTask }) {className="self-start"onClick={() => void onRetry()}>- <RotateCcw data-icon="inline-start" />+ <ResetIcon data-icon="inline-start" />{t('panel.downloads.action.retry')}</Button></AlertAction>diff --git a/src/renderer/routes/downloads/inspector/remove-tasks-dialog.tsx b/src/renderer/routes/downloads/inspector/remove-tasks-dialog.tsxindex 0d9c0d4c..298f8714 100644--- a/src/renderer/routes/downloads/inspector/remove-tasks-dialog.tsx+++ b/src/renderer/routes/downloads/inspector/remove-tasks-dialog.tsx@@ -1,3 +1,4 @@+import { WarningIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { Checkbox } from '@renderer/components/ui/checkbox'import {@@ -8,10 +9,8 @@ import {DialogTitle,} from '@renderer/components/ui/dialog'import { useByteFormat } from '@renderer/hooks/use-byte-format'-import type { DownloadTask } from '@shared/types/task'import { TaskStatus } from '@shared/types/task'-import { AlertTriangle } from 'lucide-react'import { useEffect, useId, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'@@ -131,7 +130,7 @@ export function RemoveTasksDialog({</div>{showEstimate && (<div className="flex items-center gap-2 rounded-md bg-yellow-100 px-3 py-2 text-xs text-yellow-900 dark:bg-yellow-900/30 dark:text-yellow-200">- <AlertTriangle className="size-3.5" />+ <WarningIcon className="size-3.5" /><span>{t('panel.downloads.action.removeFilesEstimate', {bytes: formatBytes(estimateDiskUsage(selected)),diff --git a/src/renderer/routes/downloads/inspector/task-inspector-action-bar.test.tsx b/src/renderer/routes/downloads/inspector/task-inspector-action-bar.test.tsxindex 8cb82115..b6d02b4d 100644--- a/src/renderer/routes/downloads/inspector/task-inspector-action-bar.test.tsx+++ b/src/renderer/routes/downloads/inspector/task-inspector-action-bar.test.tsx@@ -377,7 +377,7 @@ describe('TaskInspectorActionBar', () => {/>)const copyButton = screen.getByRole('button', { name: /Copy URL/ })- expect(copyButton.querySelector('.lucide-copy')).not.toBeNull()+ expect(copyButton.querySelector('[data-icon="copy"]')).not.toBeNull()fireEvent.click(copyButton)await waitFor(() =>@@ -385,7 +385,7 @@ describe('TaskInspectorActionBar', () => {'https://example.com/file.zip'))- expect(copyButton.querySelector('.lucide-check')).not.toBeNull()+ expect(copyButton.querySelector('[data-icon="check"]')).not.toBeNull()})it('BT task with infoHash copies a magnet URI carrying name + trackers', async () => {@@ -501,8 +501,8 @@ describe('TaskInspectorActionBar', () => {await waitFor(() => expect(toastAddMock).toHaveBeenCalledTimes(1))expect(navigator.clipboard.writeText).not.toHaveBeenCalled()- expect(copyButton.querySelector('.lucide-copy')).not.toBeNull()- expect(copyButton.querySelector('.lucide-check')).toBeNull()+ expect(copyButton.querySelector('[data-icon="copy"]')).not.toBeNull()+ expect(copyButton.querySelector('[data-icon="check"]')).toBeNull()})})})diff --git a/src/renderer/routes/downloads/inspector/task-inspector-action-bar.tsx b/src/renderer/routes/downloads/inspector/task-inspector-action-bar.tsxindex 865567ff..2bbfe535 100644--- a/src/renderer/routes/downloads/inspector/task-inspector-action-bar.tsx+++ b/src/renderer/routes/downloads/inspector/task-inspector-action-bar.tsx@@ -1,4 +1,15 @@import { CopyButton } from '@renderer/components/desktop-kit/copy-button'+import {+ ChevronDownIcon,+ OpenFileIcon,+ PauseIcon,+ RemoveIcon,+ ResumeIcon,+ RetryIcon,+ RevealFolderIcon,+ SeedStartIcon,+ StopIcon,+} from '@renderer/components/icons'import { MagnetFileSelectionButton } from '@renderer/components/task/magnet-file-selection-button'import { Button } from '@renderer/components/ui/button'import { toast } from '@renderer/components/ui/toast'@@ -10,17 +21,6 @@ import { Commands } from '@shared/protocol/commands'import type { DownloadTask } from '@shared/types/task'import { TaskStatus } from '@shared/types/task'import { canOpenTaskFile } from '@shared/types/task-actions'-import {- ChevronDown,- File,- FolderOpen,- Pause,- Play,- Repeat2,- Sprout,- Square,- Trash2,-} from 'lucide-react'import type React from 'react'import { useState } from 'react'import { useTranslation } from 'react-i18next'@@ -120,7 +120,7 @@ function OpenTaskFileButton({ task }: { task: DownloadTask }) {disabled={opening}onClick={() => void open()}>- <File />+ <OpenFileIcon />{t('panel.downloads.action.openFile')}</Button>)@@ -140,7 +140,7 @@ function FinalizingActionBar({return (<div className="flex shrink-0 items-center gap-2 border-b border-border/50 px-4 py-2"><Button size="xs" variant="outline" disabled title={reason}>- <Pause />+ <PauseIcon />{t('panel.downloads.action.pause')}</Button>{__MOTRIX_TARGET__ === 'electron' && canRevealTaskFolder(task) && (@@ -151,7 +151,7 @@ function FinalizingActionBar({transport.invoke(Commands.RevealInFolder, { taskId: task.id })}>- <FolderOpen />+ <RevealFolderIcon />{t('panel.downloads.action.openFolder')}</Button>)}@@ -177,7 +177,7 @@ function FinalizingActionBar({disabledtitle={reason}>- <Trash2 />+ <RemoveIcon />{t('panel.downloads.action.remove')}</Button><Button@@ -186,7 +186,7 @@ function FinalizingActionBar({aria-label={t('common.close')}onClick={onClose}>- <ChevronDown />+ <ChevronDownIcon /></Button></div>)@@ -224,7 +224,7 @@ export function TaskInspectorActionBar({n: actions.pauseCount,total: actions.total,})}- icon={<Pause />}+ icon={<PauseIcon />}onClick={() => void actions.onPause()}/>)}@@ -238,7 +238,7 @@ export function TaskInspectorActionBar({n: actions.resumeCount,total: actions.total,})}- icon={<Play className={rtlMirror} />}+ icon={<ResumeIcon className={rtlMirror} />}onClick={() => void actions.onResume()}/>)}@@ -256,7 +256,7 @@ export function TaskInspectorActionBar({n: actions.retryCount,total: actions.total,})}- icon={<Repeat2 />}+ icon={<RetryIcon />}onClick={(e) => void actions.onRetry({ alt: e.altKey })}/>)}@@ -274,7 +274,7 @@ export function TaskInspectorActionBar({n: actions.reseedCount,total: actions.total,})}- icon={<Sprout />}+ icon={<SeedStartIcon />}onClick={(e) => void actions.onReseed({ alt: e.altKey })}/>)}@@ -288,7 +288,7 @@ export function TaskInspectorActionBar({n: actions.stopSeedingCount,total: actions.total,})}- icon={<Square />}+ icon={<StopIcon />}onClick={() => void actions.onStopSeeding()}/>)}@@ -312,7 +312,7 @@ export function TaskInspectorActionBar({})}>- <FolderOpen />+ <RevealFolderIcon />{t('panel.downloads.action.openFolder')}</Button>)}@@ -346,7 +346,7 @@ export function TaskInspectorActionBar({n: actions.removeCount,total: actions.total,})}- icon={<Trash2 />}+ icon={<RemoveIcon />}destructiveonClick={(e) => actions.onRemove({ shift: e.shiftKey })}/>@@ -359,7 +359,7 @@ export function TaskInspectorActionBar({aria-label={t('common.close')}onClick={onClose}>- <ChevronDown />+ <ChevronDownIcon /></Button></div>)diff --git a/src/renderer/routes/downloads/inspector/trackers-tab.tsx b/src/renderer/routes/downloads/inspector/trackers-tab.tsxindex 3c8d8290..71dca0df 100644--- a/src/renderer/routes/downloads/inspector/trackers-tab.tsx+++ b/src/renderer/routes/downloads/inspector/trackers-tab.tsx@@ -1,4 +1,5 @@import { VirtualList } from '@renderer/components/desktop-kit/virtual-list/virtual-list'+import { LockedIcon, RemoveIcon } from '@renderer/components/icons'import { Alert } from '@renderer/components/ui/alert'import { Button } from '@renderer/components/ui/button'import { Spinner } from '@renderer/components/ui/spinner'@@ -13,7 +14,6 @@ import { cn } from '@renderer/lib/utils'import { Commands } from '@shared/protocol/commands'import type { DownloadTask } from '@shared/types/task'import { TaskStatus } from '@shared/types/task'-import { Lock, Trash2 } from 'lucide-react'import { type KeyboardEvent, useEffect, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'@@ -275,7 +275,7 @@ export function TrackersTab({ task }: TrackersTabProps) {<div className="flex min-h-0 flex-1 flex-col gap-2">{isPrivate && (<Alert className="shrink-0 flex items-center gap-2">- <Lock className="size-3.5 shrink-0" />+ <LockedIcon className="size-3.5 shrink-0" /><span className="text-xs">{t('panel.downloads.inspector.trackers.privateBanner')}</span>@@ -417,7 +417,7 @@ function TrackerRow({ row, onDelete, t }: TrackerRowProps) {className="opacity-0 transition-opacity duration-100 group-hover:opacity-100 group-focus-within:opacity-100"onClick={() => onDelete(row.url)}>- <Trash2 className="size-3.5" />+ <RemoveIcon className="size-3.5" /></Button>) : (<span className="size-6 shrink-0" aria-hidden="true" />diff --git a/src/renderer/routes/downloads/list-view-menu.tsx b/src/renderer/routes/downloads/list-view-menu.tsxindex c5ba3de7..3ee22744 100644--- a/src/renderer/routes/downloads/list-view-menu.tsx+++ b/src/renderer/routes/downloads/list-view-menu.tsx@@ -1,3 +1,4 @@+import { ColumnsIcon, InfoIcon } from '@renderer/components/icons'import {DropdownMenu,DropdownMenuCheckboxItem,@@ -14,7 +15,6 @@ import {DropdownMenuSubTrigger,DropdownMenuTrigger,} from '@renderer/components/ui/dropdown-menu'-import { Columns3, Info } from 'lucide-react'import type { Ref } from 'react'import { useTranslation } from 'react-i18next'import { DownloadsToolbarButton } from './downloads-toolbar-button'@@ -145,7 +145,7 @@ export function ListViewMenu({/>}>- <Columns3 className="size-4" />+ <ColumnsIcon className="size-4" /></DropdownMenuTrigger><DropdownMenuContent align="end" data-menu-density="compact"><ListViewMenuItems />@@ -218,7 +218,7 @@ export function InspectorToggle({setVisible(!visible)}}>- <Info className="size-4" />+ <InfoIcon className="size-4" /></DownloadsToolbarButton>)}diff --git a/src/renderer/routes/downloads/speed-limit-badge.test.tsx b/src/renderer/routes/downloads/speed-limit-badge.test.tsxindex 1baaebd8..8f6786c0 100644--- a/src/renderer/routes/downloads/speed-limit-badge.test.tsx+++ b/src/renderer/routes/downloads/speed-limit-badge.test.tsx@@ -47,9 +47,9 @@ beforeEach(() => {describe('SpeedLimitBadge', () => {it.each([- ['off', 'Standard', 'rabbit'],- ['on', 'Low speed', 'turtle'],- ['auto', 'Automatic', 'squirrel'],+ ['off', 'Standard', 'speed-unlimited'],+ ['on', 'Low speed', 'speed-limited'],+ ['auto', 'Automatic', 'speed-auto'],] as const)('shows the %s mode with its existing dashboard glyph',async (mode, label, icon) => {@@ -58,7 +58,7 @@ describe('SpeedLimitBadge', () => {const button = screen.getByRole('button', {name: `Speed mode: ${label}`,})- expect(button.querySelector(`.lucide-${icon}`)).toBeInTheDocument()+ expect(button.querySelector(`[data-icon="${icon}"]`)).toBeInTheDocument()await user.click(button)const radios = await screen.findAllByRole('menuitemradio')expect(radios).toHaveLength(3)diff --git a/src/renderer/routes/downloads/speed-limit-badge.tsx b/src/renderer/routes/downloads/speed-limit-badge.tsxindex 3ddcf741..3afd017c 100644--- a/src/renderer/routes/downloads/speed-limit-badge.tsx+++ b/src/renderer/routes/downloads/speed-limit-badge.tsx@@ -1,3 +1,4 @@+import { ChevronDownIcon } from '@renderer/components/icons'import { SPEED_LIMIT_MODES } from '@renderer/components/speed-limit-modes'import { Badge } from '@renderer/components/ui/badge'import {@@ -20,7 +21,6 @@ import { useSpeedLimitState } from '@renderer/hooks/use-speed-limit-state'import { saveSettings } from '@renderer/lib/settings-save'import { cn } from '@renderer/lib/utils'import type { TurtleState } from '@shared/types/settings'-import { ChevronDown } from 'lucide-react'import { useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { Link } from 'react-router'@@ -94,7 +94,7 @@ export function SpeedLimitBadge() {><Icon aria-hidden="true" />{mode}- <ChevronDown aria-hidden="true" className="opacity-55" />+ <ChevronDownIcon aria-hidden="true" className="opacity-55" /></TooltipTrigger><TooltipContent side="top" align="start" sideOffset={8}><div className="space-y-1">diff --git a/src/renderer/routes/downloads/status-title-menu.tsx b/src/renderer/routes/downloads/status-title-menu.tsxindex a0c1686a..2c8f9273 100644--- a/src/renderer/routes/downloads/status-title-menu.tsx+++ b/src/renderer/routes/downloads/status-title-menu.tsx@@ -1,4 +1,5 @@import { PANEL_TITLE_CLASS } from '@renderer/components/desktop-kit/panel/panel-shell'+import { CheckIcon, ChevronDownIcon } from '@renderer/components/icons'import { Badge } from '@renderer/components/ui/badge'import {DropdownMenu,@@ -7,7 +8,6 @@ import {DropdownMenuTrigger,} from '@renderer/components/ui/dropdown-menu'import { cn } from '@renderer/lib/utils'-import { Check, ChevronDown } from 'lucide-react'import { useTranslation } from 'react-i18next'import { DOWNLOADS_TABS, type DownloadsTab } from './filter'@@ -41,7 +41,7 @@ export function StatusTitleMenu({}><h1 className={cn(PANEL_TITLE_CLASS, 'truncate')}>{title}</h1>- <ChevronDown className="size-4 shrink-0 text-muted-foreground compact-header:size-3" />+ <ChevronDownIcon className="size-4 shrink-0 text-muted-foreground compact-header:size-3" /></DropdownMenuTrigger><DropdownMenuContentalign="start"@@ -54,7 +54,7 @@ export function StatusTitleMenu({onClick={() => onTabChange(key)}className="gap-2">- <Check+ <CheckIconclassName={cn('size-4',key === tab ? 'opacity-100' : 'opacity-0'diff --git a/src/renderer/routes/downloads/task-actions-menu.tsx b/src/renderer/routes/downloads/task-actions-menu.tsxindex b28b224b..09d2702b 100644--- a/src/renderer/routes/downloads/task-actions-menu.tsx+++ b/src/renderer/routes/downloads/task-actions-menu.tsx@@ -1,4 +1,5 @@import type { SelectionStore } from '@renderer/components/desktop-kit/selection/types'+import { MoreIcon } from '@renderer/components/icons'import {ContextMenu,ContextMenuContent,@@ -33,7 +34,6 @@ import {canOpenTaskFile,canSelectTaskFiles,} from '@shared/types/task-actions'-import { Ellipsis } from 'lucide-react'import {type ClipboardEvent,Fragment,@@ -544,7 +544,7 @@ export function TaskActionsMenu({/>}>- <Ellipsis className="size-4" />+ <MoreIcon className="size-4" /></DropdownMenuTrigger><DropdownMenuContentonKeyDownCapture={handleShortcut}diff --git a/src/renderer/routes/downloads/task-column-header.tsx b/src/renderer/routes/downloads/task-column-header.tsxindex 7fe8f714..c2ae3a44 100644--- a/src/renderer/routes/downloads/task-column-header.tsx+++ b/src/renderer/routes/downloads/task-column-header.tsx@@ -1,11 +1,11 @@import { ResizeHandle } from '@renderer/components/desktop-kit/resize-handle'+import { ChevronDownIcon, ChevronUpIcon } from '@renderer/components/icons'import {ContextMenu,ContextMenuContent,ContextMenuTrigger,} from '@renderer/components/ui/context-menu'import { cn } from '@renderer/lib/utils'-import { ChevronDown, ChevronUp } from 'lucide-react'import { useRef } from 'react'import { useTranslation } from 'react-i18next'import {@@ -67,7 +67,7 @@ export function TaskColumnHeader({: labelconst next = nextTaskSort(effectiveSort, id)const SortIcon =- effectiveSort.direction === 'asc' ? ChevronUp : ChevronDown+ effectiveSort.direction === 'asc' ? ChevronUpIcon : ChevronDownIconreturn (// biome-ignore lint/a11y/useSemanticElements: Column headers belong to the virtual ARIA grid.<divdiff --git a/src/renderer/routes/downloads/task-inspector-drawer.tsx b/src/renderer/routes/downloads/task-inspector-drawer.tsxindex 324e3d6c..5023f8e9 100644--- a/src/renderer/routes/downloads/task-inspector-drawer.tsx+++ b/src/renderer/routes/downloads/task-inspector-drawer.tsx@@ -1,6 +1,15 @@import { CopyButton } from '@renderer/components/desktop-kit/copy-button'import { InspectorDrawer } from '@renderer/components/desktop-kit/inspector-drawer'import type { SelectionStore } from '@renderer/components/desktop-kit/selection/types'+import {+ ActivityIcon,+ DiskIcon,+ FilesIcon,+ InfoIcon,+ PeersIcon,+ PiecesIcon,+ TrackerIcon,+} from '@renderer/components/icons'import { Badge } from '@renderer/components/ui/badge'import { Button } from '@renderer/components/ui/button'import {@@ -21,15 +30,6 @@ import { Commands } from '@shared/protocol/commands'import type { DownloadTask } from '@shared/types/task'import { TaskType } from '@shared/types/task'import { canInspectPieces } from '@shared/types/task-actions'-import {- Files,- Grid3x3,- HardDrive,- Info,- RadioTower,- SquareActivity,- UsersRound,-} from 'lucide-react'import { useCallback, useLayoutEffect, useMemo } from 'react'import { useTranslation } from 'react-i18next'import { ActivityTab } from './inspector/activity-tab'@@ -148,7 +148,7 @@ export function TaskInspectorDrawer({})}>- <HardDrive className="mr-1 size-3.5 shrink-0 text-muted-foreground" />+ <DiskIcon className="mr-1 size-3.5 shrink-0 text-muted-foreground" /><span className="truncate">{single.finalPath || single.diskPath}</span>@@ -174,7 +174,7 @@ export function TaskInspectorDrawer({aria-label={t('panel.downloads.inspector.tab.overview')}title={t('panel.downloads.inspector.tab.overview')}>- <Info className="size-3.5" />+ <InfoIcon className="size-3.5" /></TabsTrigger><TabsTriggervalue="files"@@ -182,7 +182,7 @@ export function TaskInspectorDrawer({aria-label={t('panel.downloads.inspector.tab.files')}title={t('panel.downloads.inspector.tab.files')}>- <Files className="size-3.5" />+ <FilesIcon className="size-3.5" /></TabsTrigger>{showPieces && (<TabsTrigger@@ -191,7 +191,7 @@ export function TaskInspectorDrawer({aria-label={t('panel.downloads.inspector.tab.pieces')}title={t('panel.downloads.inspector.tab.pieces')}>- <Grid3x3 className="size-3.5" />+ <PiecesIcon className="size-3.5" /></TabsTrigger>)}{isBt && (@@ -201,7 +201,7 @@ export function TaskInspectorDrawer({aria-label={t('panel.downloads.inspector.tab.peers')}title={t('panel.downloads.inspector.tab.peers')}>- <UsersRound className="size-3.5" />+ <PeersIcon className="size-3.5" /></TabsTrigger>)}{isBt && (@@ -211,7 +211,7 @@ export function TaskInspectorDrawer({aria-label={t('panel.downloads.inspector.tab.trackers')}title={t('panel.downloads.inspector.tab.trackers')}>- <RadioTower className="size-3.5" />+ <TrackerIcon className="size-3.5" /></TabsTrigger>)}<TabsTrigger@@ -220,7 +220,7 @@ export function TaskInspectorDrawer({aria-label={t('panel.downloads.inspector.tab.activity')}title={t('panel.downloads.inspector.tab.activity')}>- <SquareActivity className="size-3.5" />+ <ActivityIcon className="size-3.5" /></TabsTrigger></TabsList><TabsContent value="overview" className="min-h-0">diff --git a/src/renderer/routes/downloads/transfer-speed-badge.tsx b/src/renderer/routes/downloads/transfer-speed-badge.tsxindex a6e1a0fd..78ff3a29 100644--- a/src/renderer/routes/downloads/transfer-speed-badge.tsx+++ b/src/renderer/routes/downloads/transfer-speed-badge.tsx@@ -1,3 +1,4 @@+import { TransferDownIcon, TransferUpIcon } from '@renderer/components/icons'import { Badge } from '@renderer/components/ui/badge'import {Tooltip,@@ -7,7 +8,6 @@ import {import { useByteFormat } from '@renderer/hooks/use-byte-format'import { useGlobalStats } from '@renderer/hooks/use-global-stats'import { cn } from '@renderer/lib/utils'-import { ArrowDown, ArrowUp } from 'lucide-react'import { useTranslation } from 'react-i18next'export function TransferSpeedBadge() {@@ -17,12 +17,12 @@ export function TransferSpeedBadge() {const rates = [{key: 'upSpeed',- icon: ArrowUp,+ icon: TransferUpIcon,speed: stats?.totalUploadSpeed,},{key: 'downSpeed',- icon: ArrowDown,+ icon: TransferDownIcon,speed: stats?.totalDownloadSpeed,},] as constdiff --git a/src/renderer/routes/notifications/notification-icon.tsx b/src/renderer/routes/notifications/notification-icon.tsxindex 45d7e63a..35e96d73 100644--- a/src/renderer/routes/notifications/notification-icon.tsx+++ b/src/renderer/routes/notifications/notification-icon.tsx@@ -1,18 +1,23 @@+import {+ InfoIcon,+ StatusCompleteIcon,+ StatusFailedIcon,+ WarningIcon,+} from '@renderer/components/icons'import { cn } from '@renderer/lib/utils'import {type AppNotification,NotificationKinds,} from '@shared/types/notification'-import { CircleCheck, CircleX, Info, TriangleAlert } from 'lucide-react'const severityIcons = {- info: { icon: Info, className: 'text-muted-foreground' },+ info: { icon: InfoIcon, className: 'text-muted-foreground' },warning: {- icon: TriangleAlert,+ icon: WarningIcon,className: 'text-[#8b784d] dark:text-[#baa574]',},error: {- icon: CircleX,+ icon: StatusFailedIcon,className: 'text-[#a96360] dark:text-[#c98f89]',},}@@ -20,7 +25,7 @@ const severityIcons = {export function NotificationIcon({ item }: { item: AppNotification }) {const complete = item.kind === NotificationKinds.TaskCompleteconst severity = severityIcons[item.severity] ?? severityIcons.info- const Icon = complete ? CircleCheck : severity.icon+ const Icon = complete ? StatusCompleteIcon : severity.iconreturn (<spandiff --git a/src/renderer/routes/notifications/notifications-page.tsx b/src/renderer/routes/notifications/notifications-page.tsxindex fdb9fc24..78daeb34 100644--- a/src/renderer/routes/notifications/notifications-page.tsx+++ b/src/renderer/routes/notifications/notifications-page.tsx@@ -9,6 +9,11 @@ import { PanelShell } from '@renderer/components/desktop-kit/panel/panel-shell'import { Toolbar } from '@renderer/components/desktop-kit/toolbar/toolbar'import { ToolbarButton } from '@renderer/components/desktop-kit/toolbar/toolbar-button'import { ToolbarGroup } from '@renderer/components/desktop-kit/toolbar/toolbar-group'+import {+ MarkAllReadIcon,+ NotificationsIcon,+ RemoveIcon,+} from '@renderer/components/icons'import { useNotifications } from '@renderer/components/notification-center/use-notifications'import {Empty,@@ -27,7 +32,6 @@ import { isTaskAvailable, resolveTaskRoute } from '@shared/lib/task-navigation'import { Queries } from '@shared/protocol/queries'import type { AppNotification } from '@shared/types/notification'import type { DownloadTask } from '@shared/types/task'-import { Bell, CheckCheck, Trash2 } from 'lucide-react'import { useEffect, useId, useMemo, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { useNavigate } from 'react-router'@@ -149,7 +153,7 @@ function NotificationRow({onClick={onDelete}className="notification-row-remove relative z-10 flex size-7 items-center justify-center rounded-md text-muted-foreground opacity-0 outline-none hover:bg-accent hover:text-destructive group-hover:opacity-100 group-focus-within:opacity-100 focus-visible:opacity-100">- <Trash2 aria-hidden="true" className="size-3.5" />+ <RemoveIcon aria-hidden="true" className="size-3.5" /></button></div></li>@@ -245,14 +249,14 @@ export function NotificationsPage() {disabled={unreadCount === 0 || busy}onClick={() => void runAction(markAllRead)}>- <CheckCheck aria-hidden="true" />+ <MarkAllReadIcon aria-hidden="true" /></ToolbarButton><ToolbarButtonlabel={t('notification.center.clearAll')}disabled={!hasItems || busy}onClick={() => void runAction(clear)}>- <Trash2 aria-hidden="true" />+ <RemoveIcon aria-hidden="true" /></ToolbarButton></ToolbarGroup></Toolbar>@@ -302,7 +306,7 @@ export function NotificationsPage() {<Empty className="flex-1 gap-1 px-4 py-8"><EmptyHeader className="gap-1"><EmptyMedia className="mb-2 size-12 rounded-2xl bg-black/5 text-muted-foreground dark:bg-white/8 [&_svg]:size-6">- <Bell strokeWidth={1.5} />+ <NotificationsIcon strokeWidth={1.5} /></EmptyMedia><EmptyTitle className="font-sans text-sm font-medium tracking-normal">{t('notification.center.empty')}diff --git a/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-node.tsx b/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-node.tsxindex d602c84b..7d34134c 100644--- a/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-node.tsx+++ b/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-node.tsx@@ -1,8 +1,12 @@+import {+ ArrowDownLeftIcon,+ ArrowUpRightIcon,+ PluginUnavailableIcon,+} from '@renderer/components/icons'import { PluginAvatar } from '@renderer/routes/plugins/components/plugin-avatar'import { PluginStatusDot } from '@renderer/routes/plugins/components/plugin-status-dot'import type { PluginStatus } from '@shared/types/plugin'import { Handle, type Node, type NodeProps, Position } from '@xyflow/react'-import { ArrowDownLeft, ArrowUpRight, PackageX } from 'lucide-react'import type {CallGraphNodeModel,CallGraphNodeStatus,@@ -74,7 +78,7 @@ export function PluginCallGraphNode({enabled={model.status !== 'disabled'}/>) : (- <PackageX+ <PluginUnavailableIcondata-missing-status-icon="true"aria-hidden="true"className="size-3.5 shrink-0 text-muted-foreground"@@ -93,14 +97,14 @@ export function PluginCallGraphNode({<span className="sr-only">{strings.incoming}: {model.incomingCalls}</span>- <ArrowDownLeft aria-hidden="true" className="size-3" />+ <ArrowDownLeftIcon aria-hidden="true" className="size-3" /><span aria-hidden="true">{model.incomingCalls}</span></span><span className="inline-flex items-center gap-0.5"><span className="sr-only">{strings.outgoing}: {model.outgoingCalls}</span>- <ArrowUpRight aria-hidden="true" className="size-3" />+ <ArrowUpRightIcon aria-hidden="true" className="size-3" /><span aria-hidden="true">{model.outgoingCalls}</span></span></span>diff --git a/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-omni-search.tsx b/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-omni-search.tsxindex 01cf3916..de08f313 100644--- a/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-omni-search.tsx+++ b/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-omni-search.tsx@@ -1,3 +1,4 @@+import { SearchIcon } from '@renderer/components/icons'import {Autocomplete,AutocompleteCollection,@@ -12,7 +13,6 @@ import {} from '@renderer/components/ui/autocomplete'import { InputGroupAddon } from '@renderer/components/ui/input-group'import type { PluginCommandGraphEdge } from '@shared/types/plugin-command-graph'-import { SearchIcon } from 'lucide-react'import { Fragment, useMemo, useState } from 'react'import type { CallGraphNodeModel } from '../../lib/call-graph-model'diff --git a/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-toolbar.tsx b/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-toolbar.tsxindex 0e05be3a..f07030f2 100644--- a/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-toolbar.tsx+++ b/src/renderer/routes/plugins/components/call-graph/plugin-call-graph-toolbar.tsx@@ -1,3 +1,8 @@+import {+ CallGraphIcon,+ RefreshIcon,+ TableIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { Tabs, TabsList, TabsTrigger } from '@renderer/components/ui/tabs'import {@@ -6,7 +11,6 @@ import {TooltipTrigger,} from '@renderer/components/ui/tooltip'import type { PluginCommandGraphEdge } from '@shared/types/plugin-command-graph'-import { RefreshCwIcon, Table2Icon, WorkflowIcon } from 'lucide-react'import type {CallGraphDensity,CallGraphNodeModel,@@ -109,7 +113,7 @@ export function PluginCallGraphToolbar({aria-label={strings.graphMode}className="size-8 flex-none p-0">- <WorkflowIcon aria-hidden="true" />+ <CallGraphIcon aria-hidden="true" /></TabsTrigger></span>}@@ -131,7 +135,7 @@ export function PluginCallGraphToolbar({aria-label={strings.tableMode}className="size-8 flex-none p-0">- <Table2Icon aria-hidden="true" />+ <TableIcon aria-hidden="true" /></TabsTrigger></span>}@@ -156,7 +160,7 @@ export function PluginCallGraphToolbar({disabled={isRefreshing}onClick={onRefresh}>- <RefreshCwIcon+ <RefreshIconaria-hidden="true"className={isRefreshingdiff --git a/src/renderer/routes/plugins/components/plugin-guidance.tsx b/src/renderer/routes/plugins/components/plugin-guidance.tsxindex 203872f9..679043e4 100644--- a/src/renderer/routes/plugins/components/plugin-guidance.tsx+++ b/src/renderer/routes/plugins/components/plugin-guidance.tsx@@ -1,3 +1,4 @@+import { PluginStoreIcon, VerifiedIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { Card } from '@renderer/components/ui/card'import {@@ -7,7 +8,6 @@ import {} from '@renderer/components/ui/tooltip'import { usePlatformServices } from '@renderer/platform/services'import { EXTERNAL_URLS } from '@shared/external-urls'-import { ShieldCheck, Store } from 'lucide-react'import { useTranslation } from 'react-i18next'interface PluginGuidanceProps {@@ -24,7 +24,7 @@ export function PluginGuidance({ hasUserManagedPlugin }: PluginGuidanceProps) {data-testid="plugin-safety-reminder"className="flex items-start gap-2 rounded-lg bg-muted/40 px-3 py-2.5">- <ShieldCheck+ <VerifiedIconaria-hiddenclassName="mt-0.5 size-4 shrink-0 text-muted-foreground"/>@@ -45,7 +45,7 @@ export function PluginGuidance({ hasUserManagedPlugin }: PluginGuidanceProps) {<div className="min-w-0"><div className="flex items-start justify-between gap-2"><div className="flex items-center gap-2">- <ShieldCheck+ <VerifiedIconaria-hiddenclassName="size-4 shrink-0 text-muted-foreground"/>@@ -70,7 +70,7 @@ export function PluginGuidance({ hasUserManagedPlugin }: PluginGuidanceProps) {aria-label={t('plugins.help.guidance.firstUse.browse')}data-testid="plugin-guide-browse-link">- <Store aria-hidden className="size-4" />+ <PluginStoreIcon aria-hidden className="size-4" /></Button>}/>diff --git a/src/renderer/routes/plugins/components/plugin-input-group.tsx b/src/renderer/routes/plugins/components/plugin-input-group.tsxindex 2b117a2c..1ec2dda1 100644--- a/src/renderer/routes/plugins/components/plugin-input-group.tsx+++ b/src/renderer/routes/plugins/components/plugin-input-group.tsx@@ -1,3 +1,4 @@+import { AttachIcon, SearchIcon } from '@renderer/components/icons'import { Badge } from '@renderer/components/ui/badge'import { Button } from '@renderer/components/ui/button'import {@@ -17,7 +18,6 @@ import {type PluginInstallFileReference,useOptionalPlatformServices,} from '@renderer/platform/services'-import { Paperclip, Search } from 'lucide-react'import { type ChangeEvent, useCallback, useRef, useState } from 'react'import { useTranslation } from 'react-i18next'import { getAudienceTone } from '../lib/audience'@@ -137,7 +137,7 @@ export function PluginInputGroup({ onCheck, checking }: Props) {: 'plugins.install.localUnavailable')}>- <Paperclip className="size-4" />+ <AttachIcon className="size-4" /></Button></span>}@@ -173,7 +173,7 @@ export function PluginInputGroup({ onCheck, checking }: Props) {onClick={triggerCheck}aria-label={t('plugins.install.checkAriaLabel')}>- <Search />+ <SearchIcon /></Button>)}</InputGroupAddon>diff --git a/src/renderer/routes/plugins/components/plugin-log-tab.tsx b/src/renderer/routes/plugins/components/plugin-log-tab.tsxindex f193b3f2..c2c3ad18 100644--- a/src/renderer/routes/plugins/components/plugin-log-tab.tsx+++ b/src/renderer/routes/plugins/components/plugin-log-tab.tsx@@ -1,4 +1,10 @@import { CopyButton } from '@renderer/components/desktop-kit/copy-button'+import {+ FilterIcon,+ RemoveIcon,+ TerminalIcon,+ WarningIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {ScrollArea,@@ -18,7 +24,6 @@ import { Separator } from '@renderer/components/ui/separator'import { Switch } from '@renderer/components/ui/switch'import { transport } from '@renderer/lib/transport'import { Commands } from '@shared/protocol/commands'-import { ListFilter, TerminalSquare, Trash2, TriangleAlert } from 'lucide-react'import { useState } from 'react'import { useTranslation } from 'react-i18next'import { usePluginLogStream } from '../hooks/use-plugin-log-stream'@@ -75,7 +80,7 @@ export function PluginLogTab({ pluginId }: { pluginId: string }) {aria-label={t('plugins.logs.filterLabel')}className="h-7 w-32 rounded-md bg-background px-2.5 text-xs shadow-none">- <ListFilter className="size-3.5" />+ <FilterIcon className="size-3.5" /><SelectValue /></SelectTrigger><SelectContent>@@ -122,7 +127,7 @@ export function PluginLogTab({ pluginId }: { pluginId: string }) {onClick={onClear}className="text-muted-foreground hover:bg-destructive/10 hover:text-destructive active:scale-[0.97] motion-reduce:transform-none dark:hover:bg-destructive/15">- <Trash2 className="size-3" />+ <RemoveIcon className="size-3" />{t('plugins.logs.clear')}</Button></div>@@ -133,7 +138,7 @@ export function PluginLogTab({ pluginId }: { pluginId: string }) {role="status"className="flex shrink-0 items-start gap-2 rounded-md bg-amber-500/10 px-3 py-2 text-xs leading-relaxed text-amber-800 dark:text-amber-300">- <TriangleAlert className="mt-0.5 size-3.5 shrink-0" />+ <WarningIcon className="mt-0.5 size-3.5 shrink-0" /><span>{t('plugins.logs.verboseWarning')}</span></div>)}@@ -141,7 +146,7 @@ export function PluginLogTab({ pluginId }: { pluginId: string }) {<div className="flex min-h-0 flex-1 flex-col overflow-hidden rounded-lg border"><div className="flex h-9 shrink-0 items-center justify-between border-b border-border/60 bg-muted/30 px-3"><div className="flex items-center gap-2 text-xs font-medium text-foreground">- <TerminalSquare className="size-3.5 text-muted-foreground" />+ <TerminalIcon className="size-3.5 text-muted-foreground" /><span>{t('plugins.logs.output')}</span></div><span@@ -161,7 +166,7 @@ export function PluginLogTab({ pluginId }: { pluginId: string }) {{filtered.length === 0 ? (<div className="flex flex-1 flex-col items-center justify-center gap-2 px-6 py-12 text-center"><div className="mb-1 flex size-10 items-center justify-center rounded-xl border border-border/60 bg-background/80 shadow-xs">- <TerminalSquare className="size-4.5 text-muted-foreground" />+ <TerminalIcon className="size-4.5 text-muted-foreground" /></div><p className="text-sm font-medium tracking-tight text-foreground">{entries.length === 0diff --git a/src/renderer/routes/plugins/components/registry-detail-panel.tsx b/src/renderer/routes/plugins/components/registry-detail-panel.tsxindex 14d69786..1fa775e3 100644--- a/src/renderer/routes/plugins/components/registry-detail-panel.tsx+++ b/src/renderer/routes/plugins/components/registry-detail-panel.tsx@@ -2,6 +2,7 @@ import {PANEL_TITLE_CLASS,PanelShell,} from '@renderer/components/desktop-kit/panel/panel-shell'+import { ExternalLinkIcon, InstallIcon } from '@renderer/components/icons'import { Badge } from '@renderer/components/ui/badge'import { Button } from '@renderer/components/ui/button'import { Card } from '@renderer/components/ui/card'@@ -14,7 +15,6 @@ import {import { usePlatformServices } from '@renderer/platform/services'import { EXTERNAL_URLS } from '@shared/external-urls'import type { RegistryPluginDTO } from '@shared/schemas/registry'-import { Download, ExternalLink } from 'lucide-react'import { useState } from 'react'import { useTranslation } from 'react-i18next'import { registryListing } from '../lib/registry-text'@@ -100,7 +100,7 @@ export function RegistryDetailPanel({ entry }: Props) {onClick={() => setInstallOpen(true)}data-testid="registry-install-btn">- <Download className="size-3.5" />+ <InstallIcon className="size-3.5" />{t('plugins.registry.install')}</Button><Button@@ -112,7 +112,7 @@ export function RegistryDetailPanel({ entry }: Props) {)}>- <ExternalLink className="size-3.5" />+ <ExternalLinkIcon className="size-3.5" />{t('plugins.registry.viewOnWebsite')}</Button></div>diff --git a/src/renderer/routes/plugins/components/uninstall-section.tsx b/src/renderer/routes/plugins/components/uninstall-section.tsxindex ed8a7114..77adb9d7 100644--- a/src/renderer/routes/plugins/components/uninstall-section.tsx+++ b/src/renderer/routes/plugins/components/uninstall-section.tsx@@ -1,3 +1,4 @@+import { RemoveIcon } from '@renderer/components/icons'import {AlertDialog,AlertDialogAction,@@ -19,7 +20,6 @@ import {import { transport } from '@renderer/lib/transport'import { cn } from '@renderer/lib/utils'import { Commands } from '@shared/protocol/commands'-import { Trash2 } from 'lucide-react'import { useTranslation } from 'react-i18next'interface Props {@@ -47,7 +47,7 @@ export function UninstallSection({ pluginId, pluginName, hidden }: Props) {/>}>- <Trash2 className="size-4" />+ <RemoveIcon className="size-4" /></AlertDialogTrigger>}/>diff --git a/src/renderer/routes/plugins/plugin-detail-page.tsx b/src/renderer/routes/plugins/plugin-detail-page.tsxindex 604e11e5..eaec510f 100644--- a/src/renderer/routes/plugins/plugin-detail-page.tsx+++ b/src/renderer/routes/plugins/plugin-detail-page.tsx@@ -2,6 +2,12 @@ import {PANEL_TITLE_CLASS,PanelShell,} from '@renderer/components/desktop-kit/panel/panel-shell'+import {+ ChangelogIcon,+ PluginUpdateIcon,+ RefreshIcon,+ UndoIcon,+} from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {ScrollArea,@@ -28,7 +34,6 @@ import { cn } from '@renderer/lib/utils'import { usePlatformServices } from '@renderer/platform/services'import { Commands } from '@shared/protocol/commands'import type { JsonSchemaNode, PluginManifestDTO } from '@shared/types/plugin'-import { CircleFadingArrowUp, RefreshCw, ScrollText, Undo2 } from 'lucide-react'import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'import { useNavigate, useParams, useSearchParams } from 'react-router'@@ -203,7 +208,7 @@ export function PluginDetailPage() {onClick={() => setTab('logs')}aria-label={t('plugins.detail.logs')}>- <ScrollText className="size-4 text-foreground" />+ <ChangelogIcon className="size-4 text-foreground" /></Button>}/>@@ -229,7 +234,7 @@ export function PluginDetailPage() {})}data-testid="plugin-update-btn">- <CircleFadingArrowUp className="size-4 text-foreground" />+ <PluginUpdateIcon className="size-4 text-foreground" /></Button>) : (<Button@@ -240,7 +245,7 @@ export function PluginDetailPage() {aria-label={t('plugins.registry.refresh')}data-testid="plugin-detail-refresh-btn">- <RefreshCw+ <RefreshIconclassName={cn('size-4 text-foreground',refreshing && 'animate-spin'@@ -292,7 +297,7 @@ export function PluginDetailPage() {}}}>- <Undo2 className="size-4 text-foreground" />+ <UndoIcon className="size-4 text-foreground" /></Button>}/>diff --git a/src/renderer/routes/plugins/plugins-page.tsx b/src/renderer/routes/plugins/plugins-page.tsxindex 51b4077a..64f940c9 100644--- a/src/renderer/routes/plugins/plugins-page.tsx+++ b/src/renderer/routes/plugins/plugins-page.tsx@@ -6,6 +6,7 @@ import {} from '@renderer/components/desktop-kit/toolbar/toolbar-button'import { ToolbarGroup } from '@renderer/components/desktop-kit/toolbar/toolbar-group'import { ToolbarSearch } from '@renderer/components/desktop-kit/toolbar/toolbar-search'+import { AddIcon, CallGraphIcon, RefreshIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {ScrollArea,@@ -14,7 +15,6 @@ import {ScrollBar,} from '@renderer/components/ui/scroll-area'import { Skeleton } from '@renderer/components/ui/skeleton'-import { Plus, RefreshCw, Workflow } from 'lucide-react'import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { Link } from 'react-router'@@ -75,13 +75,13 @@ export function PluginsPage() {label={t('plugins.install.title')}onClick={() => setInstallOpen(true)}>- <Plus aria-hidden="true" />+ <AddIcon aria-hidden="true" /></ToolbarButton><ToolbarLinklabel={diagnosticsLabel}render={<Link to="/plugins/diagnostics" />}>- <Workflow aria-hidden="true" />+ <CallGraphIcon aria-hidden="true" /></ToolbarLink><ToolbarButtonlabel={refreshLabel}@@ -90,7 +90,7 @@ export function PluginsPage() {aria-busy={refreshing}data-testid="registry-refresh-btn">- <RefreshCw+ <RefreshIconaria-hidden="true"className={refreshingdiff --git a/src/renderer/routes/settings/card-registry.tsx b/src/renderer/routes/settings/card-registry.tsxindex ee027ac6..7aeb7ebb 100644--- a/src/renderer/routes/settings/card-registry.tsx+++ b/src/renderer/routes/settings/card-registry.tsx@@ -9,48 +9,52 @@ import { GeneralDialog } from './cards/general-dialog'import { IntegrationDialog } from './cards/integration/integration-dialog'import { NetworkDialog } from './cards/network-dialog'-const iconGeneral1x = new URL('./icons/[email protected]', import.meta.url)+const iconGeneral1x = new URL('./icons/[email protected]', import.meta.url).href-const iconGeneral2x = new URL('./icons/[email protected]', import.meta.url)+const iconGeneral2x = new URL('./icons/[email protected]', import.meta.url).hrefconst iconAppearance1x = new URL(- './icons/[email protected]',+ './icons/[email protected]',import.meta.url).hrefconst iconAppearance2x = new URL(- './icons/[email protected]',+ './icons/[email protected]',+ import.meta.url+).href+const iconDownloads1x = new URL(+ './icons/[email protected]',+ import.meta.url+).href+const iconDownloads2x = new URL(+ './icons/[email protected]',import.meta.url).href-const iconDownloads1x = new URL('./icons/[email protected]', import.meta.url)- .href-const iconDownloads2x = new URL('./icons/[email protected]', import.meta.url)- .hrefconst iconBittorrent1x = new URL(- './icons/[email protected]',+ './icons/[email protected]',import.meta.url).hrefconst iconBittorrent2x = new URL(- './icons/[email protected]',+ './icons/[email protected]',import.meta.url).hrefconst iconIntegration1x = new URL(- './icons/[email protected]',+ './icons/[email protected]',import.meta.url).hrefconst iconIntegration2x = new URL(- './icons/[email protected]',+ './icons/[email protected]',import.meta.url).href-const iconNetwork1x = new URL('./icons/[email protected]', import.meta.url)+const iconNetwork1x = new URL('./icons/[email protected]', import.meta.url).href-const iconNetwork2x = new URL('./icons/[email protected]', import.meta.url)+const iconNetwork2x = new URL('./icons/[email protected]', import.meta.url).href-const iconAdvanced1x = new URL('./icons/[email protected]', import.meta.url)+const iconAdvanced1x = new URL('./icons/[email protected]', import.meta.url).href-const iconAdvanced2x = new URL('./icons/[email protected]', import.meta.url)+const iconAdvanced2x = new URL('./icons/[email protected]', import.meta.url).href-const iconAbout1x = new URL('./icons/[email protected]', import.meta.url).href-const iconAbout2x = new URL('./icons/[email protected]', import.meta.url).href+const iconAbout1x = new URL('./icons/[email protected]', import.meta.url).href+const iconAbout2x = new URL('./icons/[email protected]', import.meta.url).hreffunction createSettingsIcon(id: string,@@ -61,6 +65,9 @@ function createSettingsIcon(<imgsrc={src1x}srcSet={`${src1x} 1x, ${src2x} 2x`}+ width={52}+ height={52}+ className="brightness-90 contrast-[1.12] saturate-[1.2] drop-shadow-[0_1px_1px_rgb(15_23_42/0.12)] dark:filter-none"alt={id}draggable={false}/>diff --git a/src/renderer/routes/settings/cards/advanced-dialog.tsx b/src/renderer/routes/settings/cards/advanced-dialog.tsxindex c7238b72..31c16163 100644--- a/src/renderer/routes/settings/cards/advanced-dialog.tsx+++ b/src/renderer/routes/settings/cards/advanced-dialog.tsx@@ -1,3 +1,4 @@+import { RandomizeIcon } from '@renderer/components/icons'import { SettingsFormRow } from '@renderer/components/settings-kit/settings-form-row'import {useSettingsForm,@@ -38,7 +39,6 @@ import { Queries } from '@shared/protocol/queries'import { DEFAULT_ENGINE_SETTINGS } from '@shared/schemas'import type { AppSettings, EngineSettings } from '@shared/types/settings'import { generateRpcSecret } from '@shared/utils/rpc-secret'-import { Dices } from 'lucide-react'import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import type { SettingsCardDialogProps } from './card-types'@@ -203,7 +203,7 @@ export function AdvancedDialog({aria-label={t('settings.common.generate')}onClick={() => field.onChange(generateRpcSecret())}>- <Dices className="h-3 w-3" />+ <RandomizeIcon className="h-3 w-3" /></Button></div><FormMessage className="basis-full text-xs" />diff --git a/src/renderer/routes/settings/cards/app-update-section.tsx b/src/renderer/routes/settings/cards/app-update-section.tsxindex e2b3c1a4..13bb024a 100644--- a/src/renderer/routes/settings/cards/app-update-section.tsx+++ b/src/renderer/routes/settings/cards/app-update-section.tsx@@ -1,10 +1,14 @@+import {+ InstallIcon,+ RefreshIcon,+ RestartIcon,+} from '@renderer/components/icons'import { Alert } from '@renderer/components/ui/alert'import { Button } from '@renderer/components/ui/button'import { Spinner } from '@renderer/components/ui/spinner'import { cn } from '@renderer/lib/utils'import type { AppUpdateState } from '@shared/types/app-update'import type { AppUpdateChannel } from '@shared/types/settings'-import { DownloadIcon, RefreshCwIcon, RotateCwIcon } from 'lucide-react'import type { ReactNode } from 'react'import { useId, useState } from 'react'import { useTranslation } from 'react-i18next'@@ -153,7 +157,7 @@ function updateAction(return {label: t('settings.about.update.checkAction'),accessibleLabel: t('settings.about.update.check'),- icon: <RefreshCwIcon data-icon="inline-start" aria-hidden="true" />,+ icon: <RefreshIcon data-icon="inline-start" aria-hidden="true" />,disabled: true,variant: 'default',}@@ -167,7 +171,7 @@ function updateAction(case 'available':return {label: t('settings.about.update.download'),- icon: <DownloadIcon data-icon="inline-start" aria-hidden="true" />,+ icon: <InstallIcon data-icon="inline-start" aria-hidden="true" />,variant: 'default',run: actions.download,}@@ -175,14 +179,14 @@ function updateAction(return {label: <span className="tabular-nums">{progress}%</span>,accessibleLabel: `${t('settings.about.update.downloading')} ${progress}%`,- icon: <DownloadIcon data-icon="inline-start" aria-hidden="true" />,+ icon: <InstallIcon data-icon="inline-start" aria-hidden="true" />,disabled: true,variant: 'default',}case 'downloaded':return {label: t('settings.about.update.restart'),- icon: <RotateCwIcon data-icon="inline-start" aria-hidden="true" />,+ icon: <RestartIcon data-icon="inline-start" aria-hidden="true" />,variant: 'default',run: actions.install,}@@ -190,7 +194,7 @@ function updateAction(case 'error':return {label: t('settings.about.update.retry'),- icon: <RefreshCwIcon data-icon="inline-start" aria-hidden="true" />,+ icon: <RefreshIcon data-icon="inline-start" aria-hidden="true" />,variant: 'default',run: state.availableVersion ? actions.download : actions.check,}@@ -198,7 +202,7 @@ function updateAction(return {label: t('settings.about.update.checkAction'),accessibleLabel: t('settings.about.update.check'),- icon: <RefreshCwIcon data-icon="inline-start" aria-hidden="true" />,+ icon: <RefreshIcon data-icon="inline-start" aria-hidden="true" />,variant: 'default',run: actions.check,}diff --git a/src/renderer/routes/settings/cards/appearance-dialog.test.tsx b/src/renderer/routes/settings/cards/appearance-dialog.test.tsxindex 8495e3b4..1499aee9 100644--- a/src/renderer/routes/settings/cards/appearance-dialog.test.tsx+++ b/src/renderer/routes/settings/cards/appearance-dialog.test.tsx@@ -451,3 +451,81 @@ it('saves only the chosen unit system when Apply is clicked', async () => {app: { byteUnitSystem: 'binary' },})})++describe('sidebar color', () => {+ it('previews a color and saves only its dirty preference', async () => {+ const { useSidebarColorState } = await import('@renderer/lib/sidebar-color')+ useSidebarColorState.setState({ saved: 'gray', preview: null, revision: 0 })+ const close = vi.fn()+ render(+ <AppearanceDialog+ open+ onClose={close}+ labelKey="settings.cards.appearance.title"+ descKey="settings.cards.appearance.desc"+ />+ )+ const user = userEvent.setup()+ await user.click(await screen.findByRole('radio', { name: 'Cyan' }))+ expect(useSidebarColorState.getState().preview).toBe('cyan')+ expect(transport.invoke).not.toHaveBeenCalledWith(+ Commands.UpdateSettings,+ expect.anything()+ )+ await user.click(screen.getByRole('button', { name: 'Save' }))+ expect(transport.invoke).toHaveBeenCalledWith(Commands.UpdateSettings, {+ app: { sidebarColor: 'cyan' },+ })+ expect(useSidebarColorState.getState().saved).toBe('cyan')+ expect(close).toHaveBeenCalledOnce()+ })+ it('hydrates a saved color and discards the preview when closed', async () => {+ const { useSidebarColorState } = await import('@renderer/lib/sidebar-color')+ vi.mocked(transport.invoke).mockResolvedValue({+ app: { ...FIXTURE.app, sidebarColor: 'pink' },+ })+ const props = {+ onClose: vi.fn(),+ labelKey: 'settings.cards.appearance.title',+ descKey: 'settings.cards.appearance.desc',+ }+ const { rerender } = render(<AppearanceDialog {...props} open />)+ await waitFor(() =>+ expect(screen.getByRole('radio', { name: 'Pink' })).toBeChecked()+ )+ const user = userEvent.setup()+ await user.click(screen.getByRole('radio', { name: 'Blue' }))+ expect(useSidebarColorState.getState().preview).toBe('blue')+ await user.click(screen.getByRole('button', { name: 'Cancel' }))+ rerender(<AppearanceDialog {...props} open={false} />)+ expect(useSidebarColorState.getState().preview).toBeNull()+ expect(transport.invoke).not.toHaveBeenCalledWith(+ Commands.UpdateSettings,+ expect.anything()+ )+ })+ it('keeps a failed save editable and supports keyboard selection', async () => {+ const close = vi.fn()+ vi.mocked(transport.invoke).mockImplementation(async (channel) => {+ if (channel === Queries.GetSettings) return FIXTURE+ throw new Error('save failed')+ })+ render(+ <AppearanceDialog+ open+ onClose={close}+ labelKey="settings.cards.appearance.title"+ descKey="settings.cards.appearance.desc"+ />+ )+ const user = userEvent.setup()+ const gray = await screen.findByRole('radio', { name: 'Gray' })+ gray.focus()+ await user.keyboard('{ArrowLeft}')+ expect(screen.getByRole('radio', { name: 'Cyan' })).toBeChecked()+ await user.click(screen.getByRole('button', { name: 'Save' }))+ expect(await screen.findByRole('alert')).toBeVisible()+ expect(close).not.toHaveBeenCalled()+ expect(screen.getByRole('radio', { name: 'Cyan' })).toBeEnabled()+ })+})diff --git a/src/renderer/routes/settings/cards/appearance-dialog.tsx b/src/renderer/routes/settings/cards/appearance-dialog.tsxindex 8ba4a69a..92aa0a56 100644--- a/src/renderer/routes/settings/cards/appearance-dialog.tsx+++ b/src/renderer/routes/settings/cards/appearance-dialog.tsx@@ -36,6 +36,7 @@ import {import { Switch } from '@renderer/components/ui/switch'import { pickDirty } from '@renderer/lib/form-utils'import { saveSettings } from '@renderer/lib/settings-save'+import { useSidebarColorState } from '@renderer/lib/sidebar-color'import { transport } from '@renderer/lib/transport'import { RunMode } from '@shared/constants'import { isSupportedLocale, SUPPORTED_LOCALES } from '@shared/constants/locales'@@ -47,10 +48,12 @@ import { useEffect } from 'react'import { useTranslation } from 'react-i18next'import type { SettingsCardDialogProps } from './card-types'import { appearanceFormSchema } from './settings-form-schemas'+import { SidebarColorPicker } from './sidebar-color-picker'type AppearanceFields = Pick<MotrixAppSettings,| 'theme'+ | 'sidebarColor'| 'reduceMotion'| 'language'| 'byteUnitSystem'@@ -66,6 +69,7 @@ type AppearanceFields = Pick<// fields it edits. Keep this Pick<> in sync if the schema fields change.const DEFAULTS: AppearanceFields = {theme: DEFAULT_APP_SETTINGS.theme,+ sidebarColor: DEFAULT_APP_SETTINGS.sidebarColor,reduceMotion: DEFAULT_APP_SETTINGS.reduceMotion,language: DEFAULT_APP_SETTINGS.language,byteUnitSystem: DEFAULT_APP_SETTINGS.byteUnitSystem,@@ -104,6 +108,7 @@ export function AppearanceDialog({if (all?.app) {form.reset({theme: all.app.theme,+ sidebarColor: all.app.sidebarColor ?? DEFAULTS.sidebarColor,reduceMotion: all.app.reduceMotion ?? DEFAULTS.reduceMotion,language: all.app.language,byteUnitSystem: all.app.byteUnitSystem ?? DEFAULTS.byteUnitSystem,@@ -127,6 +132,15 @@ export function AppearanceDialog({}}, [])+ const sidebarColor = form.watch('sidebarColor')+ const colorIsDirty = !!form.formState.dirtyFields.sidebarColor+ useEffect(() => {+ useSidebarColorState.setState({+ preview: open && colorIsDirty ? sidebarColor : null,+ })+ return () => useSidebarColorState.setState({ preview: null })+ }, [open, colorIsDirty, sidebarColor])+const onSubmit = useSettingsSubmit(form, async (values) => {const dirty = pickDirty(values, form.formState.dirtyFields)if (!dirty) {@@ -134,6 +148,12 @@ export function AppearanceDialog({return}await saveSettings({ app: dirty })+ if (dirty.sidebarColor !== undefined) {+ useSidebarColorState.setState((state) => ({+ saved: dirty.sidebarColor,+ revision: state.revision + 1,+ }))+ }onClose()})@@ -263,6 +283,26 @@ export function AppearanceDialog({)}/>+ <FormField+ control={form.control}+ name="sidebarColor"+ render={({ field }) => (+ <SettingsFormRow className="flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between sm:gap-4">+ <FormLabel className="sm:pt-2">+ {t('settings.appearance.sidebarColor')}+ </FormLabel>+ <FormControl>+ <SidebarColorPicker+ value={field.value}+ onChange={field.onChange}+ onBlur={field.onBlur}+ disabled={form.formState.isSubmitting}+ />+ </FormControl>+ </SettingsFormRow>+ )}+ />+<FormFieldcontrol={form.control}name="language"diff --git a/src/renderer/routes/settings/cards/compact-limit-input.tsx b/src/renderer/routes/settings/cards/compact-limit-input.tsxindex 5a991949..5c40f02c 100644--- a/src/renderer/routes/settings/cards/compact-limit-input.tsx+++ b/src/renderer/routes/settings/cards/compact-limit-input.tsx@@ -1,3 +1,4 @@+import { ResetIcon, UnlimitedIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import { ButtonGroup } from '@renderer/components/ui/button-group'import {@@ -12,7 +13,6 @@ import {TooltipProvider,TooltipTrigger,} from '@renderer/components/ui/tooltip'-import { Infinity as InfinityIcon, RotateCcw } from 'lucide-react'import { type ComponentProps, forwardRef, useState } from 'react'type ZeroAction = 'unlimited' | 'inherit'@@ -51,7 +51,7 @@ export const CompactLimitInput = forwardRef<null)const zero = value === 0- const ResetIcon = zeroAction === 'inherit' ? RotateCcw : InfinityIcon+ const ZeroActionIcon = zeroAction === 'inherit' ? ResetIcon : UnlimitedIconreturn (<ButtonGroup className="w-40 shrink-0">@@ -70,7 +70,7 @@ export const CompactLimitInput = forwardRef<onValueChange(0)}}>- <ResetIcon aria-hidden />+ <ZeroActionIcon aria-hidden /></Button>}/>diff --git a/src/renderer/routes/settings/cards/integration/appimage-integration-section.tsx b/src/renderer/routes/settings/cards/integration/appimage-integration-section.tsxindex f6418996..810d52b7 100644--- a/src/renderer/routes/settings/cards/integration/appimage-integration-section.tsx+++ b/src/renderer/routes/settings/cards/integration/appimage-integration-section.tsx@@ -1,3 +1,4 @@+import { StatusErrorIcon } from '@renderer/components/icons'import {Alert,AlertDescription,@@ -9,7 +10,6 @@ import { transport } from '@renderer/lib/transport'import { Commands } from '@shared/protocol/commands'import { Queries } from '@shared/protocol/queries'import type { AppImageIntegrationView } from '@shared/types/appimage-integration'-import { CircleAlert } from 'lucide-react'import { useEffect, useState } from 'react'import { useTranslation } from 'react-i18next'@@ -139,7 +139,7 @@ export function AppImageIntegrationSection({{failed && (<Alert variant="destructive">- <CircleAlert aria-hidden="true" />+ <StatusErrorIcon aria-hidden="true" /><AlertTitle>{t('settings.integration.appimage.status.failedTitle')}</AlertTitle>diff --git a/src/renderer/routes/settings/cards/integration/browser-extensions-section.tsx b/src/renderer/routes/settings/cards/integration/browser-extensions-section.tsxindex 17559068..078c0c5a 100644--- a/src/renderer/routes/settings/cards/integration/browser-extensions-section.tsx+++ b/src/renderer/routes/settings/cards/integration/browser-extensions-section.tsx@@ -1,3 +1,4 @@+import { WarningIcon } from '@renderer/components/icons'import { SettingsFormRow } from '@renderer/components/settings-kit/settings-form-row'import {Alert,@@ -15,7 +16,6 @@ import { Switch } from '@renderer/components/ui/switch'import { browserDisplayName } from '@renderer/lib/browser-name'import { cn } from '@renderer/lib/utils'import type { PairedClientInfo } from '@shared/protocol/bridge'-import { TriangleAlertIcon } from 'lucide-react'import { useFormContext } from 'react-hook-form'import { useTranslation } from 'react-i18next'import { BrowserExtensionInstalls } from './browser-extension-installs'@@ -69,7 +69,7 @@ export function BrowserExtensionsSection() {{status?.degraded && (<Alert className="border-amber-500/30 bg-amber-500/10 px-3 py-2 text-[11px] leading-4 text-amber-900 dark:text-amber-200">- <TriangleAlertIcon />+ <WarningIcon /><AlertTitle>{t('settings.integration.browser.degradedPort.title')}</AlertTitle>@@ -83,7 +83,7 @@ export function BrowserExtensionsSection() {{status?.extensionPairingHealth === 'degraded' && (<Alert className="border-destructive/30 bg-destructive/10 px-3 py-2 text-[11px] leading-4 text-destructive">- <TriangleAlertIcon />+ <WarningIcon /><AlertTitle>{t('settings.integration.browser.pairingStateDegraded.title')}</AlertTitle>diff --git a/src/renderer/routes/settings/cards/integration/cli-tool-section.tsx b/src/renderer/routes/settings/cards/integration/cli-tool-section.tsxindex 14c6d8c1..e9a0fc38 100644--- a/src/renderer/routes/settings/cards/integration/cli-tool-section.tsx+++ b/src/renderer/routes/settings/cards/integration/cli-tool-section.tsx@@ -1,4 +1,5 @@import { CopyButton } from '@renderer/components/desktop-kit/copy-button'+import { ChevronRightIcon, StatusErrorIcon } from '@renderer/components/icons'import {Alert,AlertDescription,@@ -40,7 +41,6 @@ import {CliToolReason,type CliToolStatus,} from '@shared/types/cli-tool'-import { ChevronRight, CircleAlert } from 'lucide-react'import { useState } from 'react'import { useTranslation } from 'react-i18next'import { useCliTool } from './use-cli-tool'@@ -318,7 +318,7 @@ export function CliToolSection() {status.phase === CliToolPhase.Error ? 'destructive' : 'default'}>- <CircleAlert aria-hidden="true" />+ <StatusErrorIcon aria-hidden="true" /><AlertTitle>{t('settings.integration.cli.tool.attentionTitle')}</AlertTitle>@@ -337,7 +337,7 @@ export function CliToolSection() {<CollapsibleTriggerrender={<Button type="button" variant="ghost" size="xs" />}>- <ChevronRight+ <ChevronRightIcondata-icon="inline-start"aria-hidden="true"className={cn(diff --git a/src/renderer/routes/settings/cards/integration/integration-dialog.tsx b/src/renderer/routes/settings/cards/integration/integration-dialog.tsxindex 5973c585..5239115a 100644--- a/src/renderer/routes/settings/cards/integration/integration-dialog.tsx+++ b/src/renderer/routes/settings/cards/integration/integration-dialog.tsx@@ -1,3 +1,4 @@+import { StatusErrorIcon } from '@renderer/components/icons'import {useSettingsForm,useSettingsSubmit,@@ -26,7 +27,6 @@ import { transport } from '@renderer/lib/transport'import { Queries } from '@shared/protocol/queries'import { DEFAULT_APP_SETTINGS, DEFAULT_MEDIA_SETTINGS } from '@shared/schemas'import type { AppSettings } from '@shared/types/settings'-import { CircleAlert } from 'lucide-react'import { useEffect, useState } from 'react'import { FormProvider } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -236,7 +236,7 @@ export function IntegrationDialog({)}{saveError && (<Alert variant="destructive" className="mr-auto">- <CircleAlert aria-hidden="true" />+ <StatusErrorIcon aria-hidden="true" /><AlertDescription>{saveError}</AlertDescription></Alert>)}diff --git a/src/renderer/routes/settings/cards/integration/media-tools-section.test.tsx b/src/renderer/routes/settings/cards/integration/media-tools-section.test.tsxindex dfcd5978..ed390973 100644--- a/src/renderer/routes/settings/cards/integration/media-tools-section.test.tsx+++ b/src/renderer/routes/settings/cards/integration/media-tools-section.test.tsx@@ -106,7 +106,10 @@ describe('MediaToolsSection', () => {managedPath)expect(managedPathButton).toHaveAttribute('data-size', 'icon-xs')- expect(managedPathButton.lastElementChild).toHaveClass('lucide-copy')+ expect(managedPathButton.lastElementChild).toHaveAttribute(+ 'data-icon',+ 'copy'+ )fireEvent.click(managedPathButton)diff --git a/src/renderer/routes/settings/cards/integration/media-tools-section.tsx b/src/renderer/routes/settings/cards/integration/media-tools-section.tsxindex 7d54a0ad..c7f74f22 100644--- a/src/renderer/routes/settings/cards/integration/media-tools-section.tsx+++ b/src/renderer/routes/settings/cards/integration/media-tools-section.tsx@@ -1,4 +1,13 @@import { CopyButton } from '@renderer/components/desktop-kit/copy-button'+import {+ CheckIcon,+ ChevronRightIcon,+ EditIcon,+ InstallIcon,+ RefreshIcon,+ SecurityWarningIcon,+ VerifiedToolIcon,+} from '@renderer/components/icons'import { SettingsFormRow } from '@renderer/components/settings-kit/settings-form-row'import { Badge } from '@renderer/components/ui/badge'import { Button } from '@renderer/components/ui/button'@@ -20,15 +29,6 @@ import { transport } from '@renderer/lib/transport'import { cn } from '@renderer/lib/utils'import { EXTERNAL_URLS } from '@shared/external-urls'import { Queries } from '@shared/protocol/queries'-import {- BadgeCheck,- Check,- ChevronRight,- Download,- Pencil,- RefreshCw,- ShieldAlert,-} from 'lucide-react'import { useEffect, useState } from 'react'import { useFormContext } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -138,9 +138,9 @@ export function MediaToolsSection() {<div className="min-w-0 space-y-1"><div className="flex flex-wrap items-center gap-2"><div className="text-sm font-medium">{activeLabel}</div>- {detection?.active && <BadgeCheck className="size-4" />}+ {detection?.active && <VerifiedToolIcon className="size-4" />}{hasUntrustedCandidate && (- <ShieldAlert className="size-4 text-destructive" />+ <SecurityWarningIcon className="size-4 text-destructive" />)}</div><div className="text-xs text-muted-foreground">@@ -164,7 +164,10 @@ export function MediaToolsSection() {size="icon-sm"variant="ghost">- <Download className="size-4 text-muted-foreground" aria-hidden />+ <InstallIcon+ className="size-4 text-muted-foreground"+ aria-hidden+ /></Button><Buttontype="button"@@ -173,7 +176,7 @@ export function MediaToolsSection() {aria-label={t('settings.integration.media.refresh')}onClick={refresh}>- <RefreshCw className="size-4 text-muted-foreground" />+ <RefreshIcon className="size-4 text-muted-foreground" /></Button></div></div>@@ -204,7 +207,7 @@ export function MediaToolsSection() {/>}>- <ChevronRight+ <ChevronRightIconclassName={cn('size-3.5 transition-transform duration-150',detailsOpen && 'rotate-90'@@ -307,9 +310,9 @@ export function MediaToolsSection() {}}>{editingPath ? (- <Check aria-hidden />+ <CheckIcon aria-hidden />) : (- <Pencil aria-hidden />+ <EditIcon aria-hidden />)}</Button><FormMessage className="col-span-full text-xs" />diff --git a/src/renderer/routes/settings/cards/integration/system-protocols-section.tsx b/src/renderer/routes/settings/cards/integration/system-protocols-section.tsxindex c69e7185..c11028da 100644--- a/src/renderer/routes/settings/cards/integration/system-protocols-section.tsx+++ b/src/renderer/routes/settings/cards/integration/system-protocols-section.tsx@@ -1,3 +1,4 @@+import { HelpIcon } from '@renderer/components/icons'import { SettingsFormRow } from '@renderer/components/settings-kit/settings-form-row'import { Button } from '@renderer/components/ui/button'import {@@ -14,7 +15,6 @@ import { Commands } from '@shared/protocol/commands'import { Queries } from '@shared/protocol/queries'import type { LinuxDefaultAssociations } from '@shared/types/linux-default-apps'import type { WindowsDefaultAssociations } from '@shared/types/windows-default-apps'-import { CircleQuestionMark } from 'lucide-react'import { useEffect, useState } from 'react'import { useFormContext } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -240,7 +240,7 @@ export function SystemProtocolsSection({aria-label={t('settings.common.openHelp')}className="text-muted-foreground hover:text-foreground">- <CircleQuestionMark className="size-4" />+ <HelpIcon className="size-4" /></a></span><p className="text-xs text-muted-foreground">diff --git a/src/renderer/routes/settings/cards/integration/trusted-extensions-section.tsx b/src/renderer/routes/settings/cards/integration/trusted-extensions-section.tsxindex d370de48..27a75463 100644--- a/src/renderer/routes/settings/cards/integration/trusted-extensions-section.tsx+++ b/src/renderer/routes/settings/cards/integration/trusted-extensions-section.tsx@@ -1,3 +1,8 @@+import {+ ChevronRightIcon,+ ExternalLinkIcon,+ RemoveIcon,+} from '@renderer/components/icons'import { Badge } from '@renderer/components/ui/badge'import { Button } from '@renderer/components/ui/button'import {@@ -18,7 +23,6 @@ import { browserDisplayName } from '@renderer/lib/browser-name'import { cn } from '@renderer/lib/utils'import { EXTERNAL_URLS } from '@shared/external-urls'import type { TrustedExtensionInfo } from '@shared/protocol/bridge'-import { ChevronRight, ExternalLink, Trash2 } from 'lucide-react'import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useTrustedExtensions } from './use-bridge'@@ -61,7 +65,7 @@ function ExtensionId({className="inline-flex max-w-full items-center gap-1 rounded-sm font-mono text-primary underline underline-offset-2 hover:no-underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"><span className="truncate">{id}</span>- <ExternalLink className="size-3 shrink-0" aria-hidden="true" />+ <ExternalLinkIcon className="size-3 shrink-0" aria-hidden="true" /></a>) : (<div className="truncate font-mono">{id}</div>@@ -145,7 +149,7 @@ export function TrustedExtensionsSection({ disabled }: { disabled: boolean }) {}><span className="flex items-center gap-1.5">- <ChevronRight+ <ChevronRightIconclassName={cn('size-3.5 transition-transform duration-150',open && 'rotate-90'@@ -212,7 +216,7 @@ export function TrustedExtensionsSection({ disabled }: { disabled: boolean }) {'settings.integration.browser.removeTrusted')}>- <Trash2 />+ <RemoveIcon /></Button>) : (<span />diff --git a/src/renderer/routes/settings/cards/performance-section.tsx b/src/renderer/routes/settings/cards/performance-section.tsxindex 7a783356..4efbb42f 100644--- a/src/renderer/routes/settings/cards/performance-section.tsx+++ b/src/renderer/routes/settings/cards/performance-section.tsx@@ -1,3 +1,11 @@+import {+ ArrowUpRightIcon,+ ConnectionsIcon,+ DiskCacheIcon,+ type MotrixIcon,+ PieceSizeIcon,+ ServerConnectionsIcon,+} from '@renderer/components/icons'import { SettingsSelectTrigger } from '@renderer/components/settings-kit/settings-select-trigger'import {FormControl,@@ -21,21 +29,13 @@ import {} from '@shared/constants/engine-performance-profiles'import { getDownloadPerformanceUrl } from '@shared/external-urls'import { MAX_CONNECTIONS_PER_SERVER } from '@shared/schemas/engine-settings'-import {- ArrowUpRightIcon,- DatabaseIcon,- type LucideIcon,- RulerIcon,- ServerIcon,- SplitIcon,-} from 'lucide-react'import { type UseFormReturn, useWatch } from 'react-hook-form'import { useTranslation } from 'react-i18next'import { type DownloadsFields, MB } from './downloads-form'import { EngineNumberSettingRow } from './engine-number-setting-row'type PerformanceMetric = {- icon: LucideIcon+ icon: MotrixIconlabel: stringvalue: number | string}@@ -62,22 +62,22 @@ export function PerformanceSection({selectedPerformanceValues? [{- icon: SplitIcon,+ icon: ConnectionsIcon,label: t('settings.downloads.performance.metrics.connections'),value: selectedPerformanceValues.split,},{- icon: ServerIcon,+ icon: ServerConnectionsIcon,label: t('settings.downloads.performance.metrics.perServer'),value: selectedPerformanceValues.maxConnectionPerServer,},{- icon: RulerIcon,+ icon: PieceSizeIcon,label: t('settings.downloads.performance.metrics.minimum'),value: `${Math.round(selectedPerformanceValues.minSplitSize / MB)} MiB`,},{- icon: DatabaseIcon,+ icon: DiskCacheIcon,label: t('settings.downloads.performance.metrics.cache'),value: `${Math.round(selectedPerformanceValues.diskCache / MB)} MiB`,},diff --git a/src/renderer/routes/settings/cards/proxy-section.tsx b/src/renderer/routes/settings/cards/proxy-section.tsxindex 4d58482f..fa97439a 100644--- a/src/renderer/routes/settings/cards/proxy-section.tsx+++ b/src/renderer/routes/settings/cards/proxy-section.tsx@@ -1,3 +1,8 @@+import {+ ChevronDownIcon,+ ConcealIcon,+ RevealIcon,+} from '@renderer/components/icons'import { SettingsFormRow } from '@renderer/components/settings-kit/settings-form-row'import { Button } from '@renderer/components/ui/button'import {@@ -30,7 +35,6 @@ import { transport } from '@renderer/lib/transport'import { Queries } from '@shared/protocol/queries'import type { ProxySettings } from '@shared/types/settings'import type { SystemProxyResult } from '@shared/types/system-proxy'-import { ChevronDown, Eye, EyeOff } from 'lucide-react'import { useEffect, useRef, useState } from 'react'import type { UseFormReturn } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -202,7 +206,7 @@ export function ProxySection({ form }: { form: UseFormReturn<NetworkFields> }) {}>{protoField.value}- <ChevronDown />+ <ChevronDownIcon /></DropdownMenuTrigger><DropdownMenuContent align="start"><DropdownMenuRadioGroup@@ -345,7 +349,7 @@ export function ProxySection({ form }: { form: UseFormReturn<NetworkFields> }) {)}onClick={() => setRevealPassword((v) => !v)}>- {revealPassword ? <EyeOff /> : <Eye />}+ {revealPassword ? <ConcealIcon /> : <RevealIcon />}</InputGroupButton></InputGroupAddon></InputGroup>diff --git a/src/renderer/routes/settings/cards/settings-card.tsx b/src/renderer/routes/settings/cards/settings-card.tsxindex 43b2d284..eb9d08a8 100644--- a/src/renderer/routes/settings/cards/settings-card.tsx+++ b/src/renderer/routes/settings/cards/settings-card.tsx@@ -30,7 +30,7 @@ export function SettingsCard({<div className="flex max-h-18 flex-1 items-center justify-center transition-[filter] group-active:grayscale-50 min-[914px]:max-h-none [&_img]:max-h-16 [&_img]:w-auto min-[914px]:[&_img]:max-h-none">{Icon}</div>- <div className="min-h-14 pt-3 min-[914px]:min-h-[90px] min-[914px]:pt-6">+ <div className="min-h-14 pt-3 pl-1 min-[914px]:min-h-22.5 min-[914px]:pt-6"><div className="text-sm font-semibold text-foreground">{t(labelKey)}</div>diff --git a/src/renderer/routes/settings/cards/settings-form-schemas.ts b/src/renderer/routes/settings/cards/settings-form-schemas.tsindex 803bc43f..12bcdd47 100644--- a/src/renderer/routes/settings/cards/settings-form-schemas.ts+++ b/src/renderer/routes/settings/cards/settings-form-schemas.ts@@ -18,6 +18,7 @@ export const generalFormSchema = appSettingsInputSchema.pick({export const appearanceFormSchema = appSettingsInputSchema.pick({theme: true,+ sidebarColor: true,reduceMotion: true,language: true,byteUnitSystem: true,diff --git a/src/renderer/routes/settings/cards/sidebar-color-picker.tsx b/src/renderer/routes/settings/cards/sidebar-color-picker.tsxnew file mode 100644index 00000000..61cb5acb--- /dev/null+++ b/src/renderer/routes/settings/cards/sidebar-color-picker.tsx@@ -0,0 +1,55 @@+import {+ type SidebarColor,+ sidebarColorSchema,+} from '@shared/schemas/sidebar-color'+import type { ComponentProps } from 'react'+import { useTranslation } from 'react-i18next'++export function SidebarColorPicker({+ value,+ onChange,+ disabled,+ ...props+}: Omit<ComponentProps<'fieldset'>, 'onChange'> & {+ value: SidebarColor+ onChange: (color: SidebarColor) => void+}) {+ const { t } = useTranslation()+ return (+ <fieldset+ {...props}+ disabled={disabled}+ data-color={value}+ aria-label={t('settings.appearance.sidebarColor')}+ className="sidebar-color-picker flex shrink-0 flex-wrap gap-1 border-0 p-0"+ >+ {sidebarColorSchema.options.map((color) => (+ <label+ key={color}+ className="group/color relative flex w-8 cursor-pointer flex-col items-center gap-1.5"+ >+ <input+ type="radio"+ name="sidebar-color"+ value={color}+ checked={value === color}+ onChange={() => onChange(color)}+ className="peer absolute inset-0 z-10 size-full cursor-inherit opacity-0"+ aria-label={t(`settings.appearance.sidebarColors.${color}`)}+ />+ <span+ aria-hidden="true"+ data-color={color}+ className="sidebar-color-swatch"+ />+ <span+ aria-hidden="true"+ className="h-4 whitespace-nowrap text-[10px] leading-4 text-muted-foreground opacity-0 group-hover/color:opacity-100 peer-focus-visible:opacity-100"+ >+ {t(`settings.appearance.sidebarColors.${color}`)}+ </span>+ </label>+ ))}+ </fieldset>+ )+}diff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 9cc07f11..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..3afa890fBinary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 1bf511cb..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..350bbcd5Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index b06ae4e5..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..b31b2480Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index cae3ae9d..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..6603fa62Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 6ba14225..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..d0d44ae0Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index bf7cfca8..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..6cae8932Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index f4900028..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..064bb175Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index e3fb077c..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..16652143Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 363a984d..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..0fc9b1c4Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 3a90d5d0..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..010538dcBinary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 8a56e97b..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..337e387aBinary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 91d314df..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..77735e24Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 7f95a93f..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..2e6ca645Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 11ca0bc9..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..dde92c93Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index d8d5743d..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..10e7c9c9Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]deleted file mode 100644index 965c2a9a..00000000Binary files a/src/renderer/routes/settings/icons/[email protected] and /dev/null differdiff --git a/src/renderer/routes/settings/icons/[email protected] b/src/renderer/routes/settings/icons/[email protected]new file mode 100644index 00000000..e346c0e4Binary files /dev/null and b/src/renderer/routes/settings/icons/[email protected] differdiff --git a/src/renderer/routes/trackers/components/tracker-source-combobox.tsx b/src/renderer/routes/trackers/components/tracker-source-combobox.tsxindex d19599eb..6d5965f7 100644--- a/src/renderer/routes/trackers/components/tracker-source-combobox.tsx+++ b/src/renderer/routes/trackers/components/tracker-source-combobox.tsx@@ -1,3 +1,4 @@+import { AddIcon, RemoveIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {Combobox,@@ -14,7 +15,6 @@ import {} from '@renderer/components/ui/combobox'import { Input } from '@renderer/components/ui/input'import type { TrackerSource } from '@shared/types/tracker'-import { Plus, Trash2 } from 'lucide-react'import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { z } from 'zod'@@ -147,7 +147,7 @@ export function TrackerSourceCombobox({}}onMouseDown={(e) => e.stopPropagation()}>- <Trash2 className="text-destructive" />+ <RemoveIcon className="text-destructive" /></Button>)}</ComboboxItem>@@ -175,7 +175,7 @@ export function TrackerSourceCombobox({onClick={handleAdd}disabled={!isValidNewUrl || isDuplicateNewUrl}>- <Plus className="size-4" />+ <AddIcon className="size-4" /></Button></div></ComboboxContent>diff --git a/src/renderer/routes/trackers/trackers-page.tsx b/src/renderer/routes/trackers/trackers-page.tsxindex ef9a70af..c6eeec8c 100644--- a/src/renderer/routes/trackers/trackers-page.tsx+++ b/src/renderer/routes/trackers/trackers-page.tsx@@ -1,6 +1,7 @@import { PanelShell } from '@renderer/components/desktop-kit/panel/panel-shell'import { Toolbar } from '@renderer/components/desktop-kit/toolbar/toolbar'import { ToolbarSearch } from '@renderer/components/desktop-kit/toolbar/toolbar-search'+import { LoadingIcon } from '@renderer/components/icons'import { Button } from '@renderer/components/ui/button'import {Tabs,@@ -10,7 +11,6 @@ import {} from '@renderer/components/ui/tabs'import { useSyncTrackers } from '@renderer/hooks/use-sync-trackers'import { cn } from '@renderer/lib/utils'-import { LoaderCircle } from 'lucide-react'import { useState } from 'react'import { useTranslation } from 'react-i18next'import { BlacklistTrackerPanel } from './components/blacklist-tracker-panel'@@ -68,7 +68,7 @@ export function TrackersPage() {className="shrink-0">{isSyncing && (- <LoaderCircle+ <LoadingIconclassName="size-3.5 animate-spin motion-reduce:animate-none"aria-hidden="true"/>diff --git a/src/renderer/styles/globals.css b/src/renderer/styles/globals.cssindex 7a346cd9..13b2dd7f 100644--- a/src/renderer/styles/globals.css+++ b/src/renderer/styles/globals.css@@ -1,3 +1,4 @@+@import "./sidebar-color.css";@import "tailwindcss";@import "tw-animate-css";@import "shadcn/tailwind.css";@@ -340,19 +341,12 @@* is required because it slides in as a dialog over content.*/-/* Variant A: fully transparent — pure vibrancy, no tint. */-/* .platform-darwin.window-main [data-slot="sidebar-wrapper"],-.platform-darwin.window-main [data-slot="sidebar-inner"] {- background-color: transparent;-} */--/* Variant B: low-alpha tint — closer to native Finder/Music feel.- Uncomment to A/B test, and comment out Variant A above.- */-.platform-darwin.window-main [data-slot="sidebar-wrapper"] {+/* Neutral fallback before the appearance color is resolved. Keep specificity+ low so the selected glass material also takes precedence in dark mode. */+:where(.platform-darwin.window-main) [data-slot="sidebar-wrapper"] {background-color: oklch(1 0 0 / 0.55);}-.dark.platform-darwin.window-main [data-slot="sidebar-wrapper"] {+:where(.dark.platform-darwin.window-main) [data-slot="sidebar-wrapper"] {background-color: oklch(0.205 0 0 / 0.55);}diff --git a/src/renderer/styles/sidebar-color.css b/src/renderer/styles/sidebar-color.cssnew file mode 100644index 00000000..59255902--- /dev/null+++ b/src/renderer/styles/sidebar-color.css@@ -0,0 +1,228 @@+/* The seven hues echo the Settings icons; gray uses a neutral glass tint. */+:root[data-sidebar-color="blue"],+.sidebar-color-picker[data-color="blue"],+.sidebar-color-swatch[data-color="blue"] {+ --sidebar-hue: 215;+}+:root[data-sidebar-color="violet"],+.sidebar-color-picker[data-color="violet"],+.sidebar-color-swatch[data-color="violet"] {+ --sidebar-hue: 264;+}+:root[data-sidebar-color="pink"],+.sidebar-color-picker[data-color="pink"],+.sidebar-color-swatch[data-color="pink"] {+ --sidebar-hue: 334;+}+:root[data-sidebar-color="orange"],+.sidebar-color-picker[data-color="orange"],+.sidebar-color-swatch[data-color="orange"] {+ --sidebar-hue: 25;+}+:root[data-sidebar-color="gold"],+.sidebar-color-picker[data-color="gold"],+.sidebar-color-swatch[data-color="gold"] {+ --sidebar-hue: 45;+}+:root[data-sidebar-color="green"],+.sidebar-color-picker[data-color="green"],+.sidebar-color-swatch[data-color="green"] {+ --sidebar-hue: 145;+}+:root[data-sidebar-color="cyan"],+.sidebar-color-picker[data-color="cyan"],+.sidebar-color-swatch[data-color="cyan"] {+ --sidebar-hue: 186;+}++/* Broad top lighting fades continuously into the lower tint. */+:root[data-sidebar-color] {+ --sidebar-glass-saturation: 52%;+ --sidebar-glass-alpha: 0.8;+ --sidebar-glass-top: 97%;+ --sidebar-glass-range: 9%;+}++:root.dark[data-sidebar-color] {+ --sidebar-glass-saturation: 24%;+ --sidebar-glass-alpha: 0.92;+ --sidebar-glass-top: 24%;+}++/* Keep native macOS glass and vibrancy visible beneath the color wash. */+:root.platform-darwin.window-main[data-sidebar-color] {+ --sidebar-glass-alpha: 0.4;+}++:root.dark.platform-darwin.window-main[data-sidebar-color] {+ --sidebar-glass-alpha: 0.5;+}++:root[data-sidebar-color="gray"],+:root.dark[data-sidebar-color="gray"] {+ --sidebar-hue: 220;+ --sidebar-glass-saturation: 3%;+}++:root[data-sidebar-color]:not([data-sidebar-color="gray"]) {+ --sidebar: hsl(var(--sidebar-hue) 58% 94%);+}++:root.dark[data-sidebar-color]:not([data-sidebar-color="gray"]) {+ --sidebar: hsl(var(--sidebar-hue) 24% 17%);+}++/* Smoothstep lightness stops avoid a visible edge around a radial highlight.+ Constant alpha preserves one continuous surface over native vibrancy. */+:root[data-sidebar-color] [data-slot="sidebar-wrapper"] {+ background-color: transparent;+ background-image: linear-gradient(+ 180deg in oklab,+ hsl(+ var(--sidebar-hue) var(--sidebar-glass-saturation)+ var(--sidebar-glass-top) /+ var(--sidebar-glass-alpha)+ )+ 0%,+ hsl(+ var(--sidebar-hue) var(--sidebar-glass-saturation)+ calc(var(--sidebar-glass-top) - var(--sidebar-glass-range) * 0.043) /+ var(--sidebar-glass-alpha)+ )+ 12.5%,+ hsl(+ var(--sidebar-hue) var(--sidebar-glass-saturation)+ calc(var(--sidebar-glass-top) - var(--sidebar-glass-range) * 0.156) /+ var(--sidebar-glass-alpha)+ )+ 25%,+ hsl(+ var(--sidebar-hue) var(--sidebar-glass-saturation)+ calc(var(--sidebar-glass-top) - var(--sidebar-glass-range) * 0.316) /+ var(--sidebar-glass-alpha)+ )+ 37.5%,+ hsl(+ var(--sidebar-hue) var(--sidebar-glass-saturation)+ calc(var(--sidebar-glass-top) - var(--sidebar-glass-range) * 0.5) /+ var(--sidebar-glass-alpha)+ )+ 50%,+ hsl(+ var(--sidebar-hue) var(--sidebar-glass-saturation)+ calc(var(--sidebar-glass-top) - var(--sidebar-glass-range) * 0.684) /+ var(--sidebar-glass-alpha)+ )+ 62.5%,+ hsl(+ var(--sidebar-hue) var(--sidebar-glass-saturation)+ calc(var(--sidebar-glass-top) - var(--sidebar-glass-range) * 0.844) /+ var(--sidebar-glass-alpha)+ )+ 75%,+ hsl(+ var(--sidebar-hue) var(--sidebar-glass-saturation)+ calc(var(--sidebar-glass-top) - var(--sidebar-glass-range) * 0.957) /+ var(--sidebar-glass-alpha)+ )+ 87.5%,+ hsl(+ var(--sidebar-hue) var(--sidebar-glass-saturation)+ calc(var(--sidebar-glass-top) - var(--sidebar-glass-range)) /+ var(--sidebar-glass-alpha)+ )+ 100%+ );+}++:root[data-sidebar-color] [data-slot="sidebar-inner"] {+ background-color: transparent;+}++.sidebar-color-picker {+ --selection-ring-color: hsl(var(--sidebar-hue) 74% 52%);+}+.sidebar-color-picker[data-color="gray"] {+ --selection-ring-color: #96999e;+}+.sidebar-color-picker[data-color="auto"] {+ --selection-ring-color: var(--system-accent-color, #007aff);+}+.sidebar-color-swatch {+ position: relative;+ display: block;+ width: 24px;+ height: 24px;+ margin: 4px;+ border-radius: 50%;+ background: hsl(var(--sidebar-hue) 76% 56%);+ box-shadow: inset 0 0 0 1px rgb(0 0 0 / 10%);+}+.sidebar-color-swatch[data-color="gray"] {+ background: #a2a4a8;+}+.sidebar-color-swatch[data-color="auto"] {+ background: conic-gradient(+ #ef446c,+ #f8ae24,+ #7acb42,+ #18b8d1,+ #5173ed,+ #ae4acb,+ #ef446c+ );+}+.sidebar-color-swatch::after {+ content: "";+ position: absolute;+ inset: -5px;+ border: 3px solid var(--selection-ring-color);+ border-radius: inherit;+ opacity: 0;+ transform: scale(0.9);+ transition:+ border-color 200ms ease-out,+ opacity 140ms ease-out,+ transform 180ms ease-out;+}+[data-reduced-motion="true"] .sidebar-color-swatch::after {+ transition: none;+}+.sidebar-color-picker input:checked + .sidebar-color-swatch::after {+ opacity: 1;+ transform: scale(1);+}+.sidebar-color-picker input:focus-visible + .sidebar-color-swatch {+ outline: 2px solid var(--foreground);+ outline-offset: 7px;+}+@media (prefers-reduced-motion: reduce) {+ .sidebar-color-swatch::after {+ transition: none;+ }+}+.sidebar-color-picker:disabled {+ opacity: 0.55;+}+.sidebar-color-picker:disabled label {+ cursor: default;+}++@media (prefers-reduced-transparency: reduce), (prefers-contrast: more) {+ :root[data-sidebar-color] [data-slot="sidebar-wrapper"] {+ background-color: var(--sidebar);+ background-image: none;+ }+}+@media (forced-colors: active) {+ .sidebar-color-picker input {+ position: static;+ opacity: 1;+ width: 24px;+ height: 24px;+ clip-path: none;+ }+ .sidebar-color-swatch {+ display: none;+ }+}diff --git a/src/server/index.ts b/src/server/index.tsindex 5984e18a..68772bf4 100644--- a/src/server/index.ts+++ b/src/server/index.ts@@ -321,6 +321,11 @@ async function main() {defaultSaveDir: configuredDefaultSaveDir,onChange: (old, updated) => {eventBus.emit(Events.SettingsChanged, { old, updated })+ if (old.app.sidebarColor !== updated.app.sidebarColor) {+ eventBus.emit(Events.SidebarColorChanged, {+ sidebarColor: updated.app.sidebarColor,+ })+ }if (old.app.liquidGlassEffect !== updated.app.liquidGlassEffect) {eventBus.emit(Events.LiquidGlassChanged, {liquidGlassEffect: updated.app.liquidGlassEffect,diff --git a/src/server/ipc/queries.ts b/src/server/ipc/queries.tsindex db704c0b..3700e841 100644--- a/src/server/ipc/queries.ts+++ b/src/server/ipc/queries.ts@@ -256,6 +256,8 @@ export function buildServerQueryHandlers(createDirectoryPreferencesHandlers(settingsManager).get,[Queries.GetSettings]: async () => settingsManager.get(),+ // A remote server cannot read the browser user's operating-system accent.+ [Queries.GetSystemAccentColor]: async () => null,[Queries.GetGeoIPStatus]: createGetGeoIPStatusHandler({ geoipManager }),diff --git a/src/shared/locales/en-US.json b/src/shared/locales/en-US.jsonindex 8a7923fc..0284fc1b 100644--- a/src/shared/locales/en-US.json+++ b/src/shared/locales/en-US.json@@ -1232,7 +1232,19 @@"byteUnitSystemDesc": "Applies to file sizes and transfer speeds.","byteUnitDecimal": "Decimal (MB, GB · 1000)","byteUnitBinary": "Binary (MiB, GiB · 1024)",- "byteUnitSystemDefault": "Follow system ({{units}})"+ "byteUnitSystemDefault": "Follow system ({{units}})",+ "sidebarColor": "Color",+ "sidebarColors": {+ "blue": "Blue",+ "violet": "Violet",+ "pink": "Pink",+ "orange": "Orange",+ "gold": "Gold",+ "green": "Green",+ "cyan": "Cyan",+ "gray": "Gray",+ "auto": "Auto"+ }},"advanced": {"rpc": {diff --git a/src/shared/locales/zh-CN.json b/src/shared/locales/zh-CN.jsonindex 6dd1bff6..2ad0b6ee 100644--- a/src/shared/locales/zh-CN.json+++ b/src/shared/locales/zh-CN.json@@ -1218,7 +1218,19 @@"byteUnitSystemDesc": "用于文件大小与传输速度的显示。","byteUnitDecimal": "十进制(MB、GB · 1000)","byteUnitBinary": "二进制(MiB、GiB · 1024)",- "byteUnitSystemDefault": "跟随系统({{units}})"+ "byteUnitSystemDefault": "跟随系统({{units}})",+ "sidebarColor": "颜色",+ "sidebarColors": {+ "blue": "冰蓝",+ "violet": "鸢紫",+ "pink": "玫粉",+ "orange": "琥橙",+ "gold": "香槟",+ "green": "薄荷",+ "cyan": "湖青",+ "gray": "淡灰",+ "auto": "自动"+ }},"about": {"appIconAlt": "Motrix 应用图标",diff --git a/src/shared/locales/zh-TW.json b/src/shared/locales/zh-TW.jsonindex 3ab57e7f..b2338e64 100644--- a/src/shared/locales/zh-TW.json+++ b/src/shared/locales/zh-TW.json@@ -1218,7 +1218,19 @@"byteUnitSystemDesc": "用於檔案大小與傳輸速度的顯示。","byteUnitDecimal": "十進位(MB、GB · 1000)","byteUnitBinary": "二進位(MiB、GiB · 1024)",- "byteUnitSystemDefault": "跟隨系統({{units}})"+ "byteUnitSystemDefault": "跟隨系統({{units}})",+ "sidebarColor": "顏色",+ "sidebarColors": {+ "blue": "冰藍",+ "violet": "鳶紫",+ "pink": "玫粉",+ "orange": "琥橙",+ "gold": "香檳",+ "green": "薄荷",+ "cyan": "湖青",+ "gray": "淡灰",+ "auto": "自動"+ }},"advanced": {"rpc": {diff --git a/src/shared/protocol/events.ts b/src/shared/protocol/events.tsindex 9685e747..8a84e1e3 100644--- a/src/shared/protocol/events.ts+++ b/src/shared/protocol/events.ts@@ -40,6 +40,10 @@ export const Events = {ReducedMotionChanged: 'event:reducedMotionChanged',// Payload: { liquidGlassEffect: boolean }.LiquidGlassChanged: 'event:liquidGlassChanged',+ // Payload: { sidebarColor: SidebarColor }.+ SidebarColorChanged: 'event:sidebarColorChanged',+ // Payload: { color: string | null }, an RGB hex color from the desktop host.+ SystemAccentColorChanged: 'event:systemAccentColorChanged',// Payload: { byteUnitSystem: ByteUnitPreference }.ByteUnitSystemChanged: 'event:byteUnitSystemChanged',LocaleChanged: 'event:localeChanged',diff --git a/src/shared/protocol/forwardable-events.test.ts b/src/shared/protocol/forwardable-events.test.tsindex 57a2ffd8..33b0bb46 100644--- a/src/shared/protocol/forwardable-events.test.ts+++ b/src/shared/protocol/forwardable-events.test.ts@@ -6,6 +6,8 @@ import { ForwardableEvents } from './forwardable-events'describe('ForwardableEvents', () => {it('forwards the motion preference without exposing the full settings event', () => {expect(ForwardableEvents).toContain(Events.ReducedMotionChanged)+ expect(ForwardableEvents).toContain(Events.SidebarColorChanged)+ expect(ForwardableEvents).toContain(Events.SystemAccentColorChanged)expect(ForwardableEvents).toContain(Events.LiquidGlassChanged)expect(ForwardableEvents).toContain(Events.ByteUnitSystemChanged)expect(ForwardableEvents).not.toContain(Events.SettingsChanged)@@ -25,7 +27,7 @@ describe('ForwardableEvents', () => {})it('has the expected number of forwardable events', () => {- expect(ForwardableEvents).toHaveLength(56)+ expect(ForwardableEvents).toHaveLength(58)})it('includes the bridge approval events (web-shell pairing)', () => {diff --git a/src/shared/protocol/forwardable-events.ts b/src/shared/protocol/forwardable-events.tsindex 369c34a7..dc1c6494 100644--- a/src/shared/protocol/forwardable-events.ts+++ b/src/shared/protocol/forwardable-events.ts@@ -43,6 +43,8 @@ export const ForwardableEvents = [Events.LocaleChanged,Events.ReducedMotionChanged,Events.LiquidGlassChanged,+ Events.SidebarColorChanged,+ Events.SystemAccentColorChanged,Events.ByteUnitSystemChanged,Events.DirectoryPreferencesChanged,Events.PluginConfigChanged,diff --git a/src/shared/protocol/queries.ts b/src/shared/protocol/queries.tsindex 51ab8abb..0aa7e78e 100644--- a/src/shared/protocol/queries.ts+++ b/src/shared/protocol/queries.ts@@ -9,6 +9,7 @@ export const Queries = {GetDirectoryPreferences: 'query:getDirectoryPreferences',ListServerDirectoryLocations: 'query:listServerDirectoryLocations',GetSettings: 'query:getSettings',+ GetSystemAccentColor: 'query:getSystemAccentColor',GetUpdateState: 'query:getUpdateState',GetSystemProxy: 'query:getSystemProxy',ListPlugins: 'query:listPlugins',diff --git a/src/shared/schemas/app-settings.ts b/src/shared/schemas/app-settings.tsindex fbf2382e..30153b44 100644--- a/src/shared/schemas/app-settings.ts+++ b/src/shared/schemas/app-settings.ts@@ -9,6 +9,7 @@ import {import { DirectoryPreferencesSchema } from './directory-preferences'import { supportedLocaleSchema } from './locale'import { settingsInputObject } from './settings-input'+import { sidebarColorSchema } from './sidebar-color'import { DEFAULT_TRAY_ICON_COLOR, trayIconColorSchema } from './tray-icon-color'export const appUpdateChannelSchema = z.enum(['stable', 'beta'])@@ -27,6 +28,7 @@ export const appSettingsSchema = z.object({launchAtStartup: z.boolean().catch(false),showMainWindowAtLogin: z.boolean().catch(false),theme: z.enum(['system', 'light', 'dark']).catch('system'),+ sidebarColor: sidebarColorSchema.catch('gray'),reduceMotion: z.boolean().catch(false),language: supportedLocaleSchema.catch(DEFAULT_LOCALE),byteUnitSystem: byteUnitSystemSchema.catch(DEFAULT_BYTE_UNIT_PREFERENCE),diff --git a/src/shared/schemas/sidebar-color.test.ts b/src/shared/schemas/sidebar-color.test.tsnew file mode 100644index 00000000..bcbe5c45--- /dev/null+++ b/src/shared/schemas/sidebar-color.test.ts@@ -0,0 +1,22 @@+import { expect, it } from 'vitest'+import { appSettingsInputSchema, appSettingsSchema } from './app-settings'+import { sidebarColorSchema } from './sidebar-color'++it('preserves existing gray and recovers invalid persisted colors while rejecting invalid edits', () => {+ expect(appSettingsSchema.parse({}).sidebarColor).toBe('gray')+ expect(+ appSettingsSchema.parse({ sidebarColor: 'unknown' }).sidebarColor+ ).toBe('gray')+ for (const sidebarColor of sidebarColorSchema.options) {+ expect(+ appSettingsInputSchema+ .pick({ sidebarColor: true })+ .parse({ sidebarColor })+ ).toEqual({ sidebarColor })+ }+ expect(+ appSettingsInputSchema+ .pick({ sidebarColor: true })+ .safeParse({ sidebarColor: 'unknown' }).success+ ).toBe(false)+})diff --git a/src/shared/schemas/sidebar-color.ts b/src/shared/schemas/sidebar-color.tsnew file mode 100644index 00000000..67078648--- /dev/null+++ b/src/shared/schemas/sidebar-color.ts@@ -0,0 +1,15 @@+import { z } from 'zod'++export const sidebarColorSchema = z.enum([+ 'auto',+ 'blue',+ 'violet',+ 'pink',+ 'orange',+ 'gold',+ 'green',+ 'cyan',+ 'gray',+])++export type SidebarColor = z.infer<typeof sidebarColorSchema>diff --git a/src/shared/types/settings.ts b/src/shared/types/settings.tsindex 6145bb9c..c1f62fd9 100644--- a/src/shared/types/settings.ts+++ b/src/shared/types/settings.ts@@ -1,5 +1,6 @@import type { FileDeletionMode } from '@shared/schemas/app-settings'import type { ByteUnitPreference } from '@shared/schemas/byte-unit-system'+import type { SidebarColor } from '@shared/schemas/sidebar-color'import type { TrayIconColor } from '@shared/schemas/tray-icon-color'import type { RunMode } from '../constants'import type { EnginePerformanceProfile } from '../constants/engine-performance-profiles'@@ -220,6 +221,7 @@ export interface MotrixAppSettings {launchAtStartup: booleanshowMainWindowAtLogin: booleantheme: 'system' | 'light' | 'dark'+ sidebarColor: SidebarColorreduceMotion: booleanbyteUnitSystem: ByteUnitPreferencelanguage: SupportedLocalediff --git a/tests/scripts/icon-import-boundary.test.ts b/tests/scripts/icon-import-boundary.test.tsnew file mode 100644index 00000000..8f8df186--- /dev/null+++ b/tests/scripts/icon-import-boundary.test.ts@@ -0,0 +1,79 @@+// @vitest-environment node+import { spawnSync } from 'node:child_process'+import { mkdirSync, mkdtempSync, rmSync, writeFileSync } from 'node:fs'+import os from 'node:os'+import path from 'node:path'+import { afterEach, describe, expect, it } from 'vitest'++const script = path.resolve(+ import.meta.dirname,+ '../../scripts/check-boundaries.mjs'+)+const directories: string[] = []++afterEach(() => {+ for (const directory of directories.splice(0)) {+ rmSync(directory, { recursive: true, force: true })+ }+})++function check(files: Record<string, string>) {+ const cwd = mkdtempSync(path.join(os.tmpdir(), 'motrix-icon-boundary-'))+ directories.push(cwd)+ for (const [name, source] of Object.entries(files)) {+ const file = path.join(cwd, name)+ mkdirSync(path.dirname(file), { recursive: true })+ writeFileSync(file, source)+ }+ return spawnSync(process.execPath, [script], { cwd, encoding: 'utf8' })+}++describe('semantic icon import boundary', () => {+ it.each([+ "import { Download } from 'lucide-react'",+ "import type { LucideIcon } from 'lucide-react'",+ "import * as icons from 'lucide-react'",+ "export { Download } from 'lucide-react'",+ "export * from 'lucide-react'",+ "import 'lucide-react'",+ "const icons = require('lucide-react')",+ "const icons = import(\n 'lucide-react'\n)",+ 'const icons = import(`lucide-react`)',+ "type Icon = import('lucide-react').LucideIcon",+ "import Download from 'lucide-react/dist/esm/icons/download.mjs'",+ ])('rejects a direct library reference: %s', (source) => {+ const result = check({ 'src/renderer/routes/example.tsx': source })+ expect(result.status).toBe(1)+ expect(result.stdout).toContain(+ '[FAIL] renderer must use semantic icons outside components/icons'+ )+ expect(result.stdout).toContain('src/renderer/routes/example.tsx:')+ })++ it('allows semantic consumers and isolated library adapters/tests', () => {+ const result = check({+ 'src/renderer/routes/example.tsx':+ "import { DownloadIcon, type MotrixIcon } from '@renderer/components/icons'",+ 'src/renderer/components/icons/download.tsx':+ "import { Download } from 'lucide-react'",+ 'src/renderer/components/icons/create-icon.test.tsx':+ "import { LucideProvider } from 'lucide-react'",+ 'src/renderer/components/icons/adapters/lucide.ts':+ "import type { LucideIcon } from 'lucide-react'",+ })+ expect(result.status).toBe(0)+ expect(result.stdout).toContain(+ '[PASS] renderer must use semantic icons outside components/icons'+ )+ })++ it.each([+ 'src/renderer/components/icons-extra/download.tsx',+ 'src/renderer/routes/example.test.tsx',+ 'src/renderer/routes/components/icons/download.tsx',+ ])('keeps the directory exception scoped: %s', (file) => {+ const result = check({ [file]: "import { Download } from 'lucide-react'" })+ expect(result.status).toBe(1)+ expect(result.stdout).toContain(file)+ })+})diff --git a/tests/scripts/icon-tree-shaking.test.ts b/tests/scripts/icon-tree-shaking.test.tsnew file mode 100644index 00000000..ed52d0f2--- /dev/null+++ b/tests/scripts/icon-tree-shaking.test.ts@@ -0,0 +1,57 @@+// @vitest-environment node+import path from 'node:path'+import { build } from 'vite'+import { describe, expect, it } from 'vitest'++const root = path.resolve(import.meta.dirname, '../..')++describe('renderer icon tree shaking', () => {+ it('bundles only the requested glyph from the semantic barrel', async () => {+ const entry = 'virtual:motrix-icon-probe'+ const result = await build({+ root,+ configFile: path.join(root, 'vite.renderer.config.ts'),+ logLevel: 'silent',+ plugins: [+ {+ name: 'icon-probe',+ resolveId(id) {+ if (id === entry) return `\0${entry}`+ },+ load(id) {+ if (id === `\0${entry}`) {+ return 'export { DownloadIcon } from "@renderer/components/icons"'+ }+ },+ },+ ],+ build: {+ write: false,+ emptyOutDir: false,+ minify: false,+ rolldownOptions: {+ input: entry,+ external: ['react', 'react/jsx-runtime', 'clsx', 'tailwind-merge'],+ preserveEntrySignatures: 'strict',+ },+ },+ })+ const outputs = Array.isArray(result) ? result : [result]+ const glyphs = outputs.flatMap((output) => {+ if (!('output' in output)) throw new Error('Expected a completed build')+ return output.output.flatMap((chunk) => {+ if (chunk.type !== 'chunk') return []+ return Object.entries(chunk.modules)+ .filter(+ ([id, module]) =>+ id+ .replaceAll('\\', '/')+ .includes('lucide-react/dist/esm/icons/') &&+ module.renderedLength > 0+ )+ .map(([id]) => path.basename(id))+ })+ })+ expect(glyphs).toEqual(['download.mjs'])+ })+})