Skip to content

Fix Sidebar Not Refreshing in Splits Selection#1050

Merged
CryZe merged 1 commit intoLiveSplit:masterfrom
CryZe:sidebar-refresh-bug
Apr 14, 2025
Merged

Fix Sidebar Not Refreshing in Splits Selection#1050
CryZe merged 1 commit intoLiveSplit:masterfrom
CryZe:sidebar-refresh-bug

Conversation

@CryZe
Copy link
Collaborator

@CryZe CryZe commented Apr 14, 2025

When the splits selection view is open, the sidebar and the view itself don't refresh properly anymore when in mobile mode. This is because the React compiler notices that with the way we wrote the code, these components have no reason to re-render. There is currently no proper useMobile hook. So while I implemented a quick workaround here, by forcing it to not memoize the individual props properly, we should refactor the sidebar code at some point to use a proper useMobile hook.

When the splits selection view is open, the sidebar and the view itself
don't refresh properly anymore when in mobile mode. This is because the
React compiler notices that with the way we wrote the code, these
components have no reason to re-render. There is currently no proper
`useMobile` hook. So while I implemented a quick workaround here, by
forcing it to not memoize the individual props properly, we should
refactor the sidebar code at some point to use a proper `useMobile`
hook.
@CryZe CryZe added enhancement A new feature or general improvement to LiveSplit One. UI The issue is about the user interface. high priority This is a high priority issue. labels Apr 14, 2025
@CryZe CryZe enabled auto-merge (squash) April 14, 2025 18:45
@CryZe CryZe linked an issue Apr 14, 2025 that may be closed by this pull request
@CryZe CryZe merged commit d0e37b8 into LiveSplit:master Apr 14, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement A new feature or general improvement to LiveSplit One. high priority This is a high priority issue. UI The issue is about the user interface.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Menu is not responsive and does not open from button on splits screen

1 participant