The content on this website, including videos and code examples, is for educational purposes only. All demonstrations and designs are fictional and created to illustrate coding techniques. Any resemblance to existing websites or brands is purely coincidental.
The creators and administrators of this website do not claim ownership or affiliation with any existing websites or companies. Users are encouraged to use the information responsibly for learning purposes. Liability for any misuse of the content provided is not accepted.
Below is the html code for this video.
index.html
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Quest Search Page Template</title>
<link rel="stylesheet"
href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@24,400,0,0" />
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet"
integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
<link rel="stylesheet" href="style.css">
</head>
<body>
<div class="container-fluid d-flex w-100 py-4">
<span class="ms-4 logo-top">D</span>
<ul class="list-group list-group-horizontal ms-auto me-4">
<li class="list-group-item d-flex justify-content-center align-items-center me-3">
<button class="btn btn-secondary px-3 border-0">Log in</button>
</li>
<li class="list-group-item d-flex justify-content-center align-items-center">
<span class="material-symbols-outlined fs-2 text-secondary">menu</span>
</li>
</ul>
</div>
<div class="container mt-5 pt-5">
<div class="row">
<div class="col"></div>
<div
class="col-10 col-sm-10 col-md-8 col-lg-8 w-100 d-flex flex-column justify-content-center align-items-center">
<div class="d-flex justify-content-evenly align-items-center w-100 icons-container">
<div class="d-flex flex-column justify-content-center align-items-center icons-n-text">
<span class="material-symbols-outlined">stadia_controller</span>Games
</div>
<div class="d-flex flex-column justify-content-center align-items-center icons-n-text">
<span class="material-symbols-outlined">imagesmode</span>Images
</div>
<div class="d-flex flex-column justify-content-center align-items-center icons-n-text">
<span class="material-symbols-outlined">play_arrow</span>Video
</div>
<div class="d-flex flex-column justify-content-center align-items-center icons-n-text">
<span class="material-symbols-outlined">thermostat</span>Weather
</div>
<div class="d-flex flex-column justify-content-center align-items-center icons-n-text">
<span class="material-symbols-outlined">location_on</span>Maps
</div>
<div class="d-flex flex-column justify-content-center align-items-center icons-n-text">
<span class="material-symbols-outlined">mail</span>Mail
</div>
<div class="d-flex flex-column justify-content-center align-items-center icons-n-text">
<span class="material-symbols-outlined">translate</span>Translate
</div>
</div>
<div class="mt-5 search-container">
<input type="search" id="search-area" class="w-100" placeholder="navigate your exploration">
<button class="btn btn-warning d-none">Search</button>
</div>
</div>
<div class="col"></div>
</div>
</div>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/js/bootstrap.bundle.min.js"
integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL"
crossorigin="anonymous"></script>
<script src="index.js"></script>
</body>
</html>
Below is the css code for this video.
style.css
* {
margin: 0;
padding: 0;
transition: all 0.25s ease;
}
body {
height: 100vh;
width: 100%;
background: #101010;
overflow: hidden;
}
.logo-top {
display: flex;
height: 50px;
width: 50px;
background: #ff4d1a;
color: #ffffff;
font-size: 40px;
justify-content: center;
align-items: center;
border-radius: 50%;
line-height: 1;
}
.logo-top:hover, .icons-n-text:hover span {
transform: scale(1.25);
}
.list-group-horizontal>.list-group-item:first-child:not(:last-child), .list-group-horizontal>.list-group-item+.list-group-item {
background: transparent;
border: none;
padding: 0;
}
.btn-secondary {
background-color: #4f4f4f !important;
}
.btn-secondary:hover {
background-color: #999999 !important;
}
span.text-secondary:hover {
opacity: 0.25;
}
.icons-container, .search-container {
max-width: 650px;
}
.icons-n-text, .icons-n-text:hover span {
color: #ffffff;
}
.icons-n-text span {
display: flex;
height: 50px;
width: 50px;
background: linear-gradient(135deg, #ff4d1a, #ffd41a);
justify-content: center;
align-items: center;
font-size: 36px;
border-radius: 18px;
margin-bottom: 10px;
}
.icons-n-text:hover {
color: #999999;
}
.search-container {
display: flex;
width: 100%;
background: #4f4f4f;
border-radius: 12px;
padding: 4px;
}
#search-area {
background: transparent;
color: #ffffff;
font-size: 18px;
border: none;
outline: none;
padding: 10px;
}
#search-area:focus-visible {
outline: none;
}
input[type="search"]::-webkit-search-cancel-button {
-webkit-appearance: none;
display: inline-block;
height: 12px;
width: 12px;
background: linear-gradient(45deg, transparent 0%, transparent 43%, #adadad 45%, #adadad 55%, transparent 57%, transparent 100%),
linear-gradient(135deg, transparent 0%, transparent 43%, #adadad 45%, #adadad 55%, transparent 57%, transparent 100%);
margin-left: 10px;
}
.btn-warning {
background-color: #ffd41a !important;
border-radius: 8px !important;
}
Below is the javascript code for this video.
index.js
const logotop = document.getElementsByClassName("logo-top"), loginbtn = document.getElementsByClassName("btn-secondary"),
textsecondary = document.getElementsByClassName("text-secondary"), searchcontainer = document.getElementsByClassName("search-container"),
searcharea = document.getElementById("search-area"), searchbtn = document.getElementsByClassName("btn-warning");
searcharea.addEventListener("focusin", () => {
searchcontainer[0].style.border = "2px solid #ffd41a";
logotop[0].style.opacity = loginbtn[0].style.opacity = textsecondary[0].style.opacity = 0.25;
});
searcharea.addEventListener("focusout", () => {
searchcontainer[0].style.border = "none";
logotop[0].style.opacity = loginbtn[0].style.opacity = textsecondary[0].style.opacity = 1;
});
setInterval(() => { searcharea.value !== "" ? searchbtn[0].classList.remove("d-none") : searchbtn[0].classList.add("d-none"); }, 100);
Thanks for visiting