From 06fd88a8c59af0d2d7d435d336fc9dd3e96aebe7 Mon Sep 17 00:00:00 2001 From: Polesznyák Márk Date: Tue, 14 Oct 2025 09:15:23 +0200 Subject: feat: take `IntoFragment` in `button` --- src/lib.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/lib.rs b/src/lib.rs index 6f105de..d311d14 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -3,6 +3,7 @@ pub mod dialog; pub use dialog::Dialog; use iced_widget::Button; use iced_widget::core; +use iced_widget::text::IntoFragment; use iced_widget::{container, text}; /// Creates a new [`Dialog`] with the given base and dialog content. @@ -25,7 +26,7 @@ where /// /// [`Button`]: https://docs.iced.rs/iced/widget/struct.Button.html pub fn button<'a, Message, Theme, Renderer>( - content: &'a str, + content: impl IntoFragment<'a>, message: Message, ) -> Button<'a, Message, Theme, Renderer> where -- cgit v1.2.3