Last active
August 20, 2021 12:25
-
-
Save iSapozhnik/6e920735fda27f2eabdb272d2a4b5348 to your computer and use it in GitHub Desktop.
Pixelated SwiftUI image
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var emailIcon: some View { | |
Image("mail") | |
.resizable() | |
.frame(width: 24, height: 24) | |
.foregroundColor(emailHovered ? .primary : .secondary) | |
.onHover { isHovered in | |
self.emailHovered = isHovered | |
} | |
.onTapGesture { | |
openURL(URL(string: Constants.twitterURLString)!) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment