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

Rename custom SCSS class #526

Merged
merged 1 commit into from
Nov 15, 2023
Merged

Rename custom SCSS class #526

merged 1 commit into from
Nov 15, 2023

Conversation

Cruikshanks
Copy link
Member

https://eaflood.atlassian.net/browse/WATER-4131

When working on Fix display of credit transactions in bill views after adding the missing - to credit values we found the UI was wrapping it after the sign, for example

      -
£126.74

We knew we could fix this by updating the CSS for the class to include white-space: nowrap;. The issue was where do we add it. We wasted a bunch of time trying to find the class govuk-table__cell--total in the design system code. Finally, we tracked it now to a custom class we'd added.

This change is about not making that mistake again and trying to set a precedent. From now on, if we have to add a custom class we should not prefix it with govuk so we can distinguish between our code and that provided by GDS.

https://eaflood.atlassian.net/browse/WATER-4131

When working on [Fix display of credit transactions in bill views](#522) after adding the missing `-` to credit values we found the UI was wrapping it _after_ the sign, for example

```
      -
£126.74
```

We knew we could fix this by updating the CSS for the class to include `white-space: nowrap;`. The issue was where do we add it. We wasted a bunch of time trying to find the class `govuk-table__cell--total` in the design system code. Finally, we tracked it now to a custom class we'd added.

This change is about not making that mistake again and trying to set a precedent. From now on, if we have to add out own custom class we should ***not*** prefix it with `govuk` so we can distinguish between our own code and that provided by GDS.
@Cruikshanks Cruikshanks added the housekeeping Refactoring, tidying up or other work which supports the project label Nov 14, 2023
@Cruikshanks Cruikshanks self-assigned this Nov 14, 2023
@Cruikshanks Cruikshanks marked this pull request as ready for review November 15, 2023 00:02
@Cruikshanks Cruikshanks merged commit c386550 into main Nov 15, 2023
6 checks passed
@Cruikshanks Cruikshanks deleted the rename-custom-class branch November 15, 2023 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
housekeeping Refactoring, tidying up or other work which supports the project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant