Skip to content

Commit ebde502

Browse files
edfloreshzEduardo Flores
authored and
Eduardo Flores
committed
fix: portions for snapshot view
1 parent 8562df5 commit ebde502

File tree

1 file changed

+14
-8
lines changed

1 file changed

+14
-8
lines changed

src/pages/snapshots.rs

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,15 @@ impl Snapshots {
3838
.iter()
3939
.map(|snapshot| {
4040
widget::settings::item_row(vec![
41-
widget::text(&snapshot.name).width(Length::Fill).into(),
42-
widget::text(snapshot.kind()).width(Length::Fill).into(),
43-
widget::text(snapshot.created()).width(Length::Fill).into(),
41+
widget::text(&snapshot.name)
42+
.width(Length::FillPortion(2))
43+
.into(),
44+
widget::text(snapshot.kind())
45+
.width(Length::FillPortion(1))
46+
.into(),
47+
widget::text(snapshot.created())
48+
.width(Length::FillPortion(1))
49+
.into(),
4450
widget::row()
4551
.push(widget::tooltip(
4652
widget::button::icon(icons::get_handle(
@@ -61,7 +67,7 @@ impl Snapshots {
6167
))
6268
.align_y(cosmic::iced::Alignment::Center)
6369
.spacing(spacing.space_xxs)
64-
.width(Length::Fill)
70+
.width(Length::FillPortion(1))
6571
.into(),
6672
])
6773
.align_y(cosmic::iced::Alignment::Center)
@@ -84,10 +90,10 @@ impl Snapshots {
8490
} else {
8591
Some(
8692
widget::row()
87-
.push(heading_item(fl!("name"), Length::Fill))
88-
.push(heading_item(fl!("type"), Length::Fill))
89-
.push(heading_item(fl!("created"), Length::Fill))
90-
.push(heading_item(fl!("actions"), Length::Fill))
93+
.push(heading_item(fl!("name"), Length::FillPortion(2)))
94+
.push(heading_item(fl!("type"), Length::FillPortion(1)))
95+
.push(heading_item(fl!("created"), Length::FillPortion(1)))
96+
.push(heading_item(fl!("actions"), Length::FillPortion(1)))
9197
.padding([0, spacing.space_m]),
9298
)
9399
};

0 commit comments

Comments
 (0)