feat(web): wire feature flag checks into Dashboard UI

Gate Focus Mode and Routines nav links behind focus_mode_enabled
and routines_enabled flags. Fix inverted routines_disabled check
to use the actual seeded flag key routines_enabled.
This commit is contained in:
saravanakumardb1 2026-03-21 20:30:49 -07:00
parent 09310b7eb8
commit a606617c1d

View File

@ -163,16 +163,18 @@ export function Dashboard() {
>
{theme === 'dark' ? <Sun size={18} /> : <Moon size={18} />}
</button>
<Link
href="/focus"
className="p-2 rounded-lg transition-colors"
style={{ color: 'var(--cm-text-tertiary)' }}
title="Focus Mode"
aria-label="Focus Mode"
>
<Eye size={18} />
</Link>
{isFlagEnabled('routines_disabled') ? null : (
{isFlagEnabled('focus_mode_enabled') ? (
<Link
href="/focus"
className="p-2 rounded-lg transition-colors"
style={{ color: 'var(--cm-text-tertiary)' }}
title="Focus Mode"
aria-label="Focus Mode"
>
<Eye size={18} />
</Link>
) : null}
{isFlagEnabled('routines_enabled') ? (
<Link
href="/routines"
className="p-2 rounded-lg transition-colors"
@ -181,7 +183,7 @@ export function Dashboard() {
>
<ListChecks size={18} />
</Link>
)}
) : null}
<Link
href="/history"
className="p-2 rounded-lg transition-colors"