Learn CSS Variables by Building a City Skyline - Step 60

Tell us what’s happening:

Fill in .bb3 with a repeating-linear-gradient . Use 90deg for the direction, your building-color3 for the first two colors, and window-color3 at 15% for the third. When you don’t specify a distance for a color, it will use the values that makes sense. In this case, the first two colors will default to 0% and 7.5% because it starts at 0% , and 7.5% is half of the 15% .

Your code so far

.bb3 {
  width: 10%;
  height: 55%;
  background-color: var(--building-color3);
  background: repeating-linear-gradient(
    90deg,
    building-color3,
    building-color3 7.5%,
    window-color3 15%
  );
}

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36 OPR/104.0.0.0

Challenge Information:

Learn CSS Variables by Building a City Skyline - Step 60

You’re not far off but there are a couple of issues.

Firstly, when you want to use variables for colours, you need to use the var keyword. You also need a double hyphen directly before the variable name. Look at your other linear-gradient rules elsewhere in your CSS code to see the correct syntax.

Secondly…

When you don’t specify a distance for a color, it will use the values that makes sense.

… you don’t need to specify a percentage value for building-color3.

1 Like

I just clicked the topic from top so in previous topics about step 60 I don’t saw solution for my issue but I deal with it, anyway some people write 7,5% and in my code that doesn’t work.

code removed by moderator

Here is how I sorted out. Happy coding everyone!

If you have a question about a specific challenge as it relates to your written code for that challenge and need some help, click the Ask for Help button located on the challenge (it looks like a question mark). This button only appears if you have tried to submit an answer at least three times.

The Ask for Help button will create a new topic with all code you have written and include a link to the challenge also. You will still be able to ask any questions in the post before submitting it to the forum.

Thank you.