description_list: Update label_width type to accept any Into<DefiniteLength>. (#729)
This commit is contained in:
parent
ffa36c1c5b
commit
12e3678e55
1 changed files with 2 additions and 2 deletions
|
|
@ -140,8 +140,8 @@ impl DescriptionList {
|
|||
/// Set the width of the label, only works for horizontal layout.
|
||||
///
|
||||
/// Default is `120px`.
|
||||
pub fn label_width(mut self, label_width: DefiniteLength) -> Self {
|
||||
self.label_width = label_width;
|
||||
pub fn label_width(mut self, label_width: impl Into<DefiniteLength>) -> Self {
|
||||
self.label_width = label_width.into();
|
||||
self
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue