Skip to content
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

Add `websafe` departmental colours, ported from Whitehall #262

Merged
merged 3 commits into from Mar 4, 2016

Conversation

@fofr
Copy link
Contributor

@fofr fofr commented Mar 2, 2016

We use websafe to mean strong enough contrast against white to be used for copy and meet the AAA (large text) and AA (smaller copy) WCAG guidelines.

I'd like to get feedback on whether this file structure makes sense. One problem might be, a consuming app that imports just organisations will get a $link-color not defined error.

cc @gemmaleigh @dsingleton @markhurrell

fofr added 3 commits Mar 1, 2016
We will need to use these colours and styles in government-frontend,
whitehall and static.

We use `websafe` to mean strong enough contrast against white to be
used for copy and meet the AAA (large text) and AA (smaller copy) WCAG
guidelines.

* Port the brand colour mixin which can be used to generate styles for
each organisation

Original:
https://github.com/alphagov/whitehall/blob/540b900378823c2aa7b3baf3c5245
28dd48ee30e/app/assets/stylesheets/frontend/styleguide/_colours.scss
* Separate palette and organisations
* Keep existing behaviour of `_colour.scss` by importing the two files
* Import order matters as organisations uses `link-color` which is
defined in palette.
* Remove the `organisation-brand-colour` mixin which creates an
anti-pattern of needing to nest containers to achieve the desired affect
* Instead include a simpler example of how the list can be used.
@boffbowsh
Copy link
Contributor

@boffbowsh boffbowsh commented Mar 4, 2016

Bump and /cc @alextea for an additional reviewer. It LGTM but Paul wants opinions on the new structure

@alextea
Copy link
Contributor

@alextea alextea commented Mar 4, 2016

Structure makes sense to me. 👍

Is this a breaking change? Or would the problem @fofr described only affect new apps?

@boffbowsh
Copy link
Contributor

@boffbowsh boffbowsh commented Mar 4, 2016

Older apps currently import colours which now does the imports in the correct order, so that's fine. New apps would need to ensure they have the imports in the correct order if they import organisations

@alextea
Copy link
Contributor

@alextea alextea commented Mar 4, 2016

Great, I don't think that's a blocker.

boffbowsh added a commit that referenced this pull request Mar 4, 2016
Add `websafe` departmental colours, ported from Whitehall
@boffbowsh boffbowsh merged commit b396a8a into master Mar 4, 2016
2 checks passed
2 checks passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
@boffbowsh boffbowsh deleted the websafe-colours branch Mar 4, 2016
@fofr
Copy link
Contributor Author

@fofr fofr commented Mar 4, 2016

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.