Tailwind classes in OCaml
1(** Typography utilities *)
2
3(** Typography configuration *)
4type t
5
6(** Font family *)
7type font_family = [
8 | `Sans
9 | `Serif
10 | `Mono
11]
12
13(** Font size *)
14type font_size = [
15 | `Xs | `Sm | `Base | `Lg | `Xl
16 | `Xl2 | `Xl3 | `Xl4 | `Xl5 | `Xl6
17 | `Xl7 | `Xl8 | `Xl9
18]
19
20(** Font weight *)
21type font_weight = [
22 | `Thin | `Extralight | `Light | `Normal | `Medium
23 | `Semibold | `Bold | `Extrabold | `Black
24]
25
26(** Font style *)
27type font_style = [
28 | `Italic
29 | `Not_italic
30]
31
32(** Letter spacing *)
33type letter_spacing = [
34 | `Tighter | `Tight | `Normal | `Wide | `Wider | `Widest
35]
36
37(** Line height *)
38type line_height = [
39 | `None | `Tight | `Snug | `Normal | `Relaxed | `Loose
40 | `Rem of float
41]
42
43(** Text alignment *)
44type text_align = [
45 | `Left | `Center | `Right | `Justify | `Start | `End
46]
47
48(** Text decoration *)
49type text_decoration = [
50 | `Underline | `Overline | `Line_through | `No_underline
51]
52
53(** Text transform *)
54type text_transform = [
55 | `Uppercase | `Lowercase | `Capitalize | `Normal_case
56]
57
58(** Set font family *)
59val font_family : font_family -> t
60
61(** Set font size *)
62val font_size : font_size -> t
63
64(** Set font weight *)
65val font_weight : font_weight -> t
66
67(** Set font style *)
68val font_style : font_style -> t
69
70(** Set letter spacing *)
71val letter_spacing : letter_spacing -> t
72
73(** Set line height *)
74val line_height : line_height -> t
75
76(** Set text alignment *)
77val text_align : text_align -> t
78
79(** Set text decoration *)
80val text_decoration : text_decoration -> t
81
82(** Set text transform *)
83val text_transform : text_transform -> t
84
85(** Set text color (delegates to Color module) *)
86val text_color : Color.t -> t
87
88(** Convert to CSS class *)
89val to_class : t -> Css.t
90
91(** Common text utilities *)
92val text_xs : Css.t
93val text_sm : Css.t
94val text_base : Css.t
95val text_lg : Css.t
96val text_xl : Css.t
97val font_bold : Css.t
98val font_normal : Css.t
99val italic : Css.t
100val underline : Css.t
101val uppercase : Css.t
102val lowercase : Css.t
103val capitalize : Css.t