Skip to content

Commit

Permalink
Merge pull request #1008 from haoxiuwen/iosui
Browse files Browse the repository at this point in the history
Add Updates to iOS UIKit
  • Loading branch information
haoxiuwen authored Oct 28, 2024
2 parents 2ef889c + 466ba03 commit 59c28cb
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 1 deletion.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
50 changes: 49 additions & 1 deletion docs/uikit/chatuikit/ios/chatuikit_custom_chat.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,30 @@

### 设置附件消息

#### 设置类似微信样式

若实现发送附件消息时弹出类似微信样式的弹窗,可进行如下设置:

```Swift
Appearance.chat.messageAttachmentMenuStyle = .followInput
```

效果图如下所示:

![img](/images/uikit/chatuikit/ios/configurationitem/chat/[email protected])

#### 设置仿系统 UIActionSheet 样式

若实现消息长按后弹出仿系统 `UIActionSheet` 样式的弹窗,可进行如下设置:

```Swift
Appearance.chat.messageAttachmentMenuStyle = .actionSheet
```

![img](/images/uikit/chatuikit/ios/configurationitem/chat/[email protected])

#### 设置附件消息相关的配置项

- 设置语音消息录制的最大时长

你可以通过 `Appearance.chat.audioDuration = value` 设置聊天页面语音消息录制的最大时长,默认为 60 秒。
Expand All @@ -117,7 +141,7 @@
- `Appearance.chat.imagePlaceHolder = value`:聊天页面图片消息占位图。

- `Appearance.chat.videoPlaceHolder = value`:聊天页面视频消息占位图。

### 设置消息撤回时间

你可以通过 `Appearance.chat.recallExpiredTime = value` 设置聊天页面消息撤回的有效时间,默认为 120 秒。
Expand Down Expand Up @@ -161,6 +185,30 @@ override func filterMessageActions(message: MessageEntity) -> [ActionSheetItemPr

![img](/images/uikit/chatuikit/ios/configurationitem/chat/Appearance_chat_messageLongPressedActions.png)

#### 设置类似微信样式

若实现消息长按后弹出类似微信样式的弹窗,可进行如下设置:

```Swift
Appearance.chat.messageLongPressMenuStyle = .withArrow
```

效果图如下所示:

![img](/images/uikit/chatuikit/ios/configurationitem/chat/[email protected])

#### 设置仿系统 UIActionSheet 样式

若实现消息长按后弹出仿系统 `UIActionSheet` 样式的弹窗,可进行如下设置:

```Swift
Appearance.chat.messageLongPressMenuStyle = .actionSheet
```

效果图如下所示:

![img](/images/uikit/chatuikit/ios/configurationitem/chat/[email protected])

## 设置聊天页面输入框

- `Appearance.chat.maxInputHeight = value`:聊天页面输入框最大输入高度。
Expand Down

0 comments on commit 59c28cb

Please sign in to comment.