Sha256: 01fc055e06bd30a1a6d7e2dcfd5e3fc0f7c5db47c775039bdc34f26b26708aa1

Contents?: true

Size: 1.17 KB

Versions: 1

Compression:

Stored size: 1.17 KB

Contents

// Make Row
@mixin grid-row {
  @include flex;
  @include flex-items-row;
  @include flex-items-wrap;
  @include breakpoint(sm) {
    @include flex-items-column;
    @include flex-items-nowrap;
  }
}

// Generate Columns
@mixin generate-grid-columns {
  @for $i from 1 through $grid-columns {
    .col-#{$i} {
      width: 100% / $grid-columns * $i;
    }
    .offset-#{$i} {
      $width: 100% / $grid-columns * $i;
      margin-left: $width;
    }
  }
  .gutters {
    @for $i from 1 through $grid-columns {
      & > .col-#{$i} {
        $width: 100% / $grid-columns * $i;
        width: calc(#{$width} - #{$grid-gutter});
      }
      & > .offset-#{$i} {
        $width: 100% / $grid-columns * $i;
        margin-left: calc(#{$width} + #{$grid-gutter}) !important;
      }
    }
  }
}

// Grid Media Columns
@mixin grid-media-columns($num) {
	-webkit-column-count: $num;
	-moz-column-count: $num;
	column-count: $num;
	-webkit-column-gap: var(--grid-gutter);
	-moz-column-gap: var(--grid-gutter);
	column-gap: var(--grid-gutter);
	& > div {
		display: inline-block;
		width: 100%;
	}
  @include breakpoint(sm) {
		-webkit-column-count: 1;
		-moz-column-count: 1;
		column-count: 1;
  }
}

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
kube-6.5.2.0 app/assets/stylesheets/kube/mixins/_grid.scss