Sha256: c7a16487af0b64df4209790eff08fc6c094b16129e9a06a3db62d2ea60cdb5ff

Contents?: true

Size: 1.2 KB

Versions: 15

Compression:

Stored size: 1.2 KB

Contents

// Responsive media queries

@mixin breakpoint($breakpoint) {
  @if $breakpoint == "" {
    @content;
  } @else {
    // Retrieves the value from the key
    $value: map-get($breakpoints, $breakpoint);

    // If the key exists in the map
    @if $value != null {
      // Prints a media query based on the value
      @media (min-width: $value) {
        @content;
      }
    }

    // If the key doesn't exist in the map
    @else {
      @warn "Unfortunately, no value could be retrieved from `#{$breakpoint}`. "
        + "Please make sure it is defined in `$breakpoints` map.";
    }
  }
}

// Retina media query

@mixin retina-media-query {
  @media only screen and (-webkit-min-device-pixel-ratio: 2),
    only screen and (min--moz-device-pixel-ratio: 2),
    only screen and (-moz-min-device-pixel-ratio: 2),
    only screen and (-o-min-device-pixel-ratio: 2/1),
    only screen and (min-device-pixel-ratio: 2),
    only screen and (min-resolution: 192dpi),
    only screen and (min-resolution: 2dppx) {
    @content;
  }
}

// Clearfix
//
// Clears floats via mixin.

@mixin clearfix {
  &::before {
    display: table;
    content: "";
  }

  &::after {
    display: table;
    clear: both;
    content: "";
  }
}

Version data entries

15 entries across 15 versions & 2 rubygems

Version Path
truesight-rtd-theme-1.0.1 _sass/lib/@primer/css/support/mixins/layout.scss
truesight-rtd-theme-1.0.0 _sass/lib/@primer/css/support/mixins/layout.scss
jekyll-rtd-theme-2.0.10 _sass/lib/@primer/css/support/mixins/layout.scss
jekyll-rtd-theme-2.0.9 _sass/lib/@primer/css/support/mixins/layout.scss
jekyll-rtd-theme-2.0.8 _sass/lib/@primer/css/support/mixins/layout.scss
jekyll-rtd-theme-2.0.7 _sass/lib/@primer/css/support/mixins/layout.scss
jekyll-rtd-theme-2.0.6 _sass/@primer/css/support/mixins/layout.scss
jekyll-rtd-theme-2.0.5 _sass/@primer/css/support/mixins/layout.scss
jekyll-rtd-theme-2.0.4 _sass/@primer/support/mixins/layout.scss
jekyll-rtd-theme-2.0.3 _sass/@primer/support/mixins/layout.scss
jekyll-rtd-theme-2.0.2 _sass/@primer/support/mixins/layout.scss
jekyll-rtd-theme-2.0.1 _sass/@primer/support/mixins/layout.scss
jekyll-rtd-theme-2.0.0 _sass/@primer/support/mixins/layout.scss
jekyll-rtd-theme-2.0.0.pre.beta1 _sass/@primer/support/mixins/layout.scss
jekyll-rtd-theme-2.0.0.pre.beta _sass/@primer/support/mixins/layout.scss