nhsuk-frontend icon indicating copy to clipboard operation
nhsuk-frontend copied to clipboard

Use fallback font if not including NHS font face

Open jacksonj04 opened this issue 2 years ago • 1 comments

Description

There is a configuration option $nhsuk-include-font-face which controls if the NHS corporate font is included in the compiled CSS. In the current implementation, if this option is false then font-face is not set at all, which leads to unstyled text.

This change makes it so that if the fonts are not included, a font-face declaration is still made using only the fallback fonts (as set in $nhsuk-font-fallback).

Checklist

jacksonj04 avatar May 10 '22 10:05 jacksonj04

Not passing judgement on this either negatively or positively, but just wanted to link to this pull request which has some background to why it is like it is right now, i.e. mimicing the way it works in govuk-frontend. And to note that whatever path is taken here needs to be compatible with the needs from this thread - where someone is self hosting the nhs fonts.

https://github.com/nhsuk/nhsuk-frontend/pull/732

andymantell avatar May 10 '22 11:05 andymantell