use crate::{CoreStyle, Style};
pub trait BlockContainerStyle: CoreStyle {
#[inline(always)]
fn text_align(&self) -> TextAlign {
Style::<Self::CustomIdent>::DEFAULT.text_align
}
}
pub trait BlockItemStyle: CoreStyle {
#[inline(always)]
fn is_table(&self) -> bool {
false
}
#[cfg(feature = "float_layout")]
#[inline(always)]
fn float(&self) -> super::Float {
super::Float::None
}
#[cfg(feature = "float_layout")]
#[inline(always)]
fn clear(&self) -> super::Clear {
super::Clear::None
}
}
#[derive(Debug, Clone, Copy, PartialEq, Eq, Default)]
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
pub enum TextAlign {
#[default]
Auto,
LegacyLeft,
LegacyRight,
LegacyCenter,
}
#[cfg(feature = "parse")]
crate::util::parse::impl_parse_for_keyword_enum!(TextAlign,
"auto" => Auto,
"-webkit-left" => LegacyLeft,
"-webkit-right" => LegacyRight,
"-webkit-center" => LegacyCenter,
);