perf(webui): scope interactive motion

Replace broad transitions with property-specific animation for progress bars, filters, cards, and dashboard controls. This prevents unrelated layout properties from animating while preserving the existing visual feedback.

Standardize standalone press feedback at a 0.96 scale, keep disabled controls static, and honor both operating-system and in-app reduced-motion preferences.
This commit is contained in:
DrSmoothl committed 2026-07-16 16:05:52 +08:00
1 parent cce9ab07eb
commit cd0466a7e3
11 files changed
+21 -17

No files matched your search

@@ -442,7 +442,7 @@ export function LogsPage() {
onClick={() => toggleLevel(lv)}
aria-pressed={active}
className={cn(
'inline-flex items-center gap-1.5 rounded-md px-2.5 py-1 text-[11px] font-medium transition-all cursor-pointer',
'inline-flex items-center gap-1.5 rounded-md px-2.5 py-1 text-[11px] font-medium transition-[background-color,color,box-shadow] duration-150 ease-out cursor-pointer',
active
? cn('bg-card shadow-sm ring-1 ring-border/60', levelClass[lv])
: 'text-muted-foreground/55 hover:text-foreground',
@@ -486,7 +486,7 @@ export function LogsPage() {
aria-pressed={active}
title={p.hint}
className={cn(
'inline-flex items-center gap-1.5 rounded-md px-2.5 py-1 text-[11px] font-medium transition-all cursor-pointer outline-none focus-visible:ring-[3px] focus-visible:ring-ring/40',
'inline-flex items-center gap-1.5 rounded-md px-2.5 py-1 text-[11px] font-medium transition-[background-color,color,box-shadow] duration-150 ease-out cursor-pointer outline-none focus-visible:ring-[3px] focus-visible:ring-ring/40',
active ? 'bg-card text-foreground shadow-sm ring-1 ring-border/60' : 'text-muted-foreground/70 hover:text-foreground',
)}
>
@@ -522,7 +522,7 @@ export function LogsPage() {
disabled={levelBusy || serverLevel === null}
aria-pressed={active}
className={cn(
'inline-flex items-center gap-1.5 rounded-md px-2.5 py-1 text-[11px] font-medium transition-all cursor-pointer disabled:cursor-not-allowed disabled:opacity-50',
'inline-flex items-center gap-1.5 rounded-md px-2.5 py-1 text-[11px] font-medium transition-[background-color,color,box-shadow,opacity] duration-150 ease-out cursor-pointer disabled:cursor-not-allowed disabled:opacity-50',
active
? cn('bg-card shadow-sm ring-1 ring-border/60', levelClass[lv])
: 'text-muted-foreground/70 hover:text-foreground',