Learn CSS Variables by Building a City Skyline - Step 40

Tell us what’s happening:
Describe your issue in detail here.
So for this challenge it’s telling me that i have to add a linear gradient to the background property which i feel i did, however its telling me its wrong and i can’t understand how. I have also attempted to delete background-color as i thought it might have been taking priority over background but that didn’t work wither.
Your code so far

/* BACKGROUND BUILDINGS - “bb” stands for “background building” */

.bb1a {
width: 70%;
height: 10%;
background-color: var(–building-color1);
background: linear-gradient(
–building-color1,
–window-color1
)
}

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:105.0) Gecko/20100101 Firefox/105.0

Challenge: Learn CSS Variables by Building a City Skyline - Step 40

Link to the challenge:

when you are trying to use a color that is defined as a variable in the css, you need to use the var function.

eg. var(–building-color1)

10 Likes

right totally forgot about that, thank you so much

1 Like

mod edit: solution redacted

It is great that you solved the challenge, but instead of posting your full working solution, it is best to stay focused on answering the original poster’s question(s) and help guide them with hints and suggestions to solve their own issues with the challenge.

We are trying to cut back on the number of spoiler solutions found on the forum and instead focus on helping other campers with their questions and definitely not posting full working solutions.

Thank you…It works :ok_hand:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.