Skip to content

Commit

Permalink
Fix IAA banner animation artifacts (#2996)
Browse files Browse the repository at this point in the history
* Animate placeholder to image transition when image isn't a gif/similar

* Migrate accessibility sample

* Use geometryGroup where possible and transformEffect workaround otherwise

* Don't animate setting currentImage

---------

Co-authored-by: crow <[email protected]>
  • Loading branch information
crow and crow authored Feb 22, 2024
1 parent 3d7bcc8 commit b5a8377
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Accessibility Sample/Accessibility Sample/AppView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ struct AppView: View {
systemImage: "square.3.layers.3d.down.left"
)
}.onAppear {
Airship.shared.privacyManager.enableFeatures(.push)
Airship.privacyManager.enableFeatures(.push)
Airship.push.userPushNotificationsEnabled = true
Airship.push.backgroundPushNotificationsEnabled = true
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,12 @@ struct InAppMessageBannerView: View {
let itemSpacing: CGFloat = 16

VStack(spacing:itemSpacing) {
contentBody
if #available(iOS 17.0, macOS 14.0, tvOS 17.0, watchOS 10.0, *) {
contentBody.geometryGroup()
} else {
contentBody.transformEffect(.identity)
}

buttonsView
}.padding([.top, .horizontal], itemSpacing)
.addNub(placement: displayContent.placement,
Expand Down

0 comments on commit b5a8377

Please sign in to comment.