ALTextInputBar 1.1.8

ALTextInputBar 1.1.8

测试已测试
语言语言 SwiftSwift
许可协议 MIT
发布日期最近发布2018年3月
SPM支持 SPM

Alex Littleohn 维护。



  • 作者:
  • Alex Littlejohn

ALTextInputBar

用于消息应用的自增长文本输入栏。使用 Swift 编写。
ALTextInputBar 旨在解决人们在构建消息应用时遇到的一些问题。

With some text With lots of text

功能

  • 简单易用和配置
  • 基于内容自动调整大小
  • 支持交互式 dismiss 手势

安装与要求

此项目需要在 Xcode 8.0 上运行,并用 swift 3.0 编译

ALTextInputBar 在 CocoaPods 上可用。将以下内容添加到 Podfile

pod 'ALTextInputBar'

使用方法

这是附加输入栏到键盘所需的最小配置

class ViewController: UIViewController {

    let textInputBar = ALTextInputBar()

    // The magic sauce
    // This is how we attach the input bar to the keyboard
    override var inputAccessoryView: UIView? {
        get {
            return textInputBar
        }
    }

    // Another ingredient in the magic sauce
    override var canBecomeFirstResponder: Bool {
        return true
    }
}

许可协议

ALTextInputBar 基于 MIT 许可协议。有关更多信息,请参阅 LICENSE 文件。