role角色聊天交互优化

This commit is contained in:
mh 2025-12-02 15:38:11 +08:00
parent 8db4792e61
commit 696ec2c0ec
2 changed files with 12 additions and 2 deletions

View File

@ -285,6 +285,16 @@ class SessionInputOperateView: UIView {
}
}
/// +
func resetInputState() {
inputTextView.text = ""
inputTextView.setContentOffset(.zero, animated: false)
inputTextView.snp.updateConstraints { make in
make.height.equalTo(minTextViewHeight)
}
layoutIfNeeded()
}
// MARK: - Action
@objc private func tapGiftButton() {

View File

@ -161,7 +161,7 @@ extension SessionController {
}
func hideOperateView(){
hideAllBottomViews(except: [inputEntrance])
hideAllBottomViews(except: [inputEntrance, toolView])
}
// MARK: - Functions
@ -298,7 +298,7 @@ extension SessionController: SessionInputOperateViewDelegate{
guard text.isEmpty == false else { return }
inputBar.clearInputDatas()
inputEntrance.inputTextView.text = ""
inputEntrance.resetInputState()
if isStreamChatMode {
appendOutgoingStreamMessage(text)