Skip to content

Commit dd5849d

Browse files
tnyleataylorotwell
andauthored
Adding tooltip to sidebar icons (#83)
* Adding tooltip to sidebar icons * Update nav-main.tsx --------- Co-authored-by: Taylor Otwell <[email protected]>
1 parent 732568d commit dd5849d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

resources/js/components/nav-main.tsx

+4-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,10 @@ export function NavMain({ items = [] }: { items: NavItem[] }) {
1010
<SidebarMenu>
1111
{items.map((item) => (
1212
<SidebarMenuItem key={item.title}>
13-
<SidebarMenuButton asChild isActive={item.href === page.url}>
13+
<SidebarMenuButton
14+
asChild isActive={item.href === page.url}
15+
tooltip={{ children: item.title }}
16+
>
1417
<Link href={item.href} prefetch>
1518
{item.icon && <item.icon />}
1619
<span>{item.title}</span>

0 commit comments

Comments
 (0)