Merge pull request #5989 from WoltLab/wsc-rpc-api-const
[GitHub/WoltLab/WCF.git] / wcfsetup / install / files / style / layout / containerList.scss
... / ...
CommitLineData
1.containerList {
2 > li {
3 position: relative;
4 transition: background-color 0.2s;
5
6 @include screen-md-down {
7 padding: 10px 0;
8 }
9
10 @include screen-lg {
11 padding: 20px;
12 }
13
14 &:not(:last-child) {
15 border-bottom: 1px solid var(--wcfContentBorderInner);
16 }
17
18 &:first-child {
19 border-top: 1px solid var(--wcfContentBorder);
20 }
21
22 &:last-child {
23 border-bottom: 1px solid var(--wcfContentBorder);
24 }
25
26 &:hover {
27 background-color: var(--wcfTabularBoxBackgroundActive);
28 }
29
30 &.showMore {
31 text-align: center;
32
33 &:hover {
34 background-color: transparent;
35 }
36 }
37
38 .containerHeadline {
39 position: relative;
40
41 > .containerContentType {
42 color: var(--wcfContentDimmedText);
43 position: absolute;
44 top: 5px;
45 right: 0;
46
47 @include screen-xs {
48 display: none;
49 }
50 }
51 }
52
53 &.containerListButtonGroup {
54 text-align: right;
55
56 &:hover {
57 background-color: transparent;
58 }
59
60 > .buttonGroup {
61 display: inline-flex;
62
63 &:not(:first-child) {
64 margin-left: 5px;
65 }
66 }
67 }
68
69 @include screen-md-down {
70 .hasMobileNavigation > .containerHeadline > h3 {
71 padding-right: 30px;
72 }
73
74 .buttonGroupNavigation {
75 position: absolute;
76 right: 0;
77 top: 14px;
78
79 &.open {
80 left: 0;
81
82 // dropdown is contained within this element, required to have it stand
83 // above any succeeding siblings
84 z-index: 10;
85
86 > .buttonList {
87 display: block;
88 visibility: visible;
89 }
90 }
91
92 > .dropdownLabel {
93 left: calc(100% - 24px);
94 position: relative;
95 }
96
97 > .buttonList {
98 @include dropdownMenu;
99
100 position: static !important;
101 top: 0;
102
103 > li {
104 .invisible {
105 display: inline;
106 padding-left: 5px;
107 }
108 }
109 }
110 }
111 }
112
113 @include screen-lg {
114 .buttonGroupNavigation {
115 opacity: 0;
116 position: absolute;
117 right: 20px;
118 top: 15px;
119 transition: opacity 0.12s;
120
121 > .dropdownLabel {
122 display: none;
123 }
124
125 > ul {
126 background-color: var(--wcfContentBackground);
127 border-radius: var(--wcfBorderRadius);
128 box-shadow: var(--wcfBoxShadowCard);
129
130 > li {
131 margin-right: 0;
132
133 &:not(:last-child) {
134 border-right: 1px solid var(--wcfContentContainerBorder);
135 }
136
137 > a,
138 > button {
139 display: inline-block;
140 padding: 3px 5px;
141
142 > fa-icon,
143 > .invisible {
144 opacity: 0.5;
145 }
146 }
147
148 &.active,
149 &:hover {
150 > a,
151 > button {
152 > fa-icon,
153 > .invisible {
154 color: var(--wcfContentText);
155 opacity: 1;
156 }
157 }
158 }
159 }
160 }
161 }
162
163 &:hover .buttonGroupNavigation {
164 opacity: 1;
165 }
166 }
167 }
168
169 @include screen-sm-down {
170 &.doubleColumned,
171 &.tripleColumned {
172 > li + li {
173 margin-top: 10px;
174 }
175 }
176 }
177
178 @include screen-md-up {
179 &.doubleColumned,
180 &.tripleColumned {
181 display: flex;
182 flex-wrap: wrap;
183
184 > li {
185 // this will cause the mobile drop-down menu to be cut-off
186 // overflow: hidden;
187 padding-right: 15px;
188
189 .containerBoxContent {
190 overflow: hidden;
191
192 h3 {
193 overflow: hidden;
194 text-overflow: ellipsis;
195 white-space: nowrap;
196 }
197 }
198
199 &:first-child {
200 border-top: none;
201 }
202
203 &:last-child {
204 border-bottom: none;
205 }
206 }
207
208 border-top: 1px solid var(--wcfContentBorder);
209 border-bottom: 1px solid var(--wcfContentBorder);
210 }
211
212 &.doubleColumned > li {
213 flex: 0 0 50%;
214 max-width: 50%;
215
216 &:nth-child(2n + 1):nth-last-child(-n + 2) {
217 border-bottom: none;
218 }
219 }
220
221 &.tripleColumned > li {
222 /* The `flex` shorthand fails in IE11 if `calc()` is used. */
223 flex-grow: 0;
224 flex-shrink: 0;
225 flex-basis: calc(100% / 3);
226
227 &:nth-child(3n + 1):nth-last-child(-n + 3),
228 &:nth-child(3n + 1):nth-last-child(-n + 3) ~ li {
229 border-bottom: none;
230 }
231 }
232 }
233}
234
235@include screen-lg {
236 html[data-color-scheme="dark"] .containerList > li .buttonGroupNavigation > ul {
237 border: 1px solid var(--wcfContentContainerBorder);
238 }
239}
240
241.containerBoxList {
242 @include screen-sm-down {
243 &.doubleColumned,
244 &.tripleColumned {
245 > li + li {
246 margin-top: 10px;
247 }
248 }
249 }
250
251 @include screen-md-up {
252 &.doubleColumned,
253 &.tripleColumned {
254 display: flex;
255 flex-wrap: wrap;
256 margin-bottom: -15px;
257
258 > li {
259 overflow: hidden;
260 padding-right: 15px;
261 margin-bottom: 15px;
262
263 .containerBoxContent {
264 overflow: hidden;
265
266 h3 {
267 overflow: hidden;
268 text-overflow: ellipsis;
269 white-space: nowrap;
270 }
271 }
272 }
273 }
274
275 &.doubleColumned > li {
276 flex: 0 0 50%;
277 max-width: 50%;
278 }
279
280 &.tripleColumned > li {
281 /* The `flex` shorthand fails in IE11 if `calc()` is used. */
282 flex-grow: 0;
283 flex-shrink: 0;
284 flex-basis: calc(100% / 3);
285 }
286 }
287}
288
289.flexibleCategoryList {
290 position: relative;
291
292 > li {
293 margin-bottom: 14px;
294
295 > ol {
296 margin-left: 21px;
297 }
298
299 > ol > li > ol {
300 margin-bottom: 7px;
301 margin-left: 21px;
302
303 > li {
304 font-size: var(--wcfFontSizeSmall);
305 }
306 }
307 }
308}
309
310.containerListDisplayOptions {
311 align-items: center;
312 border-bottom: 2px solid currentColor;
313 color: var(--wcfTabularBoxHeadline);
314 display: flex;
315}
316
317.containerListSortOptions,
318.containerListActiveFilters,
319.containerListFilterOptions {
320 padding: 5px 10px;
321}
322
323@include screen-sm-down {
324 .containerListActiveFilters {
325 display: none;
326 }
327}
328
329.containerListSortOptions {
330 flex: 1 auto;
331
332 > .dropdown {
333 margin-left: 10px;
334 }
335
336 fa-icon {
337 color: var(--wcfTabularBoxHeadline);
338 }
339}
340
341.containerListActiveFilters,
342.containerListFilterOptions {
343 flex: 0 auto;
344}
345
346@include screen-md-up {
347 .flexibleCategoryList:not(.flexibleCategoryListDisabled) {
348 /* WebKit */
349 -webkit-column-count: 2;
350
351 /* Firefox */
352 -moz-column-count: 2;
353
354 /* CSS 3 / Internet Explorer */
355 column-count: 2;
356
357 > li {
358 /* WebKit */
359 -webkit-column-break-inside: avoid;
360
361 /* CSS 3 / Internet Explorer */
362 break-inside: avoid;
363
364 > ol > li > ol {
365 font-size: 0;
366
367 > li {
368 display: inline-block;
369 @include wcfFontSmall;
370 }
371 }
372 }
373 }
374
375 /* Firefox */
376 @-moz-document url-prefix() {
377 .flexibleCategoryList:not(.flexibleCategoryListDisabled) > li {
378 display: block;
379 overflow: hidden;
380 }
381 }
382}
383
384.styleListPreviewImage {
385 text-align: center;
386}
387
388@include screen-md-down {
389 .styleList > li {
390 padding: 10px;
391 }
392}