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

Update label margins to match fieldsets and align with GOV.UK #946

Merged
merged 6 commits into from
May 14, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# NHS.UK frontend Changelog

## Unreleased

:wrench: **Fixes**
- Align label bottom margins with fieldset legend bottom margins ([PR 946](https://github.com/nhsuk/nhsuk-frontend/pull/946)).


## 8.1.1 - 14 March 2024

:wrench: **Fixes**
Expand Down
29 changes: 7 additions & 22 deletions packages/components/label/_label.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,45 +10,30 @@
}

/* Modifiers that make labels look more like their equivalent headings */

.nhsuk-label--xl {
@include nhsuk-typography-responsive(48);

display: block;
.nhsuk-label--xl,
.nhsuk-label--l,
.nhsuk-label--m {
font-weight: $nhsuk-font-bold;
margin-top: 0;
margin-bottom: nhsuk-spacing(3);
}

@include nhsuk-responsive-margin(7, "bottom");
.nhsuk-label--xl {
@include nhsuk-typography-responsive(48);
}

.nhsuk-label--l {
@include nhsuk-typography-responsive(32);

display: block;
font-weight: $nhsuk-font-bold;
margin-top: 0;

@include nhsuk-responsive-margin(4, "bottom");
}

.nhsuk-label--m {
@include nhsuk-typography-responsive(24);

display: block;
font-weight: $nhsuk-font-bold;
margin-top: 0;

@include nhsuk-responsive-margin(4, "bottom");
}

.nhsuk-label--s {
@include nhsuk-typography-responsive(19);

display: block;
font-weight: $nhsuk-font-bold;
margin-top: 0;

@include nhsuk-responsive-margin(4, "bottom");
}

// When the label is nested inside a heading, override the heading so that it
Expand Down
Loading