-
-
Notifications
You must be signed in to change notification settings - Fork 775
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
feat: Redesign the patches screen #2381
base: compose-dev
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll leave a review purely on what I saw in the PR body and leave the rest to the other reviewers:
- I think in the patching screen the progress bar is at the top, however in the patch selector screen it is at the bottom, perhaps this is a consistency issue we want to avoid
- The progress bar in the patch selector screen makes it look like you wanna have all patches. "Reaching 100%". However this probably isn't what we want to imply via the UI
LGTM apart from that
I can remove the progress bar from the bottom and keep the |
Satisfies the issues I mentioned 👍 |
Updated the screenshot and the video showcase according to requested changes |
Not a problem at all, as long as everyone agrees |
Works for me and avoids this label at the top aligned to the right 👍 LGTM apart from that based on the visuals. |
This comment was marked as spam.
This comment was marked as spam.
app/src/main/java/app/revanced/manager/ui/screen/PatchesSelectorScreen.kt
Outdated
Show resolved
Hide resolved
val rotation = remember { Animatable(0f) } | ||
LaunchedEffect(searchExpanded) { | ||
val direction = if (searchExpanded) 360f else 0f | ||
|
||
rotation.animateTo( | ||
targetValue = direction, | ||
animationSpec = tween(durationMillis = 400, easing = EaseInOut) | ||
) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't animateFloatAsState
work for this?
val rotation by animateFloatAsState(
if (searchExpanded) 360f else 0f,
remember { tween(durationMillis = 400, easing = EaseInOut) }
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're right, this is just a leftover from a different type of animation I was testing with. Why remember the animation spec? First time seeing that, not gonna lie
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The source code for the animate*AsState
functions use remember
or global private val
s for the default animation spec. Probably doesn't make a difference though.
app/src/main/java/app/revanced/manager/ui/screen/PatchesSelectorScreen.kt
Outdated
Show resolved
Hide resolved
How do we handle the FAB patch count if the FAB is not expanded? |
I think then the count being hidden is fine? If not, maybe disable shrinking (unless that goes against spec) |
Just hide it, as it is in the current version |
This redesigns the patcher screen to reduce clutter. The search bar is now expandable, the patch count is displayed in a bottom bar and the reset button floats neatly above the save button. I added a clear button to the search bar to clear the queries. The filter chips now have a checkmark when selected and the filters have been reworded.
New patcher screen in action:
Screen_recording_20250109_003652.webm