Skip to content

Commit

Permalink
s
Browse files Browse the repository at this point in the history
  • Loading branch information
holtzy committed Oct 22, 2024
1 parent 635f6fb commit 0c7c542
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion pages/course/svg/main-svg-elements.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ const exercices: Exercise[] = [
toDo: (
<ul>
<li>Create 4 bars using 4 rectangles.</li>
<li>The bars should be 400, 300, 200, and 100px high, respectively.</li>
<li>The bars should be 250, 200, 150, and 100px high, respectively.</li>
<li>
Distribute them along the X axis to create your first vertical bar
chart!
Expand Down
2 changes: 1 addition & 1 deletion viz/exercise/SvgFourRectsVerticalPractice/Graph.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
export const Graph = () => {
return (
<svg width={500} height={300}>
<rect x={10} y={30} height={300 - 30 - 30} width={50} fill="red" />
<rect x={10} y={300 - 250} height={250} width={50} fill="red" />
</svg>
);
};
8 changes: 4 additions & 4 deletions viz/exercise/SvgFourRectsVerticalSolution/Graph.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,28 +4,28 @@ export const Graph = () => {
<rect
x={10 + 0 * (50 + 10)}
y={30}
height={300 - 30 - 30}
height={300 - 250}
width={50}
fill="red"
/>
<rect
x={10 + 1 * (50 + 10)}
y={130}
height={200 - 30 - 30}
height={300 - 200}
width={50}
fill="red"
/>
<rect
x={10 + 2 * (50 + 10)}
y={230}
height={100 - 30 - 30}
height={300 - 150}
width={50}
fill="red"
/>
<rect
x={10 + 3 * (50 + 10)}
y={330}
height={100 - 30 - 30}
height={300 - 100}
width={50}
fill="red"
/>
Expand Down

0 comments on commit 0c7c542

Please sign in to comment.