Skip to content

Commit

Permalink
Re-export VariableFunction parser from root
Browse files Browse the repository at this point in the history
- Document VariableFunction fields.

Signed-off-by: Tin Švagelj <[email protected]>
  • Loading branch information
Caellian committed Nov 3, 2024
1 parent cf49905 commit d550433
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,4 +103,5 @@ pub use crate::path::*;
pub use crate::points::*;
pub use crate::transform::*;
pub use crate::transform_origin::*;
pub use crate::variable::VariableFunction;
pub use crate::viewbox::*;
2 changes: 2 additions & 0 deletions src/variable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ impl<'a> From<Option<&'a str>> for VariableFallback<'a> {
/// [`var()`]: https://drafts.csswg.org/css-variables/#funcdef-var
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub struct VariableFunction<'a> {
/// Variable to resolve to get the value.
pub variable: &'a str,
/// Fallback value in case variable isn't defined.
pub fallback: VariableFallback<'a>
}

Expand Down

0 comments on commit d550433

Please sign in to comment.