fix: complete Chinese frontend localization
This commit is contained in:
@@ -14,6 +14,7 @@ export function DeleteBoardConfirmation({
|
||||
}) {
|
||||
const router = useRouter();
|
||||
const { closeModal } = useModal();
|
||||
const boardTypeLabel = isTemplate ? t`template` : t`board`;
|
||||
|
||||
const deleteBoard = api.board.delete.useMutation({
|
||||
onSuccess: () => {
|
||||
@@ -33,7 +34,7 @@ export function DeleteBoardConfirmation({
|
||||
<div className="p-5">
|
||||
<div className="flex w-full flex-col justify-between pb-4">
|
||||
<h2 className="text-md pb-4 font-medium text-neutral-900 dark:text-dark-1000">
|
||||
{t`Are you sure you want to delete this ${isTemplate ? "template" : "board"}?`}
|
||||
{t`Are you sure you want to delete this ${boardTypeLabel}?`}
|
||||
</h2>
|
||||
<p className="text-sm font-medium text-light-900 dark:text-dark-900">
|
||||
{t`This action can't be undone.`}
|
||||
|
||||
@@ -31,7 +31,7 @@ export function MoveBoardForm({
|
||||
closeModal();
|
||||
showPopup({
|
||||
header: t`Board moved`,
|
||||
message: t`The board has been moved to ${targetWorkspace?.name ?? "the workspace"}.`,
|
||||
message: t`The board has been moved to ${targetWorkspace?.name ?? t`the workspace`}.`,
|
||||
icon: "success",
|
||||
});
|
||||
if (targetWorkspace) {
|
||||
|
||||
@@ -42,12 +42,13 @@ const VisibilityButton = ({
|
||||
}, [visibility]);
|
||||
|
||||
const isPublic = stateVisibility === "public";
|
||||
const visibilityLabel = isPublic ? t`public` : t`private`;
|
||||
|
||||
const updateBoardVisibility = api.board.update.useMutation({
|
||||
onSuccess: () => {
|
||||
showPopup({
|
||||
header: t`Board visibility updated`,
|
||||
message: t`The visibility of your board has been set to ${isPublic ? "public" : "private"}.`,
|
||||
message: t`The visibility of your board has been set to ${visibilityLabel}.`,
|
||||
icon: "success",
|
||||
});
|
||||
},
|
||||
|
||||
@@ -540,7 +540,7 @@ export default function BoardPage({ isTemplate }: { isTemplate?: boolean }) {
|
||||
return (
|
||||
<>
|
||||
<PageHead
|
||||
title={`${boardData?.name ?? (isTemplate ? t`Board` : t`Template`)} | ${workspace.name ?? t`Workspace`}`}
|
||||
title={`${boardData?.name ?? (isTemplate ? t`Template` : t`Board`)} | ${workspace.name ?? t`Workspace`}`}
|
||||
/>
|
||||
<div className="relative flex h-full flex-col">
|
||||
<PatternedBackground />
|
||||
@@ -567,7 +567,7 @@ export default function BoardPage({ isTemplate }: { isTemplate?: boolean }) {
|
||||
)}
|
||||
{!boardData && !isLoading && (
|
||||
<p className="order-2 block p-0 py-0 font-bold leading-[2.3rem] tracking-tight text-neutral-900 dark:text-dark-1000 sm:text-[1.2rem] md:order-1">
|
||||
{t`${isTemplate ? "Template" : "Board"} not found`}
|
||||
{isTemplate ? t`Template not found` : t`Board not found`}
|
||||
</p>
|
||||
)}
|
||||
<div className="order-1 mb-4 flex items-center justify-end space-x-2 md:order-2 md:mb-0">
|
||||
|
||||
Reference in New Issue
Block a user