Simple fluid navigation with 4 hover effects

Developer
Size
3,336 Kb
Views
16,192

How do I make an simple fluid navigation with 4 hover effects?

What is a simple fluid navigation with 4 hover effects? How do you make a simple fluid navigation with 4 hover effects? This script and codes were developed by Nick Nikolov on 17 October 2022, Monday.

Simple fluid navigation with 4 hover effects Previews

Simple fluid navigation with 4 hover effects - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Simple fluid navigation with 4 hover effects</title> <style> /* NOTE: The styles were added inline because Prefixfree needs access to your styles and they must be inlined if they are on local disk! */ html,
body { padding: 0; margin: 0; font-family: "Open Sans Condensed", Arial, sans-serif;
}
.navigation { margin: 0 0 20px 0; padding: 0; font-size: 1.2em; display: table; table-layout: fixed; width: 100%; border-bottom: 2px solid #19b9e8;
}
.navigation > li { margin: 0; padding: 0; display: table-cell; position: relative; z-index: 1;
}
.navigation > li > a { transition: all 0.2s ease-in-out; box-sizing: border-box; color: #19b9e8; display: block; padding: 10px; text-transform: uppercase; text-decoration: none; position: relative; z-index: 2; text-align: center;
}
.navigation > li.active a,
.navigation > li:hover a { color: #fff; text-shadow: rgba(0, 0, 0, 0.2) 0 1px 1px;
}
.navigation > li:after { content: ''; position: absolute; background: #19b9e8; opacity: 0; top: 100%; left: 0%; bottom: 0%; right: 0%; transition: all 0.2s ease-in-out;
}
.navigation > li:hover:after,
.navigation > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
}
.navigation.expand-center > li:after { top: 50%; left: 50%; bottom: 50%; right: 50%;
}
.navigation.expand-center > li:hover:after,
.navigation.expand-center > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
}
.navigation.expand-top > li:after { top: 0%; left: 0%; bottom: 100%; right: 0%;
}
.navigation.expand-top > li:hover:after,
.navigation.expand-top > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
}
.navigation.expand-left > li:after { top: 0%; left: 0%; bottom: 0%; right: 100%;
}
.navigation.expand-left > li:hover:after,
.navigation.expand-left > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
}
.navigation.expand-right > li:after { top: 0%; left: 100%; bottom: 0%; right: 0%;
}
.navigation.expand-right > li:hover:after,
.navigation.expand-right > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
} </style> <script src="https://cdnjs.cloudflare.com/ajax/libs/prefixfree/1.0.7/prefixfree.min.js"></script>
</head>
<body> <link href='https://fonts.googleapis.com/css?family=Open+Sans+Condensed:300,700' rel='stylesheet' type='text/css'>
<ul class="navigation"> <li><a href="#home">Home</a></li> <li><a href="#home">Services</a></li> <li><a href="#home">Gallery</a></li> <li><a href="#home">Contact</a></li>
</ul>
<ul class="navigation expand-center"> <li><a href="#home">Home</a></li> <li><a href="#home">Services</a></li> <li><a href="#home">Gallery</a></li> <li><a href="#home">Contact</a></li>
</ul>
<ul class="navigation expand-top"> <li><a href="#home">Home</a></li> <li><a href="#home">Services</a></li> <li><a href="#home">Gallery</a></li> <li><a href="#home">Contact</a></li>
</ul>
<ul class="navigation expand-left"> <li><a href="#home">Home</a></li> <li><a href="#home">Services</a></li> <li><a href="#home">Gallery</a></li> <li><a href="#home">Contact</a></li>
</ul>
<ul class="navigation expand-right"> <li><a href="#home">Home</a></li> <li><a href="#home">Services</a></li> <li><a href="#home">Gallery</a></li> <li><a href="#home">Contact</a></li>
</ul>
</body>
</html>

Simple fluid navigation with 4 hover effects - Script Codes CSS Codes

html,
body { padding: 0; margin: 0; font-family: "Open Sans Condensed", Arial, sans-serif;
}
.navigation { margin: 0 0 20px 0; padding: 0; font-size: 1.2em; display: table; table-layout: fixed; width: 100%; border-bottom: 2px solid #19b9e8;
}
.navigation > li { margin: 0; padding: 0; display: table-cell; position: relative; z-index: 1;
}
.navigation > li > a { transition: all 0.2s ease-in-out; box-sizing: border-box; color: #19b9e8; display: block; padding: 10px; text-transform: uppercase; text-decoration: none; position: relative; z-index: 2; text-align: center;
}
.navigation > li.active a,
.navigation > li:hover a { color: #fff; text-shadow: rgba(0, 0, 0, 0.2) 0 1px 1px;
}
.navigation > li:after { content: ''; position: absolute; background: #19b9e8; opacity: 0; top: 100%; left: 0%; bottom: 0%; right: 0%; transition: all 0.2s ease-in-out;
}
.navigation > li:hover:after,
.navigation > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
}
.navigation.expand-center > li:after { top: 50%; left: 50%; bottom: 50%; right: 50%;
}
.navigation.expand-center > li:hover:after,
.navigation.expand-center > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
}
.navigation.expand-top > li:after { top: 0%; left: 0%; bottom: 100%; right: 0%;
}
.navigation.expand-top > li:hover:after,
.navigation.expand-top > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
}
.navigation.expand-left > li:after { top: 0%; left: 0%; bottom: 0%; right: 100%;
}
.navigation.expand-left > li:hover:after,
.navigation.expand-left > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
}
.navigation.expand-right > li:after { top: 0%; left: 100%; bottom: 0%; right: 0%;
}
.navigation.expand-right > li:hover:after,
.navigation.expand-right > li.active:after { opacity: 1; top: 0%; left: 0%; bottom: 0%; right: 0%;
}
Simple fluid navigation with 4 hover effects - Script Codes
Simple fluid navigation with 4 hover effects - Script Codes
Home Page Home
Developer Nick Nikolov
Username necks
Uploaded October 17, 2022
Rating 4
Size 3,336 Kb
Views 16,192
Do you need developer help for Simple fluid navigation with 4 hover effects?

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!

Nick Nikolov (necks) Script Codes
Create amazing art & images 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!