From 3e67e01d59403e29dc87fa673b195b73ec462b59 Mon Sep 17 00:00:00 2001 From: Erik Date: Mon, 4 Dec 2023 02:45:47 +0100 Subject: [PATCH] changed default color of vevIT for new version --- public/css/colorschema.txt | 8 ++++++++ public/js/colorPicker.js | 11 +++++++---- public/style.css | 6 +++--- 3 files changed, 18 insertions(+), 7 deletions(-) create mode 100644 public/css/colorschema.txt diff --git a/public/css/colorschema.txt b/public/css/colorschema.txt new file mode 100644 index 0000000..75efc31 --- /dev/null +++ b/public/css/colorschema.txt @@ -0,0 +1,8 @@ + +V2.3 +--background-color: #111317; /* Default color for background*/ +--contrast-color: #21c937; /* Default color for bookVev button and IT text*/ + +V2.4 + --background-color: #111317; /* Default color for background*/ + --contrast-color: #be1313; /* Default color for bookVev button and IT text*/ \ No newline at end of file diff --git a/public/js/colorPicker.js b/public/js/colorPicker.js index 464740c..49c30c6 100644 --- a/public/js/colorPicker.js +++ b/public/js/colorPicker.js @@ -5,6 +5,9 @@ document.documentElement.style.setProperty("--background-color", getCookie("back console.log(getCookie("backgroundColor")); document.documentElement.style.setProperty("--contrast-color", getCookie("contrastColor")); +const backgroundColor = '#000000'; +const contrastColor = '#be1313'; + // Code for the color picker to change site color const backgroundColorPicker = document.getElementById("backgroundColorPicker"); @@ -42,8 +45,8 @@ resetColorPickers.addEventListener("click", () => { }); function resetColors(){ - document.documentElement.style.setProperty("--background-color", "#000000"); - document.documentElement.style.setProperty("--contrast-color", "#21c937"); - setCookie("backgroundColor", "#000000", 300) - setCookie("contrastColor", "#21c937", 300) + document.documentElement.style.setProperty("--background-color", backgroundColor); + document.documentElement.style.setProperty("--contrast-color", contrastColor); + setCookie("backgroundColor", backgroundColor, 300) + setCookie("contrastColor", contrastColor, 300) } diff --git a/public/style.css b/public/style.css index 34e02fa..e50f564 100644 --- a/public/style.css +++ b/public/style.css @@ -2,7 +2,7 @@ :root { --background-color: #111317; /* Default color for background*/ - --contrast-color: #21c937; /* Default color for bookVev button and IT text*/ + --contrast-color: #be1313; /* Default color for bookVev button and IT text*/ } /* Code for main html tags */ @@ -100,7 +100,7 @@ body { } #resetColorPickers:hover { - background: #21c937; + background: #be1313; } @@ -383,7 +383,7 @@ footer { } #understood-button { - background: #21c937; + background: #21c937; /* Should be green and not contrast color */ color: #000; border: none; padding: 10px 20px;