nhsuk / nhsuk-service-manual-community-backlog

This is a place for digital teams in the NHS to work together and develop the NHS digital service manual.
https://service-manual.nhs.uk/community-and-contribution
62 stars 5 forks source link

'Select' Component style varies between chromium and firefox browsers #527

Open TomGNorris opened 4 months ago

TomGNorris commented 4 months ago

What is the problem?

Viewing the select component in the design system shows different styling between firefox, safari and chromium browsers.

Firefox/Safari: image

Chromium: image

This is resulting in some styling on NHS services (e.g. Register with a GP) being customised/overridden to avoid the greyed out appearance which looks like the dropdown is disabled.

Bugs

Expectation: Styling of the dropdown to be consistent with a white background in the dropdown on all core browsers.

Reality: Styling of the dropdown appears differently between firefox/safari (where it appears with a grey #e4e4e8 background) and chromium based browsers e.g. Arc, Chrome, Edge (where it appears with a white background)

Reproducing the bug

Steps to reproduce it:

  1. Open https://service-manual.nhs.uk/design-system/components/select with a chromium based browser and either firefox/safari
  2. Observe the background colour of the dropdown in the specimen component card

Attachments

Firefox/Safari: image

Chromium: image

anandamaryon1 commented 4 months ago

Thanks for raising this. It is happening because the select styling depends on the browser and OS, so it looks even more different on macOS in safari for example.

However, the fact that it looks like it is disabled when compared with our other form elements (eg. a text input) is an issue, and one that GOV.UK seem to have fixed a while back: https://github.com/alphagov/govuk-frontend/pull/2524

frankieroberto commented 4 months ago

I’m seeing a different variant again in Safari (version 17.4 on MacOS):

Screenshot 2024-06-27 at 22 42 51