Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: static/scss/components/_groups.scss

Issue 29453600: Issue 4961 - Fix card group field alignment on acceptableads.com (Closed) Base URL: https://hg.adblockplus.org/web.acceptableads.com
Patch Set: Restructure card markup and fixes Created June 13, 2017, 4:44 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
OLDNEW
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 263 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 width: 100%; 274 width: 100%;
275 } 275 }
276 // un-center all cards 276 // un-center all cards
277 .group > div:nth-child(4), 277 .group > div:nth-child(4),
278 .group > div:nth-child(3), 278 .group > div:nth-child(3),
279 .group > div:nth-child(5) 279 .group > div:nth-child(5)
280 { 280 {
281 margin-left: 0; 281 margin-left: 0;
282 } 282 }
283 } 283 }
284
285 @supports (display: grid)
286 {
287
288 .group
289 {
290 display: grid;
291 // Each card should be a minimum width of the $card-max-width. Otherwise, ta ke up available space
292 grid-template-columns: repeat(auto-fit, minmax($card-max-width, 1fr));
293 }
294
295 .group .card
296 {
297 display: inline-grid;
298 }
299
300 .group-4
301 {
302 @media (min-width: $desktop-breakpoint)
303 {
304 // Each card should take a minimum of 25% width of the group
305 grid-template-columns: repeat(auto-fit, minmax(25%, 1fr));
306 }
307 }
308
309 .group-5
juliandoucette 2017/06/16 19:39:17 I'm not sure how/why yet - but this patchset seems
ire 2017/06/21 07:47:58 I've fixed the centering of the last card in 5 car
310 {
311 @media (min-width: $desktop-breakpoint)
312 {
313 grid-template-columns: repeat(auto-fit, minmax(20%, 1fr));
314 }
315 }
316
317 .group-5 > div:nth-child(4)
ire 2017/06/13 16:51:23 Since this is overwriting a previous style, I stuc
juliandoucette 2017/06/16 19:39:17 Acknowledged.
318 {
319 @media all
juliandoucette 2017/06/16 19:39:17 Why @media all?
ire 2017/06/21 07:47:58 See comment above
320 {
321 margin-left: 0;
322 }
323 }
324
325 }
OLDNEW
« static/scss/components/_cards.scss ('K') | « static/scss/components/_cards.scss ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld