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

Prevent subcomponent type styles from overriding the primary component #3253

Merged
merged 4 commits into from Dec 11, 2019

Conversation

thisisdano
Copy link
Member

@thisisdano thisisdano commented Dec 6, 2019

Now components reliably respect their font settings. Setting values like $theme-footer-font-family should set the font face for the entire component, but some CSS specificity quirks were overriding these values in some instances. Now, setting a component's font face works as expected, with no secret overrides.

@thisisdano thisisdano requested a review from a team December 6, 2019 22:47
@thisisdano thisisdano self-assigned this Dec 6, 2019
@thisisdano thisisdano marked this pull request as ready for review December 6, 2019 22:50
@@ -7,6 +7,10 @@
font-size: font-size($theme-banner-font-family, "3xs");
padding-bottom: units(0);
}

.usa-accordion {
@include typeset($theme-banner-font-family);
Copy link
Contributor

Choose a reason for hiding this comment

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

@thisisdano, this is under the assumption that usa-accordion font could be overridden right?

Copy link
Member Author

Choose a reason for hiding this comment

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

yup — this can be set with the $theme-accordion-font-family theme variable — but in this instance we don't want that value to render, instead we want to render the value of $theme-banner-font-family

because those values happened to be the same in earlier testing, we didn't catch this

@mejiaj mejiaj merged commit 71ec670 into develop Dec 11, 2019
@mejiaj mejiaj deleted the dw-typeface-overrides branch December 11, 2019 14:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants