Adjust button and add profile translations

This commit is contained in:
Owen 2025-06-11 10:00:38 -04:00
parent 31a41576d8
commit 8aa95db9bc
No known key found for this signature in database
GPG key ID: 8271FDFFD9E0CCBD
12 changed files with 61 additions and 21 deletions

View file

@ -41,13 +41,15 @@ export default function LocaleSwitcherSelect({
<Button
variant="ghost"
className={clsx(
'rounded-sm p-2 transition-colors flex items-center gap-2',
'w-full rounded-sm h-8 gap-2 justify-start font-normal',
isPending && 'pointer-events-none'
)}
aria-label={label}
>
<Languages className="h-4 w-4" />
<span >{selected?.label ?? label}</span>
<span className="text-left flex-1">
{selected?.label ?? label}
</span>
</Button>
</DropdownMenuTrigger>
<DropdownMenuContent align="end" className="min-w-[8rem]">

View file

@ -133,7 +133,7 @@ export default function ProfileIcon() {
<DropdownMenuSeparator />
</>
)}
<DropdownMenuLabel>Theme</DropdownMenuLabel>
<DropdownMenuLabel>{t("theme")}</DropdownMenuLabel>
{(["light", "dark", "system"] as const).map(
(themeOption) => (
<DropdownMenuItem
@ -152,7 +152,7 @@ export default function ProfileIcon() {
<Laptop className="mr-2 h-4 w-4" />
)}
<span className="capitalize">
{themeOption}
{t(themeOption)}
</span>
{userTheme === themeOption && (
<span className="absolute right-2 flex h-3.5 w-3.5 items-center justify-center">
@ -163,9 +163,7 @@ export default function ProfileIcon() {
)
)}
<DropdownMenuSeparator />
<div>
<LocaleSwitcher />
</div>
<DropdownMenuSeparator />
<DropdownMenuItem onClick={() => logout()}>
{/* <LogOut className="mr-2 h-4 w-4" /> */}