Skip to content
This repository has been archived by the owner on Feb 22, 2023. It is now read-only.
This repository has been archived by the owner on Feb 22, 2023. It is now read-only.

Store filter state in cookie #508

Closed
1 task
sarayourfriend opened this issue Dec 9, 2021 · 3 comments
Closed
1 task

Store filter state in cookie #508

sarayourfriend opened this issue Dec 9, 2021 · 3 comments
Labels
🕹 aspect: interface Concerns end-users' experience with the software ✨ goal: improvement Improvement to an existing user-facing feature 🟩 priority: low Low priority and doesn't need to be rushed 🚦 status: awaiting triage Has not been triaged & therefore, not ready for work

Comments

@sarayourfriend
Copy link
Contributor

Problem

Currently the filter "open" state is stored in local storage. This means that for SSR requests, we don't know whether to render the filters open or closed, so we always render them closed. For SSR pages, this means that if the filters are set to open in local storage, there's a brief period of time when the page first loads where the filters will be closed and after the page starts loading, will completely reflow to open the filters.

Description

There might be a more elegant way to do this but I was thinking we could store this state in a cookie instead of local storage, so that when the page is being rendered on the server we'd be able to read out the open/closed state there.

Alternatives

I'm not sure of any but there's very well could be a more elegant solution to this problem.

Implementation

  • 🙋 I would be interested in implementing this feature.
@sarayourfriend sarayourfriend added 🟩 priority: low Low priority and doesn't need to be rushed 🚦 status: awaiting triage Has not been triaged & therefore, not ready for work ✨ goal: improvement Improvement to an existing user-facing feature 🕹 aspect: interface Concerns end-users' experience with the software labels Dec 9, 2021
@obulat
Copy link
Contributor

obulat commented Dec 10, 2021

I like the idea of having the required state known before rendering. I wonder if we really need to have the filter saved 🤔 Maybe, @panchovm knows more about our previous user research: do the users want to have the filter sidebar state saved?

@fcoveram
Copy link

I checked the research outcome from the interviews we ran, and I found nothing related to filter preferences. However, filters were mentioned as crucial for narrowing the results. Therefore, I prefer to show filters open and show beforehand the options.

@zackkrida zackkrida assigned zackkrida and unassigned zackkrida Jan 7, 2022
@sarayourfriend
Copy link
Contributor Author

Closing as we currently default to a closed filter sidebar and we'd like to avoid using cookies for anything for the time being.

@krysal krysal closed this as completed Feb 4, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
🕹 aspect: interface Concerns end-users' experience with the software ✨ goal: improvement Improvement to an existing user-facing feature 🟩 priority: low Low priority and doesn't need to be rushed 🚦 status: awaiting triage Has not been triaged & therefore, not ready for work
Projects
None yet
Development

No branches or pull requests

5 participants