Sha256: ead93384cdc613f201e44010558c567ebfa954857502f1acfb25c3437ad271c7

Contents?: true

Size: 1.49 KB

Versions: 19

Compression:

Stored size: 1.49 KB

Contents

// Isolation Syntax
// ================


// Isolate [Mixin]
// ---------------
// Set isolation as an override.
// - $location: <span>
@mixin isolate(
  $isolate: 1
) {
  $inspect: $isolate;

  $output: (
    push: isolate($isolate),
    flow: susy-get(flow, $isolate),
  );

  @include susy-inspect(isolate, $inspect);
  @include isolate-output($output...);
}


// Isolate [function]
// ------------------
// Return an isolation offset width.
// - $location: <span>
@function isolate(
  $isolate: 1
) {
  $isolate: parse-span($isolate);
  $isolation: susy-get(span, $isolate);

  @if $isolation and not(get-location($isolate)) {
    $new: (
      span: null,
      location: $isolation,
    );
    $isolate: map-merge($isolate, $new);
  }

  @return get-isolation($isolate);
}


// Get Isolation
// -------------
// Return the isolation offset width
// - $input: <map>
@function get-isolation(
  $input
) {
  $location   : get-location($input);
  $columns    : susy-get(columns, $input);
  $width      : null;

  @if type-of($location) == number and not(unitless($location)) {
    $width: $location;
  } @else if $location {
    $push: $location - 1;
    @if $push > 0 {
      $push: map-merge($input, (
        span: $push,
        location: 1,
        spread: wide,
      ));
      $width: get-span-width($push);
    }
  }

  @if susy-get(gutter-position, $input) == split
      and susy-get(gutters, $input) > 0 {
    $width: if($width == null, gutters($input), $width + gutters($input));
  }

  @return $width or 0;
}

Version data entries

19 entries across 19 versions & 6 rubygems

Version Path
sparrow-jekyll-theme-0.1.2 _sass/vendor/susy/susy/language/susy/_isolate.scss
susy-2.2.14 sass/susy/language/susy/_isolate.scss
susy-2.2.13 sass/susy/language/susy/_isolate.scss
minimal-mistakes-jekyll-4.4.1 _sass/minimal-mistakes/vendor/susy/susy/language/susy/_isolate.scss
jekyll-theme-basically-basic-1.0.0 _sass/basically-basic/vendor/susy/language/susy/_isolate.scss
jekyll-theme-woforo-0.2.3 _sass/vendor/susy/susy/language/susy/_isolate.scss
jekyll-theme-woforo-0.2.2 _sass/vendor/susy/susy/language/susy/_isolate.scss
jekyll-theme-woforo-0.2.1 _sass/vendor/susy/susy/language/susy/_isolate.scss
jekyll-theme-woforo-0.2.0 _sass/vendor/susy/susy/language/susy/_isolate.scss
minimal-mistakes-jekyll-4.1.1 _sass/vendor/susy/susy/language/susy/_isolate.scss
minimal-mistakes-jekyll-4.0.1 _sass/vendor/susy/susy/language/susy/_isolate.scss
susy-2.2.12 sass/susy/language/susy/_isolate.scss
susy-2.2.11 sass/susy/language/susy/_isolate.scss
susy-2.2.10 sass/susy/language/susy/_isolate.scss
susy-2.2.9 sass/susy/language/susy/_isolate.scss
susy-2.2.8 sass/susy/language/susy/_isolate.scss
susy-2.2.7 sass/susy/language/susy/_isolate.scss
ghost-manager-1.0.0 magneto/source/assets/bower_components/susy/sass/susy/language/susy/_isolate.scss
susy-2.2.6 sass/susy/language/susy/_isolate.scss