dioxus_tailwindcss/
layout.rs

1use crate::ext::*;
2
3// https://tailwindcss.com/docs/aspect-ratio
4constant!(aspect auto);
5constant!(aspect square);
6constant!(aspect video);
7
8
9// https://tailwindcss.com/docs/aspect-ratio#arbitrary-values
10/// aspect-[{}/{}]
11pub fn aspect(w: u16, h: u16) -> String {
12    format!("aspect-[{}/{}]", w, h)
13}
14
15// https://tailwindcss.com/docs/container
16constant!(container);
17
18// https://tailwindcss.com/docs/columns
19_1_to_12!(columns);
20constant!(columns auto);
21_3xs_to_7xl!(columns);
22
23any!(columns);
24
25// https://tailwindcss.com/docs/break-after
26constant!(break after auto);
27constant!(break after avoid);
28constant!(break after all);
29constant!(break after avoid page);
30constant!(break after page);
31constant!(break after left);
32constant!(break after right);
33constant!(break after column);
34
35// https://tailwindcss.com/docs/break-before
36constant!(break before auto);
37constant!(break before avoid);
38constant!(break before all);
39constant!(break before avoid page);
40constant!(break before page);
41constant!(break before left);
42constant!(break before right);
43constant!(break before column);
44
45// https://tailwindcss.com/docs/break-inside
46constant!(break inside auto);
47constant!(break inside avoid);
48constant!(break inside avoid page);
49constant!(break inside avoid column);
50
51// https://tailwindcss.com/docs/box-decoration-break
52constant!(box decoration clone);
53constant!(box decoration slice);
54
55// https://tailwindcss.com/docs/box-sizing
56constant!(box border);
57constant!(box content);
58
59// https://tailwindcss.com/docs/display
60constant!(block);
61constant!(inline block);
62constant!(inline);
63constant!(flex);
64constant!(inline flex);
65
66constant!(table);
67constant!(inline table);
68constant!(table caption);
69constant!(table cell);
70constant!(table column);
71constant!(table column group);
72constant!(table footer group);
73constant!(table header group);
74constant!(table row group);
75constant!(table row);
76constant!(flow root);
77constant!(grid);
78constant!(inline grid);
79constant!(contents);
80constant!(list item);
81constant!(hidden);
82
83// https://tailwindcss.com/docs/float
84constant!(float start);
85constant!(float end);
86constant!(float right);
87constant!(float left);
88constant!(float none);
89
90// https://tailwindcss.com/docs/clear
91constant!(clear start);
92constant!(clear end);
93constant!(clear left);
94constant!(clear right);
95constant!(clear both);
96constant!(clear none);
97
98// https://tailwindcss.com/docs/isolation
99constant!(isolate);
100constant!(isolation auto);
101
102// https://tailwindcss.com/docs/object-fit
103constant!(object contain);
104constant!(object cover);
105constant!(object fill);
106constant!(object none);
107constant!(object scale down);
108
109// https://tailwindcss.com/docs/object-position
110constant!(object bottom);
111constant!(object center);
112constant!(object left);
113constant!(object left bottom);
114constant!(object left top);
115constant!(object right);
116constant!(object right bottom);
117constant!(object right top);
118constant!(object top);
119
120// https://tailwindcss.com/docs/overflow
121constant!(overflow auto);
122constant!(overflow hidden);
123constant!(overflow clip);
124constant!(overflow visible);
125constant!(overflow scroll);
126constant!(overflow x auto);
127constant!(overflow y auto);
128constant!(overflow x hidden);
129constant!(overflow y hidden);
130constant!(overflow x clip);
131constant!(overflow y clip);
132constant!(overflow x visible);
133constant!(overflow y visible);
134constant!(overflow x scroll);
135constant!(overflow y scroll);
136
137// https://tailwindcss.com/docs/overscroll-behavior
138constant!(overscroll auto);
139constant!(overscroll contain);
140constant!(overscroll none);
141constant!(overscroll y auto);
142constant!(overscroll y contain);
143constant!(overscroll y none);
144constant!(overscroll x auto);
145constant!(overscroll x contain);
146constant!(overscroll x none);
147
148// https://tailwindcss.com/docs/position
149#[doc = "static"]
150pub const static_: &'static str = "static";
151constant!(fixed);
152constant!(absolute);
153constant!(relative);
154constant!(sticky);
155
156// https://tailwindcss.com/docs/top-right-bottom-left
157constant!(top auto);
158size_0_to_96!(top);
159fraction_2_to_4!(top);
160constant!(top full);
161
162constant!(bottom auto);
163size_0_to_96!(bottom);
164fraction_2_to_4!(bottom);
165constant!(bottom full);
166
167constant!(left auto);
168size_0_to_96!(left);
169fraction_2_to_4!(left);
170constant!(left full);
171
172constant!(right auto);
173size_0_to_96!(right);
174fraction_2_to_4!(right);
175constant!(right full);
176
177constant!(inset auto);
178size_0_to_96!(inset);
179fraction_2_to_4!(inset);
180constant!(inset full);
181
182constant!(inset x auto);
183size_0_to_96!(inset x);
184fraction_2_to_4!(inset x);
185constant!(inset x full);
186
187constant!(inset y auto);
188size_0_to_96!(inset y);
189fraction_2_to_4!(inset y);
190constant!(inset y full);
191
192// https://tailwindcss.com/docs/visibility
193constant!(visible);
194constant!(invisible);
195constant!(collapse);
196
197// https://tailwindcss.com/docs/z-index
198constant!(z 0);
199constant!(z 10);
200constant!(z 20);
201constant!(z 30);
202constant!(z 40);
203constant!(z 50);
204constant!(z auto);
205
206any!(z);
207
208minus!(z 10);
209minus!(z 20);
210minus!(z 30);
211minus!(z 40);
212minus!(z 50);