TopicChatViewModel constructor
TopicChatViewModel(
- String conversationId, {
- required BotSubsessionTopicContext topicContext,
- void onTopicResolved(
- BotSubsessionTopicContext context
- ChatUIConfig? chatUIConfig,
Implementation
TopicChatViewModel(
String conversationId, {
required this.topicContext,
this.onTopicResolved,
ChatUIConfig? chatUIConfig,
}) : _currentTopic = topicContext.topic,
_isPlaceholder =
topicContext.isPlaceholder || topicContext.topic == null,
super(
conversationId,
NIMConversationType.p2p,
chatUIConfig: chatUIConfig,
) {
chatTitle = rootSessionTitle;
topicTitle = _resolveTitle();
mute = false;
_bindTopicEvents();
}