Skip to content

Commit

Permalink
Use collapsable breadcrumbs from govuk-frontend
Browse files Browse the repository at this point in the history
This feature has been ported to govuk-frontend
alphagov/govuk-frontend#1754
  • Loading branch information
alex-ju committed Jun 2, 2020
1 parent 80dfd6f commit 62ae787
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 36 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,38 +20,3 @@
.gem-c-breadcrumbs--inverse .govuk-breadcrumbs__list-item:before {
border-color: govuk-colour("white");
}

.gem-c-breadcrumbs--collapse-on-mobile {
@include govuk-media-query($until: tablet) {
.govuk-breadcrumbs__list {
display: flex;
}

.govuk-breadcrumbs__list-item:not(:last-child):not(:first-child) {
display: none;
}

.govuk-breadcrumbs__list-item {
padding-top: 14px;
padding-bottom: 14px;
}

.govuk-breadcrumbs__list-item:before {
margin: 0;
top: 18px;
}

.govuk-breadcrumbs__link {
position: relative;
}

.govuk-breadcrumbs__link::after {
content: "";
position: absolute;
top: -14px;
right: 0;
left: 0;
bottom: -14px;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
breadcrumb_presenter = GovukPublishingComponents::Presenters::Breadcrumbs.new(breadcrumbs)

classes = "gem-c-breadcrumbs govuk-breadcrumbs"
classes << " gem-c-breadcrumbs--collapse-on-mobile" if collapse_on_mobile
classes << " govuk-breadcrumbs--collapse-on-mobile" if collapse_on_mobile
classes << " gem-c-breadcrumbs--inverse" if inverse
%>

Expand Down

0 comments on commit 62ae787

Please sign in to comment.