Skip to content

Commit

Permalink
Add names to created entities (#65)
Browse files Browse the repository at this point in the history
  • Loading branch information
rparrett authored Aug 9, 2024
1 parent 7a9c01e commit 02a46e6
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -653,6 +653,7 @@ fn create(
},
..default()
},
Name::new("TextInputInner"),
TextInputInner,
))
.id();
Expand Down Expand Up @@ -686,20 +687,24 @@ fn create(
},
..default()
},
Name::new("TextInputPlaceholderInner"),
TextInputPlaceholderInner,
))
.id();

let overflow_container = commands
.spawn(NodeBundle {
style: Style {
overflow: Overflow::clip(),
justify_content: JustifyContent::FlexEnd,
max_width: Val::Percent(100.),
.spawn((
NodeBundle {
style: Style {
overflow: Overflow::clip(),
justify_content: JustifyContent::FlexEnd,
max_width: Val::Percent(100.),
..default()
},
..default()
},
..default()
})
Name::new("TextInputOverflowContainer"),
))
.id();

commands.entity(overflow_container).add_child(text);
Expand Down

0 comments on commit 02a46e6

Please sign in to comment.