feat(web): gate routines nav behind feature flag

This commit is contained in:
saravanakumardb1 2026-02-28 19:14:01 -08:00
parent 672acadba6
commit e5d18b1c9c

View File

@ -13,6 +13,7 @@ import { requestNotificationPermission } from '@/lib/notifications';
import { formatTime, formatDate } from '@/lib/format'; import { formatTime, formatDate } from '@/lib/format';
import { Plus, Clock, Bell, Keyboard, Sun, Moon, Settings, Eye, BarChart3, ListChecks, Cloud, CloudOff, Loader2 } from 'lucide-react'; import { Plus, Clock, Bell, Keyboard, Sun, Moon, Settings, Eye, BarChart3, ListChecks, Cloud, CloudOff, Loader2 } from 'lucide-react';
import { useSync } from '@/lib/use-sync'; import { useSync } from '@/lib/use-sync';
import { isEnabled as isFlagEnabled } from '@/lib/feature-flags';
import { BUILT_IN_CATEGORIES, matchesCategory } from '@/lib/categories'; import { BUILT_IN_CATEGORIES, matchesCategory } from '@/lib/categories';
import Link from 'next/link'; import Link from 'next/link';
import { FeedbackButton } from './FeedbackButton'; import { FeedbackButton } from './FeedbackButton';
@ -171,14 +172,16 @@ export function Dashboard() {
> >
<Eye size={18} /> <Eye size={18} />
</Link> </Link>
<Link {isFlagEnabled('routines_disabled') ? null : (
href="/routines" <Link
className="p-2 rounded-lg transition-colors" href="/routines"
style={{ color: 'var(--cm-text-tertiary)' }} className="p-2 rounded-lg transition-colors"
title="Routines" style={{ color: 'var(--cm-text-tertiary)' }}
> title="Routines"
<ListChecks size={18} /> >
</Link> <ListChecks size={18} />
</Link>
)}
<Link <Link
href="/history" href="/history"
className="p-2 rounded-lg transition-colors" className="p-2 rounded-lg transition-colors"