DEV: More color transformation refactoring

DEV: More color transformation refactoring

diff --git a/app/assets/stylesheets/common/base/code_highlighting.scss b/app/assets/stylesheets/common/base/code_highlighting.scss
index 2e09912..d483935 100644
--- a/app/assets/stylesheets/common/base/code_highlighting.scss
+++ b/app/assets/stylesheets/common/base/code_highlighting.scss
@@ -7,12 +7,12 @@ github.com style (c) Vasily Polovnyov <vast@whiteants.net>
 .hljs {
   display: block;
   padding: 0.5em;
-  color: dark-light-choose(#333, #f8f8f8);
+  color: $primary-very-high;
 }
 
 .hljs-comment,
 .hljs-doctag {
-  color: dark-light-choose(#998, #bba);
+  color: $hljs-comment;
   font-style: italic;
 }
 
@@ -22,26 +22,26 @@ github.com style (c) Vasily Polovnyov <vast@whiteants.net>
 .hljs-subst,
 .hljs-request,
 .hljs-status {
-  color: dark-light-choose(#333, #f8f8f8);
+  color: $primary-very-high;
   font-weight: bold;
 }
 
 .hljs-number,
 .ruby .hljs-constant {
-  color: dark-light-choose(#099, #aff);
+  color: $hljs-number;
 }
 
 .hljs-string,
 .hljs-tag .hljs-string,
 .tex .hljs-formula {
-  color: dark-light-choose(#d14, #f99);
+  color: $hljs-string;
 }
 
 .hljs-title,
 .hljs-name,
 .coffeescript .hljs-params,
 .scss .hljs-meta {
-  color: dark-light-choose(#d14, #f99);
+  color: $hljs-string;
   font-weight: bold;
 }
 
@@ -56,14 +56,14 @@ github.com style (c) Vasily Polovnyov <vast@whiteants.net>
 .haskell .hljs-type,
 .vhdl .hljs-literal,
 .tex .hljs-command {
-  color: dark-light-choose(#458, #9ae);
+  color: $hljs-literal;
   font-weight: bold;
 }
 
 .hljs-tag,
 .hljs-tag .hljs-title,
 .django .hljs-tag .hljs-keyword {
-  color: dark-light-choose(#000080, #99f);
+  color: $hljs-tag;
   font-weight: normal;
 }
 
@@ -71,7 +71,7 @@ github.com style (c) Vasily Polovnyov <vast@whiteants.net>
 .css .hljs-keyword,
 .hljs-variable,
 .lisp .hljs-body {
-  color: dark-light-choose(#008080, #0ee);
+  color: $hljs-attribute;
 }
 
 .hljs-regexp {
@@ -83,7 +83,7 @@ github.com style (c) Vasily Polovnyov <vast@whiteants.net>
 .lisp .hljs-keyword,
 .tex .hljs-special,
 .hljs-prompt {
-  color: dark-light-choose(#990073, #fbe);
+  color: $hljs-symbol;
 }
 
 .hljs-built_in,
@@ -119,8 +119,8 @@ github.com style (c) Vasily Polovnyov <vast@whiteants.net>
 p > code,
 li > code,
 pre > code {
-  color: dark-light-choose(#333, #f8f8f8);
-  background: dark-light-choose(#f8f8f8, #333);
+  color: $primary-very-high;
+  background: $hljs-bg;
 }
 
 // removed some unnecessary styles here
diff --git a/app/assets/stylesheets/common/base/header.scss b/app/assets/stylesheets/common/base/header.scss
index 796c2e1..b28747e 100644
--- a/app/assets/stylesheets/common/base/header.scss
+++ b/app/assets/stylesheets/common/base/header.scss
@@ -200,7 +200,7 @@
   .unread-notifications {
     left: auto;
     right: -3px;
-    background-color: dark-light-choose($tertiary-medium, $tertiary);
+    background-color: $tertiary-med-or-tertiary;
   }
   .unread-high-priority-notifications,
   .ring {
diff --git a/app/assets/stylesheets/common/base/onebox.scss b/app/assets/stylesheets/common/base/onebox.scss
index 341b945..6c5bde7 100644
--- a/app/assets/stylesheets/common/base/onebox.scss
+++ b/app/assets/stylesheets/common/base/onebox.scss
@@ -372,7 +372,7 @@ pre.onebox code ol.lines li {
 }
 
 pre.onebox code li.selected {
-  background-color: dark-light-choose(#f8eec7, #541);
+  background-color: $highlight-low-or-medium;
 }
 
 pre.onebox code {
diff --git a/app/assets/stylesheets/common/base/reviewables.scss b/app/assets/stylesheets/common/base/reviewables.scss
index 569cfc5..c838979 100644
--- a/app/assets/stylesheets/common/base/reviewables.scss
+++ b/app/assets/stylesheets/common/base/reviewables.scss
@@ -227,7 +227,7 @@
 
 .reviewable-item {
   padding-top: 2em;
-  border-top: 1px solid dark-light-choose($primary-low, $secondary-low);
+  border-top: 1px solid $primary-low;
 
   .topic-statuses {
     font-size: $font-up-2;
diff --git a/app/assets/stylesheets/common/base/share_link.scss b/app/assets/stylesheets/common/base/share_link.scss
index 4f22dfe..946bd3a 100644
--- a/app/assets/stylesheets/common/base/share_link.scss
+++ b/app/assets/stylesheets/common/base/share_link.scss
@@ -49,15 +49,15 @@
     margin-right: 8px;
     font-size: $font-up-4;
     .d-icon {
-      color: dark-light-choose($tertiary, white);
+      color: $tertiary-or-white;
     }
     .d-icon-fab-facebook {
       // Adheres to Facebook brand guidelines
-      color: dark-light-choose($facebook, white);
+      color: $facebook-or-white;
     }
     .d-icon-fab-twitter-square {
       // Adheres to Twitter brand guidelines
-      color: dark-light-choose($twitter, white);
+      color: $twitter-or-white;
     }
   }
 
diff --git a/app/assets/stylesheets/common/base/tagging.scss b/app/assets/stylesheets/common/base/tagging.scss
index 5209a74..fc49727 100644
--- a/app/assets/stylesheets/common/base/tagging.scss
+++ b/app/assets/stylesheets/common/base/tagging.scss
@@ -61,11 +61,9 @@
   }
 }
 
-$tag-color: $primary-medium;
-
 .discourse-tag-count {
   font-size: $font-down-1;
-  color: $tag-color;
+  color: $primary-medium;
   line-height: $line-height-small;
   vertical-align: middle;
 }
@@ -79,11 +77,11 @@ $tag-color: $primary-medium;
 
 .discourse-tag {
   margin: 0;
-  color: $tag-color;
+  color: $primary-medium;
 
   &:visited,
   &:hover {
-    color: $tag-color;
+    color: $primary-medium;
   }
 
   .extra-info-wrapper & {
@@ -181,7 +179,7 @@ $tag-color: $primary-medium;
 }
 
 header .discourse-tag {
-  color: $tag-color;
+  color: $primary-medium;
 }
 
 .list-tags {
@@ -210,13 +208,14 @@ header .discourse-tag {
 }
 
 .autocomplete {
-  .d-icon-tag {
-    color: dark-light-choose($primary, $primary-low-mid);
-    padding-right: 5px;
+  a {
+    color: $primary-medium;
   }
 
-  a {
-    color: $tag-color;
+  .d-icon-tag {
+    padding-right: 5px;
+    vertical-align: middle;
+    height: 0.9em;
   }
 }
 
diff --git a/app/assets/stylesheets/common/base/topic-post.scss b/app/assets/stylesheets/common/base/topic-post.scss
index 0768780..f1f8079 100644
--- a/app/assets/stylesheets/common/base/topic-post.scss
+++ b/app/assets/stylesheets/common/base/topic-post.scss
@@ -307,7 +307,7 @@ blockquote {
   .btn:hover,
   .d-icon,
   .btn:hover .d-icon {
-    color: dark-light-choose($secondary, $primary);
+    color: $secondary-or-primary;
   }
 
   .insert-quote + .quote-sharing {
@@ -693,8 +693,8 @@ pre {
 
 kbd {
   align-items: center;
-  background: dark-light-choose(#fafafa, #303030);
-  border: 1px solid dark-light-choose(#d0d0d0, #505050);
+  border: 1px solid $primary-low-mid;
+  background: $primary-very-low;
   border-bottom-width: 2px;
   border-radius: 3px;
   box-sizing: border-box;
diff --git a/app/assets/stylesheets/common/components/badges.scss b/app/assets/stylesheets/common/components/badges.scss
index 6506a88..10d0e6b 100644
--- a/app/assets/stylesheets/common/components/badges.scss
+++ b/app/assets/stylesheets/common/components/badges.scss
@@ -169,7 +169,7 @@
   font-size: $font-down-2;
   line-height: $line-height-small;
   text-align: center;
-  background-color: dark-light-choose($primary-low-mid, $secondary-low);
+  background-color: $primary-low-mid-or-secondary-low;
   &[href] {
     color: $secondary;
   }
@@ -182,7 +182,7 @@
 
   &.new-posts,
   &.unread-posts {
-    background-color: dark-light-choose($tertiary-medium, $tertiary);
+    background-color: $tertiary-med-or-tertiary;
     color: $secondary;
     font-weight: dark-light-choose(normal, bold);
   }
diff --git a/app/assets/stylesheets/common/components/hashtag.scss b/app/assets/stylesheets/common/components/hashtag.scss
index a36a1f8..0d379db 100644
--- a/app/assets/stylesheets/common/components/hashtag.scss
+++ b/app/assets/stylesheets/common/components/hashtag.scss
@@ -1,10 +1,10 @@
 a.hashtag {
-  color: dark-light-choose($primary, $primary-low-mid);
+  color: $primary-or-primary-low-mid;
   font-weight: bold;
 
   &:visited,
   &:hover {
-    color: dark-light-choose($primary, $primary-low-mid);

[... diff too long, it was truncated ...]

GitHub sha: 25dcc577