Skip to content

Commit

Permalink
Add text to taffy example
Browse files Browse the repository at this point in the history
  • Loading branch information
nicoburns committed Nov 9, 2023
1 parent 68c3df6 commit 6a6ff39
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion examples/taffy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,11 @@ fn app_logic(data: &mut i32) -> impl View<i32> {
s.justify_content = Some(JustifyContent::Center);
s.align_items = Some(AlignItems::Center);
}),
div(())
div(String::from("Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."))
.with_background_color(Color::RED)
.with_style(|s| s.padding = length(20.0)),
div(())
.with_background_color(Color::FOREST_GREEN)
.with_style(|s| s.flex_grow = 1.0),
))
.with_style(|s| {
Expand Down

0 comments on commit 6a6ff39

Please sign in to comment.