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

Shows size of items array in the Settings > Storage tab #45

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

aanand3
Copy link
Contributor

@aanand3 aanand3 commented Jan 7, 2025

Added functionality to show the size of the current entries list in the Settings modal. Addresses #19.

Notes

  • I deliberately left the styling pretty simple, I think by keeping the styling the same as the <Title /> on the left side, it showed that the value had equal importance as the label. It naturally meshed with the other Settings tabs too. Happy to iterate on any feedback.
  • The size will currently show as n bytes and then go to n.nn for KB and above.
  • The empty array is 2 bytes on it's own... so I subtracted 2 from the calculated value.

Let me know your thoughts!
Screenshot 2025-01-07 at 10 43 54 PM

Screenshot 2025-01-07 at 10 45 27 PM

@aanand3
Copy link
Contributor Author

aanand3 commented Jan 8, 2025

@ayoung19 pushed a refac which stores the size in an atom - thanks for the review 🙂

@ayoung19 ayoung19 self-requested a review January 9, 2025 18:32
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.

1 participant