Skip to content

Fix: Bootstrap 4 flexbox grid #75

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 2, 2016
Merged

Conversation

stroebjo
Copy link
Contributor

@stroebjo stroebjo commented Apr 1, 2016

The flexbox enabled grid in bootstap 4 requires the lowest .col- to be set. twbs/bootstrap#17603 (comment)

The flexbox enabled grid in bootstap 4 requires the lowest `.col-` to be set. twbs/bootstrap#17603 (comment)
@DataTables
Copy link
Collaborator

I'm afraid I don't quite understand. If the viewport is less than md then I want the columns to be broken up into rows. Has that changed in v4? The docs don't seem to reflect such a change.

@stroebjo
Copy link
Contributor Author

stroebjo commented Apr 4, 2016

In the classic float grid it works in v4, but when you enable flexbox in Bootstrap the rows wont be 100% width. See the attached screens.
If you use the flexbox grid the grid cells dont fallback to 100% width, on lower breakpoints, you need to explictly define die lower breakpoints (col-xs-12).

Classic float grid in v4, centered cells on xs.
twbs4-float-col-md

Flexbox grid, without col-xs-12, rows stick to left.
twbs4-flex-col-md

Flexbox grid, added col-xs-12, works as expected.
twbs4-flex-col-xs

@DataTables
Copy link
Collaborator

Ah I see - thanks for the clarification. I wonder if we should wait for the BS issue you linked to to be resolved before making changes here.

@DataTables DataTables merged commit 6049a1e into DataTables:master Dec 2, 2016
@DataTables
Copy link
Collaborator

Sorry its taken me so long to get around to this! I agreed, based on mdo's comment's in that bug that your fix is correct. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants