Skip to content

Commit bea2100

Browse files
comments added for the individual nodes creation information
1 parent 66c4d1d commit bea2100

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/app/components/ComponentMap.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ export default function ComponentMap({
3838
const [stepPercent, setStepPercent] = useState<number>(0.5);
3939
// Declared this variable and assigned it to the useForceUpdate function that forces a state to change causing that component to re-render and display on the map
4040
const forceUpdate = useForceUpdate();
41-
// setting the margins for the Map to render in the tab
41+
// setting the margins for the Map to render in the tab window.
4242
const innerWidth = totalWidth - margin.left - margin.right;
4343
const innerHeight = totalHeight - margin.top - margin.bottom;
4444

@@ -132,6 +132,7 @@ export default function ComponentMap({
132132
}}
133133
/>
134134
)}
135+
{/* This creates the rectangle boxes for each component and sets it relative position to other parent nodes of the same level. */}
135136
{node.depth !== 0 && (
136137
<rect
137138
height={height}
@@ -150,6 +151,7 @@ export default function ComponentMap({
150151
}}
151152
/>
152153
)}
154+
{/* Display text inside of each component node */}
153155
<text
154156
dy='.33em'
155157
fontSize={9}

0 commit comments

Comments
 (0)