gui: fix layout with scrollbar for big windows
This commit is contained in:
parent
474adddc9c
commit
e3db475be2
@ -251,13 +251,17 @@ pub fn dashboard<'a, T: Into<Element<'a, Message>>>(
|
|||||||
Column::new()
|
Column::new()
|
||||||
.push(warn(warning))
|
.push(warn(warning))
|
||||||
.push(
|
.push(
|
||||||
main_section(Container::new(scrollable(row!(
|
Container::new(scrollable(row!(
|
||||||
Space::with_width(Length::FillPortion(1)),
|
Space::with_width(Length::FillPortion(1)),
|
||||||
column!(Space::with_height(Length::Units(150)), content.into())
|
column!(Space::with_height(Length::Units(150)), content.into())
|
||||||
.width(Length::FillPortion(8)),
|
.width(Length::FillPortion(8))
|
||||||
|
.max_width(1500),
|
||||||
Space::with_width(Length::FillPortion(1)),
|
Space::with_width(Length::FillPortion(1)),
|
||||||
))))
|
)))
|
||||||
.width(Length::Fill),
|
.center_x()
|
||||||
|
.style(theme::Container::Background)
|
||||||
|
.width(Length::Fill)
|
||||||
|
.height(Length::Fill),
|
||||||
)
|
)
|
||||||
.width(Length::FillPortion(10)),
|
.width(Length::FillPortion(10)),
|
||||||
)
|
)
|
||||||
@ -266,14 +270,6 @@ pub fn dashboard<'a, T: Into<Element<'a, Message>>>(
|
|||||||
.into()
|
.into()
|
||||||
}
|
}
|
||||||
|
|
||||||
fn main_section<'a, T: 'a>(menu: Container<'a, T>) -> Container<'a, T> {
|
|
||||||
Container::new(menu.max_width(1500))
|
|
||||||
.style(theme::Container::Background)
|
|
||||||
.center_x()
|
|
||||||
.width(Length::Fill)
|
|
||||||
.height(Length::Fill)
|
|
||||||
}
|
|
||||||
|
|
||||||
pub fn modal<'a, T: Into<Element<'a, Message>>, F: Into<Element<'a, Message>>>(
|
pub fn modal<'a, T: Into<Element<'a, Message>>, F: Into<Element<'a, Message>>>(
|
||||||
is_previous: bool,
|
is_previous: bool,
|
||||||
warning: Option<&Error>,
|
warning: Option<&Error>,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user