Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialMatt Coston
18,425 PointsChallenge task 4 of 5 in Adding Pages to a Website.
I am having trouble with this challenge. The question is With the anchor elements inside the contact-info list still selected, set the background size to 20 pixels square. Then set the left padding to 30 pixels, with all other padding at 0.
Here is my current CSS:
.contact-info a { display:block; min-height: 20px; background-size: 20px; background-repeat: no-repeat; padding: 0 0 0 30px;
}
I am not sure what I am lacking. Any ideas? I appreciate any feedback.
3 Answers
Colby Work
20,422 Pointsyou're close...
background-size: 20px 20px :)
Dustin Matlock
33,856 PointsHey Matt, see if this will work for you.
.contact-info a {
display: block;
min-height: 20px;
background: no-repeat;
background-size: 20px 20px;
padding: 0 0 0 30px;
}
Matt Coston
18,425 PointsThank you both very much. It works like a charm.
Colby Work
20,422 PointsColby Work
20,422 Pointsjust to elaborate, background-size takes a width and height, and the challenge is asking for 20px "squared," which would be 20px 20px