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

Style accordion and tabs text content with govuk-body class #2723

Merged
merged 5 commits into from Jul 22, 2022

Conversation

vanitabarrett
Copy link
Contributor

Fixes #2703

What

Wraps content.text and panel.text in a paragraph with the govuk-body class when passed into the accordion and tabs component respectively. A user can pass in content.html or panel.html if they need something more custom.

Why

Passing in content.text or panel.text meant displaying text in the default font as it wasn't being styled.

Before vs After (accordion)

Screenshot 2022-07-22 at 10 54 40

Screenshot 2022-07-22 at 10 23 18

Before vs After (tabs)

Screenshot 2022-07-22 at 10 27 54

Screenshot 2022-07-22 at 10 28 50

@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-frontend-pr-2723 July 22, 2022 10:01 Inactive
@owenatgov owenatgov self-requested a review July 22, 2022 10:03
Copy link
Contributor

@owenatgov owenatgov left a comment

Choose a reason for hiding this comment

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

Code looks sharp. Needs a changelog entry then I'll approve.

@vanitabarrett vanitabarrett changed the title Style accordion and tabs text content Style accordion and tabs text content with govuk-body class Jul 22, 2022
@govuk-design-system-ci govuk-design-system-ci temporarily deployed to govuk-frontend-pr-2723 July 22, 2022 10:08 Inactive
Copy link
Contributor

@owenatgov owenatgov left a comment

Choose a reason for hiding this comment

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

✅ Also approved the Percy build

@vanitabarrett vanitabarrett merged commit 29355be into main Jul 22, 2022
@vanitabarrett vanitabarrett deleted the component-unstyled-text branch July 22, 2022 10:20
@querkmachine querkmachine mentioned this pull request Aug 9, 2022
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.

Accordion content.text doesn't render with the right font
3 participants