package app.closer.domain.model

data class QuestionMessage(
    val id: String = "",
    val userId: String = "",
    val text: String = "",
    /** "text", "image" (also GIFs/stickers/Bitmoji), or "voice". */
    val type: String = "text",
    /** Download URL of the ENCRYPTED media bytes in Storage (empty for text messages). */
    val mediaUrl: String = "",
    /** Voice-note length in milliseconds (0 for non-voice). */
    val durationMs: Long = 0L,
    val createdAt: Long = 0L
) {
    val isImage: Boolean get() = type == "image" && mediaUrl.isNotBlank()
    val isVoice: Boolean get() = type == "voice" && mediaUrl.isNotBlank()
}
