css cat meme toggle button

How we can create a toggle button with an image masking? Solution: See this CSS Cat Meme Toggle Button With Checkbox, Women Yelling At Cat Viral Meme Toggle Switch.

Earlier I have shared some Toggle Button program, but it is a little different from those because it has an image mask in button. Basically, Toggle button means if you need to button with two options like Play/Stop in a button at that time on the first click it will be working as a play button and second time working as a stop button this is a toggle button. And we can create this type of toggle switch using the radio input and checkbox method also.

Today you will learn to create a toggle button with famous Women Yelling At Cat meme mask. Basically, there is a toggle button and it is for indicating dark and light mode, but you can use according to your choice. First, you will see the famous meme lady’s face and text on the opposite side “It’s Light Mode”. And on click, the toggle will switch to the cat face and the text reveal on another side “No, Night Mode”. It is a funny concept, developers and website owner who is a meme lover, they will love it.

So, Today I am sharing CSS Cat Meme Toggle Button With Checkbox. There I have used pure CSS and HTML for creating this program, there is no JS or any JS library. This is a good and funny example of how we can use HTML CSS together for creating amazing stuff. If you like meme and development both, then you can use this program on your website as dark/light mode toggle or anything else.

If you are thinking now how this meme toggle actually is, then see the preview given below.

Preview Of Women Yelling At Cat Dark/Light Mode Toggle Switch

See this video preview to getting an idea of how this toggle button looks like.

Live Demo

Now you can see this visually, also you can see it live by pressing the button given above. If you like this, then get the source code of its.

You May Also Like:

CSS Cat Meme Toggle Button With Checkbox Source Code

Before sharing source code, let’s talk about it. First I have created checkbox input using HTML <input type="checkbox"> tag and a label for the input. Inside the label, I have placed 3 divs inside it for circle shape and two texts. The texts are dark and light mode, and the circle is for showing the button or switch.

Now using CSS I have placed all the elements in the right place, as you can see in the preview. With CSS first did the checkbox display none, and gave the size to the label and contents inside it. Inside the circle, I have placed the meme image and gave the background-size according to the label’s size. On clicking the circle changing margin and image changing the background size.

Left all other things you will understand after getting the codes, I can’t explain all in writing. For creating this program you have to create only 2 files, one for HTML and one for CSS. Follow the steps to creating this without any error.

index.html

Create an HTML file named ‘index.html‘ and put these codes given here.

style.css

That’s It. Now you have successfully created CSS Cat Meme Toggle Button With Checkbox, Famous Women Yelling At Cat Meme Dark/Light Mode Toggle. If you have any doubt or question then comment down below.

Thanks For Visiting, Keep Visiting.

3 COMMENTS

LEAVE A REPLY

Please enter your comment!
Please enter your name here