[WIP] Remove GOV.UK frontend toolkit and convert to GOV.UK Frontend#34
[WIP] Remove GOV.UK frontend toolkit and convert to GOV.UK Frontend#34Nooshu wants to merge 8 commits into
Conversation
923a604 to
3883f3f
Compare
3883f3f to
96e9916
Compare
36degrees
left a comment
There was a problem hiding this comment.
This feels like it's adopting the framework but avoiding adopting any of the conventions - is that intentional?
| source 'https://rubygems.org' | ||
|
|
||
| gem 'govuk_tech_docs', path: '..' | ||
| gem 'middleman-search', git: 'git://github.com/alphagov/middleman-search.git' |
There was a problem hiding this comment.
Don't think this change is related?
There was a problem hiding this comment.
Without this change the build freezes. This is just about to be rolled into master I believe.
| @@ -36,12 +57,12 @@ $desktop-breakpoint: 992px !default; | |||
| @import "accessibility"; | |||
|
|
|||
| html, body { | |||
There was a problem hiding this comment.
Ideally the template should be updated to use the classes from https://github.com/alphagov/govuk-frontend/blob/master/src/core/_template.scss
|
|
||
| a:link { | ||
| color: $link-colour; | ||
| color: govuk-colour("blue"); |
There was a problem hiding this comment.
Suggest enabling global link and paragraph styling in Frontend and removing these link rules.
There was a problem hiding this comment.
If not, this should be $govuk-link-colour
There was a problem hiding this comment.
I'm going to raise all of your suggestions as GH suggestions
| @@ -0,0 +1,75 @@ | |||
| # The `src` directory | |||
There was a problem hiding this comment.
Ideally GOV.UK Frontend would be installed via npm install to avoid having to vendor it in.
If that's not possible, I strongly recommend using the package folder from the repo rather than the contents of source, as the Sass in source is not vendor-prefixed, and the source folder includes e.g. all the tests.
| @@ -0,0 +1,53 @@ | |||
| import { nodeListForEach } from './common' | |||
There was a problem hiding this comment.
The javascript from Frontend is inside a folder called 'stylesheets'. Suggest moving the Frontend dependency into a vendor directory or something (assuming installing it via npm install is not possible)
|
|
||
| a:hover { | ||
| color: $link-hover-colour; | ||
| color: govuk-colour("light-blue"); |
There was a problem hiding this comment.
$govuk-link-hover-colour
| } | ||
| } | ||
| } | ||
|
|
||
| @include print { | ||
| a:link, a:visited { | ||
| color: $black; | ||
| color: govuk-colour("black"); |
There was a problem hiding this comment.
$govuk-print-text-colour (which is actually #000!)
| @@ -9,14 +9,14 @@ | |||
| */ | |||
|
|
|||
| .phase-banner { | |||
| @include bold-14; | |||
| @include govuk-font(14, $weight: bold); | |||
There was a problem hiding this comment.
Can we use the phase banner component from Frontend?
| @@ -19,13 +19,13 @@ | |||
| &:focus { | |||
There was a problem hiding this comment.
Can we use the skip link component from Frontend?
| @@ -42,65 +46,65 @@ | |||
|
|
|||
| // Headings | |||
| h1 { | |||
There was a problem hiding this comment.
Can we use the new typography classes from Frontend? We do this in the Design System like this
At the moment yes to get it to a state where it looks and functions fine. I've raised the PR for general feedback and also in the hope that someone will be able to pick up some of the other areas of integration as it is quite a time consuming task. |
lewisnyman
left a comment
There was a problem hiding this comment.
It's great to see this being implemented., thanks for working on this.
I ran a quick visual regression test. It looks like the new logo implementation increases the logo height by one pixel, I don't know if that's worth worrying about or not.
| @@ -14,7 +14,7 @@ | |||
| .collapsible__toggle { | |||
| position: absolute; | |||
| top: 0; | |||
| right: -25px; | |||
| right: $govuk-gutter-half * -1; | |||
There was a problem hiding this comment.
This was the only other visual regression I found, this changes the value and moves the placement of the toggle button. I'd recommend using the previous value.
|
@Nooshu what's the name of that component the design system uses? I like how it works on the design system site, but I'm wondering how it would work for sites where the tech docs is only part of the service. For example on registers this page has a different layout to the documentation part, which is a bit jarring, but the top level navigation still looks the same wherever you are. Also on the GDS way site, one of the top level links is an external link, which might not work well with the new thing. |
|
Pushing latest updates:
Issues:
|
|
@Nooshu Just out of interest, is this still being worked on? |
|
@bendyson not at the moment I'm afraid. Leaving the information here and I'm hoping someone else will have the capacity to finish it. |
|
|
||
| a:link { | ||
| color: $link-colour; | ||
| color: govuk-colour("blue"); |
There was a problem hiding this comment.
| color: govuk-colour("blue"); | |
| color: $govuk-link-colour; |
|
|
||
| a:hover { | ||
| color: $link-hover-colour; | ||
| color: govuk-colour("light-blue"); |
There was a problem hiding this comment.
| color: govuk-colour("light-blue"); | |
| color: $govuk-link-hover-colour; |
|
|
||
| a:active { | ||
| color: $link-active-colour; | ||
| color: govuk-colour("light-blue"); |
There was a problem hiding this comment.
| color: govuk-colour("light-blue"); | |
| color: $govuk-link-active-colour; |


See task list of areas left to be integrated
Related issue: #154 raised here.
The dependency on GOV.UK frontend toolkit has been removed and been replaced by GOV.UK Frontend.
Note: this also fixes the Base64 encoded font issue / PR too.
Below are some screenshots comparing the homepage for both on mobile, tablet and desktop:
Mobile
Toolkit
Frontend
Tablet
Toolkit
Frontend
Desktop
Toolkit
Frontend