OLD | NEW |
1 // This file is part of acceptableads.org. | 1 // This file is part of acceptableads.org. |
2 // Copyright (C) 2016 Eyeo GmbH | 2 // Copyright (C) 2016 Eyeo GmbH |
3 // | 3 // |
4 // acceptableads.org is free software: you can redistribute it and/or modify | 4 // acceptableads.org is free software: you can redistribute it and/or modify |
5 // it under the terms of the GNU General Public License as published by | 5 // it under the terms of the GNU General Public License as published by |
6 // the Free Software Foundation, either version 3 of the License, or | 6 // the Free Software Foundation, either version 3 of the License, or |
7 // (at your option) any later version. | 7 // (at your option) any later version. |
8 // | 8 // |
9 // acceptableads.org is distributed in the hope that it will be useful, | 9 // acceptableads.org is distributed in the hope that it will be useful, |
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 // but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
292 width: 100%; | 292 width: 100%; |
293 } | 293 } |
294 // un-center all cards | 294 // un-center all cards |
295 .group > div:nth-child(4), | 295 .group > div:nth-child(4), |
296 .group > div:nth-child(3), | 296 .group > div:nth-child(3), |
297 .group > div:nth-child(5) | 297 .group > div:nth-child(5) |
298 { | 298 { |
299 margin-left: 0; | 299 margin-left: 0; |
300 } | 300 } |
301 } | 301 } |
| 302 |
| 303 @supports (display: grid) |
| 304 { |
| 305 |
| 306 .group.cards |
| 307 { |
| 308 display: grid; |
| 309 grid-template-columns: repeat(1, 1fr); |
| 310 |
| 311 @media (min-width: $card-min-width) |
| 312 { |
| 313 // Each card should be a minimum width of the $card-min-width. Otherwise,
take up available space |
| 314 grid-template-columns: repeat(auto-fit, minmax($card-min-width, 1fr)); |
| 315 } |
| 316 } |
| 317 |
| 318 .group.cards .card |
| 319 { |
| 320 display: inline-grid; |
| 321 width: 100%; |
| 322 grid-template-rows: auto 1fr auto; |
| 323 } |
| 324 |
| 325 .group.cards .card-summary |
| 326 { |
| 327 height: auto; |
| 328 } |
| 329 |
| 330 .group-4.cards |
| 331 { |
| 332 @media (min-width: $desktop-breakpoint) |
| 333 { |
| 334 // Each card should take a minimum of 25% width of the group |
| 335 grid-template-columns: repeat(auto-fit, minmax(25%, 1fr)); |
| 336 } |
| 337 } |
| 338 |
| 339 .group-5.cards |
| 340 { |
| 341 @media (min-width: $tablet-breakpoint) |
| 342 { |
| 343 grid-template-columns: repeat(auto-fit, minmax(33.3%, 1fr)); |
| 344 } |
| 345 @media (min-width: $desktop-breakpoint) |
| 346 { |
| 347 grid-template-columns: repeat(auto-fit, minmax(20%, 1fr)); |
| 348 } |
| 349 } |
| 350 |
| 351 .group-5.cards > div:nth-child(4), |
| 352 .group-5.cards > div:nth-child(5) |
| 353 { |
| 354 margin-left: 0; |
| 355 } |
| 356 |
| 357 .group-5.cards > div:nth-child(4) |
| 358 { |
| 359 @media (min-width: $tablet-breakpoint) and (max-width: $desktop-breakpoint -
1px) |
| 360 { |
| 361 margin-left: 50%; |
| 362 } |
| 363 } |
| 364 |
| 365 .group-5.cards > div:nth-child(5) |
| 366 { |
| 367 @media (min-width: 700px) and (max-width: $desktop-breakpoint - 1px) |
| 368 { |
| 369 margin-left: 50%; |
| 370 } |
| 371 } |
| 372 } |
OLD | NEW |