InlineEdit builder
Text that a click or enter turns into a field.
A builder is RenderOnce. Construct and mount it in one expression.
use gpui_kit::controls::InlineEdit;
Construct
new(ident: impl Into<Ident>, value: impl Into<SharedString>) -> SelfOptions
Chain onto the value.
placeholder(placeholder: impl Into<SharedString>) -> Self
editing(editing: bool) -> Self
multiline(multiline: bool) -> Self
rows(rows: usize) -> Self
failure(failure: impl Into<SharedString>) -> Self
on_edit(handler: impl Fn(&mut Window, &mut App) + 'static) -> Self
on_commit(handler: impl Fn(SharedString, &mut Window, &mut App) + 'static) -> Self
on_cancel(handler: impl Fn(&mut Window, &mut App) + 'static) -> SelfRendered by
Each of these compiles and is captured by the gate, so the code behind them is verified rather than written.