diff --git a/classes/SectionView/SeneddView.php b/classes/SectionView/SeneddView.php index b0471ba400..2a3cf3ac2d 100644 --- a/classes/SectionView/SeneddView.php +++ b/classes/SectionView/SeneddView.php @@ -107,11 +107,7 @@ protected function display_front_senedd() { protected function getSearchBox(array $data): \MySociety\TheyWorkForYou\Search\SearchBox{ $search_box = new \MySociety\TheyWorkForYou\Search\SearchBox(); $search_box->homepage_panel_class = "panel--homepage--senedd"; - if (LANGUAGE == 'cy') { - $search_box->homepage_subhead = "Senedd"; - } else { - $search_box->homepage_subhead = "Senedd / Welsh Parliament"; - } + $search_box->homepage_subhead = gettext("Senedd / Welsh Parliament"); $search_box->homepage_desc = ""; $search_box->search_section = "senedd"; $search_box->quick_links = []; @@ -122,11 +118,7 @@ protected function getSearchBox(array $data): \MySociety\TheyWorkForYou\Search\S $constituencies[$member["constituency"]] = 1; } $constituencies = array_keys($constituencies); - if (LANGUAGE == 'cy'){ - $search_box->add_quick_link('Darganfod mwy am eich Aelodau Cynulliad dros ' . $constituencies[0] . ' a ' . $constituencies[1], '/postcode/?pc=' . $data["mp_data"]['postcode'],'torso'); - } else { - $search_box->add_quick_link('Find out more about your MSs for ' . $constituencies[0] . ' and ' . $constituencies[1], '/postcode/?pc=' . $data["mp_data"]['postcode'],'torso'); - } + $search_box->add_quick_link(gettext('Find out more about your MSs for ') . $constituencies[0] . gettext(' and ') . $constituencies[1], '/postcode/?pc=' . $data["mp_data"]['postcode'],'torso'); } $search_box->add_quick_link(gettext('Create and manage email alerts'), '/alert/','megaphone'); $search_box->add_quick_link(gettext('Subscribe to our newsletter'), '/about/#about-mysociety', 'mail'); diff --git a/locale/cy_GB.UTF-8/LC_MESSAGES/TheyWorkForYou.po b/locale/cy_GB.UTF-8/LC_MESSAGES/TheyWorkForYou.po index 797bec3ef8..446668dfea 100644 --- a/locale/cy_GB.UTF-8/LC_MESSAGES/TheyWorkForYou.po +++ b/locale/cy_GB.UTF-8/LC_MESSAGES/TheyWorkForYou.po @@ -173,7 +173,14 @@ msgstr "Ni allwch chwilio am fwy nag un ystod o ddyddiadau." msgid "Maximum term length is 255 characters." msgstr "Yr hyd term mwyaf yw 255 nod." -#: classes/SectionView/SeneddView.php:131 +#: classes/SectionView/SeneddView.php:125 +msgid "Find out more about your MSs for " +msgstr "Darganfod mwy am eich Aelodau Cynulliad dros " + +#: classes/SectionView/SeneddView.php:125 +msgid " and " +msgstr " a " + msgid "Create and manage email alerts" msgstr "Creu hysbysiad"