Last active
December 11, 2021 02:08
-
-
Save ZevEisenberg/05c417256aa10e120c0619ab9a014226 to your computer and use it in GitHub Desktop.
This file contains 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
import SwiftUI | |
struct ContentView: View { | |
var body: some View { | |
NicerButton(action: {}, label: { isPressed in | |
Text("Rabbit Season") | |
.foregroundColor(Color.white) | |
.frame(width: 200) | |
.padding() | |
.background(Color.blue.brightness(isPressed ? -0.3 : 0)) | |
}) | |
} | |
} | |
struct ContentView_Previews: PreviewProvider { | |
static var previews: some View { | |
ContentView() | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment