Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

readme.md

Change the Color of an SVG Element

link solution
The bars are in the right position, but they are all the same black color. SVG has a way to change the color of the bars.

In SVG, a rect shape is colored with the fill attribute. It supports hex codes, color names, and rgb values, as well as more complex options like gradients and transparency. Add an attr() method to set the fill of all the bars to the color navy.

Tests

The bars should all have a fill color of navy.