-
Notifications
You must be signed in to change notification settings - Fork 17
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
Taxonomy navigation collections #1008
Conversation
No longer display related collections in the sidebar if the new navigation is enabled.
.taxonomy-navigation__section:first-of-type { | ||
margin-top: $gutter * 1.5; | ||
.taxonomy-navigation__row { | ||
display: flex; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason why this needs to use flex rather than just the grid classes (grid-row
and column-one-third
)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So that they line up with the highlight boxes below.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah I see, I didn't spot that - that's annoying! Thanks for explaining.
I wonder if we need it to match up or if we could just have each column half the width of that row. But using flex isn't a big deal, it just adds a lot of CSS.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was something @miaallers mentioned when we went through it together. I should imagine we can find a better way to implement if the AB test is positive.
49091b5
to
6f1c843
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very small suggestions for improvement, but don't need to be blocking
@include bold-24; | ||
display: block; | ||
.taxonomy-navigation__list-item { | ||
margin-bottom: $gutter / 6; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At this point it might just be more useful to write it out as 5px
or perhaps $gutter-one-third / 2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same for padding-bottom below
<div class="taxonomy-navigation__row"> | ||
<div class="taxonomy-navigation__column"> | ||
<%= render "govuk_publishing_components/components/heading", | ||
text: 'Topics', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to make this a translated string
<% if related_collections.any? %> | ||
<div class="taxonomy-navigation__column"> | ||
<%= render "govuk_publishing_components/components/heading", | ||
text: 'Collections', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also need to add this as a translated string
Moves related collections from the sidebar to the taxonomy navigation.
Before:
After:
https://trello.com/c/zUWqJgX9
Visual regression results:
https://government-frontend-pr-1008.surge.sh/gallery.html
Component guide for this PR:
https://government-frontend-pr-1008.herokuapp.com/component-guide