Border-radius animation

Developer
Size
2,480 Kb
Views
32,384

How do I make an border-radius animation?

What is a border-radius animation? How do you make a border-radius animation? This script and codes were developed by Yukulélé on 26 August 2022, Friday.

Border-radius animation Previews

Border-radius animation - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Border-radius animation</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! */ #foo { width: 200px; height: 200px; background: #444; animation: corner 3s; border-radius: 50%; animation-iteration-count: infinite; animation-timing-function: linear; position: absolute; top: 0; left: 0; right: 0; bottom: 0; margin: auto;
}
@keyframes corner { 0% { border-top-left-radius: 1% 50%; } 12.5% { border-top-left-radius: 50%; border-top-right-radius: 50%; } 25% { border-top-right-radius: 1% 50%; } 25.001% { border-top-right-radius: 50% 1%; } 37.5% { border-top-right-radius: 50%; border-bottom-right-radius: 50%; } 50% { border-bottom-right-radius: 50% 1%; } 50.001% { border-bottom-right-radius: 1% 50%; } 62.5% { border-bottom-right-radius: 50%; border-bottom-left-radius: 50%; } 75% { border-bottom-left-radius: 1% 50%; } 75.001% { border-bottom-left-radius: 50% 1%; } 87.5% { border-bottom-left-radius: 50%; border-top-left-radius: 50%; } 100% { border-top-left-radius: 50% 1%; }
} </style> <script src="https://cdnjs.cloudflare.com/ajax/libs/prefixfree/1.0.7/prefixfree.min.js"></script>
</head>
<body> <div id="foo"></div>
</body>
</html>

Border-radius animation - Script Codes CSS Codes

#foo { width: 200px; height: 200px; background: #444; animation: corner 3s; border-radius: 50%; animation-iteration-count: infinite; animation-timing-function: linear; position: absolute; top: 0; left: 0; right: 0; bottom: 0; margin: auto;
}
@keyframes corner { 0% { border-top-left-radius: 1% 50%; } 12.5% { border-top-left-radius: 50%; border-top-right-radius: 50%; } 25% { border-top-right-radius: 1% 50%; } 25.001% { border-top-right-radius: 50% 1%; } 37.5% { border-top-right-radius: 50%; border-bottom-right-radius: 50%; } 50% { border-bottom-right-radius: 50% 1%; } 50.001% { border-bottom-right-radius: 1% 50%; } 62.5% { border-bottom-right-radius: 50%; border-bottom-left-radius: 50%; } 75% { border-bottom-left-radius: 1% 50%; } 75.001% { border-bottom-left-radius: 50% 1%; } 87.5% { border-bottom-left-radius: 50%; border-top-left-radius: 50%; } 100% { border-top-left-radius: 50% 1%; }
}
Border-radius animation - Script Codes
Border-radius animation - Script Codes
Home Page Home
Developer Yukulélé
Username yukulele
Uploaded August 26, 2022
Rating 4
Size 2,480 Kb
Views 32,384
Do you need developer help for Border-radius animation?

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!

Yukulélé (yukulele) Script Codes
Create amazing captions 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!