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

Fix form element typefaces #156

Merged
merged 1 commit into from
Jul 29, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Fixed

- Further fixed gallery component layout when CSS loads but JS fails
- Buttons using the `<button>` element now have the correct typeface (they were using the browser default)
- Buttons, inputs, selects and textareas now use the correct typeface rather than the browser default

### Security

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,6 @@

appearance: none;

font-size: inherit;
font-weight: inherit;
line-height: inherit;

background-color: transparent;
Expand Down
2 changes: 1 addition & 1 deletion src/nationalarchives/components/button/button.scss
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ $button-border-width: 4px !default;
cursor: pointer;

@include typography.font-size(18);
@include typography.main-font(true);
@include typography.main-font-weight-bold;

@include colour.colour-background("button-background");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@

@include colour.always-light;
@include colour.colour-font("input-foreground");
font-size: inherit;
line-height: 2rem;

@include colour.colour-background("input-background");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@

@include colour.always-light;
@include colour.colour-font("input-foreground");
@include typography.detail-font;
font-size: inherit;
line-height: 2rem;

@include colour.colour-background("input-background");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@

@include colour.always-light;
@include colour.colour-font("input-foreground");
font-size: inherit;
line-height: 2rem;

@include colour.colour-background("input-background");
Expand Down
1 change: 0 additions & 1 deletion src/nationalarchives/components/select/select.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@

@include colour.always-light;
@include colour.colour-font("input-foreground");
font-size: inherit;
line-height: 2rem;

@include colour.colour-background("input-background");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@

@include colour.always-light;
@include colour.colour-font("input-foreground");
font-size: inherit;
line-height: 2rem;

@include colour.colour-background("input-background");
Expand Down
2 changes: 0 additions & 2 deletions src/nationalarchives/components/textarea/textarea.scss
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ $textarea-vertical-padding: 0.25 !default;
display: block;
box-sizing: border-box;

font-family: inherit;
font-size: inherit;
line-height: 1.5rem;

border-radius: 0.1px;
Expand Down
8 changes: 8 additions & 0 deletions src/nationalarchives/utilities/_reset.scss
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,14 @@ canvas {
display: block;
}

button,
input,
select,
textarea {
font-family: inherit;
font-size: inherit;
}

[hidden] {
display: none !important;
}
Expand Down