Skip to content
This repository has been archived by the owner on Oct 10, 2024. It is now read-only.

Commit

Permalink
Fixed Themes Button Dropdown...
Browse files Browse the repository at this point in the history
  • Loading branch information
anshnk committed Mar 26, 2024
1 parent 65a144c commit 559ae0d
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/components/mode-toggle.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,22 +23,24 @@ export function ModeToggle({ text }: { text?: string }) {
return (

<DropdownMenu>
<DropdownMenuTrigger asChild>
<TooltipProvider>
<TooltipProvider>
<Tooltip>
<TooltipTrigger asChild>
<TooltipTrigger>
<DropdownMenuTrigger asChild>

<Button variant="outline" size={text ? "default" : "icon"}>
{text}
<SwatchBook
className={`${text && "ml-2"} h-[1.2rem] w-[1.2rem] transition-all`}
/>
<span className="sr-only">Toggle theme</span>
</Button>
</TooltipTrigger>

</DropdownMenuTrigger>
</TooltipTrigger>
<TooltipContent>Themes</TooltipContent>
</Tooltip>
</TooltipProvider>
</DropdownMenuTrigger>

<DropdownMenuContent align="end">
<DropdownMenuLabel>Themes</DropdownMenuLabel>
Expand Down

0 comments on commit 559ae0d

Please sign in to comment.