@@ -27,8 +27,9 @@ type domRef
27
27
28
28
(*
29
29
This list isn't exhaustive. We'll add more as we go.
30
+ 'aria* type variables can be removed once we can rewrite *.ml libs to *res.
30
31
*)
31
- type domProps = {
32
+ type ('ariaCurrent, 'ariaInvalid, 'ariaHaspopup, 'ariaChecked, 'ariaPressed, 'loading) domProps = {
32
33
(* V10 compiler will enable to change label declaration to `key?: string` *)
33
34
key : string
34
35
[@ ns.optional];
@@ -39,15 +40,17 @@ type domProps = {
39
40
(* accessibility *)
40
41
(* https://www.w3.org/TR/wai-aria-1.1/ *)
41
42
(* https://accessibilityresources.org/<aria-tag> is a great resource for these *)
42
- ariaCurrent : [`page | `step | `location | `date | `time | `_true | `_false]
43
+ (* ariaCurrent: [`page | `step | `location | `date | `time | `_true | `_false] *)
44
+ ariaCurrent : 'ariaCurrent
43
45
[@ ns.optional] [@ bs.as "aria-current" ];
44
46
ariaDetails : string
45
47
[@ ns.optional] [@ bs.as "aria-details" ];
46
48
ariaDisabled : bool
47
49
[@ ns.optional] [@ bs.as "aria-disabled" ];
48
50
ariaHidden : bool
49
51
[@ ns.optional] [@ bs.as "aria-hidden" ];
50
- ariaInvalid : [`grammar | `spelling | `_true| `_false]
52
+ (* ariaInvalid: [`grammar | `spelling | `_true | `_false ] *)
53
+ ariaInvalid : 'ariaInvalid
51
54
[@ ns.optional] [@ bs.as "aria-invalid" ];
52
55
ariaKeyshortcuts : string
53
56
[@ ns.optional] [@ bs.as "aria-keyshortcuts" ];
@@ -58,11 +61,13 @@ type domProps = {
58
61
(* Widget Attributes *)
59
62
ariaAutocomplete : [`inline | `list | `both | `none ]
60
63
[@ ns.optional] [@ bs.as "aria-autocomplete" ];
61
- ariaChecked : [`_true | `_false | `mixed ] (* https://www.w3.org/TR/wai-aria-1.1/#valuetype_tristate *)
64
+ (* ariaChecked: [`_true | `_false | `mixed] https://www.w3.org/TR/wai-aria-1.1/#valuetype_tristate *)
65
+ ariaChecked : 'ariaChecked
62
66
[@ ns.optional] [@ bs.as "aria-checked" ];
63
67
ariaExpanded : bool
64
68
[@ ns.optional] [@ bs.as "aria-expanded" ];
65
- ariaHaspopup : [`menu | `listbox | `tree | `grid | `dialog | `_true | `_false]
69
+ (* ariaHaspopup: [`menu | `listbox | `tree | `grid | `dialog | `_true | `_false] *)
70
+ ariaHaspopup : 'ariaHaspopup
66
71
[@ ns.optional] [@ bs.as "aria-haspopup" ];
67
72
ariaLevel : int
68
73
[@ ns.optional] [@ bs.as "aria-lavel" ];
@@ -76,7 +81,8 @@ type domProps = {
76
81
[@ ns.optional] [@ bs.as "aria-orientation" ];
77
82
ariaPlaceholder : string
78
83
[@ ns.optional] [@ bs.as "aria-placeholder" ];
79
- ariaPressed : [`_true | `_false| `mixed ] (* https://www.w3.org/TR/wai-aria-1.1/#valuetype_tristate *)
84
+ (* ariaPressed: [`_true | `_false| `mixed] https://www.w3.org/TR/wai-aria-1.1/#valuetype_tristate *)
85
+ ariaPressed : 'ariaPressed
80
86
[@ ns.optional] [@ bs.as "aria-pressed" ];
81
87
ariaReadonly : bool
82
88
[@ ns.optional] [@ bs.as "aria-readonly" ];
@@ -275,7 +281,8 @@ type domProps = {
275
281
[@ ns.optional];
276
282
list : string
277
283
[@ ns.optional];
278
- loading : [`_lazy | `eager ]
284
+ (* loading: [`_lazy | `eager] *)
285
+ loading : 'loading
279
286
[@ ns.optional];
280
287
loop : bool
281
288
[@ ns.optional];
0 commit comments