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

Tweak whitespace HTML for text input component to improve readability #2475

Merged
merged 2 commits into from
Dec 22, 2021

Conversation

vanitabarrett
Copy link
Contributor

Tweak the input component nunjucks macro slightly to improve the whitespace of the output HTML so that:

Before vs After (default input example)

Before:
Screenshot 2021-12-14 at 14 36 57

After:
Screenshot 2021-12-14 at 14 37 03

Before vs After (input with prefix and suffix)

Before:
Screenshot 2021-12-14 at 14 36 29

After:
Screenshot 2021-12-14 at 14 36 37

@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-frontend-pr-2475 December 14, 2021 14:38 Inactive
@vanitabarrett vanitabarrett changed the title Tweak whitespace for input component HTML Tweak whitespace in input component HTML for improved readability Dec 21, 2021
@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-frontend-pr-2475 December 21, 2021 16:47 Inactive
@vanitabarrett vanitabarrett requested a review from a team December 21, 2021 16:48
Copy link
Contributor

@36degrees 36degrees left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this makes sense – just a minor issue re heading levels in the changelog.

We should keep an eye out for feedback from those using our fixtures – hopefully most will be testing in a way that's forgiving of whitespace changes, but otherwise this sort of 'tweaking' might create extra work for them.

CHANGELOG.md Outdated Show resolved Hide resolved
@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-frontend-pr-2475 December 22, 2021 09:28 Inactive
Vanita Barrett added 2 commits December 22, 2021 09:29
Tweak the input component nunjucks macro slightly to improve
the whitespace of the output HTML so that:

- the closing `div` for the form group is on a new line
(fixes alphagov/govuk-design-system#1939)
- there is no unecessary whitespace between the `govuk-input__wrapper`
and `govuk-input__prefix` or `govuk-input__suffix`
@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-frontend-pr-2475 December 22, 2021 09:30 Inactive
@vanitabarrett vanitabarrett merged commit de237af into main Dec 22, 2021
@vanitabarrett vanitabarrett deleted the whitespace-input branch December 22, 2021 09:39
@EoinShaughnessy EoinShaughnessy changed the title Tweak whitespace in input component HTML for improved readability Tweak whitespace HTML for text input component to improve readability Feb 1, 2022
@owenatgov owenatgov mentioned this pull request Feb 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging this pull request may close these issues.

3 participants