PHP Classes

File: public/asset/vendor/select2/docs/themes/learn2/scss/vendor/color-schemer/color-schemer/_mix.scss

Recommend this page to a friend!
  Classes of fathurrahman   mnTemplate   public/asset/vendor/select2/docs/themes/learn2/scss/vendor/color-schemer/color-schemer/_mix.scss   Download  
File: public/asset/vendor/select2/docs/themes/learn2/scss/vendor/color-schemer/color-schemer/_mix.scss
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: mnTemplate
Route HTTP requests to callback functions
Author: By
Last change:
Date: 1 year ago
Size: 1,408 bytes
 

Contents

Class file image Download
@function cs-mix($color1, $color2, $percent: 50%, $model: $cs-color-model) { $decimal : abs($percent - 100%) / 100%; $hue-offset : (); @if $model == rgb { $hue-offset : (hue($color1) - hue($color2)) * $decimal; @if (hue($color1) - hue($color2)) * .5 < -90deg { $hue-offset : (hue($color1) + 360deg - hue($color2)) * $decimal; } @if (hue($color1) - hue($color2)) * .5 > 90deg { $hue-offset : (hue($color1) - 360deg - hue($color2)) * $decimal; } } @if $model == ryb { $hue-offset : (ryb-hue($color1) - ryb-hue($color2)) * $decimal; @if (ryb-hue($color1) - ryb-hue($color2)) * .5 < -90deg { $hue-offset : (ryb-hue($color1) + 360deg - ryb-hue($color2)) * $decimal; } @if (ryb-hue($color1) - ryb-hue($color2)) * .5 > 90deg { $hue-offset : (ryb-hue($color1) - 360deg - ryb-hue($color2)) * $decimal; } } $saturation-offset : (saturation($color1) - saturation($color2)) * $decimal; $lightness-offset : (lightness($color1) - lightness($color2)) * $decimal; @if $model == ryb { $color1: ryb-adjust-hue($color1, $hue-offset * -1); } @else { $color1: adjust-hue($color1, $hue-offset * -1); } $color1: set-saturation($color1, saturation($color1) - $saturation-offset); $color1: set-lightness($color1, lightness($color1) - $lightness-offset); @return $color1; }