Responsive css icon
How do I make an responsive css icon?
Part of a gamepad from http://codepen.io/beedesigned/pen/WbZzQx?editors=110 BEM style & responsive. What is a responsive css icon? How do you make a responsive css icon? This script and codes were developed by Fedor Troitsky on 11 November 2022, Friday.
Responsive css icon - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>responsive css icon</title> <link rel="stylesheet" href="css/style.css">
</head>
<body> <div class="icon"> <div class="icon__"> <div class="pad"> <div class="pad__btn-block pad__btn-block--left"> <div class="pad__btn pad__btn--blue"></div> <div class="pad__btn pad__btn--green"></div> </div> <div class="pad__btn-block pad__btn-block--right"> <div class="pad__btn pad__btn--red"></div> <div class="pad__btn pad__btn--yellow"></div> </div> </div> </div> <img class="icon__scaling-img" src="data:image/gif;base64,R0lGODlhAQABAIAAAP7//wAAACH5BAAAAAAALAAAAAABAAEAAAICRAEAOw==" />
</div>
</body>
</html>
Responsive css icon - Script Codes CSS Codes
/* Part of a gamepad from https://codepen.io/beedesigned/pen/WbZzQx?editors=110 */
/* recreated with BEM style & responsiveness */
/* internal sizes */
.icon { position: relative; width: auto; height: auto;
}
.icon__ { position: absolute; top: 0; left: 0; right: 0; bottom: 0; overflow: hidden;
}
.icon__scaling-img { position: relative; visibility: hidden; width: 100%; max-width: 100%; /* max-height: 100%; */
}
.pad { width: 100%; height: 100%; position: relative; background: #383d43; border-radius: 100%;
}
.pad__btn-block { width: 25%; height: 60%; position: absolute; background: #24292f; border-radius: 1000px;
}
.pad__btn-block--left { -webkit-transform: rotate(45deg); transform: rotate(45deg); -webkit-transform-origin: 50% 20%; transform-origin: 50% 20%; top: 13%; left: 37.5%;
}
.pad__btn-block--right { -webkit-transform: rotate(45deg); transform: rotate(45deg); -webkit-transform-origin: 50% 80%; transform-origin: 50% 80%; bottom: 13%; left: 37.5%;
}
.pad__btn { width: 65%; height: 26%; position: absolute; border-radius: 100%;
}
.pad__btn--green { left: 17.5%; bottom: 8.75%; background: #82e6a0;
}
.pad__btn--blue { left: 17.5%; top: 8.75%; background: #6482fa;
}
.pad__btn--red { left: 17.5%; top: 8.75%; background: #fa64be;
}
.pad__btn--yellow { left: 17.5%; bottom: 8.75%; background: #fae664;
}
/* for demo */
html,
body { height: 100%;
}
body { background: #191e1e;
}
Developer | Fedor Troitsky |
Username | ftroitsky |
Uploaded | November 11, 2022 |
Rating | 3 |
Size | 2,967 Kb |
Views | 8,096 |
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 |
Pacman css loader | 2,507 Kb |
A Pen by Fedor Troitsky | 1,452 Kb |
Svg animated logo for Fetchee | 3,103 Kb |
Simple label | 2,751 Kb |
A Pen by Fedor Troitsky | 1,843 Kb |
Cylon css loader | 2,054 Kb |
Node editor layout prototype | 7,410 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 |
Algorithm practice | Abensur | 5,620 Kb |
Resume | Rottingroom | 5,483 Kb |
A Pen by panstable | Panstable | 2,940 Kb |
A form arranged using automatic placement. | Vikasford | 2,103 Kb |
Marching Squares Visualized | Sakri | 7,074 Kb |
A Pen by Mike Otis | Mikeotis | 3,185 Kb |
Ionic Infinite outside ion-content with ion-pane | Felquis | 3,117 Kb |
Basic HTML5 Structure | YuvarajTana | 1,289 Kb |
Cool audio | Bigliam | 1,868 Kb |
Blockquote design | Sjmcpherson | 1,863 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!