Visitar URL original
Utilize $theme-font-weight-bold variable for customizing bold font-weight by sawyerh · Pull Request #3811 · uswds/uswds · GitHub
Skip to content

Utilize $theme-font-weight-bold variable for customizing bold font-weight - #3811

Merged
thisisdano merged 1 commit into
uswds:developfrom
navapbc:sawyerh/themeable-bold-font-weight
Dec 8, 2020
Merged

thisisdano merged 1 commit into
uswds:developfrom
navapbc:sawyerh/themeable-bold-font-weight

Conversation

@sawyerh

@sawyerh sawyerh commented Nov 5, 2020 •

Copy link
Copy Markdown
Contributor

Description

This addresses an issue where sites could not theme the weight value for "bold" using $theme-font-weight-bold.

"bold" maps to 700. This is an issue if a site is using a custom font that is not part of the USWDS and has a non-standard weight value (like 550).

Additional information

This was discovered why working a site that pretty heavily themes USWDS since it's a state govt website with their own unique branding. They utilize a variable font and "bold" is closer to 550.

In my Sass, I've set $theme-global-content-styles: true and $theme-font-weight-bold: 550 however all of the headings still output font-weight: bold. I would expect them to output font-weight: 550 instead. This change should enable that.

image

  • Follow the 18F Front End Coding Style Guide and Accessibility Guide.
  • Run npm test and make sure the tests for the files you have changed have passed.
  • Run your code through HTML_CodeSniffer and make sure it’s error free.
  • Title your pull request using this format: [Website] - [UI component]: Brief statement describing what this pull request solves.

@sawyerh sawyerh changed the title Utilize theme variable for bold font-weight Utilize $theme-font-weight-bold variable for customizing bold font-weight Nov 5, 2020
@sawyerh

sawyerh commented Nov 16, 2020

Copy link
Copy Markdown
Contributor Author

@mejiaj Just confirming, no further action needed on my end for this? Couldn't tell why the federalist/build step wasn't running.

@mejiaj

mejiaj commented Nov 20, 2020

Copy link
Copy Markdown
Contributor

@sawyerh no, you shouldn't have to do anything on your part. Just needs final review and pulled into a branch from @uswds/core to get the build working.

@thisisdano
thisisdano merged commit 6f45ee1 into uswds:develop Dec 8, 2020
@sawyerh
sawyerh deleted the sawyerh/themeable-bold-font-weight branch December 12, 2020 19:40
@thisisdano thisisdano mentioned this pull request Dec 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants