ChatInput - admiral-team/admiralui-ios GitHub Wiki

Class

A view for chat input message and add files


Declaration

open class ChatInputView: TextViewInput, AnyAppThemable, AccessibilitySupport

Overview

The component for typing a text message.

Configure a ChatInputView

let chatInputView = ChatInputView()
chatInputView.actionState = .attachFiles
chatInputView.placeholder = Constants.chatPlaceHolder

Detect changing the size of ChatInputView

let chatInputView = ChatInputView()
chatInputView.chatInputDelegate = self

extension InputChatViewController: ChatInputViewDelegate {
  func textViewSizeDidChange(_ chatInput: ChatInputView, size: CGSize) {
     ....
  }
}

Handle the send button tap action

let chatInputView = ChatInputView()
chatInputView.chatInputDelegate = self

extension InputChatViewController: ChatInputViewDelegate {
  func didTapSendButton(_ chatInput: ChatInputView) {
     ...
  }
}

Contribution

You can help us to find bugs or ask us to add features.

  • To start issue please use ready-made templates.
  • To make changes to the repository, you need to create a fork of the project, make changes to the code and create a pull request in our project. You can read more about this in the Github documentation.