Skip to content
A reusable UITextView that expands and contracts like a chat input field.
Swift
Branch: master
Clone or download

Latest commit

Fetching latest commit…
Cannot retrieve the latest commit at this time.

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
DynamicTextView
README.md

README.md

ruuiDynamicTextView

A production level reusable UITextView that expands and contracts like a chat input field.

This class takes care of these things while minimizing jitter and keeping the caret in view.

Class is WIP but should be stable enough for production use.

I love contributions. Send me your fixes.

Demo

alt text

Usage

Usage is straight forward.

let textView = ruuiDynamicTextView(frame: CGRectMake(10, 10, 100, 35))
textView.maxHeight = 100
containerView.addSubview(textView)

Features

  • Grow & shrink
  • Keeps caret in view
  • Animates cleanly
  • Maximum and minimum size

Testing

  • Tested on iOS 9.3.1
You can’t perform that action at this time.