-
Notifications
You must be signed in to change notification settings - Fork 5
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
QE: Share image #572
base: trunk
Are you sure you want to change the base?
QE: Share image #572
Conversation
📲 You can test the changes from this Pull Request in Gravatar Prototype Build by scanning the QR code below to install the corresponding build.
|
# Conflicts: # Demo/Gravatar-Demo.xcodeproj/project.pbxproj
@@ -30,8 +31,7 @@ class AvatarPickerViewModel: ObservableObject { | |||
@Published var selectedAvatarURL: URL? | |||
@Published private(set) var backendSelectedAvatarURL: URL? | |||
@Published private(set) var gridResponseStatus: Result<Void, Error>? | |||
|
|||
let grid: AvatarGridModel = .init(avatars: []) | |||
@Published private(set) var grid: AvatarGridModel = .init(avatars: []) |
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.
This should have been a @Published
var from the beginning imo. Otherwise the UI can fail to get updated properly.
⛏️ small adjustment We will want to append an ellipsis to the "Share" menu item:
|
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.
In the simulator, the context menu seems to work fine. But on a physical device, tapping the menu selects the image as an avatar. Once it is selected, then the menu is tappable
I test in the real device as well. Maybe the tapping area wasn't big enough for you and we need to make it a bit bigger 🤔 |
The problem seems to be related with iOS 17.x. Putting the Menu in the overlay doesn't seem to work there. I made a fix. Feel free to check again. @andrewdmontgomery and good catch 🎉 |
Closes #566
Description
Opens a share sheet via the avatar menu. Downloads the image in full size before that. Otherwise the share sheet doesn't share the image. Also adding the URL because then the metadata is captured by the system and automatically displayed in the share sheet's navigation bar.
Discussion
I wonder how you feel about the medium detent for the share sheet. I added it to be able to test it, but not sure how I feel about it. Please also test the full size sheet by just commenting out
.presentationDetentsIfAvailable([.medium, .large])
and compare.Testing Steps
Test with both horizontal and vertical layouts.
Try different color schemes.
Test an error case like for example turn off internet.
Demo app > Quick Editor > Avatar ... menu > Share