reflex-dom-contrib-0.4.1: A playground for experimenting with infrastructure and common code for reflex applications

Safe HaskellNone
LanguageHaskell2010

Reflex.Dom.Contrib.Widgets.EditInPlace

Synopsis

Documentation

editInPlace Source

Arguments

:: 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.