mirror of
https://github.com/Luchexx/wacrm.git
synced 2026-11-02 09:19:51 +00:00
refactor: update translation key type assertions from any to string in header and sidebar components
This commit is contained in:
parent
07b20f42d4
commit
738b0dde1f
@ -69,7 +69,7 @@ export function Header({ onOpenSidebar }: HeaderProps) {
|
||||
<Menu className="h-5 w-5" />
|
||||
</button>
|
||||
<h1 className="truncate text-base font-semibold text-foreground sm:text-lg">
|
||||
{t(titleKey as any)}
|
||||
{t(titleKey as string)}
|
||||
</h1>
|
||||
</div>
|
||||
|
||||
|
||||
@ -236,7 +236,7 @@ export function Sidebar({ open = false, onClose }: SidebarProps) {
|
||||
)}
|
||||
>
|
||||
<item.icon className="h-4 w-4" />
|
||||
<span className="flex-1">{t(item.labelKey as any)}</span>
|
||||
<span className="flex-1">{t(item.labelKey as string)}</span>
|
||||
{item.beta && (
|
||||
<span
|
||||
aria-label={t("beta")}
|
||||
@ -285,7 +285,7 @@ export function Sidebar({ open = false, onClose }: SidebarProps) {
|
||||
)}
|
||||
>
|
||||
<item.icon className="h-4 w-4" />
|
||||
{t(item.labelKey as any)}
|
||||
{t(item.labelKey as string)}
|
||||
</Link>
|
||||
</li>
|
||||
);
|
||||
@ -323,7 +323,7 @@ export function Sidebar({ open = false, onClose }: SidebarProps) {
|
||||
className={`ml-auto inline-flex shrink-0 items-center gap-1 rounded-full border px-1.5 py-0.5 text-[10px] font-medium uppercase tracking-wider ${meta.className}`}
|
||||
>
|
||||
<Icon className="size-3" />
|
||||
{t(meta.labelKey as any)}
|
||||
{t(meta.labelKey as string)}
|
||||
</span>
|
||||
);
|
||||
})()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user