fix: Use container-fluid for builder-compatible components #2641
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR Type
What kind of change does this PR introduce?
Description
Before
https://imgur.com/ZyUlCn0
After
https://imgur.com/ZY8J8fZ
Problem
When Directorist components (
all-authors,author-contents, andsidebar-archive-contents) are used within page builders (Elementor, Gutenberg, etc.), the hardcodeddirectorist-containerclass applies max-width constraints that conflict with the builder's layout system. This prevents proper container control from the builder side.Solution
Changed container classes from
directorist-containertodirectorist-container-fluidin three template files:templates/all-authors.php(line 16)templates/author-contents.php(line 15)templates/sidebar-archive-contents.php(line 13)Technical Details
Why container-fluid?
directorist-containerapplies responsive max-widths (540px → 1320px) that interfere with builder layoutsdirectorist-container-fluiduseswidth: 100%with no max-width, allowing full builder controldirectorist_container()anddirectorist_container_fluid()) support filters for builder overrides, but container-fluid is the appropriate default for embedded componentsConsistency
This change aligns with existing patterns:
templates/single-contents.phpalready usesHelper::directorist_container_fluid()templates/dashboard-contents.phpalready usesHelper::directorist_container_fluid()Builder Integration
Page builders typically wrap components in their own container elements. By using
container-fluid, we:Testing
Impact
Any linked issues
Fixes #
Checklist