| 407 | /// ``` |
| 408 | #[inline] |
| 409 | pub fn text_input( |
| 410 | mut self, |
| 411 | f: impl for<'a> FnOnce(&'a mut text_input::TextInputBuilder) -> &'a mut text_input::TextInputBuilder, |
| 412 | ) -> Self { |
| 413 | let mut builder = text_input::TextInputBuilder::new(); |
| 414 | f(&mut builder); |
| 415 | self.inner.text_input = Some(builder.config); |
| 416 | self.text_input_on_changed_fn = builder.on_changed_fn; |
| 417 | self.text_input_on_submit_fn = builder.on_submit_fn; |
| 418 | self |
| 419 | } |
| 420 | |
| 421 | /// Finalizes the element with children defined in a closure. |
| 422 | pub fn children(self, f: impl FnOnce(&mut Ui<'_, CustomElementData>)) -> Id { |