Label component states in stories (#3019)

This PR updates the UI component stories to label the various states
that they are in.

Release Notes:

- N/A
This commit is contained in:
Marshall Bowers 2023-09-22 15:48:32 -04:00 committed by GitHub
parent d0b15ed940
commit 27e3e09bb9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 53 additions and 51 deletions

View file

@ -9,8 +9,10 @@ pub struct Facepile {
players: Vec<Avatar>,
}
pub fn facepile(players: Vec<Avatar>) -> Facepile {
Facepile { players }
pub fn facepile<P: Iterator<Item = Avatar>>(players: P) -> Facepile {
Facepile {
players: players.collect(),
}
}
impl Facepile {

View file

@ -46,7 +46,7 @@ impl FollowGroup {
.px_1()
.rounded_lg()
.fill(player_bg)
.child(facepile(self.players.clone())),
.child(facepile(self.players.clone().into_iter())),
)
}
}