fix(rule): allow changing thickness after creation

This commit is contained in:
laniakea64 2026-03-22 16:41:17 -04:00 committed by Ashley Wulber
parent 70f54c994a
commit 716c75da3f

View file

@ -105,20 +105,14 @@ where
}
/// Set the width of the rule
/// Will not be applied if it is vertical
pub fn width(mut self, width: impl Into<Length>) -> Self {
if !self.is_vertical {
self.width = width.into();
}
self.width = width.into();
self
}
/// Set the height of the rule
/// Will not be applied if it is horizontal
pub fn height(mut self, height: impl Into<Length>) -> Self {
if self.is_vertical {
self.height = height.into();
}
self.height = height.into();
self
}