UNPKG

5.55 kBTypeScriptView Raw
1declare namespace imbacss {
2 /** Represents elements whose numeric position in a series of siblings is odd 1, 3, 5, etc
3* @detail :nth-child(odd)
4*/
5 interface αodd { name: 'nth-child', valueType: 'string', value: 'odd' };
6
7 /** Represents elements whose numeric position in a series of siblings is even 2, 4, 6, etc
8 * @detail :nth-child(even)
9 */
10 interface αeven { name: 'nth-child', valueType: 'string', value: 'even' };
11
12 /** Represents the first element among a group of sibling elements
13 * @detail :first-child
14 */
15 interface αfirst { name: 'first-child' }
16
17 /** Represents the last element among a group of sibling elements
18 * @detail :last-child
19 */
20 interface αlast { name: 'last-child' };
21
22 /** Represents an element without any siblings
23 * @detail :only-child
24 */
25 interface αonly { name: 'only-child' };
26
27 /** Generally triggered when the user hovers over an element with the cursor (mouse pointer) */
28 interface αhover { name: 'hover' };
29
30 /** Element is being activated by the user. When using a mouse, "activation" typically starts when the user presses down the primary mouse button. */
31 interface αactive { name: 'active' };
32
33 interface αvisited { name: 'visited' };
34
35 interface αlink { name: 'link' };
36
37 interface αenabled { name: 'enabled' };
38
39 interface αchecked { name: 'checked' };
40
41 interface αinvalid { name: 'invalid' };
42
43 interface αvalid { name: 'valid' };
44
45 /** Element has focus */
46 interface αfocus { name: 'focus' };
47
48 /** Element OR descendant of element has focus */
49 interface αfocin {};
50
51
52 /** @detail (min-width: 480px) */
53 interface αxs { media: '(min-width: 480px)' }
54 /** @detail (min-width: 640px) */
55 interface αsm { media: '(min-width: 640px)' }
56 /** @detail (min-width: 768px) */
57 interface αmd { media: '(min-width: 768px)' }
58 /** @detail (min-width: 1024px) */
59 interface αlg { media: '(min-width: 1024px)' }
60 /** @detail (min-width: 1280px) */
61 interface αxl { media: '(min-width: 1280px)' }
62
63 /** @detail (max-width: 479px) */
64 interface αltΞxs { media: '(max-width: 479px)' }
65 /** @detail (max-width: 639px) */
66 interface αltΞsm { media: '(max-width: 639px)' }
67 /** @detail (max-width: 767px) */
68 interface αltΞmd { media: '(max-width: 767px)' }
69 /** @detail (max-width: 1023px) */
70 interface αltΞlg { media: '(max-width: 1023px)' }
71 /** @detail (max-width: 1279px) */
72 interface αltΞxl { media: '(max-width: 1279px)' }
73
74 // color modifiers
75
76 /** Indicates that user has notified that they prefer an interface that has a dark theme.
77 * @detail (prefers-color-scheme: dark)
78 */
79 interface αdark { media: '(prefers-color-scheme: dark)' }
80
81 /** Indicates that user has notified that they prefer an interface that has a light theme, or has not expressed an active preference.
82 * @detail (prefers-color-scheme: light)
83 */
84 interface αlight { media: '(prefers-color-scheme: light)' }
85
86 /**
87 * @custom
88 * @summary Matches when a `@touch` handler is active for element
89 */
90 interface αtouch { flag: '_touch_' }
91
92 /**
93 * @custom
94 * @summary Matches when a `@touch.moved` modifier is active for element
95 */
96 interface αmove { flag: '_move_' }
97
98 /**
99 * @custom
100 * @summary Matches when a `@touch.hold` modifier is active for element
101 */
102 interface αhold { flag: '_hold_' }
103
104 /**
105 * @custom
106 * @summary Matches components rendered from server that are not hydrated
107 */
108 interface αssr { flag: '_ssr_' }
109
110 /**
111 * @custom
112 * @summary Matches when the element has been suspended (see imba.Component.suspend)
113 */
114 interface αsuspended { flag: '_suspended_' }
115
116 /**
117 * The viewport is in a landscape orientation, i.e., the width is greater than the height.
118 * @detail (orientation: landscape)
119 * */
120 interface αlandscape { media: '(orientation: landscape)' }
121
122 /**
123 * The viewport is in a portrait orientation, i.e., the height is greater than or equal to the width.
124 * @detail (orientation: portrait)
125 */
126 interface αportrait { media: '(orientation: portrait)' }
127
128 /**
129 * @summary Intended for paged material and documents viewed on a screen in print preview mode.
130 * @detail (media: print)
131 */
132 interface αprint { media: 'print' }
133
134 /**
135 * @summary Intended primarily for screens.
136 * @detail (media: screen)
137 */
138 interface αscreen { media: 'screen' }
139
140 /**
141 * @summary Pseudo-element that is the first child of the selected element
142 * @detail ::before { ... }
143 * @pseudoelement
144 */
145 interface αbefore { name: '::before' }
146
147 /**
148 * @summary Pseudo-element that is the last child of the selected element
149 * @pseudoelement
150 * @detail ::after { ... }
151 */
152 interface αafter { name: '::after' }
153
154
155 /**
156 * @see [Transitions](https://imba.io/css/transitions)
157 * @summary Matches when element is transitioning into the dom
158 * @custom
159 */
160 interface αin { }
161
162 /**
163 * @see [Transitions](https://imba.io/css/transitions)
164 * @summary Matches when element is transitioning out of the dom
165 * @custom
166 */
167 interface αout { }
168
169 /**
170 * @see [Transitions](https://imba.io/css/transitions)
171 * @summary Matches when element is transitioning into or out of the dom
172 * @custom
173 */
174 interface αoff { }
175}
\No newline at end of file