fix: replace all hardcoded accent rgba with color-mix(in srgb, var(--accent) X%, transparent)
All elements that were hardcoded to lime green rgba(168,230,0,...) now use color-mix() so they automatically follow accent color changes: - FolderTreeItem: active item background + specular box-shadows - MessageListItem: selected + checked row backgrounds and highlights - MessageList: icon-btn.active, bulk-actions background + border - AppShell: resize handle hover - AccountSwitcher: avatar active glow - base.css: input focus border + shadow ring Also added --bg-selected to applyAccentColor() in settings.store Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
99b6ef52a0
commit
ccdec7f9c1
7 changed files with 17 additions and 15 deletions
|
|
@ -69,8 +69,8 @@ textarea {
|
|||
input:focus,
|
||||
select:focus,
|
||||
textarea:focus {
|
||||
border-color: rgba(168, 230, 0, 0.5);
|
||||
box-shadow: 0 0 0 3px rgba(168, 230, 0, 0.10);
|
||||
border-color: color-mix(in srgb, var(--accent) 50%, transparent);
|
||||
box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 10%, transparent);
|
||||
}
|
||||
|
||||
/* ── Scrollbar ─────────────────────────────────────────── */
|
||||
|
|
|
|||
|
|
@ -179,7 +179,7 @@ function stopResize(): void {
|
|||
|
||||
.resize-handle:hover,
|
||||
.resize-handle:active {
|
||||
background: rgba(168, 230, 0, 0.4);
|
||||
background: color-mix(in srgb, var(--accent) 40%, transparent);
|
||||
}
|
||||
|
||||
.statusbar {
|
||||
|
|
|
|||
|
|
@ -240,7 +240,7 @@ async function handleSwipeAction(action: SwipeAction, messageId: string): Promis
|
|||
|
||||
.icon-btn.active {
|
||||
color: var(--accent);
|
||||
background: rgba(168, 230, 0, 0.12);
|
||||
background: color-mix(in srgb, var(--accent) 12%, transparent);
|
||||
}
|
||||
|
||||
.icon-btn:disabled {
|
||||
|
|
@ -275,8 +275,8 @@ async function handleSwipeAction(action: SwipeAction, messageId: string): Promis
|
|||
align-items: center;
|
||||
gap: 6px;
|
||||
padding: 6px 10px;
|
||||
background: rgba(168, 230, 0, 0.05);
|
||||
border-bottom: 1px solid rgba(168, 230, 0, 0.12);
|
||||
background: color-mix(in srgb, var(--accent) 5%, transparent);
|
||||
border-bottom: 1px solid color-mix(in srgb, var(--accent) 12%, transparent);
|
||||
flex-shrink: 0;
|
||||
backdrop-filter: var(--blur-sm);
|
||||
-webkit-backdrop-filter: var(--blur-sm);
|
||||
|
|
|
|||
|
|
@ -335,17 +335,18 @@ onUnmounted(() => {
|
|||
}
|
||||
.message-item:hover { background: var(--glass-bg-hover); }
|
||||
.message-item.selected {
|
||||
background: rgba(168, 230, 0, 0.08);
|
||||
background: color-mix(in srgb, var(--accent) 8%, transparent);
|
||||
border-left: 2px solid var(--accent);
|
||||
padding-left: 2px;
|
||||
box-shadow: inset 0 1px 0 rgba(168, 230, 0, 0.10),
|
||||
inset 0 -1px 0 rgba(168, 230, 0, 0.05);
|
||||
box-shadow:
|
||||
inset 0 1px 0 color-mix(in srgb, var(--accent) 10%, transparent),
|
||||
inset 0 -1px 0 color-mix(in srgb, var(--accent) 5%, transparent);
|
||||
}
|
||||
.message-item.checked {
|
||||
background: rgba(168, 230, 0, 0.06);
|
||||
background: color-mix(in srgb, var(--accent) 6%, transparent);
|
||||
}
|
||||
.message-item.checked:hover {
|
||||
background: rgba(168, 230, 0, 0.10);
|
||||
background: color-mix(in srgb, var(--accent) 10%, transparent);
|
||||
}
|
||||
|
||||
/* Left column: holds either circle-check or unread-dot */
|
||||
|
|
|
|||
|
|
@ -96,7 +96,7 @@ function getAccountColor(index: number): string {
|
|||
box-shadow:
|
||||
0 0 0 2px rgba(9, 9, 14, 0.8),
|
||||
0 0 0 3.5px var(--accent),
|
||||
0 4px 12px rgba(168, 230, 0, 0.3);
|
||||
0 4px 12px color-mix(in srgb, var(--accent) 30%, transparent);
|
||||
}
|
||||
|
||||
.account-btn:not(.active):hover .account-avatar {
|
||||
|
|
|
|||
|
|
@ -91,10 +91,10 @@ function toggleExpand(event: Event): void {
|
|||
}
|
||||
|
||||
.folder-item.active {
|
||||
background: rgba(168, 230, 0, 0.10);
|
||||
background: color-mix(in srgb, var(--accent) 10%, transparent);
|
||||
box-shadow:
|
||||
inset 0 1px 0 rgba(168, 230, 0, 0.15),
|
||||
inset 0 -1px 0 rgba(168, 230, 0, 0.05);
|
||||
inset 0 1px 0 color-mix(in srgb, var(--accent) 15%, transparent),
|
||||
inset 0 -1px 0 color-mix(in srgb, var(--accent) 5%, transparent);
|
||||
}
|
||||
|
||||
.folder-item.active::before {
|
||||
|
|
|
|||
|
|
@ -56,6 +56,7 @@ function applyAccentColor(hex: string): void {
|
|||
root.style.setProperty('--accent-muted', `rgba(${r},${g},${b},0.12)`)
|
||||
root.style.setProperty('--accent-text', lum > 0.35 ? '#0d0d0d' : '#ffffff')
|
||||
root.style.setProperty('--accent-glow', `rgba(${r},${g},${b},0.08)`)
|
||||
root.style.setProperty('--bg-selected', `rgba(${r},${g},${b},0.10)`)
|
||||
}
|
||||
|
||||
// ─── Storage ─────────────────────────────────────────────
|
||||
|
|
|
|||
Loading…
Reference in a new issue