benjaminkott / benjaminkott/bootstrap_package

masonry layout for gallery via backend option

Open
#768 2 comments 0 reactions 1 assignee Claimed by @gilbertsoft View on GitHub
feature
Dominant language
PHP
Stars
355
Forks
212
Avg merge
1h 4m
Merged PRs (30d)
31

Description

# Feature Request

Right now you can create a gallery of images and each row has the same height. If you have a picture in portrait mode and several landscape images you will end up with white space under the landscape images.
see this: https://stackoverflow.com/questions/33512647/flexbox-stack-different-height-childs

It would be nice to have an option for a gallery you will get using the masonry library: https://masonry.desandro.com/

**Is your feature request related to a problem? Please describe.**
No

**Describe the solution you'd like**

1)
A solution could be this: http://thenewcode.com/844/Easy-Masonry-Layout-With-Flexbox

set `flex-direction:column` and a `height` to the gallery container.

2 problems I noticed:
- depending on the number ans sizes of images the `height` has to be variable. A fixed `height` does not work an every case.
- if you set the `flex-direction` to `column` the order of images is vertically and not chronological anymore

2)
another solution could be the use of css grid but that would need a fallback for IE
https://codepen.io/balazs_sziklai/pen/mOwoLg

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.