Fullscreen Menu With Hamburger Icon

Developer
Size
3,612 Kb
Views
6,072

How do I make an fullscreen menu with hamburger icon?

What is a fullscreen menu with hamburger icon? How do you make a fullscreen menu with hamburger icon? This script and codes were developed by Danwarfel on 18 January 2023, Wednesday.

Fullscreen Menu With Hamburger Icon Previews

Fullscreen Menu With Hamburger Icon - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Fullscreen Menu With Hamburger Icon</title> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css"> <link rel="stylesheet" href="css/style.css">
</head>
<body> <input id="toggle" type="checkbox" />
<label for="toggle"> <svg class="burger" width="86" height="60" viewbox="0 0 150 150"> <g stroke-width="12"> <line x1="6" y1="6" x2="80" y2="6"></line> <line x1="6" y1="28" x2="80" y2="28"></line> <line x1="6" y1="50" x2="80" y2="50"> </line> </g> </svg> <svg class="close" width="86" height="60" viewbox="0 0 150 150"> <g stroke-width="12"> <line x1="42" y1="6" x2="42" y2="80"></line> <line x1="6" y1="42" x2="80" y2="42"></line> </g> </svg>
</label>
<div class="menu"> <div>Home</div> <div>About</div> <div>Hello</div> <div>Contact</div>
</div>
<span class="main"> <span>Fullscreen Menu With Hamburger Icon</span> </div>
</span>
</body>
</html>

Fullscreen Menu With Hamburger Icon - Script Codes CSS Codes

@import url(https://fonts.googleapis.com/css?family=Lato:400,300,100,700);
body { background-color: #5B80AA; font-family: 'Lato', sanserif; font-weight: 300; /* ff3.6+ */ background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, black), color-stop(17%, #05c1ff), color-stop(100%, #002c37)); /* safari4+,chrome */ background: -webkit-linear-gradient(90deg, #002c37 0%, #05c1ff 83%, black 100%); /* safari5.1+,chrome10+ */ /* opera 11.10+ */ /* ie10+ */ background: -webkit-linear-gradient(bottom, #002c37 0%, #05c1ff 83%, black 100%); background: linear-gradient(0deg, #002c37 0%, #05c1ff 83%, black 100%); /* w3c */ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#000000', endColorstr='#30aaff',GradientType=1 ); /* ie6-9 */
}
label { position: absolute; z-index: 1;
}
input { display: none;
}
input:checked ~ label { right: 0;
}
.burger { position: relative; top: 24px; cursor: pointer;
}
.burger g { stroke: #ffffff; -webkit-transition: stroke 0.25s ease-in-out; transition: stroke 0.25s ease-in-out;
}
.burger g:hover { stroke: #cccccc;
}
input:checked ~ label .burger { opacity: 0;
}
.close { position: relative; top: 24px; cursor: pointer; opacity: 0;
}
.close g:hover { stroke: #cccccc;
}
.close g { stroke: #ffffff; -webkit-transition: stroke 0.25s ease-in-out; transition: stroke 0.25s ease-in-out;
}
.close line { -webkit-transform-origin: 0%; transform-origin: 0%;
}
.close g { -webkit-transform: rotateZ(45deg); transform: rotateZ(45deg); -webkit-transform-origin: 50%; transform-origin: 50%;
}
input:checked ~ label .close { opacity: 1;
}
.menu { display: -webkit-box; display: -ms-flexbox; display: flex; -webkit-box-orient: vertical; -webkit-box-direction: normal; -ms-flex-direction: column; flex-direction: column; -webkit-box-align: center; -ms-flex-align: center; align-items: center; -ms-flex-pack: distribute; justify-content: space-around; position: absolute; opacity: 0; width: 100vw; height: 100vh; background-color: tomato; -webkit-transition: opacity 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275); transition: opacity 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275); color: #eee; text-transform: uppercase; font-size: 24px; font-weight: 100; font-family: Arial, Helvetica, sans-serif;
}
input:checked ~ .menu { opacity: 1;
}
.menu div { margin-top: 50px; -webkit-transition: margin 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275); transition: margin 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
input:checked ~ .menu div { margin-top: 0px;
}
.main { display: -webkit-box; display: -ms-flexbox; display: flex; width: 100vw; height: 100vh;
}
.main span { margin: auto; font-size: 40px; text-transform: uppercase; color: #eee;
}
Fullscreen Menu With Hamburger Icon - Script Codes
Fullscreen Menu With Hamburger Icon - Script Codes
Home Page Home
Developer Danwarfel
Username danwarfel
Uploaded January 18, 2023
Rating 3
Size 3,612 Kb
Views 6,072
Do you need developer help for Fullscreen Menu With Hamburger Icon?

Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!

Danwarfel (danwarfel) Script Codes
Create amazing love letters with AI!

Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!