From 55b8ea71ccc1ef93a0ca4b50fee125e7db4e2d4d Mon Sep 17 00:00:00 2001 From: Abdullah Jamal Date: Mon, 12 Feb 2024 08:30:59 +0530 Subject: [PATCH] add complete support for light theme --- src/classes/botClass.js | 3 +-- src/setup/sketch.js | 16 ++++++++-------- 2 files changed, 9 insertions(+), 10 deletions(-) diff --git a/src/classes/botClass.js b/src/classes/botClass.js index 936df8c..59c06b2 100644 --- a/src/classes/botClass.js +++ b/src/classes/botClass.js @@ -48,8 +48,7 @@ botClass.prototype.drawProbabilityDensityGrid = function () { } rect(indent + 550 + 35 * (i + 1), indent_y + 35 * (j + 1), 35, 35); } else if (this.grid[i][j] === 2) { - // fill(0, 0, 0); - fill(19, 41, 75); + fill(0, 0, 0); rect(indent + 550 + 35 * (i + 1), indent_y + 35 * (j + 1), 35, 35); } } diff --git a/src/setup/sketch.js b/src/setup/sketch.js index 4206bc9..c19b9d0 100644 --- a/src/setup/sketch.js +++ b/src/setup/sketch.js @@ -46,34 +46,34 @@ var isLightTheme = true; const RGB = { get BACKGROUND() { - return isLightTheme ? 'rgb(19, 41, 75)': 'rgb(19, 41, 75)'; + return isLightTheme ? 'rgb(19, 41, 75)': 'rgb(22, 92, 125)'; }, get BUTTON() { - return isLightTheme ? 'rgba(54, 157, 160, 1.0)': 'rgba(54, 157, 160, 1.0)'; + return isLightTheme ? 'rgba(54, 157, 160, 1.0)': 'rgba(198, 218, 231, 1.0)'; }, get SHIP_HIT() { return isLightTheme ? 'rgb(210, 43, 43)': 'rgb(210, 43, 43)'; }, get SHIP_MISS() { - return isLightTheme ? 'rgb(54, 157, 160)': 'rgb(54, 157, 160)'; + return isLightTheme ? 'rgb(54, 157, 160)': 'rgb(198, 218, 231)'; }, get BUTTON_TEXT() { return isLightTheme ? 'rgb(0, 0, 0)': 'rgb(0, 0, 0)'; }, get BOARD_OCEAN_BLOCK() { - return isLightTheme ? 'rgb(22, 92, 125)': 'rgb(211, 187, 168)'; + return isLightTheme ? 'rgb(22, 92, 125)': 'rgb(54, 157, 160)'; }, get BOARD_OCEAN_BLOCK_HIGHLIGHT() { - return isLightTheme ? 'rgba(31, 126, 171, 0.8)': 'rgba(31, 126, 171, 0.8)'; + return isLightTheme ? 'rgba(31, 126, 171, 0.8)': 'rgba(70, 170, 190, 0.8)'; }, get BOARD_ISLAND_BLOCK() { - return isLightTheme ? 'rgb(211, 187, 168)': 'rgb(22, 92, 125)'; + return isLightTheme ? 'rgb(211, 187, 168)': 'rgb(228, 213, 211)'; }, get STATS_HIGH() { - return isLightTheme ? 'rgb(211, 187, 168)': 'rgb(144, 238, 144)'; + return isLightTheme ? 'rgb(211, 187, 168)': 'rgb(211, 187, 168)'; }, get STATS_LOW() { - return isLightTheme ? 'rgb(228, 213, 211)': 'rgb(255, 127, 127)'; + return isLightTheme ? 'rgb(228, 213, 211)': 'rgb(228, 213, 211)'; } }