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 HTML Publication layout to work with design system columns #3332

Merged
merged 1 commit into from
Sep 17, 2024

Conversation

matthillco
Copy link
Contributor

@matthillco matthillco commented Sep 16, 2024

What

Fix the HTML Publication layout so that it uses the grid layout classes supplied by govuk-frontend. Trello

This commit removes some of the rules that were previously set for the .main-content-container and instead uses the column rules from govuk-frontend.

The .main-content-container has now been renamed as contents-container to be consistent with the contents-list-container. I had hoped to remove this class entirely, but it's required to apply different float rules when in RTL reading mode.

This also adds the new class for collapsing columns to full width when printing.

Why

HTML Publication uses some custom classes for managing its layout, but these more-or-less replicate what’s already available with the row/grid layout classes from the design system. These differences affect our ability to improve generic print styles for rows/columns, as well as being harder to maintain.

@govuk-ci govuk-ci temporarily deployed to government-frontend-pr-3332 September 16, 2024 11:47 Inactive
@matthillco matthillco force-pushed the html-publication-columns-fix branch from b0df4d3 to 1607329 Compare September 16, 2024 11:50
@govuk-ci govuk-ci temporarily deployed to government-frontend-pr-3332 September 16, 2024 11:50 Inactive
This commit removes some of the rules that were previously set for the
`.main-content-container` and instead uses the column rules from
`govuk-frontend`.

The container has now been renamed as `contents-container` to be
consistent with the `contents-list-container`. I had hoped to remove
this class entirely, but it's required to apply different float rules
when in RTL reading mode.

This also adds the new class for collapsing columns to full width
when printing.
@matthillco matthillco force-pushed the html-publication-columns-fix branch from 1607329 to 9019d3d Compare September 17, 2024 10:07
@govuk-ci govuk-ci temporarily deployed to government-frontend-pr-3332 September 17, 2024 10:07 Inactive
@matthillco matthillco merged commit 0d81a3e into main Sep 17, 2024
11 checks passed
@matthillco matthillco deleted the html-publication-columns-fix branch September 17, 2024 11:03
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