package com.crm.chat.ui.chat

import com.crm.chat.data.model.Chat
import com.crm.chat.data.model.ChatMessage

sealed class ChatState {
    object Loading : ChatState()
    data class Success(val chat: Chat) : ChatState()
    data class Error(val message: String) : ChatState()
}

sealed class MessagesState {
    object Loading : MessagesState()
    data class Success(val messages: List<ChatMessage>) : MessagesState()
    data class Error(val message: String) : MessagesState()
}

sealed class SendMessageState {
    object Loading : SendMessageState()
    data class Success(val message: ChatMessage) : SendMessageState()
    data class Error(val message: String) : SendMessageState()
}

sealed class EditMessageState {
    object Loading : EditMessageState()
    data class Success(val message: ChatMessage) : EditMessageState()
    data class Error(val message: String) : EditMessageState()
}

sealed class DeleteMessageState {
    object Loading : DeleteMessageState()
    object Success : DeleteMessageState()
    data class Error(val message: String) : DeleteMessageState()
}

sealed class ReactionState {
    object Loading : ReactionState()
    data class Success(val message: ChatMessage) : ReactionState()
    data class Error(val message: String) : ReactionState()
}
