All files / src/components/nav/NavTitle NavTitle.tsx

50% Statements 1/2
0% Branches 0/4
0% Functions 0/1
50% Lines 1/2

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17                4x                
import { LucideIcon } from "lucide-react";
 
interface NavTitleProps {
  icon: LucideIcon;
  label: string;
  sub?: boolean;
}
 
const NavTitle = ({ icon: Icon, label, sub }: NavTitleProps) => (
  <div className="flex gap-2 items-center w-full">
    <Icon className={sub ? "size-3 shrink-0" : "size-4 shrink-0"} />
    <div className={`truncate ${sub ? "text-sm" : "text-lg"}`}>{label}</div>
  </div>
);
 
export default NavTitle;