messaging_api_line/models/
flex_margin.rs

1/*
2 * LINE Messaging API
3 *
4 * This document describes LINE Messaging API.
5 *
6 * The version of the OpenAPI document: 0.0.1
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// FlexMargin : You can specify the minimum space before a child component with the `margin` property of the child component, in pixels or with a keyword. FlexMargin just provides only keywords. 
15/// You can specify the minimum space before a child component with the `margin` property of the child component, in pixels or with a keyword. FlexMargin just provides only keywords. 
16#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
17pub enum FlexMargin {
18    #[serde(rename = "none")]
19    None,
20    #[serde(rename = "xs")]
21    Xs,
22    #[serde(rename = "sm")]
23    Sm,
24    #[serde(rename = "md")]
25    Md,
26    #[serde(rename = "lg")]
27    Lg,
28    #[serde(rename = "xl")]
29    Xl,
30    #[serde(rename = "xxl")]
31    Xxl,
32
33}
34
35impl std::fmt::Display for FlexMargin {
36    fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
37        match self {
38            Self::None => write!(f, "none"),
39            Self::Xs => write!(f, "xs"),
40            Self::Sm => write!(f, "sm"),
41            Self::Md => write!(f, "md"),
42            Self::Lg => write!(f, "lg"),
43            Self::Xl => write!(f, "xl"),
44            Self::Xxl => write!(f, "xxl"),
45        }
46    }
47}
48
49impl Default for FlexMargin {
50    fn default() -> FlexMargin {
51        Self::None
52    }
53}
54