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

store current color selections in local browser storage #585

Merged
merged 13 commits into from
Oct 22, 2024

Conversation

interim17
Copy link
Contributor

Time estimate or Size

x-small

Problem

Closes #580, advances #511

Solution

Store user color selections as UIDisplayData in local storage in the browser.

Behavior is limited in current scope, no need to store defaults, and no application of any stored settings.

Whenever a user applies a color change, store a snapshot of the current color selections in local storage, using simularium file name as key.

Steps to Verify:

  1. Open dev tools Application tab, storage.
  2. Make a color change, key: value of current trajectory name and current color selections should be in local storage.

@interim17 interim17 marked this pull request as ready for review October 15, 2024 19:55
@interim17 interim17 requested a review from a team as a code owner October 15, 2024 19:55
@interim17 interim17 requested review from toloudis and tyler-foster and removed request for a team October 15, 2024 19:55
Copy link
Contributor

@toloudis toloudis left a comment

Choose a reason for hiding this comment

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

is there code to load them back in?

Base automatically changed from feature/user-colors to main October 22, 2024 18:53
Copy link

Coverage report

St.
Category Percentage Covered / Total
🟡 Statements
66.24% (-0.1% 🔻)
675/1019
🟡 Branches 65.31% 96/147
🔴 Functions 35% 91/260
🟡 Lines
64.62% (-0.1% 🔻)
601/930

Test suite run success

121 tests passing in 7 suites.

Report generated by 🧪jest coverage report action from e87d5d3

@interim17 interim17 merged commit 4ad009a into main Oct 22, 2024
6 checks passed
@interim17 interim17 deleted the feature/local-storage branch October 22, 2024 18:58
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.

ability to store current ui display data in local storage
3 participants