<commit_before>//
// Colors function
// --------------------------------------------------


// Variables
//
$theme-color-interval:      8% !default;
$yiq-text-dark:             $text-color !default;
$yiq-text-light:            $white !default;
$yiq-contrasted-threshold:  150 !default;


@function theme-color-level($color: $gray-300, $level: 0) {
  $color-base: if($level > 0, $black, $white);
  $level: abs($level);

  @return mix($color-base, $color, $level * $theme-color-interval);
}


// Color contrast
// Credit: Bootstrap functions
// https://github.com/twbs/bootstrap/blob/v4-dev/scss/_functions.scss
// v4.1.3
// License: MIT
//
@function color-yiq($color, $dark: $yiq-text-dark, $light: $yiq-text-light) {
  $r: red($color);
  $g: green($color);
  $b: blue($color);

  $yiq: (($r * 299) + ($g * 587) + ($b * 114)) / 1000;

  @if ($yiq >= $yiq-contrasted-threshold) {<commit_msg>Reference to up<commit_after>//
// Colors function
// --------------------------------------------------


// Variables
//
$theme-color-interval:      8% !default;
$yiq-text-dark:             $text-color !default;
$yiq-text-light:            $white !default;
$yiq-contrasted-threshold:  150 !default;

// Credit: Bootstrap functions
// https://github.com/twbs/bootstrap/blob/v4-dev/scss/_functions.scss
// v4.1.3
// License: MIT
//

@function theme-color-level($color: $gray-300, $level: 0) {
  $color-base: if($level > 0, $black, $white);
  $level: abs($level);

  @return mix($color-base, $color, $level * $theme-color-interval);
}


// Color contrast
@function color-yiq($color, $dark: $yiq-text-dark, $light: $yiq-text-light) {
  $r: red($color);
  $g: green($color);
  $b: blue($color);

  $yiq: (($r * 299) + ($g * 587) + ($b * 114)) / 1000;

  @if ($yiq >= $yiq-contrasted-threshold) {
{'fraction_non_alphanumeric': 0.25925925925925924, 'fraction_numerical': 0.029180695847362513, 'mean_word_length': 2.5306930693069307, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3715564', 'n_tokens_mistral': 693, 'n_tokens_neox': 639, 'n_words': 132}