fix: replace various anchor tags with buttons to prevent text selection on repeated clicks

This commit is contained in:
git-bruh 2023-04-07 19:25:30 +05:30
parent 6ce1b9d850
commit fc91ed49bc
4 changed files with 8 additions and 8 deletions

View file

@ -10,12 +10,12 @@ export default function DarkMode() {
const mode = theme === 'dark' ? 'Light mode' : 'Dark mode';
return (
<a
<button
className="flex cursor-pointer items-center gap-3 rounded-md py-3 px-3 text-sm text-white transition-colors duration-200 hover:bg-gray-500/10"
onClick={clickHandler}
>
{theme === 'dark' ? <LightModeIcon /> : <DarkModeIcon />}
{mode}
</a>
</button>
);
}