This PR aims to review and rewrite both the CityCoins UI auth management and user state.
The main goals are to:
~implement the CityCoins API for all read-only data calls~
~use jotai atoms for state management across components~
~eliminate the "per-city" page by using "selected city" state instead~
This will resolve a few open issues, speed up the load times, and create a more consistent experience that can be built on top of. Definitely still a WIP - collaborators are welcome!
Update: After trying out a few ways to approach data storage and transitions, patterns are emerging! The mining and stacking activity components are a great example of fetching, computing, and storing data. If the block height is updated then data is automatically fetched again.
There are definitely some optimizations to be had here, but it's a great start and will let me focus on the action pages to bring this back to life.
Done
[x] finished variable/color selection for light/dark mode (not active/implemented)
[x] rewrote auth system and user data using jotai atoms (issue: persist with refresh)
[x] determine method/structure to fetch and store city data from API
[x] determine method/structure to indicate city selection in UI
[x] re-implement header logo
[x] re-implement content router
[x] implement rate limiting on all requests to avoid 429 errors
[x] dashboard: mining claims
[x] atom data doesn't persist on refresh (localStorage?)
Moved known issues to #129 to track for future PRs.
This PR aims to review and rewrite both the CityCoins UI auth management and user state.
The main goals are to:
This will resolve a few open issues, speed up the load times, and create a more consistent experience that can be built on top of. Definitely still a WIP - collaborators are welcome!
Update: After trying out a few ways to approach data storage and transitions, patterns are emerging! The mining and stacking activity components are a great example of fetching, computing, and storing data. If the block height is updated then data is automatically fetched again.
There are definitely some optimizations to be had here, but it's a great start and will let me focus on the action pages to bring this back to life.
Done
Moved known issues to #129 to track for future PRs.
Fixes #126 Fixes #120 Fixes #117 Fixes #102