refactor: consolidate English translations (#6640)

This commit is contained in:
Thomas authored and GitHub committed 2026-08-21 19:00:27 +02:00
1 parent 81aa704537
commit 9e14a07e64
449 files changed
+3515 -3922

No files matched your search

@@ -5,7 +5,7 @@ import { clientApi } from "@homarr/api/client";
import { AppForm } from "@homarr/forms-collection";
import { createModal, modalSizeForm } from "@homarr/modals";
import { showErrorNotification, showSuccessNotification } from "@homarr/notifications";
import { useI18n, useScopedI18n } from "@homarr/translation/client";
import { useI18n } from "@homarr/translation/client";
import type { appManageSchema } from "@homarr/validation/app";
interface QuickAddAppModalProps {
@@ -13,13 +13,14 @@ interface QuickAddAppModalProps {
}
export const QuickAddAppModal = createModal<QuickAddAppModalProps>(({ actions, innerProps }) => {
const tScoped = useScopedI18n("app.page.create.notification");
const t = useI18n();
const tScoped = useI18n("app.page.create.notification");
const tCommon = useI18n("common");
const tBoard = useI18n("board");
const { mutate, isPending } = clientApi.app.create.useMutation({
onError: () => {
showErrorNotification({
title: tScoped("error.title"),
title: tCommon("notification.create.error"),
message: tScoped("error.message"),
});
},
@@ -29,7 +30,7 @@ export const QuickAddAppModal = createModal<QuickAddAppModalProps>(({ actions, i
mutate(values, {
onSuccess(app) {
showSuccessNotification({
title: tScoped("success.title"),
title: tCommon("notification.create.success"),
message: tScoped("success.message"),
});
@@ -42,7 +43,7 @@ export const QuickAddAppModal = createModal<QuickAddAppModalProps>(({ actions, i
return (
<AppForm
buttonLabels={{
submit: t("board.action.quickCreateApp.modal.createAndUse"),
submit: tBoard("action.quickCreateApp.modal.createAndUse"),
submitAndCreateAnother: undefined,
}}
showBackToOverview={false}