diff --git a/src/components/customerCaseEmployeeCard/CustomerCaseEmployeeCard.tsx b/src/components/customerCaseEmployeeCard/CustomerCaseEmployeeCard.tsx index bab24148b..7ea34672d 100644 --- a/src/components/customerCaseEmployeeCard/CustomerCaseEmployeeCard.tsx +++ b/src/components/customerCaseEmployeeCard/CustomerCaseEmployeeCard.tsx @@ -1,4 +1,5 @@ import Image from "next/image"; +import { useTranslations } from "next-intl"; import Text from "src/components/text/Text"; import formatPhoneNumber from "src/components/utils/formatPhoneNumber"; @@ -15,6 +16,8 @@ export interface CustomerCaseEmployeeCardProps { export default function CustomerCaseEmployeeCard({ employee, }: CustomerCaseEmployeeCardProps) { + const t = useTranslations("employee_card"); + return ( employee.imageThumbUrl && employee.name && @@ -38,7 +41,7 @@ export default function CustomerCaseEmployeeCard({ type="labelRegular" key={competence} > - {competence} + {t(competence)} ))} diff --git a/src/components/employeeCard/EmployeeCard.tsx b/src/components/employeeCard/EmployeeCard.tsx index b9999e7aa..f380657a9 100644 --- a/src/components/employeeCard/EmployeeCard.tsx +++ b/src/components/employeeCard/EmployeeCard.tsx @@ -1,5 +1,6 @@ import Image from "next/image"; import Link from "next/link"; +import { useTranslations } from "next-intl"; import Text from "src/components/text/Text"; import formatPhoneNumber from "src/components/utils/formatPhoneNumber"; @@ -19,6 +20,7 @@ export default function EmployeeCard({ employeePageSlug, language, }: EmployeeCardProps) { + const t = useTranslations("employee_card"); return ( employee.imageUrl && employee.name && @@ -56,7 +58,7 @@ export default function EmployeeCard({ key={competence} as="span" > - {competence} + {t(competence)} ))} diff --git a/src/components/employeePage/EmployeePage.tsx b/src/components/employeePage/EmployeePage.tsx index 6e94cdde4..b85793e4a 100644 --- a/src/components/employeePage/EmployeePage.tsx +++ b/src/components/employeePage/EmployeePage.tsx @@ -1,4 +1,5 @@ import Image from "next/image"; +import { useTranslations } from "next-intl"; import Text from "src/components/text/Text"; import formatPhoneNumber from "src/components/utils/formatPhoneNumber"; @@ -12,6 +13,7 @@ export interface EmployeePageProps { export default function EmployeePage({ employee }: EmployeePageProps) { const image = employee.imageUrl ?? employee.imageThumbUrl ?? null; + const t = useTranslations("employee_card"); return ( employee.name && ( @@ -47,7 +49,7 @@ export default function EmployeePage({ employee }: EmployeePageProps) { )} {employee.competences.map((competence) => ( - {competence} + {t(competence)} ))}