blob: c2b145b6973aba5206552e363b4c847b1c17c649 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
module Form : sig
(** Fonctions for creating forms elements
In each function, the element returned by the function is not the field
element. *)
val input_field :
?name:Jstr.t ->
?id':Jstr.t ->
?value':Jstr.t ->
label:Jstr.t ->
unit ->
Brr.El.t
(** Create a new input element *)
type choice_value = {
id' : Jstr.t option;
label : Jstr.t;
value : Jstr.t;
checked : bool;
}
(** Values inside a radio button list *)
val radio :
?name:Jstr.t ->
?values:choice_value list ->
label:Jstr.t ->
unit ->
Brr.El.t
val submit : ?value':Jstr.t -> unit -> Brr.El.t
end
|