From e30b64bed3f73f579e8eaf2353008c11b23dd599 Mon Sep 17 00:00:00 2001 From: Shalini M Date: Mon, 16 Dec 2024 17:08:27 +0530 Subject: [PATCH] Changed the avatar color to checkmate blue color --- Client/src/Components/Avatar/index.jsx | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/Client/src/Components/Avatar/index.jsx b/Client/src/Components/Avatar/index.jsx index 3760c04b8..18bb6be47 100644 --- a/Client/src/Components/Avatar/index.jsx +++ b/Client/src/Components/Avatar/index.jsx @@ -9,19 +9,8 @@ import { useEffect, useState } from "react"; * @returns {string} */ const stringToColor = (string) => { - let hash = 0; - let i; - for (i = 0; i < string.length; i += 1) { - hash = string.charCodeAt(i) + ((hash << 5) - hash); - } - let color = "#"; - for (i = 0; i < 3; i += 1) { - const value = (hash >> (i * 8)) & 0xff; - color += `00${value.toString(16)}`.slice(-2); - } - - return color; + return "#156EEF"; }; /**