use serde::{Deserialize, Serialize};

#[derive(Debug, Serialize, Deserialize)]
pub struct FlashcardSet {
    pub id: String,
    pub title: String,
    pub topic: String,
    pub color: String,
    pub created_at: Option<String>,
    // In Rust, we might not include the cards directly in the set struct when fetching lists,
    // but for compatibility with the frontend mock, we can include them or fetch them separately.
    // For now, let's keep it simple and fetch cards separately usually, but here is a struct that mirrors the frontend.
}

#[derive(Debug, Serialize, Deserialize)]
pub struct Flashcard {
    pub id: String,
    pub set_id: String,
    pub front: String,
    pub back: String,
    pub status: String,
    pub created_at: Option<String>,
}

#[derive(Debug, Serialize, Deserialize)]
pub struct FlashcardSetWithCards {
    pub id: String,
    pub title: String,
    pub topic: String,
    pub color: String,
    pub cards: Vec<Flashcard>,
}
