Skip to content

Commit 3f46c3a

Browse files
committed
removed unneeded comments
1 parent 4109688 commit 3f46c3a

File tree

3 files changed

+17
-93
lines changed

3 files changed

+17
-93
lines changed

src/app/components/StateRoute/ComponentMap/ComponentMap.tsx

Lines changed: 14 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -29,13 +29,11 @@ const nodeParentFill = '#161521'; //#161521 original
2929
const nodeChildFill = '#62d6fb'; //#62d6fb original
3030
const nodeParentStroke = '#F00008'; //#F00008 original
3131
const nodeChildStroke = '#4D4D4D'; //#4D4D4D original
32-
let stroke = '';
33-
//css class for hovered stroke change
34-
// const hoverClass = {
35-
// stroke: "#ab269b"//pinkish
36-
// }
3732
const hoverClass = '#ab269b'; //pinkish
3833

34+
let stroke = '';
35+
36+
3937
/* Heat Map Colors (for links) */
4038
const lightOrange = '#F1B476';
4139
const darkOrange = '#E4765B';
@@ -264,22 +262,19 @@ export default function ComponentMap({
264262
const k = .4;
265263
const strokeWidthIndex = yshift + L / (1 + Math.exp(-k * (childPropsLength - x0)));
266264

267-
// function findStrokeColor() {
268-
if (strokeWidthIndex <= 1) {
269-
stroke = '#808080';
265+
if (strokeWidthIndex <= 1) {
266+
stroke = '#808080';
267+
} else {
268+
if (childPropsLength <= 1) {
269+
stroke = lightOrange;
270+
} else if (childPropsLength <= 2) {
271+
stroke = darkOrange;
272+
} else if (childPropsLength <= 3) {
273+
stroke = red;
270274
} else {
271-
if (childPropsLength <= 1) {
272-
stroke = lightOrange;
273-
} else if (childPropsLength <= 2) {
274-
stroke = darkOrange;
275-
} else if (childPropsLength <= 3) {
276-
stroke = red;
277-
} else {
278-
stroke = plum;
279-
}
275+
stroke = plum;
280276
}
281-
// }
282-
// findStrokeColor();
277+
}
283278

284279

285280
const [isHovered, setIsHovered] = useState(false);
@@ -300,62 +295,6 @@ export default function ComponentMap({
300295
strokeColor = stroke
301296
}
302297

303-
304-
305-
306-
307-
308-
/* CODE GRAVEYARD
309-
//hover state
310-
// const [hoverStroke, setHoverStroke] = useState('');
311-
// const [strokeColor, setStrokeColor] = useState(stroke);
312-
const [isHovered, setIsHovered] = useState(false);
313-
const handleMouseEnter = () => {
314-
setIsHovered(true);
315-
// stroke = hoverClass;
316-
// setStrokeColor(hoverClass);
317-
stroke = strokeColor;
318-
// make box
319-
};
320-
const handleMouseLeave = () => {
321-
setIsHovered(false);
322-
// if (strokeWidthIndex <= 1) {
323-
// setStrokeColor = '#808080';
324-
// } else {
325-
// if (childPropsLength <= 1) {
326-
// setStrokeColor = lightOrange;
327-
// } else if (childPropsLength <= 2) {
328-
// setStrokeColor = darkOrange;
329-
// } else if (childPropsLength <= 3) {
330-
// setStrokeColor = red;
331-
// } else {
332-
// setStrokeColor = plum;
333-
// }
334-
// }
335-
stroke = hoverClass;
336-
337-
// };
338-
339-
let strokeColor: string;
340-
if (isHovered) {
341-
strokeColor = hoverClass
342-
// strokeColor =
343-
} else {
344-
strokeColor = stroke;
345-
};
346-
// let strokeColor: string;
347-
function linkHover() {
348-
if (isHovered) {
349-
strokeColor = hoverClass
350-
} else {
351-
strokeColor = stroke;
352-
};
353-
// return strokeColor;
354-
}
355-
strokeColor = linkHover();
356-
357-
// // const strokeColor = isHovered ? hoverClass.stroke : stroke;
358-
// isHovered ? stroke="ab269b" : stroke; */
359298

360299
return (
361300
<>

src/app/styles/components/_componentMap.scss

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,5 @@
1-
// .compMapLink {
2-
// // stroke: $map-link;
3-
// stroke: $secondary-color;
4-
// }
5-
// .compMapLink:hover {
6-
// box-shadow: 10px 10px rgb(163, 205, 24);
7-
// };
8-
// * {
9-
// border: 1px solid red;
10-
// }
1+
2+
113

124
.comp-map-options {
135
color: $map-options-label;
@@ -25,10 +17,7 @@
2517
// //stroke: $map-parent-stroke;
2618
// }
2719

28-
//Jose testing onhover
29-
.compMapParent:hover {
30-
stroke: color(red)
31-
}
20+
3221

3322
.compMapParentText {
3423
fill: $map-parent-text

src/app/styles/layout/_stateContainer.scss

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -242,10 +242,6 @@
242242
z-index: 2;
243243
}
244244

245-
// .state-container .router-link {
246-
// border: 0.5px solid rgba(0, 0, 0, 0.5);
247-
// border-bottom: none;
248-
// }
249245

250246
.tooltipData {
251247
background-color: #373737;

0 commit comments

Comments
 (0)