zen_rs/
aspects.rs

1//! Base types of aspects
2//!
3//! This module defines base aspects and their associated types.
4
5pub mod border;
6pub mod color;
7pub mod font;
8pub mod order;
9pub mod spaceing;
10pub mod svg;
11
12pub use border::*;
13pub use color::*;
14pub use font::*;
15pub use order::*;
16pub use spaceing::*;
17pub use svg::*;
18
19/// Indicates whether an element should be displayed.
20///
21/// This is a helper type that serves as a replacement for `Option` in certain cases.
22///
23/// **Note**: This type may be removed in future versions.
24pub type Show = bool;
25
26/// Represents a path to a destination.
27pub type Path = String;
28
29/// Represents a size value.
30///
31/// By default, size is assumed to be in pixels, but specific layouts may interpret it differently.
32pub type Size = u64;
33
34/// Represents a hyperlink.
35///
36/// **Note**: This is applicable only for HTML/Leptos render attributes and will be ignored for other render types.
37///
38/// For example, this corresponds to an HTML `href` attribute.
39pub type Link = Option<Path>;
40
41// Size-related types
42/// Represents the width of an element.
43/// Presumably measured in pixels.
44pub type Width = Size;
45
46/// Represents the height of an element.
47/// Presumably measured in pixels.
48pub type Height = Size;