Gallery right margin hide
-
Hi Me again. I used the code Michael(@alchymyth) supplied which was fine, for only three columns but now I need to use 4, 5, and 6 columns. When I do they space unevenly. I have removed the previous css edit, obviously the gallery has reverted to showing the right margin on the last item. How would the code below be edited to include up to six items. I have removed the css below.
demo at https://www.nicallen.com/hbs/?page_id=132
.gallery-item { margin-right: 4%; padding-right: 0; width: 48%;}
.gallery-item:nth-child( 2n ) { margin-right: 0; }
@media screen and (min-width: 30em) {
.gallery-columns-3 .gallery-item { padding-right: 0; width: 32%; margin-right: 2%; }
.gallery-columns-3 .gallery-item:nth-child( 3n ) { margin-right: 0; }
}
@media screen and (max-width: 30em) {.gallery-columns-3 .gallery-item {
min-width: 100%;
}
}PS I am using a child theme which has the full width page fix applied.
Thanks Best wishes Nick.
- The topic ‘Gallery right margin hide’ is closed to new replies.