diff --git a/messages/en.json b/messages/en.json index 8ce9cc52f..35d30a9d6 100644 --- a/messages/en.json +++ b/messages/en.json @@ -36,7 +36,7 @@ "visit_cv": "Visit mini-CV", "read_more": "Read more" }, - "compensation_calculator": { + "compensation": { "calculator": { "formLabel": "Salary calculator", "educationInput": "Education", @@ -47,6 +47,12 @@ "degreeOptions": { "bachelor": "Bachelor", "master": "Master" + }, + "bonus": { + "location": "Location", + "bonuses": "Previous bonuses", + "year": "Year", + "amount": "Amount" } }, "employee_card": { diff --git a/messages/no.json b/messages/no.json index 45652d68d..12545766a 100644 --- a/messages/no.json +++ b/messages/no.json @@ -32,7 +32,7 @@ "contact_sale": "Kontakt salg!", "contact_us": "Kontakt oss" }, - "compensation_calculator": { + "compensation": { "calculator": { "formLabel": "Lønnskalkulator", "educationInput": "Utdanning", @@ -44,7 +44,12 @@ "bachelor": "Bachelor", "master": "Master" }, - "test": "test" + "bonus": { + "location": "Lokasjon", + "bonuses": "Tidligere bonuser", + "year": "År", + "amount": "Beløp" + } }, "custom_link": { "visit_cv": "Gå til mini-CV", diff --git a/messages/se.json b/messages/se.json index d784bbc9a..e8160bc16 100644 --- a/messages/se.json +++ b/messages/se.json @@ -32,7 +32,7 @@ "contact_sale": "Kontakta sälj!", "contact_us": "Kontakt oss" }, - "compensation_calculator": { + "compensation": { "calculator": { "formLabel": "Lönskalkulator", "educationInput": "Utbildning", @@ -43,6 +43,12 @@ "degreeOptions": { "bachelor": "Bachelor", "master": "Master" + }, + "bonus": { + "location": "Kontor", + "bonuses": "Tidigare bonusar", + "year": "År", + "amount": "Belopp" } }, "custom_link": { diff --git a/src/components/compensations/CompensationSelector.tsx b/src/components/compensations/CompensationSelector.tsx index 4174bd11c..5fcb9200b 100644 --- a/src/components/compensations/CompensationSelector.tsx +++ b/src/components/compensations/CompensationSelector.tsx @@ -1,4 +1,5 @@ "use client"; +import { useTranslations } from "next-intl"; import { useState } from "react"; import { @@ -24,6 +25,8 @@ export default function CompensationSelector({ locations, locale, }: CompensationsProps) { + const t = useTranslations("compensation"); + const hasBenefits = (id: string) => compensations.benefitsByLocation.some((b) => b.location._ref === id); @@ -51,7 +54,7 @@ export default function CompensationSelector({
{ diff --git a/src/components/compensations/components/yearlyBonuses/YearlyBonuses.tsx b/src/components/compensations/components/yearlyBonuses/YearlyBonuses.tsx index 9ebf0ff89..76c04d186 100644 --- a/src/components/compensations/components/yearlyBonuses/YearlyBonuses.tsx +++ b/src/components/compensations/components/yearlyBonuses/YearlyBonuses.tsx @@ -1,3 +1,5 @@ +import { useTranslations } from "next-intl"; + import Text from "src/components/text/Text"; import { formatAsCurrency } from "src/utils/i18n"; import { BonusPage } from "studio/lib/interfaces/compensations"; @@ -11,17 +13,18 @@ interface YearlyBonusesProps { } const YearlyBonuses = ({ bonuses, locale }: YearlyBonusesProps) => { + const t = useTranslations("compensation"); return (
- Historisk bonus + {t("bonus.bonuses")} diff --git a/src/components/sections/compensation-calculator/Calculator.tsx b/src/components/sections/compensation-calculator/Calculator.tsx index 77bea8887..1c4176374 100644 --- a/src/components/sections/compensation-calculator/Calculator.tsx +++ b/src/components/sections/compensation-calculator/Calculator.tsx @@ -32,7 +32,7 @@ export default function Calculator({ initialYear, background, }: CalculatorProps) { - const t = useTranslations("compensation_calculator"); + const t = useTranslations("compensation"); const locale = use(localeRes); const salaries = use(salariesRes); const [year, setYear] = useState(
- År + {t("bonus.year")} - Beløp + {t("bonus.amount")}