Resolve Issue #990

Resolve Add Accessible Name to Theme Switcher Button #990
This commit is contained in:
ray-android 2024-07-31 01:14:00 +08:00 committed by GitHub
parent 6b5287e066
commit f04fc9d38b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -57,7 +57,7 @@ const ThemeSwitch = () => {
<div className="mr-5 flex items-center">
<Menu as="div" className="relative inline-block text-left">
<div className="flex items-center justify-center hover:text-primary-500 dark:hover:text-primary-400">
<Menu.Button>
<Menu.Button aria-label="Theme switcher">
{mounted ? resolvedTheme === 'dark' ? <Moon /> : <Sun /> : <Blank />}
</Menu.Button>
</div>