Skip to content

Commit

Permalink
Change descriptor view in installer behind scrollable
Browse files Browse the repository at this point in the history
View is broken because of the long line of text of the
descriptor, current fix is to put it behind a scrollable
until we find a better way to display it to the user.
  • Loading branch information
edouardparis committed Apr 29, 2024
1 parent 20a7fd1 commit ad69711
Showing 1 changed file with 20 additions and 2 deletions.
22 changes: 20 additions & 2 deletions gui/src/installer/view.rs
Original file line number Diff line number Diff line change
Expand Up @@ -758,7 +758,16 @@ pub fn register_descriptor<'a>(
.push(card::simple(
Column::new()
.push(text("The descriptor:").small().bold())
.push(text(descriptor.clone()).small())
.push(
scrollable(
Column::new()
.push(text(descriptor.to_owned()).small())
.push(Space::with_height(Length::Fixed(5.0))),
)
.direction(scrollable::Direction::Horizontal(
scrollable::Properties::new().width(5).scroller_width(5),
)),
)
.push(
Row::new().push(Column::new().width(Length::Fill)).push(
button::secondary(Some(icon::clipboard_icon()), "Copy")
Expand Down Expand Up @@ -859,7 +868,16 @@ pub fn backup_descriptor<'a>(
.push(card::simple(
Column::new()
.push(text("The descriptor:").small().bold())
.push(text(descriptor.clone()).small())
.push(
scrollable(
Column::new()
.push(text(descriptor.to_owned()).small())
.push(Space::with_height(Length::Fixed(5.0))),
)
.direction(scrollable::Direction::Horizontal(
scrollable::Properties::new().width(5).scroller_width(5),
)),
)
.push(
Row::new().push(Column::new().width(Length::Fill)).push(
button::secondary(Some(icon::clipboard_icon()), "Copy")
Expand Down

0 comments on commit ad69711

Please sign in to comment.