From dc7be2d33435948dd41fb0352d4c7fee4b2766b3 Mon Sep 17 00:00:00 2001 From: MartinBraquet Date: Fri, 2 Jan 2026 15:10:58 +0200 Subject: [PATCH] Translate comment input --- web/components/comments/comment-input.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/web/components/comments/comment-input.tsx b/web/components/comments/comment-input.tsx index 52f1ef7..27953c7 100644 --- a/web/components/comments/comment-input.tsx +++ b/web/components/comments/comment-input.tsx @@ -17,6 +17,7 @@ import { Tooltip } from 'web/components/widgets/tooltip' import { track } from 'web/lib/service/analytics' import { firebaseLogin } from 'web/lib/firebase/users' import { useEvent } from 'web/hooks/use-event' +import {useT} from "web/lib/locale"; export function CommentInput(props: { replyToUserInfo?: ReplyToUserInfo @@ -144,6 +145,8 @@ export function CommentInputTextArea(props: { commentTypes = ['comment'], cancelEditing, } = props + const t = useT() + useEffect(() => { editor?.setEditable(!isSubmitting) }, [isSubmitting, editor]) @@ -216,7 +219,7 @@ export function CommentInputTextArea(props: { className="text-primary-600 hover:underline" onClick={cancelEditing} > - Cancel + {t("comment.cancel", "Cancel")} )}