diff --git a/app/src/components/Header.tsx b/app/src/components/Header.tsx index fc02c5c7..94148e3c 100644 --- a/app/src/components/Header.tsx +++ b/app/src/components/Header.tsx @@ -9,6 +9,18 @@ import { getNavigation } from '../../../config/navigation'; const FEEDBACK_HREF = buildMailto({ subject: 'ProtSpace feedback' }); +// Ghost-style Feedback CTA: transparent, on-brand blue text/icon with a faint blue +// hover — de-emphasized vs. the app-shell primary (#3c83f6). The hue is variant-aware +// so the label clears WCAG AA on both header backgrounds: the canonical ProtSpace blue +// (#00a3e0, ~5.6:1) on the dark header, and a darker shade (#006d96, ~5.3:1) on the +// light Explore header, where #00a3e0 would only reach ~2.6:1. +// Both literals are spelled out so Tailwind's source scan can generate the arbitrary +// color utilities (it cannot see classes built from interpolated strings). +const FEEDBACK_BUTTON_CLASS_DEFAULT = + 'text-[#00a3e0] hover:bg-[#00a3e0]/10 hover:text-[#00a3e0] focus-visible:ring-[#00a3e0]'; +const FEEDBACK_BUTTON_CLASS_LIGHT = + 'text-[#006d96] hover:bg-[#006d96]/10 hover:text-[#006d96] focus-visible:ring-[#006d96]'; + const mode = import.meta.env.MODE === 'production' ? 'production' : 'development'; const navItems = getNavigation(mode); @@ -31,6 +43,8 @@ const Header = ({ variant = 'default', className }: HeaderProps) => { const textClass = variant === 'light' ? 'text-slate-900' : 'text-foreground'; const hoverTextClass = variant === 'light' ? 'hover:text-slate-700' : 'hover:text-primary'; const mutedTextClass = variant === 'light' ? 'text-slate-700' : 'text-foreground/80'; + const feedbackButtonClass = + variant === 'light' ? FEEDBACK_BUTTON_CLASS_LIGHT : FEEDBACK_BUTTON_CLASS_DEFAULT; const headerClasses = cn( 'fixed top-0 left-0 right-0 z-50 border-b backdrop-blur-lg', @@ -127,7 +141,7 @@ const Header = ({ variant = 'default', className }: HeaderProps) => { })} {/* Feedback CTA */} -