From edb429e30796c9312de9a28c262008c7d44757e6 Mon Sep 17 00:00:00 2001
From: Henry Jameson <me@hjkos.com>
Date: Thu, 15 Nov 2018 17:17:20 +0300
Subject: [PATCH] cleanup and fixes

---
 src/components/style_switcher/style_switcher.js | 16 ++--------------
 src/services/color_convert/color_convert.js     |  2 --
 2 files changed, 2 insertions(+), 16 deletions(-)

diff --git a/src/components/style_switcher/style_switcher.js b/src/components/style_switcher/style_switcher.js
index 9e236488..f4f9331f 100644
--- a/src/components/style_switcher/style_switcher.js
+++ b/src/components/style_switcher/style_switcher.js
@@ -288,19 +288,6 @@ export default {
     },
 
     setCustomTheme () {
-      if (!this.bgColorLocal && !this.btnColorLocal && !this.linkColorLocal) {
-        // reset to picked themes
-      }
-
-      const rgb = (hex) => {
-        const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex)
-        return result ? {
-          r: parseInt(result[1], 16),
-          g: parseInt(result[2], 16),
-          b: parseInt(result[3], 16)
-        } : null
-      }
-
       this.$store.dispatch('setOption', {
         name: 'customTheme',
         value: this.currentTheme
@@ -310,6 +297,8 @@ export default {
     clearV1 () {
       this.bgOpacityLocal = undefined
       this.fgOpacityLocal = undefined
+
+      this.fgTextColorLocal = undefined
       this.fgLinkColorLocal = undefined
 
       this.btnColorLocal = undefined
@@ -371,7 +360,6 @@ export default {
       }
 
       const keys = new Set(version !== 1 ? Object.keys(colors) : [])
-      console.log(keys)
       if (version === 1) {
         // V1 ignores the rest
         this.clearV1()
diff --git a/src/services/color_convert/color_convert.js b/src/services/color_convert/color_convert.js
index 00b6c552..58c434fa 100644
--- a/src/services/color_convert/color_convert.js
+++ b/src/services/color_convert/color_convert.js
@@ -99,9 +99,7 @@ const alphaBlend = (fg, fga, bg) => {
 
 const invert = (rgb) => {
   return 'rgb'.split('').reduce((acc, c) => {
-    console.log(rgb[c])
     acc[c] = 255 - rgb[c]
-    console.log(acc[c])
     return acc
   }, {})
 }