-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Fix: Reduce logo size and ensure it resizes dynamically and fits all screen sizes #8710
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
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.
@SttApollo This implementation reduces the logo size across all screen sizes, which diverges from the original design intention of making it prominent. To fix this, I suggest two changes:
- Slighlty reduce the logo size from its original values to have more room in general.
- Only use the shrinking logic when a certain maxWidth threshold is reached.
(Optional) Given the impracticality of fitting all page elements on every screen size, especially very small phones and in landscape mode, I think it would be more effective to use a scroll indicator in these cases.
Hii @wmontwe - thank you for your patience. I slightly reduced the logo size and added a custom scroll indicator ( I couldn't find it in the project files and wasn't sure if I could add additional libraries). Below are additional notes, brief screen recordings and screenshots to explain this implementation. Please let me know your thoughts and I'll adjust accordingly again, as needed.
|
…icator appears correctly in WelcomeContent.kt
be236de
to
0910586
Compare
Hi @wmontwe! I was trying to make sure the commit passes detekt, so I moved the scroll indicator function to a different file and shortened the welcome content. Do you want me to keep working on these changes or revert to the last commit state? |
@SttApollo I rebased the pull-request on the latest version of main. I tried the solution, but I see some performance issues with the scroll indicator that causes compose to redraw a lot. I checked if there is another solution available, but not really. Worst case without the indicator, but I would like to look into it a bit. |
Sounds good - I'll hold until further. Perhaps, I can look at other bugs I can be assigned to. |
@wmontwe any updates on this? I know you've been out a bit, when you have a chance to get back to it I'd appreciate! |
@SttApollo Unfortunately, my attempts to enhance the scroll indicator were unsuccessful. It seems this requires significant efforts and should be a separate task. I think it's best to remove it for now and I have a look at the version without scroll indicator.
Is there a specific area of interest (UI etc)? |
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 think the size changes are working very good. Just the logo and title should be part of the header section. The Box around the layout is not needed, as it prevents the list to draw it's content to full screen size.
You could fix the formatting issues by running ./gradlew spotlessApply
. Run ./gradlew detekt
to find other issues.
@@ -1,5 +1,6 @@ | |||
package app.k9mail.feature.onboarding.welcome.ui | |||
|
|||
|
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 guess your using a different code format. Just run ./gradlew spotlessApply
to streamline your changes with our code format. If you update the branch to current main, Spotless is also way quicker.
...nboarding/welcome/src/main/kotlin/app/k9mail/feature/onboarding/welcome/ui/WelcomeContent.kt
Outdated
Show resolved
Hide resolved
...nboarding/welcome/src/main/kotlin/app/k9mail/feature/onboarding/welcome/ui/WelcomeContent.kt
Outdated
Show resolved
Hide resolved
...nboarding/welcome/src/main/kotlin/app/k9mail/feature/onboarding/welcome/ui/WelcomeContent.kt
Show resolved
Hide resolved
...nboarding/welcome/src/main/kotlin/app/k9mail/feature/onboarding/welcome/ui/WelcomeContent.kt
Outdated
Show resolved
Hide resolved
...nboarding/welcome/src/main/kotlin/app/k9mail/feature/onboarding/welcome/ui/WelcomeContent.kt
Outdated
Show resolved
Hide resolved
...nboarding/welcome/src/main/kotlin/app/k9mail/feature/onboarding/welcome/ui/WelcomeContent.kt
Outdated
Show resolved
Hide resolved
...nboarding/welcome/src/main/kotlin/app/k9mail/feature/onboarding/welcome/ui/WelcomeContent.kt
Outdated
Show resolved
Hide resolved
...nboarding/welcome/src/main/kotlin/app/k9mail/feature/onboarding/welcome/ui/WelcomeContent.kt
Outdated
Show resolved
Hide resolved
...nboarding/welcome/src/main/kotlin/app/k9mail/feature/onboarding/welcome/ui/WelcomeContent.kt
Outdated
Show resolved
Hide resolved
Co-authored-by: Wolf-Martell Montwé <hi@wolfmontwe.com>
@wmontwe thank you, done! |
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.
Thank you!
Fixes #8458
Description
This PR addresses #8458 where the logo on the onboarding screen flattened the text below. The
WelcomeLogo
composable has been updated to ensure dynamic resizing usingBoxWithConstraints
ensuring that the logo scales proportionally based on screen dimensions and fits properly without overlapping or pushing other components off-screen.Changes Made
WelcomeLogo
to useBoxWithConstraints
for adaptive sizing.LazyColumnWithHeaderFooter
components are unaffected by the logo's size.Testing
Visual Example