Last active
May 16, 2020 21:45
-
-
Save markiv/c9db4d129c3875a0188ddfb427d26d58 to your computer and use it in GitHub Desktop.
FloatingTextField1.swift
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
struct FloatingTextField: View { | |
let title: String | |
let text: Binding<String> | |
var body: some View { | |
VStack(alignment: .leading, spacing: 2) { | |
Text(title) | |
.font(.caption) | |
.foregroundColor(Color(.placeholderText)) | |
TextField(title, text: text) | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment