Sha256: e9129226bad00fd3d7a44471ff23a1d0173eee8b35c67c90126c32faa132f46e

Contents?: true

Size: 1.3 KB

Versions: 7

Compression:

Stored size: 1.3 KB

Contents

// Settings
// ========

// Version
// -------
$su-version: 1.1;


// Default Settings
// ----------------
// PRIVATE: The basic settings
$susy-defaults: (
  columns: 4,
  gutters: 1/4,
);


// User Settings
// -------------
// - Define the $susy variable with a map of your own settings.
// - Set EITHER $column-width OR $container
// - Use $column-width for static layouts
$susy: () !default;


// Susy Defaults
// -------------
// PRIVATE: Add defaults to Susy
@mixin susy-defaults(
  $defaults
) {
  $susy-defaults: map-merge($susy-defaults, $defaults) !global;
}


// Susy Set
// --------
// Change one setting
// - $key   : setting name
// - $value : setting value
@mixin susy-set(
  $key-value...
) {
  $susy: _susy-deep-set($susy, $key-value...) !global;
}


// Susy Get
// --------
// Return one setting from a grid
// - $key     : <keyword>
// - $layout  : <settings>
@function susy-get(
  $key,
  $layout: map-merge($susy-defaults, $susy)
) {
  $layout: parse-grid($layout);
  $_options: $layout $susy $susy-defaults;
  $_break: false;
  $_return: null;

  @each $opt in $_options {
    @if type-of($opt) == map and not($_break) {
      $_keyset: _susy-deep-has-key($opt, $key...);
      @if $_keyset {
        $_return: _susy-deep-get($opt, $key...);
        $_break: true;
      }
    }
  }

  @return $_return;
}

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
susy-2.2.2 sass/susy/su/_settings.scss
susy-2.2.2.alpha.1 sass/susy/su/_settings.scss
susy-2.2.1 sass/susy/su/_settings.scss
susy-2.2.0.rc.2 sass/susy/su/_settings.scss
susy-2.2.0.rc.1 sass/susy/su/_settings.scss
susy-2.2.0.beta.3 sass/susy/su/_settings.scss
susy-2.2.0.beta.2 sass/susy/su/_settings.scss