Information Icon
How do I make an information icon?
This is just a quick demo on creating a simple 'i' icon to show information is available.. What is a information icon? How do you make a information icon? This script and codes were developed by Colm Hewson on 05 December 2022, Monday.
Information Icon - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Information Icon</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <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> <svg id="icon-info" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewbox="0 0 512 512"> <circle id="icon-info-outercircle" cx="256" cy="256"/> <circle id="icon-info-letter-i-top" cx="256" cy="128" stroke-width="0"/> <line id="icon-info-letter-i-bottom" x1="256" y1="384" x2="256" y2="224" stroke-width="48" stroke-linecap="round"/>
</svg> <script src='https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.0/jquery.min.js'></script> <script src="js/index.js"></script>
</body>
</html>
Information Icon - Script Codes CSS Codes
html, body { padding: 0; margin: 0;
}
body { width: 100%; height: 100vh; font-family: 'Open Sans', sans-serif; font-weight: 400; font-style: normal; font-size: 16px; line-height: 24px; display: -webkit-box; display: -ms-flexbox; display: flex; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; -webkit-touch-callout: none; display: flex; -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; -webkit-box-align: center; -ms-flex-align: center; align-items: center; -ms-flex-line-pack: center; align-content: center;
}
#icon-info { -webkit-box-flex: 0; -ms-flex: 0 0 calc(100% - 2rem); flex: 0 0 calc(100% - 2rem); max-width: 512px; cursor: pointer;
}
#icon-info-outercircle { stroke: #25D49D; fill: transparent; stroke-width: 32; r: 240; stroke-dasharray: 1507.2; stroke-dashoffset: 0; -webkit-animation: draw-circle-once 1s cubic-bezier(0.75, 0, 0.75, 1) forwards; animation: draw-circle-once 1s cubic-bezier(0.75, 0, 0.75, 1) forwards;
}
#icon-info-letter-i-bottom { stroke: #25D49D; fill: #25D49D; stroke-dasharray: 160; stroke-dashoffset: 160; -webkit-animation: draw-i-once 0.5s cubic-bezier(0.75, 0, 0.75, 1) forwards 0.5s; animation: draw-i-once 0.5s cubic-bezier(0.75, 0, 0.75, 1) forwards 0.5s;
}
#icon-info-letter-i-top { stroke: #25D49D; fill: #25D49D; r: 0; stroke-dasharray: 160; stroke-dashoffset: 160; -webkit-animation: draw-dot-once 0.3s cubic-bezier(1, 0, 1, 1) forwards 1s; animation: draw-dot-once 0.3s cubic-bezier(1, 0, 1, 1) forwards 1s;
}
@-webkit-keyframes draw-circle-loop { 0% { stroke-dashoffset: 1507.2; } 25% { stroke-dashoffset: 0; } 50% { stroke-dashoffset: -1507.2; } 50.1% { stroke-dashoffset: 1507.2; } 75% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: -1507.2; }
}
@keyframes draw-circle-loop { 0% { stroke-dashoffset: 1507.2; } 25% { stroke-dashoffset: 0; } 50% { stroke-dashoffset: -1507.2; } 50.1% { stroke-dashoffset: 1507.2; } 75% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: -1507.2; }
}
@-webkit-keyframes draw-circle-once { 0% { stroke-dashoffset: 1507.2; } 100% { stroke-dashoffset: 0; }
}
@keyframes draw-circle-once { 0% { stroke-dashoffset: 1507.2; } 100% { stroke-dashoffset: 0; }
}
@-webkit-keyframes draw-i-once { 0% { stroke-dashoffset: 160; } 100% { stroke-dashoffset: 0; }
}
@keyframes draw-i-once { 0% { stroke-dashoffset: 160; } 100% { stroke-dashoffset: 0; }
}
@-webkit-keyframes draw-dot-once { 0% { r: 0; } 75% { r: 28; } 100% { r: 24; }
}
@keyframes draw-dot-once { 0% { r: 0; } 75% { r: 28; } 100% { r: 24; }
}
Information Icon - Script Codes JS Codes
// This is just a little calculator so you can put the circles radius in and find out the circumference.
// Check the console button for the circumference.
// You need to use this to for the stroke-dashoffset value... 0 means the line is fully extended... The value of the circumference means it's retracted by its own length i.e.
// If you use different values for the stroke-dasharray value for different types of lines | circumference / 2 = A half circle, circumference / 4 = Two quarter arcs etc.
$(document).ready(function() { var radius = 240; var circum = 2 * 3.14 * radius; console.log(circum);
});
Developer | Colm Hewson |
Username | legofsalmon |
Uploaded | December 05, 2022 |
Rating | 3 |
Size | 3,613 Kb |
Views | 12,144 |
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!
Name | Size |
Map Marker Test | 2,330 Kb |
SVG Icons Template - Event | 5,373 Kb |
Brens thing | 4,542 Kb |
Listy - Version 1 | 7,049 Kb |
Des1gnon Logo - Testing the Wave Pattern | 2,201 Kb |
A Pen by Colm Hewson | 12,521 Kb |
SVG Icons Template | 2,618 Kb |
SVG Animate Test | 3,310 Kb |
Get a Route - Draft v02 | 6,979 Kb |
Breadcrumbs for motor journey top bar thing. | 8,548 Kb |
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!
Name | Username | Size |
My Starter Kit For Codepen | Dkdesign | 2,012 Kb |
A Pen by Jonas Bjork | Jonasbjork | 3,115 Kb |
Canvas Orbital Trails v2 | Jackrugile | 3,421 Kb |
Responsive slide | Thorien | 2,400 Kb |
Table Exercise | Fresco | 9,585 Kb |
Fellowship of the Ring | Aussieyang | 2,639 Kb |
Pure CSS Read More Arrow | Zephyr | 1,747 Kb |
Opening Reveal Modal On Document Ready | Winghouchan | 1,787 Kb |
NAV WPMANAGER | Mstoic | 1,991 Kb |
Comment Jquery | SquishyAndroid | 2,421 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!