Last active
September 11, 2023 21:54
-
-
Save unnamedd/0331f65732184ef9bc0d9a41f4cb9709 to your computer and use it in GitHub Desktop.
[SwiftUI] Text + Border Bottom
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 body: some View { | |
Group { | |
Text(language.name) | |
.font(.body) | |
.padding([.leading, .trailing], 10) | |
.padding([.top, .bottom], 5) | |
.background(Color.gray) | |
.overlay( | |
Rectangle() | |
.frame(height: 4) | |
.foregroundColor(.blue), | |
alignment: .bottom | |
) | |
} | |
.cornerRadius(5) | |
.frame(height: 40) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment