-
Notifications
You must be signed in to change notification settings - Fork 641
Open
Description
Describe the bug
We have been updating for iOS 26 and have added a few UIVisualEffectViews with the glass effect to some elements. When re-recording the snapshots we noticed that the views are recorded as a solid dark grey or black color. Tinkering around it seems that this is related to the tint color on the visual effect view. If I remove the tint color, then the view is recorded correctly. It only seems to be an issue when adding a tint color.
private lazy var visualEffectView: UIVisualEffectView = {
let visualEffectView = UIVisualEffectView()
if #available(iOS 26, *) {
let glassEffect = UIGlassEffect()
glassEffect.tintColor = SystemColors.Surface.Neutral.default // this line causes the recording issue
visualEffectView.effect = glassEffect
visualEffectView.cornerConfiguration =
.corners(radius: UICornerRadius(floatLiteral: Constants.cornerRadius))
}
visualEffectView.translatesAutoresizingMaskIntoConstraints = false
return visualEffectView
}()Screenshots
This is what is recorded when using a tint color on the visual effect view. The tint color used here was white.
Expected snapshot. This is recorded with the glass effect, but no tint color. I added a white background for the snapshot since the background is clear by default.
Environment
- swift-snapshot-testing version 1.18.6
- Xcode 26 RC
- Swift 5.10
- OS: iOS 26
MatthewFolbigg, jvanderwee, akaDuality and nicholaslythall
Metadata
Metadata
Assignees
Labels
No labels