Skip to content

Commit

Permalink
Merge pull request #3918 from alphagov/remove-popular-from-super-nav
Browse files Browse the repository at this point in the history
Remove "Popular" links from super navigation header
  • Loading branch information
davidtrussler authored Mar 15, 2024
2 parents 4a17fd0 + 24595b3 commit 404eea0
Show file tree
Hide file tree
Showing 69 changed files with 7 additions and 243 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
## 37.8.0

* Disable the single consent cookie API code ([PR #3916](https://github.com/alphagov/govuk_publishing_components/pull/3916))
* Remove "Popular" links from super navigation header ([PR #3918](https://github.com/alphagov/govuk_publishing_components/pull/3918))

## 37.7.1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -884,7 +884,11 @@ $after-button-padding-left: govuk-spacing(4);
}

.gem-c-layout-super-navigation-header__search-form {
padding: 0 0 govuk-spacing(8) 0;
padding: 0;

@include govuk-media-query($from: "desktop") {
padding-bottom: govuk-spacing(2);
}
}

// Popular links.
Expand All @@ -893,17 +897,6 @@ $after-button-padding-left: govuk-spacing(4);
padding: govuk-spacing(1) 0;
}

.gem-c-layout-super-navigation-header__popular-link {
display: inline-block;
font-size: 16px;
font-size: govuk-px-to-rem(16px);
padding: 0;

&::after {
@include make-selectable-area-bigger;
}
}

.gem-c-layout-super-navigation-header__width-container {
@include govuk-media-query($until: "desktop") {
margin: 0;
Expand Down Expand Up @@ -988,11 +981,6 @@ $after-button-padding-left: govuk-spacing(4);
}

@include govuk-media-query($until: tablet) {
.gem-c-layout-super-navigation-header__popular-links-heading--large-navbar {
font-size: 24px;
font-size: govuk-px-to-rem(24px);
}

// can't disable responsive styling because using override classes
// from govuk-frontend which are all responsive so have to supply
// custom class to the label of the search component to turn off
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@
navigation_menu_heading = t("components.layout_super_navigation_header.navigation_menu_heading")
navigation_search_heading = t("components.layout_super_navigation_header.navigation_search_heading")
navigation_search_subheading = t("components.layout_super_navigation_header.navigation_search_subheading")
popular_links = t("components.layout_super_navigation_header.popular_links")
popular_links_heading = t("components.layout_super_navigation_header.popular_links_heading")
search_text = t("components.layout_super_navigation_header.search_text")

hide_search_menu_text = t("components.layout_super_navigation_header.menu_toggle_label.hide", :label => "search")
Expand Down Expand Up @@ -68,9 +66,6 @@
dropdown_menu_classes = %w(gem-c-layout-super-navigation-header__navigation-dropdown-menu)
dropdown_menu_classes << "gem-c-layout-super-navigation-header__navigation-dropdown-menu--large-navbar" if large_navbar

popular_links_heading_classes = %w(govuk-heading-m)
popular_links_heading_classes << "gem-c-layout-super-navigation-header__popular-links-heading--large-navbar" if large_navbar

absolute_links_helper = GovukPublishingComponents::Presenters::AbsoluteLinksHelper.new()
%>
<%= content_tag("header",
Expand Down Expand Up @@ -385,45 +380,6 @@
</form>
</div>
</div>
<div class="govuk-grid-row">
<div class="govuk-grid-column-full">
<%= content_tag(:h3, {
class: popular_links_heading_classes
}) do %>
<%= popular_links_heading %>
<% end %>
<ul class="govuk-list">
<% index_total = popular_links.length %>
<% popular_links.each_with_index do | popular_link, index | %>
<li class="gem-c-layout-super-navigation-header__popular-item">
<% link_href = absolute_links_helper.make_url_absolute(popular_link[:href]) %>
<%= link_to popular_link[:label], link_href, {
class: [
"govuk-link",
"gem-c-layout-super-navigation-header__popular-link",
],
data: {
track_action: "popularLink",
track_category: "headerClicked",
track_label: popular_link[:href],
track_dimension: popular_link[:label],
track_dimension_index: "29",
ga4_link: {
"event_name": "navigation",
"type": "header menu bar",
"index_section": 4,
"index_link": index + 1,
"index_section_count": 4,
"index_total": index_total,
"section": popular_links_heading,
}
}
} %>
</li>
<% end %>
</ul>
</div>
</div>
</div>
<% end %>
</nav>
Expand Down
2 changes: 0 additions & 2 deletions config/locales/ar.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,6 @@ ar:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: من
Expand Down
2 changes: 0 additions & 2 deletions config/locales/az.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ az:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: "...dan (dən)"
Expand Down
2 changes: 0 additions & 2 deletions config/locales/be.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,6 @@ be:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: З
Expand Down
2 changes: 0 additions & 2 deletions config/locales/bg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,6 @@ bg:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: От
Expand Down
2 changes: 0 additions & 2 deletions config/locales/bn.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,6 @@ bn:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: থেকে
Expand Down
2 changes: 0 additions & 2 deletions config/locales/cs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,6 @@ cs:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: 'Komu I:'
Expand Down
2 changes: 0 additions & 2 deletions config/locales/cy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,6 @@ cy:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Gan
Expand Down
2 changes: 0 additions & 2 deletions config/locales/da.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,6 @@ da:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Fra
Expand Down
2 changes: 0 additions & 2 deletions config/locales/de.yml
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,6 @@ de:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Von
Expand Down
2 changes: 0 additions & 2 deletions config/locales/dr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,6 @@ dr:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: از
Expand Down
2 changes: 0 additions & 2 deletions config/locales/el.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ el:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Από
Expand Down
14 changes: 0 additions & 14 deletions config/locales/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -231,20 +231,6 @@ en:
navigation_menu_heading: Navigation menu
navigation_search_heading: Search and popular pages
navigation_search_subheading: Search
popular_links:
- label: Get support with the cost of living
href: "/cost-of-living"
- label: Find out about help you can get with your energy bills
href: "/get-help-energy-bills"
- label: Find a job
href: "/find-a-job"
- label: 'Universal Credit account: sign in'
href: "/sign-in-universal-credit"
- label: Check your National Insurance record
href: "/check-national-insurance-record"
- label: 'Check MOT history of a vehicle'
href: /check-mot-history
popular_links_heading: Popular on GOV.UK
search_text: Search GOV.UK
metadata:
from: From
Expand Down
2 changes: 0 additions & 2 deletions config/locales/es-419.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ es-419:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Desde
Expand Down
2 changes: 0 additions & 2 deletions config/locales/es.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ es:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Desde
Expand Down
2 changes: 0 additions & 2 deletions config/locales/et.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,6 @@ et:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Alates
Expand Down
2 changes: 0 additions & 2 deletions config/locales/fa.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,6 @@ fa:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: از
Expand Down
2 changes: 0 additions & 2 deletions config/locales/fi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,6 @@ fi:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Alkaen
Expand Down
2 changes: 0 additions & 2 deletions config/locales/fr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ fr:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: De
Expand Down
2 changes: 0 additions & 2 deletions config/locales/gd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,6 @@ gd:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: De
Expand Down
2 changes: 0 additions & 2 deletions config/locales/gu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ gu:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: થી
Expand Down
2 changes: 0 additions & 2 deletions config/locales/he.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ he:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: מ-
Expand Down
2 changes: 0 additions & 2 deletions config/locales/hi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ hi:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: से
Expand Down
2 changes: 0 additions & 2 deletions config/locales/hr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,6 @@ hr:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Iz
Expand Down
2 changes: 0 additions & 2 deletions config/locales/hu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,6 @@ hu:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Feladó
Expand Down
2 changes: 0 additions & 2 deletions config/locales/hy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,6 @@ hy:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Ումից՝
Expand Down
2 changes: 0 additions & 2 deletions config/locales/id.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ id:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Dari
Expand Down
2 changes: 0 additions & 2 deletions config/locales/is.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ is:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Frá
Expand Down
2 changes: 0 additions & 2 deletions config/locales/it.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,6 @@ it:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: Da
Expand Down
2 changes: 0 additions & 2 deletions config/locales/ja.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,6 @@ ja:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: から
Expand Down
2 changes: 0 additions & 2 deletions config/locales/ka.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,6 @@ ka:
navigation_menu_heading:
navigation_search_heading:
navigation_search_subheading:
popular_links:
popular_links_heading:
search_text:
metadata:
from: დან
Expand Down
Loading

0 comments on commit 404eea0

Please sign in to comment.