tailwind_css_fixes/modules/layouts/placement/
bottom.rs1use super::*;
2
3#[doc=include_str!("readme.md")]
4#[derive(Clone, Debug)]
5pub struct TailwindBottom {
6 kind: UnitValue,
7}
8
9impl Display for TailwindBottom {
10 fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
11 self.kind.write_negative(f)?;
12 self.kind.write_class(f, "bottom-")
13 }
14}
15
16impl TailwindInstance for TailwindBottom {
17 fn attributes(&self, _: &TailwindBuilder) -> CssAttributes {
18 css_attributes! {
19 "bottom" => self.kind.get_properties_rem()
20 }
21 }
22}
23
24impl TailwindBottom {
25 pub fn parse(pattern: &[&str], arbitrary: &TailwindArbitrary, negative: Negative) -> Result<Self> {
27 let kind = get_kind_px_full_auto_fract("bottom", pattern, arbitrary, negative)?;
28 Ok(Self { kind })
29 }
30 pub fn check_valid(mode: &str) -> bool {
32 check_valid_auto(mode)
33 }
34}