From c472f9844ed2806f7965713cf618363210e37de1 Mon Sep 17 00:00:00 2001
From: Nathan-SR <144961007+Nathan-SR@users.noreply.github.com>
Date: Sat, 15 Jun 2024 00:08:00 -0400
Subject: text highlighting works with 'this.' format

---
 .../collections/collectionSchema/CollectionSchemaView.tsx    | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

(limited to 'src/client/views/collections/collectionSchema/CollectionSchemaView.tsx')

diff --git a/src/client/views/collections/collectionSchema/CollectionSchemaView.tsx b/src/client/views/collections/collectionSchema/CollectionSchemaView.tsx
index ac9b57414..d75f076d2 100644
--- a/src/client/views/collections/collectionSchema/CollectionSchemaView.tsx
+++ b/src/client/views/collections/collectionSchema/CollectionSchemaView.tsx
@@ -523,16 +523,13 @@ export class CollectionSchemaView extends CollectionSubView() {
         this.removeCellHighlights();
 
         const randomRGBColor = (): string[] => {
-            let r; let g; let b;
             const brightness = 450;
-            r = Math.floor(Math.random() * 256);
-            g = Math.floor(Math.random() * Math.min(256, brightness - r));
-            b = Math.floor(brightness - r - g);
+            const r = Math.floor(Math.random() * 256);
+            const g = Math.floor(Math.random() * Math.min(256, brightness - r));
+            const b = Math.floor(brightness - r - g);
         
             const lightenedRGB =  ClientUtils.lightenRGB(r, g, b, 65);
-            const rL = lightenedRGB[0];
-            const gL = lightenedRGB[1];
-            const bL = lightenedRGB[2];
+            const rL = lightenedRGB[0]; const gL = lightenedRGB[1]; const bL = lightenedRGB[2]; // prettier-ignore
             const bgdRGB = {rL, gL, bL};
 
             return new Array<string>(`rgb(${r}, ${g}, ${b})`, `rgb(${bgdRGB.rL}, ${bgdRGB.gL}, ${bgdRGB.bL})`);
@@ -542,7 +539,6 @@ export class CollectionSchemaView extends CollectionSubView() {
         this._highlightedCells = [...cellsToHighlight];
         this._highlightedCells.forEach(cell => {
             const color = randomRGBColor();
-            console.log('border: ' + color[0] + ' background: ' + color[1])
             if (!this._cellHighlightColors.has(cell)) {this._cellHighlightColors.set(cell, new Array<string>(`solid 2px ${color[0]}`, color[1]))}
             cell.style.border = this._cellHighlightColors.get(cell)[0];
             cell.style.backgroundColor = this._cellHighlightColors.get(cell)[1];
-- 
cgit v1.2.3-70-g09d2

