Safe Haskell | None |
---|---|
Language | Haskell2010 |
- editInPlace :: MonadWidget t m => Behavior t Bool -> Dynamic t String -> m (Event t String)
Documentation
:: MonadWidget t m | |
=> Behavior t Bool | Whether or not click-to-edit is enabled |
-> Dynamic t String | The definitive value of the thing being edited |
-> m (Event t String) | Event that fires when the text is edited |
Control that can be used in place of dynText whenever you also want that text to be editable in place.
This control creates a span that either holds text or a text input field allowing that text to be edited. The edit state is activated by clicking on the text. Edits are saved when the user presses enter or abandoned if the user presses escape or the text input loses focus.