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

Review organisation colours #1919

Open
1 of 3 tasks
36degrees opened this issue Aug 18, 2020 · 6 comments · May be fixed by #3407
Open
1 of 3 tasks

Review organisation colours #1919

36degrees opened this issue Aug 18, 2020 · 6 comments · May be fixed by #3407

Comments

@36degrees
Copy link
Member

36degrees commented Aug 18, 2020

The organisation colours do not currently seem to make much sense, and could do with being reviewed.

They were ported from Frontend Toolkit but have not really been looked at for a long time. (Before Frontend Toolkit, they were in Whitehall and were moved to frontend toolkit when they needed to be used in other GOV.UK apps.)

As I understand it, the 'websafe' colours are meant to be a 'darkened' version of the brand colour, provided where a brand colour would not otherwise meet the 4.5:1 contrast ratio required for text. However, in many cases the defined websafe colour has less contrast than the non-websafe colour.

In two cases, the websafe and non-websafe colours are completely different.

department websafe non websafe notes
attorney-generals-office #a03a88 (6.1) #9f1888 (6.7) WS contrast < non WS
cabinet-office #347da4 (4.5) #005abb (6.6) WS contrast < non WS
civil-service #af292e (6.5) #af292e (6.5)
department-for-business-innovation-skills #347da4 (4.5) #003479 (11.9) WS contrast < non WS
department-for-communities-and-local-government #37836e (4.5) #009999 (3.5)
department-for-culture-media-sport #a03155 (6.8) #d40072 (5.2)
department-for-education #347ca9 (4.6) #003a69 (11.6) WS contrast < non WS
department-for-environment-food-rural-affairs #008938 (4.5) #00a33b (3.3)
department-for-international-development #405e9a (6.4) #002878 (13) WS contrast < non WS
department-for-international-trade #005ea5 (6.7) #cf102d (5.2) !?
department-for-transport #398373 (4.5) #006c56 (6.4) WS contrast < non WS
department-for-work-pensions #37807b (4.6) #00beb7 (2.3)
department-of-energy-climate-change #2b7cac (4.6) #009ddb (3.1)
department-of-health #39836e (4.5) #00ad93 (2.8)
foreign-commonwealth-office #406e97 (5.4) #003e74 (10.8) WS contrast < non WS
government-equalities-office #9325b2 (6.5) #9325b2 (6.5) WS contrast < non WS
hm-government #347da4 (4.5) #0076c0 (4.8) WS contrast < non WS
hm-revenue-customs #008670 (4.5) #009390 (3.8)
hm-treasury #832322 (9) #af292e (6.5)
home-office #9440b2 (5.8) #9325b2 (6.5) WS contrast < non WS
ministry-of-defence #5a5c92 (6.2) #4d2942 (12) WS contrast < non WS
ministry-of-justice #5a5c92 (6.2) #231f20 (14.4) WS contrast < non WS
northern-ireland-office #3e598c (7) #002663 (13.8) WS contrast < non WS
office-of-the-advocate-general-for-scotland #005ea5 (6.7) #002663 (13.8) WS contrast < non WS
office-of-the-leader-of-the-house-of-commons #005f8f (6.9) #317023 (6)
office-of-the-leader-of-the-house-of-lords #c2395d (5.2) #9c132e (7.6) WS contrast < non WS
scotland-office #405c8a (6.7) #002663 (13.8) WS contrast < non WS
uk-export-finance #005ea5 (6.7) #005747 (8.6) WS contrast < non WS
uk-trade-investment #005ea5 (6.7) #c80651 (5.8) !?
wales-office #7a242a (9.6) #a33038 (6.9)

Tasks

  1. 2 of 3
    stevenjmesser
  2. querkmachine stevenjmesser
@36degrees 36degrees added awaiting triage Needs triaging by team colour labels Aug 18, 2020
@kellylee-gds kellylee-gds added 🔍 investigation 🕔 days and removed awaiting triage Needs triaging by team labels Aug 24, 2020
@CharlotteDowns
Copy link
Contributor

CharlotteDowns commented Sep 7, 2020

Advice sort from HM Government Brand

I flagged this to the HM Government Brand Team, who referred me to Jo Benjafield and Zach Quirk on the accounts team at Design102.

Brand colours do undergo change when departments merge or are newly created. Parent department colours usually derive from the former logo colour before departments were moved over to the new crown brand system. Any agencies that sit within a department often take the parent department's colour.

The colour codes for each department I've been advised can be found in the online guidelines for each department.

Chat with Design102

When talking about this issue specifically it seemed that there was limited knowledge about the websafe versions of the logo colour and speculation around whether they needed to be high contrast. They wondered if the colours could be seen as decorative and therefore didn't require a websafe alternative?

Design102 will inform us of any changes to department colours so we can update.

@36degrees
Copy link
Member Author

They wondered if the colours could be seen as decorative and therefore didn't require a websafe alternative?

The brand colours are used for text links on the organisation pages, like this:
https://www.gov.uk/government/organisations/attorney-generals-office

This means they need to meet colour contrast. As I understand it, that's where we use the websafe colour. Non-websafe for borders, or anything 'decorational', websafe for links or anything that otherwise needs to be perceivable.


Just to illustrate the two issues with examples…

Inconsistency between websafe and non-websafe colours

On https://www.gov.uk/government/organisations/department-for-international-trade the borders are red (#cf102d), but because the websafe colour isblue (#005ea5) the links are our 'old' blue.

Maybe this is intentional, but if that's the case should the blue be updated to the new blue #1d70b8?

Websafe colour sometimes has worse contrast than non-websafe

On https://www.gov.uk/government/organisations/home-office, the borders are the non-websafe #9325b2 with a contrast of 6.5. But the links are 'websafe' and so use #9440b2, giving them a worse contrast of 5.8.

@36degrees
Copy link
Member Author

I think the intention for organisations that have #005ea5 as their websafe colour was that they use the 'default' link colour, which also used to be #005ea5 but was changed to #1d70b8 when we updated the GOV.UK colours.

If that's the case, it may make sense to change all occurences of #005ea5 to #1d70b8.

@edwardhorsford
Copy link
Contributor

I proposed this some years ago, but thoughts on renaming it to contrast-safe or similar? As you note, it's nothing to do with websafe (in the traditional use of the word).

@querkmachine
Copy link
Member

Outside of the discussion of contrast-appropriate colours...

The organisation colours we provide within Frontend, barring the occassional contribution, haven't been updated for some years and don't reflect any departmental rebrandings or machinery of government changes made in the interim.

This means our colours are outdated, our class names are wrong, and the GOV.UK folks have had to resort to either mapping modern departments onto different or older class names (e.g. the page for Business and Trade uses the classes of the defunct DIT), writing their own code to add or overwrite Frontend's colours, or using the wrong colours entirely (e.g. DSIT's page uses the old BEIS brand colour, even though this is not the department colour for DSIT).

This annoys me more than it probably should.

As such, I've collated information from various sources—including Freedom of Information requests, past and present versions of HMG/departmental branding documents, and usage 'in the wild'—in a neat little spreadsheet (internal only).

In it, I've also made some suggestions for colours to use should we update our Sass. It's mostly evolutionary, using the colours already present if they're 'close enough' in most cases, but there are some changes and new introductions (like DSIT cyan!) that we should probably make happen if we can!

Organisation Candidate colour
Attorney General's Office #9f1888
Cabinet Office #005abb
Civil Service #af292e
Department for Business and Trade #e52d13
Department for Business, Energy and Industrial Strategy (defunct) #003479
Department for Business, Innovation and Skills (defunct) #003479
Department for Communities and Local Government (defunct) #009999
Department for Culture, Media and Sport (1997–2017, defunct) #d40072
Department for Culture, Media and Sport (2023–) #d40072
Department for Digital, Culture, Media and Sport (defunct) #d40072
Department for Education #003a69
Department for Energy Security and Net Zero #00a33b
Department for Environment, Food and Rural Affairs #00a33b
Department for International Development (defunct) #002878
Department for International Trade (defunct) #cf102d
Department for Levelling Up, Housing and Communities #012169
Department for Science, Innovation and Technology #00f9f8
Department for Transport #006c56
Department for Work and Pensions #00beb7
Department of Energy and Climate Change (defunct) #009ddb
Department of Health (defunct) #00ad93
Department of Health and Social Care #00ad93
Foreign and Commonwealth Office (defunct) #003e74
Foreign, Commonwealth and Development Office #012169
Government Equalities Office #005abb
HM Government #266ebc
HM Revenue and Customs #009390
HM Treasury #af292e
Home Office #9325b2
Ministry of Defence #4d2942
Ministry of Housing, Communities and Local Government (defunct) #009999
Ministry of Justice #231f20
Northern Ireland Office #002663
Office of the Advocate General for Scotland #002663
Office of the Leader of the House of Commons #317023
Office of the Leader of the House of Lords #9c132e
Office of the Secretary of State for Scotland #002663
Office of the Secretary of State for Wales #a33038
Prime Minister's Office, 10 Downing Street #0b0c0c
Scotland Office (defunct) #002663
UK Export Finance #d0132f
UK Trade and Investment (defunct) #c80651
Wales Office (defunct) #a33038

(This list includes organisations that existed after GOV.UK was created, but which no longer exist, for backwards compatibility.)

@querkmachine querkmachine linked a pull request Mar 23, 2023 that will close this issue
@stevenjmesser stevenjmesser linked a pull request Jan 12, 2024 that will close this issue
@stevenjmesser
Copy link

Does anyone have any recommendations on making this less toil in future? For example, revisiting class names and colours whenever there are machinery of government changes?

What's handy is that we now have a methodology for determining contrast-safe colours (see linked pull request).

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

Successfully merging a pull request may close this issue.

6 participants