From bd22cc0bc0f7551d29cf2acd22520f4a906f253c Mon Sep 17 00:00:00 2001 From: Héctor Ramón Jiménez Date: Sat, 12 Feb 2022 17:21:28 +0700 Subject: Implement pure version of `todos` example :tada: The `Widget` trait in `iced_pure` needed to change a bit to make the implementation of `Element::map` possible. Specifically, the `children` method has been split into `diff` and `children_state`. --- src/pure.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/pure.rs b/src/pure.rs index 7fe2bc59..29495c07 100644 --- a/src/pure.rs +++ b/src/pure.rs @@ -17,12 +17,15 @@ //! [the original widgets]: crate::widget //! [`button::State`]: crate::widget::button::State //! [impure `Application`]: crate::Application -pub use iced_pure::{Element as _, *}; +pub use iced_pure::{Element as _, Text as _, *}; /// A generic, pure [`Widget`]. pub type Element<'a, Message> = iced_pure::Element<'a, Message, crate::Renderer>; +/// A pure text widget. +pub type Text = iced_pure::Text; + mod application; mod sandbox; -- cgit