Pass IDs to IconButtons instead of generating them

This commit is contained in:
Marshall Bowers 2023-10-24 11:20:31 +02:00
parent 7719ed0d6c
commit 47f979d457
11 changed files with 40 additions and 39 deletions

View file

@ -32,7 +32,7 @@ impl BufferSearch {
h_stack().bg(color.toolbar).p_2().child(
h_stack().child(Input::new("Search")).child(
IconButton::<Self>::new(Icon::Replace)
IconButton::<Self>::new(Icon::Replace, "replace")
.when(self.is_replace_open, |this| this.color(IconColor::Accent))
.on_click(|buffer_search, cx| {
buffer_search.toggle_replace(cx);