Fix Column
and Row
styling for iced_web
This commit is contained in:
parent
6c8fdfefbe
commit
8e83f3632c
@ -130,11 +130,6 @@ impl<'a, Message> Widget<Message> for Column<'a, Message> {
|
|||||||
let padding_class =
|
let padding_class =
|
||||||
style_sheet.insert(bump, css::Rule::Padding(self.padding));
|
style_sheet.insert(bump, css::Rule::Padding(self.padding));
|
||||||
|
|
||||||
let width = css::length(self.width);
|
|
||||||
let height = css::length(self.height);
|
|
||||||
|
|
||||||
let align_items = css::align(self.align_items);
|
|
||||||
|
|
||||||
// TODO: Complete styling
|
// TODO: Complete styling
|
||||||
div(bump)
|
div(bump)
|
||||||
.attr(
|
.attr(
|
||||||
@ -144,12 +139,12 @@ impl<'a, Message> Widget<Message> for Column<'a, Message> {
|
|||||||
)
|
)
|
||||||
.attr("style", bumpalo::format!(
|
.attr("style", bumpalo::format!(
|
||||||
in bump,
|
in bump,
|
||||||
"width: {}; height: {}; max-width: {}px; max-height: {}px; align-items: {}",
|
"width: {}; height: {}; max-width: {}; max-height: {}; align-items: {}",
|
||||||
width,
|
css::length(self.width),
|
||||||
height,
|
css::length(self.height),
|
||||||
self.max_width,
|
css::max_length(self.max_width),
|
||||||
self.max_height,
|
css::max_length(self.max_height),
|
||||||
align_items
|
css::align(self.align_items)
|
||||||
).into_bump_str()
|
).into_bump_str()
|
||||||
)
|
)
|
||||||
.children(children)
|
.children(children)
|
||||||
|
@ -131,11 +131,6 @@ impl<'a, Message> Widget<Message> for Row<'a, Message> {
|
|||||||
let padding_class =
|
let padding_class =
|
||||||
style_sheet.insert(bump, css::Rule::Padding(self.padding));
|
style_sheet.insert(bump, css::Rule::Padding(self.padding));
|
||||||
|
|
||||||
let width = css::length(self.width);
|
|
||||||
let height = css::length(self.height);
|
|
||||||
|
|
||||||
let justify_content = css::align(self.align_items);
|
|
||||||
|
|
||||||
// TODO: Complete styling
|
// TODO: Complete styling
|
||||||
div(bump)
|
div(bump)
|
||||||
.attr(
|
.attr(
|
||||||
@ -145,12 +140,12 @@ impl<'a, Message> Widget<Message> for Row<'a, Message> {
|
|||||||
)
|
)
|
||||||
.attr("style", bumpalo::format!(
|
.attr("style", bumpalo::format!(
|
||||||
in bump,
|
in bump,
|
||||||
"width: {}; height: {}; max-width: {}px; max-height: {}px; justify-content: {}",
|
"width: {}; height: {}; max-width: {}; max-height: {}; align-items: {}",
|
||||||
width,
|
css::length(self.width),
|
||||||
height,
|
css::length(self.height),
|
||||||
self.max_width,
|
css::max_length(self.max_width),
|
||||||
self.max_height,
|
css::max_length(self.max_height),
|
||||||
justify_content
|
css::align(self.align_items)
|
||||||
).into_bump_str()
|
).into_bump_str()
|
||||||
)
|
)
|
||||||
.children(children)
|
.children(children)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user