Sha256: 7b439a116e993f6e908faebedb4f17b0d712a75df2af4c7c214cb196e60ee0ae

Contents?: true

Size: 1.04 KB

Versions: 1

Compression:

Stored size: 1.04 KB

Contents

/* 52 framework grid */

$max-columns: 16 !default;
$column-width: 40px !default;
$gutter-width: 10px !default;

@mixin width($columns, $side_gutters: false) {
  @if $side_gutters == true {
    width: ($column-width + ($gutter-width * 2)) * ($columns);
  } @else {
    width: ($column-width + ($gutter-width * 2)) * ($columns - 1) + $column-width;
  }
}

.col {
  margin-left: $gutter-width;
  margin-right: $gutter-width;
  display: inline;
  overflow: hidden;
  float: left;
  position: relative;
}

.row {
  overflow: hidden;
  margin: 0 auto;
  @include width($max-columns, true);
}

.inner_row {
  margin: 0 -$gutter-width;
  display: inline-block;
  width: auto;
}

.row .row {
  @extend .inner_row;
}

@mixin column($columns) {
  @extend .col;
  @include width($columns);
}

@mixin row($inner: false) {
  @extend .row;
  @if $inner == true {
    @extend .inner_row;
  }
}

@for $i from 1 through $max-columns {
  .col_#{$i} {
    @include column($i)
  }
  .width_#{$i} {
    @include width($i)
  }
}

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
compass-52-plugin-0.1 stylesheets/52/_grid.scss