0
0
SASSmarkup~5 mins

Lighten and darken functions in SASS - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What does the lighten() function do in Sass?
It makes a color lighter by increasing its lightness by a given percentage.
Click to reveal answer
beginner
How does the darken() function affect a color in Sass?
It makes a color darker by decreasing its lightness by a given percentage.
Click to reveal answer
beginner
Write a Sass code snippet to lighten a blue color by 20%.
$light-blue: lighten(blue, 20%);
Click to reveal answer
intermediate
What happens if you use darken($color, 100%) in Sass?
The color becomes completely black because lightness is reduced to 0%.
Click to reveal answer
intermediate
Why is it better to use lighten() and darken() instead of hardcoding colors?
Because they keep color relationships consistent and make it easier to adjust themes by changing base colors.
Click to reveal answer
What parameter does the lighten() function take besides the color?
AA percentage to increase lightness
BA hex code
CA font size
DA pixel value
If you want to make a color darker by 10%, which function do you use?
Afade-out()
Blighten()
Csaturate()
Ddarken()
What will lighten(red, 0%) return?
AThe same red color
BA lighter red
CA darker red
DWhite
Which CSS property can be affected by using lighten() and darken() in Sass?
Afont-family
Bbackground-color
Cmargin
Dborder-width
What is the range of the percentage value used in lighten() and darken()?
A1 to 10
B0 to 255
C0% to 100%
DAny negative number
Explain how the lighten() and darken() functions work in Sass and give an example of each.
Think about how colors get lighter or darker by changing their lightness.
You got /4 concepts.
    Why is using lighten() and darken() functions helpful when designing a website's color theme?
    Consider how changing one base color can update many related colors.
    You got /3 concepts.