3.2.13 (Media Mark) 07e8b985f706e22c904330511e26ed70410d2943 o:Sass::Tree::RootNode : @linei:@has_childrenT:@template";//************************************************************************// // Background property for adding multiple backgrounds using shorthand // notation. //************************************************************************// @mixin background( $background-1 , $background-2: false, $background-3: false, $background-4: false, $background-5: false, $background-6: false, $background-7: false, $background-8: false, $background-9: false, $background-10: false, $fallback: false ) { $backgrounds: compact($background-1, $background-2, $background-3, $background-4, $background-5, $background-6, $background-7, $background-8, $background-9, $background-10); $fallback-color: false; @if (type-of($fallback) == color) or ($fallback == "transparent") { $fallback-color: $fallback; } @else { $fallback-color: _extract-background-color($backgrounds); } @if $fallback-color { background-color: $fallback-color; } background: _background-add-prefix($backgrounds, webkit); background: _background-add-prefix($backgrounds); } @function _extract-background-color($backgrounds) { $final-bg-layer: nth($backgrounds, length($backgrounds)); @if type-of($final-bg-layer) == list { @for $i from 1 through length($final-bg-layer) { $value: nth($final-bg-layer, $i); @if type-of($value) == color { @return $value; } } } @return false; } @function _background-add-prefix($backgrounds, $vendor: false) { $backgrounds-prefixed: (); @for $i from 1 through length($backgrounds) { $shorthand: nth($backgrounds, $i); // Get member for current index $type: type-of($shorthand); // Get type of variable - List (gradient) or String (image) // If shorthand is a list (gradient) @if $type == list { $first-member: nth($shorthand, 1); // Get first member of shorthand // Linear Gradient @if index(linear radial, nth($first-member, 1)) { $gradient-type: nth($first-member, 1); // linear || radial $gradient-args: false; $gradient-positions: false; $shorthand-start: false; @if type-of($first-member) == list { // Linear gradient plus additional shorthand values - lg(red,orange)repeat,... $gradient-positions: nth($first-member, 2); $gradient-args: nth($first-member, 3); $shorthand-start: 2; } @else { // Linear gradient only - lg(red,orange),... $gradient-positions: nth($shorthand, 2); $gradient-args: nth($shorthand, 3); // Get gradient (red, blue) } $gradient-positions: _gradient-positions-parser($gradient-type, $gradient-positions); $gradient: _render-gradients($gradient-positions, $gradient-args, $gradient-type, $vendor); // Append any additional shorthand args to gradient @if $shorthand-start { @for $j from $shorthand-start through length($shorthand) { $gradient: join($gradient, nth($shorthand, $j), space); } } $backgrounds-prefixed: append($backgrounds-prefixed, $gradient, comma); } // Image with additional properties @else { $backgrounds-prefixed: append($backgrounds-prefixed, $shorthand, comma); } } // If shorthand is a simple string (color or image) @else if $type == string { $backgrounds-prefixed: join($backgrounds-prefixed, $shorthand, comma); } } @return $backgrounds-prefixed; } //Examples: //@include background(linear-gradient(top, orange, red)); //@include background(radial-gradient(circle at 40% 40%, orange, red)); //@include background(url("/images/a.png") no-repeat, linear-gradient(orange, red)); //@include background(url("image.png") center center, linear-gradient(orange, red), url("image.png")); :@children[ o:Sass::Tree::CommentNode ;i: @type: silent; [: @value["ð/*************************************************************************// * Background property for adding multiple backgrounds using shorthand * notation. *************************************************************************// */: @options{o:Sass::Tree::MixinDefNode ;i: @name"background;T: @splat0; [ o:Sass::Tree::VariableNode : @expro:Sass::Script::Funcall ;i;" compact;0;@ :@keywords{: @args[o:Sass::Script::Variable ;i;"background-1:@underscored_name"background_1;@ o; ;i;"background-2;"background_2;@ o; ;i;"background-3;"background_3;@ o; ;i;"background-4;"background_4;@ o; ;i;"background-5;"background_5;@ o; ;i;"background-6;"background_6;@ o; ;i;"background-7;"background_7;@ o; ;i;"background-8;"background_8;@ o; ;i;"background-9;"background_9;@ o; ;i;"background-10;"background_10;@ ;i;"backgrounds; [: @guarded0;@ o; ;o:Sass::Script::Bool;i; F;@ ;i;"fallback-color; [;0;@ u:Sass::Tree::IfNodeY[o:Sass::Script::Operation : @linei:@operand2o; ;i;o:Sass::Script::String ;i: @type: string: @value"transparent: @options{:@operand1o:Sass::Script::Variable ;i: @name" fallback:@underscored_name" fallback; @ ; @ :@operator:eq; o; ;i;o; ;i; :identifier; " color; @ ; o:Sass::Script::Funcall ;i;" type-of: @splat0; @ :@keywords{: @args[o; ;i;" fallback;" fallback; @ ; @ ;;; @ ;:oru:Sass::Tree::IfNode[00[o:Sass::Tree::VariableNode : @expro:Sass::Script::Funcall : @linei: @name"_extract-background-color: @splat0: @options{:@keywords{: @args[o:Sass::Script::Variable ;i; "backgrounds:@underscored_name"backgrounds; @ ;i; "fallback-color:@children[: @guarded0; @ [o:Sass::Tree::VariableNode : @expro; ;i;" fallback;" fallback; @ ;i;"fallback-color:@children[: @guarded0; @ u;[o:Sass::Script::Variable : @linei!: @name"fallback-color:@underscored_name"fallback_color: @options{0[o:Sass::Tree::PropNode ;i";["background-color:@prop_syntax:new: @tabsi:@children[: @valueo; ;i";"fallback-color;"fallback_color; @ ; @ o:Sass::Tree::PropNode ;i$;["background:@prop_syntax:new: @tabsi; [; o; ;i$;"_background-add-prefix;0;@ ;{;[o; ;i$;"backgrounds;"backgrounds;@ o:Sass::Script::String ;i$; :identifier; " webkit;@ ;@ o; ;i%;["background;;;i; [; o; ;i%;"_background-add-prefix;0;@ ;{;[o; ;i%;"backgrounds;"backgrounds;@ ;@ ;@ ;[[o;;"background-1;"background_1;@ 0[o;;"background-2;"background_2;@ o;;i ; F;@ [o;;"background-3;"background_3;@ o;;i ; F;@ [o;;"background-4;"background_4;@ o;;i ; F;@ [o;;"background-5;"background_5;@ o;;i; F;@ [o;;"background-6;"background_6;@ o;;i; F;@ [o;;"background-7;"background_7;@ o;;i; F;@ [o;;"background-8;"background_8;@ o;;i; F;@ [o;;"background-9;"background_9;@ o;;i; F;@ [o;;"background-10;"background_10;@ o;;i; F;@ [o;;" fallback;" fallback;@ o;;i; F;@ o:Sass::Tree::FunctionNode ;i(;"_extract-background-color;T;0; [o; ;o; ;i);"nth;0;@ ;{;[o; ;i);"backgrounds;"backgrounds;@ o; ;i);" length;0;@ ;{;[o; ;i);"backgrounds;"backgrounds;@ ;i);"final-bg-layer; [;0;@ u;•[o:Sass::Script::Operation : @linei*:@operand2o:Sass::Script::String ;i*: @type:identifier: @value" list: @options{:@operand1o:Sass::Script::Funcall ;i*: @name" type-of: @splat0; @ :@keywords{: @args[o:Sass::Script::Variable ;i*;"final-bg-layer:@underscored_name"final_bg_layer; @ ; @ :@operator:eq0[o:Sass::Tree::ForNode ;i+: @fromo:Sass::Script::Number ;i+:@numerator_units[:@original"1; i:@denominator_units[; @ : @var"i:@has_childrenT:@too; ;i+;" length;0; @ ;{;[o; ;i+;"final-bg-layer;"final_bg_layer; @ :@children[o:Sass::Tree::VariableNode : @expro; ;i,;"nth;0; @ ;{;[o; ;i,;"final-bg-layer;"final_bg_layer; @ o; ;i,;"i;"i; @ ;i,;" value; [: @guarded0; @ u:Sass::Tree::IfNode‡[o:Sass::Script::Operation : @linei-:@operand2o:Sass::Script::String ;i-: @type:identifier: @value" color: @options{:@operand1o:Sass::Script::Funcall ;i-: @name" type-of: @splat0; @ :@keywords{: @args[o:Sass::Script::Variable ;i-;" value:@underscored_name" value; @ ; @ :@operator:eq0[o:Sass::Tree::ReturnNode : @expro; ;i.;" value;" value; @ ;i.:@children[; @ :@exclusiveF; @ o:Sass::Tree::ReturnNode ;o;;i2; F;@ ;i2; [;@ ;@ ;[[o;;"backgrounds;"backgrounds;@ 0o;" ;i5;"_background-add-prefix;T;0; [o; ;o:Sass::Script::List ;i6:@separator: space; [;@ ;i6;"backgrounds-prefixed; [;0;@ o:Sass::Tree::ForNode ;i8: @fromo:Sass::Script::Number ;i8:@numerator_units[:@original"1; i:@denominator_units[;@ : @var"i;T:@too; ;i8;" length;0;@ ;{;[o; ;i8;"backgrounds;"backgrounds;@ ; [ o; ;o; ;i9;"nth;0;@ ;{;[o; ;i9;"backgrounds;"backgrounds;@ o; ;i9;"i;"i;@ ;i9;"shorthand; [;0;@ o; ;i9; ; ; [; ["'/* Get member for current index */;@ o; ;o; ;i:;" type-of;0;@ ;{;[o; ;i:;"shorthand;"shorthand;@ ;i:;" type; [;0;@ o; ;i:; ; ; [; ["C/* Get type of variable - List (gradient) or String (image) */;@ o; ;i<; ; ; [; [",/* If shorthand is a list (gradient) */;@ u;’[o:Sass::Script::Operation : @linei=:@operand2o:Sass::Script::String ;i=: @type:identifier: @value" list: @options{:@operand1o:Sass::Script::Variable ;i=: @name" type:@underscored_name" type; @ ; @ :@operator:equ:Sass::Tree::IfNode[o:Sass::Script::Operation : @lineia:@operand2o:Sass::Script::String ;ia: @type:identifier: @value" string: @options{:@operand1o:Sass::Script::Variable ;ia: @name" type:@underscored_name" type; @ ; @ :@operator:eq0[o:Sass::Tree::VariableNode : @expro:Sass::Script::Funcall ;ib;" join: @splat0; @ :@keywords{: @args[o; ;ib;"backgrounds-prefixed;"backgrounds_prefixed; @ o; ;ib;"shorthand;"shorthand; @ o; ;ib; ; ; " comma; @ ;ib;"backgrounds-prefixed:@children[: @guarded0; @ [ o:Sass::Tree::VariableNode : @expro:Sass::Script::Funcall ;i>;"nth: @splat0; @ :@keywords{: @args[o; ;i>;"shorthand;"shorthand; @ o:Sass::Script::Number ;i>:@numerator_units[:@original"1; i:@denominator_units[; @ ;i>;"first-member:@children[: @guarded0; @ o:Sass::Tree::CommentNode ;i>; : silent;[; ["(/* Get first member of shorthand */; @ o; ;i@; ;!;[; ["/* Linear Gradient */; @ u;æ[o:Sass::Script::Funcall : @lineiA: @name" index: @splat0: @options{:@keywords{: @args[o:Sass::Script::List ;iA:@separator: space: @value[o:Sass::Script::String ;iA: @type:identifier;" linear; @o; ;iA;;;" radial; @; @o; ;iA;"nth;0; @; {; [o:Sass::Script::Variable ;iA;"first-member:@underscored_name"first_member; @o:Sass::Script::Number ;iA:@numerator_units[:@original"1;i:@denominator_units[; @u:Sass::Tree::IfNodeŠ[00[o:Sass::Tree::VariableNode : @expro:Sass::Script::Funcall : @linei]: @name" append: @splat0: @options{:@keywords{: @args[o:Sass::Script::Variable ;i]; "backgrounds-prefixed:@underscored_name"backgrounds_prefixed; @ o; ;i]; "shorthand;"shorthand; @ o:Sass::Script::String ;i]: @type:identifier: @value" comma; @ ;i]; "backgrounds-prefixed:@children[: @guarded0; @ [o:Sass::Tree::VariableNode : @expro; ;iB;"nth;0; @; {; [o; ;iB;"first-member;"first_member; @o; ;iB;[;"1;i;@; @;iB;"gradient-type:@children[: @guarded0; @o:Sass::Tree::CommentNode ;iB;: silent;[;["/* linear || radial */; @o; ;o:Sass::Script::Bool;iC;F; @;iC;"gradient-args;[;0; @o; ;o; ;iD;F; @;iD;"gradient-positions;[;0; @o; ;o; ;iE;F; @;iE;"shorthand-start;[;0; @u;C[o:Sass::Script::Operation : @lineiF:@operand2o:Sass::Script::String ;iF: @type:identifier: @value" list: @options{:@operand1o:Sass::Script::Funcall ;iF: @name" type-of: @splat0; @ :@keywords{: @args[o:Sass::Script::Variable ;iF;"first-member:@underscored_name"first_member; @ ; @ :@operator:equ:Sass::Tree::IfNode“[00[ o:Sass::Tree::CommentNode : @lineiK: @type: silent:@children[: @value["4/* Linear gradient only - lg(red,orange),... */: @options{o:Sass::Tree::VariableNode : @expro:Sass::Script::Funcall ;iL: @name"nth: @splat0; @ :@keywords{: @args[o:Sass::Script::Variable ;iL;"shorthand:@underscored_name"shorthand; @ o:Sass::Script::Number ;iL:@numerator_units[:@original"2; i:@denominator_units[; @ ;iL;"gradient-positions; [: @guarded0; @ o; ; o; ;iM;"nth;0; @ ;{;[o; ;iM;"shorthand;"shorthand; @ o; ;iM;[;"3; i;@; @ ;iM;"gradient-args; [;0; @ o; ;iM;;; [; ["#/* Get gradient (red, blue) */; @ [ o:Sass::Tree::CommentNode ;iF; : silent:@children[; ["V/* Linear gradient plus additional shorthand values - lg(red,orange)repeat,... */; @ o:Sass::Tree::VariableNode : @expro; ;iG;"nth;0; @ ;{;[o; ;iG;"first-member;"first_member; @ o:Sass::Script::Number ;iG:@numerator_units[:@original"2; i:@denominator_units[; @ ;iG;"gradient-positions;[: @guarded0; @ o; ;o; ;iH;"nth;0; @ ;{;[o; ;iH;"first-member;"first_member; @ o; ;iH;[;"3; i; @"; @ ;iH;"gradient-args;[;!0; @ o; ;o; ;iI;[;"2; i; @"; @ ;iI;"shorthand-start;[;!0; @ o; ;o; ;iP;"_gradient-positions-parser;0; @; {; [o; ;iP;"gradient-type;"gradient_type; @o; ;iP;"gradient-positions;"gradient_positions; @;iP;"gradient-positions;[;0; @o; ;o; ;iQ;"_render-gradients;0; @; {; [ o; ;iQ;"gradient-positions;"gradient_positions; @o; ;iQ;"gradient-args;"gradient_args; @o; ;iQ;"gradient-type;"gradient_type; @o; ;iQ;" vendor;" vendor; @;iQ;" gradient;[;0; @o; ;iS;;;[;[";/* Append any additional shorthand args to gradient */; @u;—[o:Sass::Script::Variable : @lineiT: @name"shorthand-start:@underscored_name"shorthand_start: @options{0[o:Sass::Tree::ForNode ;iU: @fromo; ;iU;"shorthand-start;"shorthand_start; @ : @var"j:@has_childrenT:@too:Sass::Script::Funcall ;iU;" length: @splat0; @ :@keywords{: @args[o; ;iU;"shorthand;"shorthand; @ :@children[o:Sass::Tree::VariableNode : @expro; ;iV;" join;0; @ ;{;[o; ;iV;" gradient;" gradient; @ o; ;iV;"nth;0; @ ;{;[o; ;iV;"shorthand;"shorthand; @ o; ;iV;"j;"j; @ o:Sass::Script::String ;iV: @type:identifier: @value" space; @ ;iV;" gradient;[: @guarded0; @ :@exclusiveF; @ o; ;o; ;iY;" append;0; @; {; [o; ;iY;"backgrounds-prefixed;"backgrounds_prefixed; @o; ;iY;" gradient;" gradient; @o; ;iY;;;" comma; @;iY;"backgrounds-prefixed;[;0; @:@exclusiveF;@ o;# ;o; ;ie;"backgrounds-prefixed;"backgrounds_prefixed;@ ;ie; [;@ ;@ ;[[o;;"backgrounds;"backgrounds;@ 0[o;;" vendor;" vendor;@ o;;i5; F;@ o; ;ih; ; ; [; ["L/*Examples: *@include background(linear-gradient(top, orange, red)); *@include background(radial-gradient(circle at 40% 40%, orange, red)); *@include background(url("/images/a.png") no-repeat, linear-gradient(orange, red)); *@include background(url("image.png") center center, linear-gradient(orange, red), url("image.png")); */;@ ;@