diff --git a/web/public/locales/en/views/faceLibrary.json b/web/public/locales/en/views/faceLibrary.json index ee3dc2c29..da6c44ff3 100644 --- a/web/public/locales/en/views/faceLibrary.json +++ b/web/public/locales/en/views/faceLibrary.json @@ -21,6 +21,11 @@ "new": "Create New Face", "nextSteps": "To build a strong foundation:
  • Use the Train tab to select and train on images for each detected person.
  • Focus on straight-on images for best results; avoid training images that capture faces at an angle.
  • " }, + "steps": { + "faceName": "Enter Face Name", + "uploadFace": "Upload Face Image", + "nextSteps": "Next Steps" + }, "train": { "title": "Train", "aria": "Select train" diff --git a/web/src/components/indicators/StepIndicator.tsx b/web/src/components/indicators/StepIndicator.tsx index 641ae32ca..cf183f90b 100644 --- a/web/src/components/indicators/StepIndicator.tsx +++ b/web/src/components/indicators/StepIndicator.tsx @@ -1,13 +1,18 @@ import { cn } from "@/lib/utils"; +import { useTranslation } from "react-i18next"; type StepIndicatorProps = { steps: string[]; currentStep: number; + translationNameSpace: string; }; export default function StepIndicator({ steps, currentStep, + translationNameSpace, }: StepIndicatorProps) { + const { t } = useTranslation(translationNameSpace); + return (
    {steps.map((name, idx) => ( @@ -20,7 +25,7 @@ export default function StepIndicator({ > {idx + 1}
    -
    {name}
    +
    {t(name)}
    ))} diff --git a/web/src/components/overlay/detail/FaceCreateWizardDialog.tsx b/web/src/components/overlay/detail/FaceCreateWizardDialog.tsx index 00e4b5c5f..b2ac8d591 100644 --- a/web/src/components/overlay/detail/FaceCreateWizardDialog.tsx +++ b/web/src/components/overlay/detail/FaceCreateWizardDialog.tsx @@ -25,7 +25,7 @@ import { LuExternalLink } from "react-icons/lu"; import { Link } from "react-router-dom"; import { toast } from "sonner"; -const STEPS = ["Enter Face Name", "Upload Face Image", "Next Steps"]; +const STEPS = ["steps.faceName", "steps.uploadFace", "steps.nextSteps"]; type CreateFaceWizardDialogProps = { open: boolean; @@ -107,7 +107,11 @@ export default function CreateFaceWizardDialog({ {t("button.addFace")} {isDesktop && {t("description.addFace")}} - + {step == 0 && (