Skip to content
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

Customizable grid gutters per breakpoint #17481

Merged

Conversation

pixelbandito
Copy link
Contributor

As per #17021 (which references #11873), this change adds a $grid-gutters-widths array in _variables.scss, and then uses the array in the grid framework instead of a single gutter width.

Possible concern: The old $grid-gutter-width was used several places, so I left it in; but that might cause confusion.

@@ -119,6 +118,13 @@ $container-max-widths: (
$grid-columns: 12 !default;
$grid-gutter-width: 1.875rem !default; // 30px
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confusing indeed, this one should be removed.

@mdo mdo mentioned this pull request Dec 8, 2015
17 tasks
@julionc
Copy link

julionc commented Dec 24, 2015

that's awesome! @pixelbandito
Any progress on this PR for the v4?

@mdo
Copy link
Member

mdo commented Feb 6, 2016

This is now pretty out of date. Holler if you feel like taking a fresh pass after #19099 is merged <3.

@robfrawley
Copy link

@pixelbandito Do you still intend to get this merged? It's mad out of date, but I'd love to see this feature available...

@mdo
Copy link
Member

mdo commented Sep 8, 2016

This would be super dope to get into Alpha 5. Any help on getting this rebased and up to speed would be amazing!

@mdo mdo added this to the v4.0.0-alpha.5 milestone Sep 8, 2016
@pixelbandito
Copy link
Contributor Author

I'm awake! I'll pick this back up. Thanks for the encouragement, folks.

@pixelbandito pixelbandito force-pushed the customizable-grid-gutters-per-breakpoint branch from 147b070 to d211810 Compare September 12, 2016 03:29
@each $breakpoint in map-keys($gutters) {
@include media-breakpoint-up($breakpoint) {
$gutter: map-get($gutters, $breakpoint);
margin-left: ($gutter / -2);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Properties should be ordered margin-right, margin-left

@pixelbandito pixelbandito force-pushed the customizable-grid-gutters-per-breakpoint branch 6 times, most recently from f81c1d3 to 074f559 Compare September 12, 2016 06:00
@pixelbandito
Copy link
Contributor Author

@mdo Rebased and up to speed.

@pixelbandito pixelbandito force-pushed the customizable-grid-gutters-per-breakpoint branch from 074f559 to 0ef64d8 Compare September 14, 2016 04:03
@mdo mdo merged commit 0ef64d8 into twbs:v4-dev Oct 3, 2016
@mdo
Copy link
Member

mdo commented Oct 3, 2016

Thanks so much!

@mdo mdo mentioned this pull request Oct 3, 2016
@pixelbandito pixelbandito deleted the customizable-grid-gutters-per-breakpoint branch October 3, 2016 02:28
@mdo
Copy link
Member

mdo commented Oct 9, 2016

@pixelbandito Any chance you have time to do a follow up to this PR that implements the same flexibility to the containers? If not I can try to swing back around to it soon :).

@pixelbandito
Copy link
Contributor Author

@mdo Breakpoint-specific container gutters have an open issue on #19304

I'll try :)

@mdo mdo mentioned this pull request Jun 30, 2017
@antoine3000
Copy link

Hey @pixelbandito & @mdo, the ability to define a customizable grid gutters width per breakpoint has been remove from the brand new V4, right? If so, this would be very useful to put it back.
Thanks for your work.

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

Successfully merging this pull request may close these issues.

9 participants