From 204826e62e58b03a9399d6b3b4193d1a0e8d68d0 Mon Sep 17 00:00:00 2001 From: Sergei Maertens Date: Fri, 13 Sep 2024 11:49:08 +0200 Subject: [PATCH] :globe_with_meridians: Translate newly added literals --- .../EmailVerificationForm.stories.js | 20 +++++------ src/components/FormStep/FormStep.stories.js | 22 ++++++------ src/i18n/compiled/nl.json | 36 +++++++++---------- src/i18n/messages/nl.json | 32 ++++++++--------- 4 files changed, 54 insertions(+), 56 deletions(-) diff --git a/src/components/EmailVerification/EmailVerificationForm.stories.js b/src/components/EmailVerification/EmailVerificationForm.stories.js index 496068ab4..3bc0f4f10 100644 --- a/src/components/EmailVerification/EmailVerificationForm.stories.js +++ b/src/components/EmailVerification/EmailVerificationForm.stories.js @@ -34,12 +34,12 @@ export const HappyFlow = { play: async ({canvasElement}) => { const canvas = within(canvasElement); - await userEvent.click(await canvas.findByRole('button', {name: 'Send code'})); - const codeInput = await canvas.findByLabelText('Enter the six-character code'); + await userEvent.click(await canvas.findByRole('button', {name: 'Verstuur code'})); + const codeInput = await canvas.findByLabelText('Voer de bevestigingscode in'); expect(codeInput).toBeVisible(); await userEvent.type(codeInput, 'abcd12'); expect(codeInput).toHaveValue('ABCD12'); // automatically convert to uppercase - await userEvent.click(canvas.getByRole('button', {name: 'Verify'})); + await userEvent.click(canvas.getByRole('button', {name: 'Bevestigen'})); }, }; @@ -53,7 +53,7 @@ export const ArbitrarySendCodeErrorFlow = { play: async ({canvasElement}) => { const canvas = within(canvasElement); - await userEvent.click(await canvas.findByRole('button', {name: 'Send code'})); + await userEvent.click(await canvas.findByRole('button', {name: 'Verstuur code'})); expect(await canvas.findByText('No permission to perform this action.')).toBeVisible(); }, }; @@ -62,11 +62,11 @@ export const InvalidCodeFlow = { play: async ({canvasElement}) => { const canvas = within(canvasElement); - await userEvent.click(await canvas.findByRole('button', {name: 'Send code'})); - const codeInput = await canvas.findByLabelText('Enter the six-character code'); + await userEvent.click(await canvas.findByRole('button', {name: 'Verstuur code'})); + const codeInput = await canvas.findByLabelText('Voer de bevestigingscode in'); expect(codeInput).toBeVisible(); await userEvent.type(codeInput, 'FAILME'); // mock returns validation error - await userEvent.click(canvas.getByRole('button', {name: 'Verify'})); + await userEvent.click(canvas.getByRole('button', {name: 'Bevestigen'})); expect(await canvas.findByText('Not a valid verification code')).toBeVisible(); }, @@ -76,11 +76,11 @@ export const ArbitraryVerificationErrorFlow = { play: async ({canvasElement}) => { const canvas = within(canvasElement); - await userEvent.click(await canvas.findByRole('button', {name: 'Send code'})); - const codeInput = await canvas.findByLabelText('Enter the six-character code'); + await userEvent.click(await canvas.findByRole('button', {name: 'Verstuur code'})); + const codeInput = await canvas.findByLabelText('Voer de bevestigingscode in'); expect(codeInput).toBeVisible(); await userEvent.type(codeInput, 'NOPERM'); // mock returns 403 - await userEvent.click(canvas.getByRole('button', {name: 'Verify'})); + await userEvent.click(canvas.getByRole('button', {name: 'Bevestigen'})); expect(await canvas.findByText('No permission to perform this action.')).toBeVisible(); }, diff --git a/src/components/FormStep/FormStep.stories.js b/src/components/FormStep/FormStep.stories.js index 2242a3763..b1cfb717e 100644 --- a/src/components/FormStep/FormStep.stories.js +++ b/src/components/FormStep/FormStep.stories.js @@ -259,14 +259,14 @@ export const EmailVerification = { const modal = await canvas.findByRole('dialog'); expect(modal).toBeVisible(); - await userEvent.click(within(modal).getByRole('button', {name: 'Send code'})); - const codeInput = await within(modal).findByLabelText('Enter the six-character code'); + await userEvent.click(within(modal).getByRole('button', {name: 'Verstuur code'})); + const codeInput = await within(modal).findByLabelText('Voer de bevestigingscode in'); expect(codeInput).toBeVisible(); await userEvent.type(codeInput, 'ABCD12'); - const submitButton = within(modal).getByRole('button', {name: 'Verify'}); + const submitButton = within(modal).getByRole('button', {name: 'Bevestigen'}); await userEvent.click(submitButton); - expect(await within(modal).findByText(/The email address has now been verified/)).toBeVisible(); + expect(await within(modal).findByText(/Je e-mailadres is bevestigd/)).toBeVisible(); }, }; @@ -324,16 +324,14 @@ export const EmailVerificationNotDone = { const modal = await canvas.findByRole('dialog'); expect(modal).toBeVisible(); - await userEvent.click(within(modal).getByRole('button', {name: 'Send code'})); - const codeInput = await within(modal).findByLabelText('Enter the six-character code'); + await userEvent.click(within(modal).getByRole('button', {name: 'Verstuur code'})); + const codeInput = await within(modal).findByLabelText('Voer de bevestigingscode in'); expect(codeInput).toBeVisible(); await userEvent.type(codeInput, 'ABCD12'); - const submitButton = within(modal).getByRole('button', {name: 'Verify'}); + const submitButton = within(modal).getByRole('button', {name: 'Bevestigen'}); await userEvent.click(submitButton); - expect( - await within(modal).findByText(/The email address has now been verified/) - ).toBeVisible(); + expect(await within(modal).findByText(/Je e-mailadres is bevestigd/)).toBeVisible(); // close modal await userEvent.click(within(modal).getByRole('button', {name: 'Sluiten'})); }); @@ -403,7 +401,7 @@ export const SummaryProgressVisible = { play: async ({canvasElement}) => { const canvas = within(canvasElement); - expect(await canvas.findByText(/Step 1 of 1/)).toBeVisible(); + expect(await canvas.findByText(/Stap 1 van 1/)).toBeVisible(); }, }; @@ -416,6 +414,6 @@ export const SummaryProgressNotVisible = { play: async ({canvasElement}) => { const canvas = within(canvasElement); - expect(canvas.queryByText(/Step 1 of 1/)).toBeNull(); + expect(canvas.queryByText(/Stap 1 van 1/)).toBeNull(); }, }; diff --git a/src/i18n/compiled/nl.json b/src/i18n/compiled/nl.json index 7d15cecb3..af7fa4deb 100644 --- a/src/i18n/compiled/nl.json +++ b/src/i18n/compiled/nl.json @@ -58,7 +58,7 @@ "1+Q55M": [ { "type": 0, - "value": "You are verifying the email address " + "value": "Om door te gaan moet je jouw e-mailadres " }, { "children": [ @@ -72,7 +72,7 @@ }, { "type": 0, - "value": ". First, we need to send you a verification code on this email address. Then, you need to enter the code to confirm it." + "value": " bevestigen. We sturen je eerst een bevestigingscode naar dit e-mailadres. Vervolgens moet je deze bevestigingscode hier invoeren." } ], "1hdvgS": [ @@ -132,7 +132,7 @@ "4tPKAs": [ { "type": 0, - "value": "Verify" + "value": "Bevestigen" } ], "5uh2hS": [ @@ -498,7 +498,7 @@ "Dvt0Fv": [ { "type": 0, - "value": "The email address has now been verified. You can close this window and continue with the rest of the form." + "value": "Je e-mailadres is bevestigd. Je kan dit bericht sluiten en doorgaan met de rest van het formulier." } ], "DxbUkA": [ @@ -580,19 +580,19 @@ "EZ7myd": [ { "type": 0, - "value": "Email address verification" + "value": "E-mailadres bevestigen" } ], "FDy8nr": [ { "type": 0, - "value": "The verification code may only contain letters (A-Z) and numbers (0-9)." + "value": "De bevestigingscode bestaat uit hoofdletters (A-Z) en getallen (0-9)." } ], "FrFeZj": [ { "type": 0, - "value": "You haven't entered an email address yet." + "value": "Je hebt nog geen e-mailadres ingevuld." } ], "GbPef0": [ @@ -1034,7 +1034,7 @@ "R7k4JC": [ { "type": 0, - "value": "Enter the six-character code" + "value": "Voer de bevestigingscode in" } ], "RJ+0F/": [ @@ -1372,7 +1372,7 @@ "c0Ry9H": [ { "type": 0, - "value": "The verification code must contain exactly six characters." + "value": "De bevestigingscode moet precies zes tekens lang zijn." } ], "cBsrax": [ @@ -1514,7 +1514,7 @@ "ijV760": [ { "type": 0, - "value": "Step " + "value": "Stap " }, { "type": 1, @@ -1522,7 +1522,7 @@ }, { "type": 0, - "value": " of " + "value": " van " }, { "type": 1, @@ -1538,7 +1538,7 @@ "ixMIBJ": [ { "type": 0, - "value": "What would you like to do?" + "value": "Wat wil je doen?" } ], "jAZped": [ @@ -1702,7 +1702,7 @@ "lQY+Zm": [ { "type": 0, - "value": "Enter the verification code" + "value": "Een bevestigingscode invullen" } ], "lVNV/d": [ @@ -1720,7 +1720,7 @@ "lmWBQT": [ { "type": 0, - "value": "The code is exactly six characters long and consists of only uppercase letters and numbers." + "value": "De bevestigingscode is precies zes tekens lang en bestaat uit hoofdletters en getallen." } ], "lq29t6": [ @@ -1762,7 +1762,7 @@ "n1vyJM": [ { "type": 0, - "value": "Introduction" + "value": "Introductie" } ], "nLymjB": [ @@ -1976,7 +1976,7 @@ "qyWfE+": [ { "type": 0, - "value": "Receive a verification code" + "value": "Een bevestigingscode ontvangen" } ], "r1L6Zj": [ @@ -1994,7 +1994,7 @@ "riuSfc": [ { "type": 0, - "value": "Send code" + "value": "Verstuur code" } ], "sSmY1N": [ @@ -2052,7 +2052,7 @@ "tMO7aH": [ { "type": 0, - "value": "Continue ➜" + "value": "Doorgaan ➜" } ], "tohkCS": [ diff --git a/src/i18n/messages/nl.json b/src/i18n/messages/nl.json index 2e705ad40..606636f45 100644 --- a/src/i18n/messages/nl.json +++ b/src/i18n/messages/nl.json @@ -20,7 +20,7 @@ "originalDefault": "Log out" }, "1+Q55M": { - "defaultMessage": "You are verifying the email address {emailAddress}. First, we need to send you a verification code on this email address. Then, you need to enter the code to confirm it.", + "defaultMessage": "Om door te gaan moet je jouw e-mailadres {emailAddress} bevestigen. We sturen je eerst een bevestigingscode naar dit e-mailadres. Vervolgens moet je deze bevestigingscode hier invoeren.", "description": "Email verification modal body text", "originalDefault": "You are verifying the email address {emailAddress}. First, we need to send you a verification code on this email address. Then, you need to enter the code to confirm it." }, @@ -70,7 +70,7 @@ "originalDefault": "Bad" }, "4tPKAs": { - "defaultMessage": "Verify", + "defaultMessage": "Bevestigen", "description": "Email verification: verify code button text", "originalDefault": "Verify" }, @@ -268,7 +268,7 @@ "originalDefault": "Are you sure that you want to logout?" }, "Dvt0Fv": { - "defaultMessage": "The email address has now been verified. You can close this window and continue with the rest of the form.", + "defaultMessage": "Je e-mailadres is bevestigd. Je kan dit bericht sluiten en doorgaan met de rest van het formulier.", "description": "Text displayed after successful email verification", "originalDefault": "The email address has now been verified. You can close this window and continue with the rest of the form." }, @@ -314,17 +314,17 @@ "originalDefault": "House number addition must be up to four letters and digits." }, "EZ7myd": { - "defaultMessage": "Email address verification", + "defaultMessage": "E-mailadres bevestigen", "description": "Email verification modal title", "originalDefault": "Email address verification" }, "FDy8nr": { - "defaultMessage": "The verification code may only contain letters (A-Z) and numbers (0-9).", + "defaultMessage": "De bevestigingscode bestaat uit hoofdletters (A-Z) en getallen (0-9).", "description": "Validation error message for verification code pattern", "originalDefault": "The verification code may only contain letters (A-Z) and numbers (0-9)." }, "FrFeZj": { - "defaultMessage": "You haven't entered an email address yet.", + "defaultMessage": "Je hebt nog geen e-mailadres ingevuld.", "description": "Email verification modal: warning that no email is specified", "originalDefault": "You haven't entered an email address yet." }, @@ -517,7 +517,7 @@ "originalDefault": "Extend" }, "R7k4JC": { - "defaultMessage": "Enter the six-character code", + "defaultMessage": "Voer de bevestigingscode in", "description": "Email verification: code input field label", "originalDefault": "Enter the six-character code" }, @@ -669,7 +669,7 @@ "originalDefault": "Your payment is received and processed." }, "c0Ry9H": { - "defaultMessage": "The verification code must contain exactly six characters.", + "defaultMessage": "De bevestigingscode moet precies zes tekens lang zijn.", "description": "Validation error message for verification codes with length != 6", "originalDefault": "The verification code must contain exactly six characters." }, @@ -764,7 +764,7 @@ "originalDefault": "Invalid input: must include \"{includes}\" at one or more positions greater than or equal to {position}." }, "ijV760": { - "defaultMessage": "Step {current} of {total}", + "defaultMessage": "Stap {current} van {total}", "description": "Summary progress label", "originalDefault": "Step {current} of {total}" }, @@ -774,7 +774,7 @@ "originalDefault": "The email address where you will receive the resume link." }, "ixMIBJ": { - "defaultMessage": "What would you like to do?", + "defaultMessage": "Wat wil je doen?", "description": "Email verification mode selection label", "originalDefault": "What would you like to do?" }, @@ -846,7 +846,7 @@ "originalDefault": "You must provide a postcode." }, "lQY+Zm": { - "defaultMessage": "Enter the verification code", + "defaultMessage": "Een bevestigingscode invullen", "description": "Email verification mode selection: enter code label", "originalDefault": "Enter the verification code" }, @@ -862,7 +862,7 @@ "originalDefault": "Product" }, "lmWBQT": { - "defaultMessage": "The code is exactly six characters long and consists of only uppercase letters and numbers.", + "defaultMessage": "De bevestigingscode is precies zes tekens lang en bestaat uit hoofdletters en getallen.", "description": "Email verification: code input field description", "originalDefault": "The code is exactly six characters long and consists of only uppercase letters and numbers." }, @@ -887,7 +887,7 @@ "originalDefault": "Your session is about to expire {delta}. Extend your session if you wish to continue." }, "n1vyJM": { - "defaultMessage": "Introduction", + "defaultMessage": "Introductie", "description": "introduction page title", "originalDefault": "Introduction" }, @@ -952,7 +952,7 @@ "originalDefault": "Log in to co-sign the form" }, "qyWfE+": { - "defaultMessage": "Receive a verification code", + "defaultMessage": "Een bevestigingscode ontvangen", "description": "Email verification mode selection: send code label", "originalDefault": "Receive a verification code" }, @@ -967,7 +967,7 @@ "originalDefault": "Postcode must be four digits followed by two letters (e.g. 1234 AB)." }, "riuSfc": { - "defaultMessage": "Send code", + "defaultMessage": "Verstuur code", "description": "Email verification: send code button text", "originalDefault": "Send code" }, @@ -992,7 +992,7 @@ "originalDefault": "Not co-signed" }, "tMO7aH": { - "defaultMessage": "Continue ➜", + "defaultMessage": "Doorgaan ➜", "description": "Button text for link to continue from introduction page to start page", "originalDefault": "Continue ➜" },