Module Ui.Jstr_editorSource
String editors.
String editors are for editing short strings. See the styling information.
String editors
The type for string editors.
Source
val v :
?class':Jstr.t ->
?enabled:bool Note.signal ->
?on:'a Note.event ->
?length:int Note.signal ->
Jstr.t Note.signal ->
tv ~class' ~enabled ~on ~size s is an editor for a string:
sis the string value to edit.lengthis the length of the editor in number of characters (defaults toS.const 20).oncan be used to put the string editor on focus and in editing mode.enabledindicates if the editor can be interacted with defaults toNote.S.Bool.true'.class'is added to the underlying element's classes.
action e occurs with a new string when an edition was validated.
enabled e is true iff the editor is enabled.
editing e is true whenever the string is being edited.
Styling
The element returned by el makes use of the following CSS classes: