Convert TextView/Text component to iOS/Android code.
Last updated 3 years ago
Text View allows the user to enter more than one line of text. A textView image is and its code is shown below.
While creating the component, Monday Hero automatically detects the text and Background in the TextView.
//HomePageViewController.swift import UIKit class HomePageViewController: UIViewController { //Connection from an Interface Builder to a UI component @IBOutlet private weak var addNotesTextView: UITextView! override func viewDidLoad() { super.viewDidLoad() setupViews() } } extension HomePageViewController { private func setupViews() { //TextView properties addNotesTextView.backgroundColor = UIColor.daisy2 addNotesTextView.text = NSLocalizedString("add.note.here", comment: "") addNotesTextView.textColor = UIColor.spruce_40 addNotesTextView.font = UIFont.textStyle5 addNotesTextView.textAlignment = .left } }
Android does not have a separate component for Text Areas, the same code is used for the Texts are also used for Text Areas.