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-9787: Local storage cleanup #961

Merged
merged 6 commits into from
Apr 17, 2024
Merged

UHF-9787: Local storage cleanup #961

merged 6 commits into from
Apr 17, 2024

Conversation

teroelonen
Copy link
Contributor

@teroelonen teroelonen commented Apr 15, 2024

UHF-9787

What was done

  • Add general purpose local storage manager and use it in closable announcements and accordions

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-9787
  • Update the Helfi Platform config
    • composer require drupal/helfi_platform_config:dev-UHF-9787
  • Run make drush-updb drush-cr

How to test

  • Check that the accordion functionality that remembers what accordions you have opened even if you reload the page still works.
  • Check that the announcement hiding functionality that hides the announcements that you have closed still works.
  • Make sure that you get a new local storage row called helfi-settings that gets all the information above.
  • Try breaking it a little since the functionality was heavily refactored.
  • Try adding a local storage row 'hidden-helfi-announcements' and for example 'liikenne-accordion' if you are using KYMP to test the feature. Then refresh the page and check that the browser console says that the two local storage rows were removed. Check that they were actually removed as well.
  • 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

Other PRs

@teroelonen teroelonen changed the title UHF-9787: LocalStorage cleanup UHF-9787: Local storage cleanup Apr 16, 2024
@teroelonen teroelonen marked this pull request as ready for review April 16, 2024 13:17
Copy link
Contributor

@rpnykanen rpnykanen left a comment

Choose a reason for hiding this comment

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

Must update libraries.yml closable announcement version or this won't work. set 1.0 or 1.1

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/961/html_report/

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