Motivation
Right now, since we just use UILabels for chat messages, our messages only support single lines of text. We want to extend that to support multiple lines of text because that is standard behavior across messaging apps.
The Task
Accepting multiline input involves several things:
The textbox where the user types in the message would need to be able to dynamically grow and shrink based on the amount of text the user types in or deletes.
The size of the textbox displaying the message would be dynamic too based on the number of lines needed to display it.
The dynamic size of the tetxbox displaying the message adds some complication to the UITableView calculations for the Table View that is displaying the messages. These need to be handled.
Requirements
Since this is such a common problem, there are bound to be tutorials on how to do this properly online. Look them up and figure out how to apply their solutions to our codebase.
Also, check out our contribution guide for the git/github workflow we will be adopting from now.
Acceptable Criteria
Dynamically adjust size (both growing and shrinking) as the size of the message changes. The input text field should get larger and smaller (can cap that at 2 lines for now if turns out to be hard)
Correct number of lines should be shown when you send or receive a message
Let’s cap the maximum word size at 300 (do not allow typing post that)
Let’s do the line height first, followed by width.
Motivation Right now, since we just use UILabels for chat messages, our messages only support single lines of text. We want to extend that to support multiple lines of text because that is standard behavior across messaging apps.
The Task Accepting multiline input involves several things:
Requirements
Acceptable Criteria