In Phase 3 of our Mastering Flexbox series, we explored Layout Wrapping, the differences between Wrap and No Wrap, how Align Content material subject material affects wrapped multi-line layouts, and the best way Wrap Reverse and Display Order can fortify responsive drift.
In this fourth installment, we’ll focal point on probably the most the most important common construction tough scenarios in web design: aligning content material subject material without relying on hidden spacers, information spacing hacks, or custom designed CSS.
Forward of Divi 5, designers often used empty Divider modules, information padding, margins, or custom designed CSS to push content material subject material into place, create visual balance, or energy portions to align inside equal-height packing containers. Those methods worked, then again they added further building, required further breakpoint-specific cleanup, and made layouts harder to maintain.
Divi 5 will give you a cleaner visual workflow. With Flexbox controls harking back to Justify Content material subject material, Align Items, Align Content material subject material, and Hollow, plus supporting apparatus like Broaden To Fill, Module Teams, and Nested Modules, you’ll align content material subject material directly inside the Visual Builder with far a lot much less custom designed code.
Let’s dive in.
Why Typical Alignment Methods Fall Temporary
Forward of Divi 5, precise vertical or horizontal alignment often required workarounds. Some of the the most important most common techniques integrated:
- The usage of hidden Divider modules to push content material subject material down or create artificial space.
- Together with custom designed CSS to vertically center or bottom-align content material subject material inside equal-height columns.
- Relying on information padding and margin values that sought after constant adjustment all over breakpoints.
Those approaches would possibly treatment the fast visual downside, then again as well as they made layouts further fragile. If a headline changed, a button label wrapped, or a little bit switched to a smaller breakpoint, the construction often sought after every other round of spacing adjustments.
With Divi 5’s native Flexbox Format Machine, alignment will also be handled at the container level. Tools like Justify Content material subject material, Align Items, Hollow, and Broaden To Fill mean you can create balanced layouts that answer further naturally to exact content material subject material.

Core Alignment Tools You’ll Use Most
Most Flexbox alignment controls live inside the Layout selection workforce. Crucial ones to clutch are Justify Content material subject material, Align Items, Align Content material subject material, and Hollow.
Justify Content material subject material distributes child portions along the main axis. In a Row direction, that in most cases means horizontal distribution. In a Column direction, that in most cases means vertical distribution. Its possible choices, along side Get began, Heart, End, Space Between, Space Spherical, and Space Evenly, mean you can keep an eye on how content material subject material is positioned inside its mum or dad container.

Align Items controls alignment along the move axis. In a Row construction, this in most cases affects vertical alignment. In a Column construction, it in most cases affects horizontal alignment. The available possible choices, Get began, Heart, End, and Stretch, are useful for centering items, aligning edges, or stretching items when their sizing shall we in it.

When Layout Wrapping is enabled and content material subject material flows onto a couple of lines, Align Content material subject material controls how those wrapped lines are allotted along the move axis. This surroundings most efficient has a visible have an effect on when there are a couple of flex lines and the mum or dad container has extra space to distribute, harking back to a defined or minimum peak.

The ones alignment apparatus develop into a lot more difficult when combined with Horizontal Hollow and Vertical Hollow for consistent spacing, Broaden To Fill inside the Sizing selection workforce for flexible products growth, Module Teams for grouping similar modules, and Nested Modules for rising impartial alignment contexts inside modules.
Alignment Examples Built With Divi 5
To show how the ones apparatus art work together, let’s walk through a few smart alignment examples and the settings used in every one.

Serve as: Assemble a header navigation where the logo and menu links take a seat down on the left, the CTA buttons take a seat down on the suitable, and the whole thing stays vertically targeted.
Settings Used: The construction uses a single-column row. At the column level, Justify Content material subject material is set to Space Between, Align Items is set to Heart, and the Horizontal Hollow is set to 20px. The main Module Staff, containing the logo and navigation links, uses Justify Content material subject material > Space Between and Align Items > Heart. The second Module Staff, containing the two buttons, uses Justify Content material subject material > End, Align Items > Heart, and a 10px Horizontal Hollow so the buttons take a seat down neatly side-by-side.
This combination creates a balanced navigation header without hidden spacing modules or information margin adjustments between every element.
2. Hero Phase

Serve as: Create a clean hero segment where the content material subject material stacks vertically, spacing stays consistent, and the two CTA buttons take a seat down side-by-side.
Settings Used: The mum or dad row uses Align Items > Stretch. At the column level, Align Items and Justify Content material subject material are every set to Get began, with a 20px Vertical Hollow performed between child portions. A Module Staff wraps the two buttons the usage of Layout Trail > Row and a 15px Horizontal Hollow, protective them aligned horizontally with consistent space between them.
This fashion will give you predictable spacing from the mum or dad container as an alternative of relying on further Divider modules or one-off padding values.
3. Statistics Grid

Serve as: Display 4 key metrics in a responsive grid where every stat card feels targeted, balanced, and easy to scan.
Settings Used: This segment uses a four-column row with Layout Wrapping > Wrap and Column Class > 1/2 on every column, creating a two-by-two grid. The row uses 20px Horizontal Hollow and 20px Vertical Hollow to keep an eye on spacing between the enjoying playing cards. At the column level, Justify Content material subject material and Align Items are every set to Heart. Each and every column moreover uses 20px Padding on all 4 aspects inside the Spacing selection workforce to create breathing room inside every card.
Hollow handles spacing between enjoying playing cards, while padding handles spacing inside every card. Holding those two roles separate makes the construction more straightforward to control all over breakpoints.
4. Supplier Taking part in playing cards

Serve as: Create a supplier segment where the headline row aligns cleanly and every supplier card keeps its button positioned consistently, despite the fact that text lengths vary.
Settings Used: The very best row makes use of 2 columns with Column Class > 1/2 and Align Items > End at the row level to align the content material subject material against the bottom edge. Each and every column moreover uses Align Items > Stretch so its internal portions can fill the available width.
The second row contains six columns with Layout Wrapping > Wrap and Column Class > 1/2. The row uses Align Items > Get began. Inside every supplier card, the Heading module uses a Nested Module for the supporting text, paired with a 10px Horizontal Hollow for spacing. Broaden To Fill is enabled where the content material subject material space needs to absorb extra space, helping the button stay aligned with reference to the bottom of every card.
This technique is useful for card layouts where text lengths vary then again the CTA position needs to stick consistent.
5. Mixed-Width Highlight Phase

Serve as: Assemble a focus space that combines a large featured content material subject material block, a statistic card, and smaller supporting packing containers while protective the construction visually balanced.
Settings Used: This segment uses a row with blended column spans and Layout Wrapping. The row has every Horizontal Hollow and Vertical Hollow set to 30px. At the mum or dad level, Align Items > Stretch helps columns percentage a relentless row peak when their sizing shall we in it. One column uses Justify Content material subject material > Space Between to distribute its internal content material subject material from peak to bottom, while the other columns use Get began. A 15px Vertical Hollow on every column controls spacing between modules, and every column moreover applies 20px Padding on all 4 aspects for internal breathing room.
This combination creates a further dynamic construction while protective spacing, alignment, and internal building more straightforward to keep an eye on.
6. Process Steps

Serve as: Assemble a four-step How It Works process construction where icons, step numbers, headings, and supporting text stay structured and aligned all over columns.
Settings Used: This segment uses a two-column row with Column Class > 1/2 and Layout Wrapping > Wrap enabled. Each and every column has 10px Padding on all 4 aspects for internal spacing. At the column level, Align Items > Stretch and Justify Content material subject material > Get began are performed.
Inside every column, a Module Staff wraps the icon and step amount. This workforce uses Layout Trail > Row, Justify Content material subject material > Space Between, and Align Items > Heart, protective the icon and large amount aligned on the equivalent horizontal line.
This setup creates a structured process segment without further spacer modules.
Step-By the use of-Step Assemble Walkthrough
Let’s walk through learn how to assemble a three-column workforce member card segment the usage of native Flexbox alignment apparatus, with Spacing used most efficient where it is helping internal padding or visual breathing room.
Step 1: Create The Guardian Row
Add a brand spanking new three-column row. Choose Flex for the reason that Layout Style if it isn’t already determined on. Set the row to Layout Wrapping > Wrap when you occur to devise with the intention to upload more than 3 workforce members later. This allows additional columns to move onto new flex lines as an alternative of requiring further rows.
Next, set the Horizontal Hollow and Vertical Hollow to 20px for consistent spacing between columns.

Open the main column’s settings. Throughout the Content material subject material tab, assign a Background Color.

Throughout the Layout selection workforce, set the Vertical Hollow to 0px. This removes automatic spacing between the column’s direct child portions so the card building will also be controlled further intentionally with internal Module Groups.

Use the Border selection workforce with the intention to upload a Border Radius, Border Style, Border Width, and Border Color to the column.

Return to the row and make a choice the Content material subject material tab. Throughout the Portions selection workforce, right-click the main column, copy its products types, and paste those types onto the rest columns.
Step 2: Add The Content material subject material
Add an Image module to the main column. Throughout the Design tab, building up the Sizing selection workforce and set the Facet Ratio to 1:1. This frames the image as a sq..

Next, building up the Framing selection workforce. Change Object Are compatible from the default Are compatible strategy to Duvet. Use the Object Position picker to choose which part of the image will have to keep visible all over the sq. frame.
Next, add a Module Staff and a Heading module to the main column.
Throughout the Staff’s Design tab, open the Layout selection workforce and set a 15px Vertical Hollow. Then open the Spacing selection workforce and add 20px Padding to all 4 aspects.
Add a Text module as a nested element inside the main Heading module.

Nested Modules imply you’ll place modules inside other modules, turning the mum or dad module correct right into a construction container. This will give you every other level of keep an eye on over alignment, spacing, and internal building.
Next, add a brand spanking new Module Staff with 3 Text modules below the other modules inside the column. Style them as sought after, then regulate the Staff’s Flexbox settings. Throughout the Layout selection workforce, set the Horizontal Hollow and Vertical Hollow to 8px. Use Row for the Layout Trail and make allowance Layout Wrapping so the tags can drift onto additional lines when sought after.

To finish the column, add every other Module Staff. Use the Layers panel to make sure it’s nested all over the Primary Staff.

During without equal Staff, add a Social Media Observe module and a Text module, then style them. Set the Staff’s Layout Trail to Row and Justify Content material subject material to Space Between.

Alignment will also be controlled at the module level, too. Throughout the Text module’s Layout selection workforce, set every Justify Content material subject material and Align Items to Heart.

Fill the rest two columns with content material subject material to finish the initial design.
Step 3: Make Alignment Adjustments
Depending on the duration of your content material subject material, such for the reason that bio text or the collection of skill tags, chances are high that you’ll perceive small alignment shifts.

To stick the construction balanced as content material subject material changes, make a few targeted Flexbox and Sizing adjustments with Justify Content material subject material and Broaden To Fill.
Although it may well be tempting to set Justify Content material subject material > Space Between most efficient at the column level, that doesn’t treatment every internal alignment issue. It separates the main and supreme direct child portions, then again heart content material subject material harking back to bios and tags would in all probability nevertheless shift depending on its duration.
A further unswerving manner is to set every Column and number one Module Staff to Justify Content material subject material > Space Between, then use Broaden To Fill on the content material subject material space that should absorb the rest space.
Next, make a choice the number one Module Staff. Open the Sizing selection workforce and make allowance Broaden To Fill.
This allows the main content material subject material workforce to extend all over the cardboard, helping the bottom Social Icons workforce stay aligned with reference to the highest of the card all over different content material subject material lengths.
To stick the Tag Staff aligned above the Social Staff, permit Broaden To Fill on the Heading module as well.
This lets the heading and bio space absorb extra space, protective the tag workforce and social row in a further consistent position as content material subject material changes.

Step 4: Use Divi 5’s Responsive Tools
Flexbox helps layouts adapt all over breakpoints, then again you will have to nevertheless review tablet and get in touch with views. Use Divi’s Customizable Responsive Breakpoints to preview the construction on smaller screens. Switch between breakpoints to spot alignment or spacing issues, then apply targeted adjustments with per-breakpoint Flexbox settings, Column Class values, or Development Templates when sought after.
Step 5: Edit, Copy, Or Delete Columns
Once your workforce member card works all over breakpoints, together with further workforce members is unassuming. Open the row settings, then move to the Portions selection workforce. From correct right here, you’ll edit, reproduction, or delete any column.

Duplicating a column copies the column styling, Flexbox settings, padding, borders, and nested modules. Exchange the content material subject material inside the new column, then review the construction at every breakpoint. Because of Layout Wrapping is enabled on the row, additional enjoying playing cards can drift onto new lines as an alternative of requiring new rows.
Best possible Practices And Skilled Tips
Now that you just’ve seen Flexbox alignment in movement, listed below are a few smart guidelines that can assist you assemble cleaner, further maintainable layouts.
Control Alignment In line with Breakpoint
You don’t have to use the an identical alignment settings all over every device. For example, it’s good to use Heart alignment on mobile for upper visual balance while protective Get began alignment on desktop. Divi 5’s Responsive Editor and Customizable Responsive Breakpoints make the ones changes more straightforward to keep an eye on.
Combine Alignment With Layout Trail
Switching between Row and Column direction at different breakpoints changes how Justify Content material subject material and Align Items behave. Use this intentionally when a horizontal desktop construction will have to develop into a stacked or targeted mobile construction.
Use Most sensible When Running With Align Content material subject material
Align Content material subject material most efficient has a visible have an effect on when wrapping creates a couple of flex lines and the mum or dad container has further cross-axis space. Together with a peak or minimum peak, harking back to 600px, provides Align Content material subject material room to distribute those wrapped lines.
At all times Check out With Exact Content material subject material
Placeholder content material subject material can hide alignment issues. Check out with fast, medium, and long copy, different button labels, more than a few tag counts, and exact footage early inside the process so that you’ll catch construction issues forward of publishing.
Download The Layouts
That will help you apply the whole thing coated in this publish, we’ve in a position a zipped report known as Flexbox Alignment. It accommodates the example layouts confirmed above, built with Flexbox alignment patterns you’ll check out and reuse. You’ll be capable to import any construction individually or upload the Flexbox Alignment – ALL.json report to import them all at once.

To import them, move to your WordPress dashboard and navigate to Divi > Divi Library. Click on at the Import & Export button at the peak.

Switch to the Import tab, make a choice a JSON report, and click on on Import Divi Builder Layouts.

Once imported, open a internet web page inside the Visual Builder or create a brand spanking new one. When the Builder reasonably so much, click on on with the intention to upload a new segment to the internet web page.

Choose the Add From Library tab, make a choice a construction, and click on on Use This Phase to load it onto the internet web page.
Snatch Alignment With Flexbox In Divi 5
For a lot of common alignment patterns, you no longer need hidden Divider modules, spacing hacks, or custom designed CSS. Divi 5‘s Flexbox apparatus get a hold of visual, content-aware controls for positioning, spacing, and aligning portions all over responsive layouts.
In Section 5 Of Mastering Flexbox: Reordering Content material subject material For Upper Cell Layouts, we’ll show learn how to combine Display Order, Flexbox direction changes, and Wrap Reverse to create upper mobile flows without duplicating content material subject material.
Download the example layouts, experiment inside the Visual Builder, and get began building cleaner, further maintainable pages. Drop a observation below and let us know which alignment method you’re most excited to try.
The publish Phase 4 Of Mastering Flexbox: Aligning Content material With out Spacers Or Customized CSS seemed first on Sublime Subject matters Weblog.


![15 Very best Examples of Skilled Targets [+Tips to Achieve Them]](https://wpmountain.com/wp-content/uploads/2022/07/a482387e-c9f6-456b-b92f-4ba795780b19-150x60.png)


0 Comments