When you’re laying out content pulled in via a Collection List, you might notice content of different lengths breaking your tidy grid. Thankfully, flexbox can help you fix this problem, giving you more control over your layout, especially on different devices.
This quick tutorial will show you how easy it is to convert your existing Collection List layouts to a more fluid, flexbox-powered grid layout.
We’ll be styling three different elements throughout this tutorial:
First, select your Collection List Wrapper, then go to the Settings tab.
Then set the layout to full-width. This clears out the the floating columns applied to your Collection items, allowing each item to stretch across its own row.
Next, select your Collection List, then switch over to the Styles panel.
Give your Collection List a class name, then give it the flex display setting. This will cause all of your Collection items to bunch up together, each in their own column, in one row.
Now tick the the Wrap Children checkbox.
Build completely custom, production-ready websites — or ultra-high-fidelity prototypes — without writing a line of code. Only with Webflow.
Now let’s style those Collection items themselves. Select the Collection Item in the Navigator, then switch to the Styles tab and create a new class.
Next, under the Flex Child Settings, click the cog icon to access the Advanced Sizing settings. In the third field, you can set a percentage for the width of your columns.
You can set your fluid grid to have any number of columns per row. For example:
Finally, toggle through each breakpoint to set the right width for each viewport.
Switch to preview mode and enjoy your new, more flexible layout!
In your inbox, every other week. And unsubscribe in a click, if you want.