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

Add handling of for_static parameter #4255

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

KludgeKML
Copy link
Contributor

  • original behaviour was to always include wrapper class unless show_account_layout or custom_layout was present (custom layout is as of yet not used). Alter behaviour so that default is not to have the wrapper, and it's only included if for_static is true.

What

Why

layout_for_public does not behave like a standard layout - it's default is to include a wrapper element which is cut out by slimmer and replaced with the wrapper from the client app. If we try to use layout_for_public directly, this results in a double wrapper (or a single wrapper, but without the ability to add classes to it). Adding a parameter which maintains this behaviour (which can be added in Static: alphagov/static#3440 ), but defaulting to not including the wrapper element allows other apps to use the layout component directly.

https://trello.com/c/COQYfYgn/347-allow-layoutforpublic-to-work-like-a-normal-layout

Visual Changes

None expected

- original behaviour was to always include wrapper class unless show_account_layout or custom_layout was present (custom layout is as of yet not used). Alter behaviour so that default is not to have the wrapper, and it's only included if for_static is true.
@govuk-ci govuk-ci temporarily deployed to components-gem-pr-4255 September 24, 2024 13:36 Inactive
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.

2 participants