/*
 * Zernio API
 *
 * API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api
 *
 * The version of the OpenAPI document: 1.0.4
 * Contact: support@zernio.com
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

/// CreateLeadFormRequestContextCard : Intro card shown before the questions page. Omit to skip the intro screen.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct CreateLeadFormRequestContextCard {
    /// Headline / title of the intro card.
    #[serde(rename = "title", skip_serializing_if = "Option::is_none")]
    pub title: Option<String>,
    /// Body text lines shown on the intro card.
    #[serde(rename = "content", skip_serializing_if = "Option::is_none")]
    pub content: Option<Vec<String>>,
    /// Visual layout of the intro card.
    #[serde(rename = "style", skip_serializing_if = "Option::is_none")]
    pub style: Option<Style>,
    /// CTA button label on the intro card.
    #[serde(rename = "buttonText", skip_serializing_if = "Option::is_none")]
    pub button_text: Option<String>,
    /// Image hash of the cover photo (obtain from the Meta Ad Images API). Omit to show no image.
    #[serde(rename = "coverPhoto", skip_serializing_if = "Option::is_none")]
    pub cover_photo: Option<String>,
}

impl CreateLeadFormRequestContextCard {
    /// Intro card shown before the questions page. Omit to skip the intro screen.
    pub fn new() -> CreateLeadFormRequestContextCard {
        CreateLeadFormRequestContextCard {
            title: None,
            content: None,
            style: None,
            button_text: None,
            cover_photo: None,
        }
    }
}
/// Visual layout of the intro card.
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Style {
    #[serde(rename = "LIST_STYLE")]
    ListStyle,
    #[serde(rename = "PARAGRAPH_STYLE")]
    ParagraphStyle,
}

impl Default for Style {
    fn default() -> Style {
        Self::ListStyle
    }
}
