i18n(sidebar): localise company delete confirmation + Yes/No buttons (P3-48)

Delete-company confirmation text now uses sidebar.deleteCompanyConfirm key
with {name} placeholder; Yes/No buttons route through common.yes/no.
This commit is contained in:
ZacharyZhang-NY committed 2026-04-16 23:09:15 -04:00
1 parent 3a1f79324d
commit d8c2e10005
3 files changed
+5 -3

No files matched your search

+3 -3
View File
@@ -86,20 +86,20 @@ export function SidebarView({
<div key={company.id} className="group flex items-center">
{confirmDeleteCompanyId === company.id ? (
<div className="flex w-full items-center gap-2 px-3 py-2">
<span className="flex-1 truncate text-[12px] text-destructive">Delete {company.name}?</span>
<span className="flex-1 truncate text-[12px] text-destructive">{t("sidebar.deleteCompanyConfirm", `Delete ${company.name}?`).replace("{name}", company.name)}</span>
<button
type="button"
className="rounded px-2 py-0.5 text-[11px] font-semibold text-destructive transition hover:bg-destructive hover:text-primary-foreground"
onClick={() => void deleteCompany(company.id)}
>
Yes
{t("common.yes")}
</button>
<button
type="button"
className="rounded px-2 py-0.5 text-[11px] font-semibold text-muted-foreground transition hover:bg-muted"
onClick={() => setConfirmDeleteCompanyId(null)}
>
No
{t("common.no")}
</button>
</div>
) : (