Closed pinarol closed 2 months ago
App Name | Gravatar SwiftUI Prototype Build | |
Build Number | 1101 | |
Version | 1.0 | |
Bundle ID | com.automattic.gravatar-sdk-demo-swiftui.prototype-build | |
Commit | 53136e93b7ff6de8225b3447eb71865658614378 | |
App Center Build | Gravatar SDK Demo - SwiftUI #42 |
App Name | Gravatar UIKit Prototype Build | |
Build Number | 1101 | |
Version | 1.0 | |
Bundle ID | com.automattic.gravatar-sdk-demo-uikit.prototype-build | |
Commit | 53136e93b7ff6de8225b3447eb71865658614378 | |
App Center Build | Gravatar SDK Demo - UIKit #44 |
One more thing:
On the Horizontal layout, it doesn't seem obvious that I can scroll horizontally when I see 3 avatars aligned on the screen. (Testing on iPhone 15 sim)
The design shows a bit of a 4th avatar appearing from the right. This helps the user see that there's more content and discover the scrolling.
Can we do this also and have this extra bit of 4th avatar appearing independent of the screen width? I know that on UICollectionView we can have a layout based on percentages of the screen, maybe there's a similar thing on SwiftUI 🤔
I made some changes to avoid glitches. The horizontal version uses fixed size avatars now.
Also, I tried calculating the avatar size with the help of GeometryReader to display 3.25 avatars on every device but it is messing up the height of HorizontalAvatarGrid
. I tried setting the height manually but no good way of doing it. So I left it. I made the avatar larger and the space between each avatar smaller. This way it is also more close to the designs. I think this will make it less likely to happen.
Also, it is not great to always show 3.25 avatars, it is causing giant avatars in landscape mode and in ipad. This needs a more sophisticated formula. But the bigger problem is the height of HorizontalAvatarGrid
.
Can you try again? @etoledom
Closes #345
From designs:
Description
Introduces the horizontally scrolling avatars. For now i didn't implement anything interactive like using number of avatars or height of the modal to decide the layout type.
https://github.com/user-attachments/assets/b9476158-388e-4b33-a8d7-31709469e66e
AvatarPickerAvatarView
to be able to use it both from horizontal & vertical grids.Testing Steps