Horje
How to make Element transparent in CSS ?

The CSS opacity Property is used to adjust the transparency of an element. It controls the level of opacity or see-through effect, allowing you to make elements partially or fully transparent.

Note: The opacity property accepts values between 0 (completely transparent) and 1 (completely opaque).

Syntax

.transparent-box {
opacity: 0.7;
}

Features

  • Transparency Control: opacity allows you to control how transparent or opaque an element is.
  • Values Range: Values range from 0 (completely transparent) to 1 (completely opaque).
  • Affects Child Elements: The opacity of an element affects not only the element itself but also its child elements.
  • Use Cases: Useful for creating subtle background overlays, fade-in/fade-out effects, or making certain elements less prominent.



Reffered: https://www.geeksforgeeks.org


Web Technologies

Related
What is the purpose of using the <meta charset="UTF-8"> Tag ? What is the purpose of using the <meta charset="UTF-8"> Tag ?
What is the importance of WAI-ARIA in HTML ? What is the importance of WAI-ARIA in HTML ?
What is the purpose of using the Geolocation API ? What is the purpose of using the Geolocation API ?
How to display the time in HTML ? How to display the time in HTML ?
How to create a text area in HTML ? How to create a text area in HTML ?

Type:
Geek
Category:
Coding
Sub Category:
Tutorial
Uploaded by:
Admin
Views:
10