0
0
Tailwindmarkup~5 mins

Opacity modifiers on colors in Tailwind - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What does an opacity modifier do in Tailwind CSS?
It changes how transparent a color looks, making it see-through to some degree.
Click to reveal answer
beginner
How do you apply 50% opacity to a background color in Tailwind?
Use a color with an opacity suffix like bg-blue-500/50 where /50 means 50% opacity.
Click to reveal answer
beginner
What range of values can you use for opacity modifiers in Tailwind?
You can use values from 0 to 100, where 0 is fully transparent and 100 is fully opaque.
Click to reveal answer
intermediate
True or False: Opacity modifiers affect only the color, not the whole element.
True. Opacity modifiers like /50 change only the color's transparency, not the entire element's opacity.
Click to reveal answer
beginner
How would you write a red text color with 30% opacity in Tailwind?
Use text-red-500/30 to make the red text 30% opaque (70% transparent).
Click to reveal answer
What does bg-green-400/75 mean in Tailwind CSS?
AGreen background with no opacity
BGreen background with 75% opacity
CGreen background with 100% opacity
DGreen background with 25% opacity
Which opacity modifier makes a color fully transparent?
A/0
B/50
C/100
D/25
Can you use opacity modifiers on text color in Tailwind?
AOnly on borders
BNo, only background colors support opacity
COnly with extra plugins
DYes, like <code>text-blue-600/40</code>
What happens if you omit the opacity modifier on a Tailwind color class?
AThe color uses 50% opacity by default
BThe color is fully transparent
CThe color is fully opaque (100%)
DThe color becomes grayscale
Which of these is a valid Tailwind opacity modifier?
A/25
B/110
C/-10
D/abc
Explain how opacity modifiers work on colors in Tailwind CSS and give an example.
Think about how you make a color partly see-through.
You got /3 concepts.
    Describe the difference between using opacity modifiers on colors versus using the CSS opacity property on an element.
    Consider what parts become transparent in each case.
    You got /3 concepts.