alphagov / alphagov/tech-docs-gem

[Enhancement]: Implement the Generic header component into an 'unbranded' version of the tech docs

Open
#516 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Ruby
Stars
16
Forks
47
Avg merge
1d 21h
Merged PRs (30d)
14

Description

What should change?

Add a feature that allows tech docs to toggle using the GOV.UK header and the Generic header. Additionally tie this into automatically using a font other than Transport.

User need

In GOV.UK Frontend v6.3.0, the design system team released the Generic header component, along with accompanying tech guidance on removing GOV.UK branding from a GOV.UK service. This is for services that might be part of UK government digital and would therefore benefit from using the design system, but aren't part of GOV.UK and therefore aren't entitled to use its branding.

We know that some tech docs are part of a user facing GOV.UK service, but some aren't eg: internal docs or docs for non-GOV.UK services. A holistic 'turn off the branding' toggle would enable that latter group to more easily use the tech docs and customise them to fit their needs without infringing on the GOV.UK branding.

Proposed solution

The API could be:

  • a boolean option with an extra text/html option to specify a unique logo
  • just the unique logo option

Both these interact nicely with https://github.com/alphagov/tech-docs-gem/pull/435

This would swap the header block class from govuk-header to govuk-generic-header.

This could also render the specified unique logo next to the :service_name if present, as the Generic header doesn't include an option for a product name.

As well as setting the header, this could also reset the font. The best solution I've come up with for this is loading a separate stylesheet that re-specifies $govuk-font-family, which feels wasteful.

I also think that as part of this we should deprecate and remove :show_govuk_logo as the logic for this could be replaced by the above proposal.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the existing header rendering and the :show_govuk_logo option, then review the GOV.UK Generic header guidance and the interaction with pull request #435. Done means tech docs can switch between GOV.UK and Generic headers, support the proposed logo behavior, use an appropriate font, and provide a replacement or deprecation path for :show_govuk_logo.

Written by the indexing model from the issue text.

Assessment

Tech stack
ruby, sass
Domain
design, frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.