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

UHF-9797 standalone cookie page #965

Merged
merged 8 commits into from
Apr 22, 2024

Conversation

Arkkimaagi
Copy link
Contributor

@Arkkimaagi Arkkimaagi commented Apr 17, 2024

UHF-9797

The cookie banner should be able to render itself on a standard page instead of as a banner when conditions are met.

What was done

  • Cookie banner functionality was extended to support the page rendering

How to install

  • Make sure your instance is up and running on latest dev branch.
    • git pull origin dev
    • make fresh
  • Update the HDBT theme
    • composer require drupal/hdbt:dev-UHF-9797_standalone_cookie_page
  • Run make drush-cr

How to test

  • Add a snippet like <p id="hds-cookie-consent-full-page">Keksiasetukset vaativat javascript tuen toimiakseen.</p> to page, for example to paragraph--text.html.twig so that you can see the code on the page.
  • Check that the cookie banner code (cookie-container.html.twig) has settingsPageSelector: '#hds-cookie-consent-full-page', set up.
  • Verify that cookie banner renders on a page without the text paragraph (landing page) as a normal banner.
    • Check that banner version still hides when cookies are set
  • Verify that cookie banner renders on a page with the text paragraph in page.
    • Check that in page version does not get hidden at all
  • Check that code follows our standards

Continuous documentation

  • This feature has been documented/the documentation has been updated
  • This change doesn't require updates to the documentation

Copy link

⚠️ Visual regression found! Please check if this change is wanted or accidental. You can check the output here: https://city-of-helsinki.github.io/drupal-hdbt/pull/965/html_report/

@Arkkimaagi Arkkimaagi force-pushed the UHF-9675_cookie_banner branch from 9217f92 to 489225c Compare April 18, 2024 07:45
@Arkkimaagi Arkkimaagi force-pushed the UHF-9797_standalone_cookie_page branch from 013d8af to c6c2830 Compare April 18, 2024 07:46
@Arkkimaagi Arkkimaagi marked this pull request as ready for review April 22, 2024 10:33
@Arkkimaagi Arkkimaagi merged commit 51d32c8 into UHF-9675_cookie_banner Apr 22, 2024
1 of 2 checks passed
@Arkkimaagi Arkkimaagi deleted the UHF-9797_standalone_cookie_page branch April 22, 2024 10:33
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