Files
eranos/src/lib/utils.ts
T
Chad Curtis 780271f3c1 Fix sticky headers to use top-mobile-bar pattern
- Change STICKY_HEADER_CLASS to use 'top-mobile-bar sidebar:top-0'
- Matches the pattern used in Feed and NotificationsPage
- On mobile: sticky tabs position below the MobileTopBar (accounting for safe area)
- On desktop: sticky tabs position at top-0 (no top bar on desktop)
- Fixes issue where safe-area-top created unwanted space above tabs
2026-02-19 08:03:08 -06:00

14 lines
429 B
TypeScript

import { clsx, type ClassValue } from "clsx"
import { twMerge } from "tailwind-merge"
export function cn(...inputs: ClassValue[]) {
return twMerge(clsx(inputs))
}
/**
* Sticky header class for pages inside MainLayout.
* On mobile, sticks below the top bar (accounting for safe area).
* On desktop (sidebar+), sticks to the top of the viewport.
*/
export const STICKY_HEADER_CLASS = 'sticky top-mobile-bar sidebar:top-0';