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

Additional margin & padding helpers #41

Closed
oscarstranger opened this issue Jan 22, 2018 · 0 comments
Closed

Additional margin & padding helpers #41

oscarstranger opened this issue Jan 22, 2018 · 0 comments
Assignees

Comments

@oscarstranger
Copy link

For squeaky clean margins 🛀

Something along the lines of:

@for $i from 1 through 10 {
  $division: $gutter/5;
  $spacing: $division*$i;
  .margin-#{$i}x {
    margin: $spacing;
  }
  .margin-top-#{$i}x {
    margin-top: $spacing;
  }
  .margin-bottom-#{$i}x {
    margin-bottom: $spacing;
  }
  .margin-left-#{$i}x {
    margin-left: $spacing;
  }
  .margin-right-#{$i}x {
    margin-right: $spacing;
  }
  .padding-#{$i}x {
    padding: $spacing;
  }
  .padding-top-#{$i}x {
    padding-top: $spacing;
  }
  .padding-bottom-#{$i}x {
    padding-bottom: $spacing;
  }
  .padding-left-#{$i}x {
    padding-left: $spacing;
  }
  .padding-right-#{$i}x {
    padding-right: $spacing;
  }
}
@oscarstranger oscarstranger self-assigned this Jan 22, 2018
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

No branches or pull requests

1 participant