Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SDCSRM 621 Update Contact Details #50

Merged
merged 5 commits into from
Jul 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ collates all the text to translate into a single file.
To build/re-build the translation messages.pot use:

```
pipenv run pybabel extract -F babel.cfg -o app/translations/messages.pot .
pipenv run pybabel extract -F babel.cfg -o rh_ui/translations/messages.pot .
```

To create a new language messages file, run the following, changing the 2 character language code at the end to the
Expand All @@ -46,22 +46,22 @@ Note that this implementation includes an English translation. This is needed du
with aiohttp.

```
pipenv run pybabel init -i app/translations/messages.pot -d app/translations -l cy
pipenv run pybabel init -i rh_ui/translations/messages.pot -d rh_ui/translations -l cy
```

Once created, you can update the existing language messages.po files to include changes in the messages.pot by running
the following. This will update ALL language files.

```
pipenv run pybabel update -i app/translations/messages.pot -d app/translations
pipenv run pybabel update -i rh_ui/translations/messages.pot -d rh_ui/translations
```

To compile updates to the messages.po files into messages.mo (the file actually used by the site) use:

(If you've only changes made one small change and there's a `#, fuzzy` entry in the translation,
double-check the translation then remove the comment before compiling)
```
pipenv run pybabel compile -d app/translations
pipenv run pybabel compile -d rh_ui/translations
```

## Venom Tests

We have a suite of [Venom tests](https://github.com/ovh/venom) for testing the OWASP header recommendations. These tests
Expand Down
2 changes: 1 addition & 1 deletion rh_ui/templates/start.html
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ <h2 class="ons-u-fs-xl ons-u-mt-l" id="find_access_code">{{ _('Where to find you
Your 16-character access code will be a combination of letters and numbers.') }}</p>

{%- set further_info_content -%}
<p>{{ _('Telephone: +44 800 085 7376<br>8am to 7pm Monday to Friday<br>8am to 1pm Saturday') }}</p>
<p>{{ _('Telephone: +44 0808 196 1270<br>9am to 4:30pm Monday to Thursday<br>9am to 3pm Friday') }}</p>
<p>{{ _('Minicom (for the deaf and hearing impaired): 18001 +44 800 085 7376') }}</p>
<p>{{ _('Email:') }} <a href="mailto: [email protected]">[email protected]</a></p>
{%- endset -%}
Expand Down
Binary file modified rh_ui/translations/cy/LC_MESSAGES/messages.mo
Binary file not shown.
75 changes: 38 additions & 37 deletions rh_ui/translations/cy/LC_MESSAGES/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2023-08-31 09:17+0100\n"
"POT-Creation-Date: 2024-07-25 11:50+0100\n"
"PO-Revision-Date: 2022-11-18 18:31+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language: cy\n"
Expand All @@ -17,7 +17,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.12.1\n"
"Generated-By: Babel 2.14.0\n"

#: rh_ui/templates/base.html:12 rh_ui/templates/base.html:68
msgid "Cookies"
Expand Down Expand Up @@ -93,60 +93,60 @@ msgstr "https://cy.ons.gov.uk/"
msgid "ONS Surveys"
msgstr "Arolygon SYG"

#: rh_ui/templates/start.html:20
#: rh_ui/templates/start.html:12
msgid "Enter an access code"
msgstr "Rhowch god mynediad"

#: rh_ui/templates/start.html:21 rh_ui/templates/start.html:24
#: rh_ui/templates/start.html:27
#: rh_ui/templates/start.html:13 rh_ui/templates/start.html:16
#: rh_ui/templates/start.html:19
msgid "Error: Start study - ONS Surveys"
msgstr "Gwall: Dechrau'r astudiaeth - Arolygon SYG"

#: rh_ui/templates/start.html:23
#: rh_ui/templates/start.html:15
msgid "Enter a 16-character access code"
msgstr "Rhowch god mynediad 16 nod"

#: rh_ui/templates/start.html:26
#: rh_ui/templates/start.html:18
msgid "Access code not recognised. Enter the code again."
msgstr "Nid yw'r cod mynediad yn cael ei gydnabod. Rhowch y cod eto."

#: rh_ui/templates/start.html:31
#: rh_ui/templates/start.html:23
msgid "Start study - ONS Surveys"
msgstr "Dechrau'r astudiaeth - Arolygon SYG"

#: rh_ui/templates/start.html:39
#: rh_ui/templates/start.html:31
msgid "Start study"
msgstr "Dechrau'r astudiaeth"

#: rh_ui/templates/start.html:46 rh_ui/templates/start.html:68
msgid "Where to find your access code"
msgstr "Ble i ddod o hyd i'ch cod mynediad"

#: rh_ui/templates/start.html:50
#: rh_ui/templates/start.html:39
msgid "Enter your 16-character access code"
msgstr "Rhowch eich cod mynediad sy'n cynnwys 16 o nodau"

#: rh_ui/templates/start.html:51
#: rh_ui/templates/start.html:40
msgid ""
"Keep this code safe. You will need to enter it every time you access your"
" study"
msgstr ""
"Cadwch y cod hwn yn ddiogel. Bydd angen i chi roi eich cod bob tro y "
"byddwch chi'n mynd at eich astudiaeth"

#: rh_ui/templates/start.html:54
#: rh_ui/templates/start.html:43
msgid ""
"Your personal information is protected by law and will be kept "
"confidential."
msgstr ""
"Mae eich gwybodaeth bersonol wedi'i diogelu gan y gyfraith a chaiff ei "
"chadw'n gyfrinachol."

#: rh_ui/templates/start.html:62
#: rh_ui/templates/start.html:51
msgid "Access study"
msgstr "Agor yr astudiaeth"

#: rh_ui/templates/start.html:69
#: rh_ui/templates/start.html:57
msgid "Where to find your access code"
msgstr "Ble i ddod o hyd i'ch cod mynediad"

#: rh_ui/templates/start.html:58
msgid ""
"Your access code can be found in the invitation letter or email you "
"received.\n"
Expand All @@ -157,23 +157,23 @@ msgstr ""
" gawsoch. Bydd eich cod mynediad 16 nod yn gyfuniad o lythrennau a "
"rhifau."

#: rh_ui/templates/start.html:73
#: rh_ui/templates/start.html:62
msgid ""
"Telephone: +44 800 085 7376<br>8am to 7pm Monday to Friday<br>8am to 1pm "
"Saturday"
"Telephone: +44 0808 196 1270<br>9am to 4:30pm Monday to Thursday<br>9am "
"to 3pm Friday"
msgstr ""
"Ffôn: +44 800 085 7376<br>8am i 7pm o ddydd Llun i ddydd Gwener<br>8am i "
"1pm ar ddydd Sadwrn"
"Ffôn: +44 0808 196 1270<br>9am i 4:30pm o ddydd Llun i ddydd Iau<br>9am i"
" 3pm ar ddydd Gwener"

#: rh_ui/templates/start.html:74
#: rh_ui/templates/start.html:63
msgid "Minicom (for the deaf and hearing impaired): 18001 +44 800 085 7376"
msgstr "Minicom (ar gyfer pobl fyddar neu drwm eu clyw): 18001 +44 800 085 7376"

#: rh_ui/templates/start.html:75
#: rh_ui/templates/start.html:64
msgid "Email:"
msgstr "E-bost:"

#: rh_ui/templates/start.html:81
#: rh_ui/templates/start.html:70
msgid "Who can I contact for further information?"
msgstr "Â phwy y gallaf gysylltu i gael rhagor o wybodaeth?"

Expand Down Expand Up @@ -523,8 +523,8 @@ msgid ""
msgstr ""
"cydnabod eich bod yn rhannu gwybodaeth bersonol â ni a'i thrin yn "
"gyfrinachol, yn unol â'r <a "
"href=\"https://code.statisticsauthority.gov.uk/\" target=\"_blank\">Cod Ymarfer ar gyfer "
"Ystadegau</a>"
"href=\"https://code.statisticsauthority.gov.uk/\" target=\"_blank\">Cod "
"Ymarfer ar gyfer Ystadegau</a>"

#: rh_ui/templates/info_pages/privacy-and-data-protection.html:32
msgid ""
Expand Down Expand Up @@ -567,13 +567,14 @@ msgid ""
"and the Code of Practice for Statistics"
msgstr ""
"darparu gwybodaeth arolwg i <a "
"href=\"https://cy.ons.gov.uk/aboutus/whatwedo/statistics/requestingstatistics/accesstounpublishedonsresearchdatabygovernmentorganisationsforstatisticalresearch\" target=\"_blank\">adrannau"
" eraill y Llywodraeth, sefydliadau cymeradwy</a> ac <a "
"href=\"https://cy.ons.gov.uk/aboutus/whatwedo/statistics/requestingstatistics/approvedresearcherscheme\" target=\"_blank\">ymchwilwyr"
" cymeradwys</a> at ddibenion ystadegol yn unig, gan gydymffurfio â'r un "
"safonau diogelwch rydym yn eu dilyn (ac yn unol â darpariaethau "
"Deddfwriaeth Diogelu Data, y Ddeddf Ystadegau a'r Gwasanaeth Cofrestru "
"2007 a'r Cod Ymarfer ar gyfer Ystadegau)"
"href=\"https://cy.ons.gov.uk/aboutus/whatwedo/statistics/requestingstatistics/accesstounpublishedonsresearchdatabygovernmentorganisationsforstatisticalresearch\""
" target=\"_blank\">adrannau eraill y Llywodraeth, sefydliadau "
"cymeradwy</a> ac <a "
"href=\"https://cy.ons.gov.uk/aboutus/whatwedo/statistics/requestingstatistics/approvedresearcherscheme\""
" target=\"_blank\">ymchwilwyr cymeradwys</a> at ddibenion ystadegol yn "
"unig, gan gydymffurfio â'r un safonau diogelwch rydym yn eu dilyn (ac yn "
"unol â darpariaethau Deddfwriaeth Diogelu Data, y Ddeddf Ystadegau a'r "
"Gwasanaeth Cofrestru 2007 a'r Cod Ymarfer ar gyfer Ystadegau)"

#: rh_ui/templates/info_pages/privacy-and-data-protection.html:50
msgid ""
Expand Down Expand Up @@ -621,8 +622,8 @@ msgstr ""
"Os bydd gennych chi gwestiwn am y ffordd rydyn ni'n prosesu eich data "
"personol, neu os byddwch chi am ddysgu mwy am eich hawliau o dan "
"ddeddfwriaeth diogelu data, gweler ein <a "
"href=\"https://cy.ons.gov.uk/aboutus/transparencyandgovernance/dataprotection\" target=\"_blank\">tudalen"
" diogelu data.</a>"
"href=\"https://cy.ons.gov.uk/aboutus/transparencyandgovernance/dataprotection\""
" target=\"_blank\">tudalen diogelu data.</a>"

#: rh_ui/templates/partials/messages.html:7
msgid "There is a problem with this page"
Expand Down
52 changes: 26 additions & 26 deletions rh_ui/translations/messages.pot
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
# Translations template for PROJECT.
# Copyright (C) 2023 ORGANIZATION
# Copyright (C) 2024 ORGANIZATION
# This file is distributed under the same license as the PROJECT project.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2023.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2024.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2023-08-31 09:17+0100\n"
"POT-Creation-Date: 2024-07-25 11:50+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <[email protected]>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.12.1\n"
"Generated-By: Babel 2.14.0\n"

#: rh_ui/templates/base.html:12 rh_ui/templates/base.html:68
msgid "Cookies"
Expand Down Expand Up @@ -85,78 +85,78 @@ msgstr ""
msgid "ONS Surveys"
msgstr ""

#: rh_ui/templates/start.html:20
#: rh_ui/templates/start.html:12
msgid "Enter an access code"
msgstr ""

#: rh_ui/templates/start.html:21 rh_ui/templates/start.html:24
#: rh_ui/templates/start.html:27
#: rh_ui/templates/start.html:13 rh_ui/templates/start.html:16
#: rh_ui/templates/start.html:19
msgid "Error: Start study - ONS Surveys"
msgstr ""

#: rh_ui/templates/start.html:23
#: rh_ui/templates/start.html:15
msgid "Enter a 16-character access code"
msgstr ""

#: rh_ui/templates/start.html:26
#: rh_ui/templates/start.html:18
msgid "Access code not recognised. Enter the code again."
msgstr ""

#: rh_ui/templates/start.html:31
#: rh_ui/templates/start.html:23
msgid "Start study - ONS Surveys"
msgstr ""

#: rh_ui/templates/start.html:39
#: rh_ui/templates/start.html:31
msgid "Start study"
msgstr ""

#: rh_ui/templates/start.html:46 rh_ui/templates/start.html:68
msgid "Where to find your access code"
msgstr ""

#: rh_ui/templates/start.html:50
#: rh_ui/templates/start.html:39
msgid "Enter your 16-character access code"
msgstr ""

#: rh_ui/templates/start.html:51
#: rh_ui/templates/start.html:40
msgid ""
"Keep this code safe. You will need to enter it every time you access your"
" study"
msgstr ""

#: rh_ui/templates/start.html:54
#: rh_ui/templates/start.html:43
msgid ""
"Your personal information is protected by law and will be kept "
"confidential."
msgstr ""

#: rh_ui/templates/start.html:62
#: rh_ui/templates/start.html:51
msgid "Access study"
msgstr ""

#: rh_ui/templates/start.html:69
#: rh_ui/templates/start.html:57
msgid "Where to find your access code"
msgstr ""

#: rh_ui/templates/start.html:58
msgid ""
"Your access code can be found in the invitation letter or email you "
"received.\n"
" Your 16-character access code will be a combination of letters "
"and numbers."
msgstr ""

#: rh_ui/templates/start.html:73
#: rh_ui/templates/start.html:62
msgid ""
"Telephone: +44 800 085 7376<br>8am to 7pm Monday to Friday<br>8am to 1pm "
"Saturday"
"Telephone: +44 0808 196 1270<br>9am to 4:30pm Monday to Thursday<br>9am "
"to 3pm Friday"
msgstr ""

#: rh_ui/templates/start.html:74
#: rh_ui/templates/start.html:63
msgid "Minicom (for the deaf and hearing impaired): 18001 +44 800 085 7376"
msgstr ""

#: rh_ui/templates/start.html:75
#: rh_ui/templates/start.html:64
msgid "Email:"
msgstr ""

#: rh_ui/templates/start.html:81
#: rh_ui/templates/start.html:70
msgid "Who can I contact for further information?"
msgstr ""

Expand Down