Convert TextField/EditText component to Android/iOS code.
TextField in Swift and EditText in Kotlin is generally used for form pages. It's generally used for the user to enter the email and password like in the images below. TextFields have different names and properties in iOS and Android, they're explained below.
Examples of Components
TextField
TextFields have 4 properties in Monday Hero :
Text: The initial text displayed by the text field. You can specify the text as a plain string or as an attributed string.
Placeholder: A placeholder is a text displayed by the textField when the string is empty. Typing any text into the text field hides this string.
Left icon: You can add an icon to the left side of the textField.
Right icon: You can add an icon to the right side of the textField.
Edit Text
⚠️This feature is available in only Mac App. Web App support for Android is coming soon.
If you need to install the desktop app, click here.
EditTextis used for entering and modifying text.
Additionally, Monday Hero also lets you select and generate 3 attributes of this component:
Text: The initial text displayed by the text field. You can specify the text as a plain string or as an attributed string.
Hint: A hint is a text displayed by the EditText when the string is empty. Typing any text into the text field hides this string.
Left icon: You can add an icon to the left side of the EditText.
Generated iOS/Android code
Let's see the code that generated for the e-mail textField.