Tailwind CSS Backdrop Sepia
The backdrop sepia class is an inbuilt class that is used to apply a filter to the image to convert an image into a sepia image. Tailwind CSS newly added feature brightness in 2.1 version.
Backdrop Sepia:
- backdrop-sepia-0: This class is used to represent the original image
- backdrop-sepia: This class is used to represent the sepia image.
Syntax:
<element class="filter backdrop-sepia | backdrop-sepia-0"> </element>
Example:
HTML
<!DOCTYPE html> < html > < head > < link href = "https://unpkg.com/tailwindcss@^2.1/dist/tailwind.min.css" rel = "stylesheet" > </ head > < body class = "text-center mx-4 " > < h1 class = "text-green-600 text-5xl font-bold" > GeeksforGeeks </ h1 > < b >Tailwind CSS Backdrop Sepia Class</ b > < div class = " mx-16 mt-18 h-36 relative" > < div class = "absolute w-full py-18" > < img class = "rounded-lg object-cover" src = alt = "image" > </ div > < div class = "relative h-32 flex overflow-x-auto space-x-4" > < div class="flex-shrink-0 border-4 border-green-500 backdrop-filter backdrop-sepia-0 w-1/2"> </ div > < div class="flex-shrink-0 border-4 border-green-500 backdrop-filter backdrop-sepia w-1/2"> </ div > </ div > </ div > </ body > </ html > |
Output:
Please Login to comment...