Items on circle

Developer
Size
3,437 Kb
Views
40,480

How do I make an items on circle?

A Sass version of Ana's work consisting on putting items on circle with CSS: http://stackoverflow.com/questions/12813573/position-icons-into-circle.. What is a items on circle? How do you make a items on circle? This script and codes were developed by Hugo Giraudel on 09 August 2022, Tuesday.

Items on circle Previews

Items on circle - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Items on circle</title> <script src="http://s.codepen.io/assets/libs/modernizr.js" type="text/javascript"></script> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css"> <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! */ .circle-container { position: relative; /* 1 */ width: 20em; height: 20em; padding: 0; border-radius: 50%; list-style: none; /* 2 */ box-sizing: content-box; /* 3 */ margin: 5em auto 0; border: solid 5px tomato;
}
.circle-container > * { /* 4 */ display: block; position: absolute; top: 50%; left: 50%; width: 6em; height: 6em; margin: -3em;
}
.circle-container > :nth-of-type(1) { transform: rotate(0deg) translate(10em) rotate(0deg);
}
.circle-container > :nth-of-type(2) { transform: rotate(45deg) translate(10em) rotate(-45deg);
}
.circle-container > :nth-of-type(3) { transform: rotate(90deg) translate(10em) rotate(-90deg);
}
.circle-container > :nth-of-type(4) { transform: rotate(135deg) translate(10em) rotate(-135deg);
}
.circle-container > :nth-of-type(5) { transform: rotate(180deg) translate(10em) rotate(-180deg);
}
.circle-container > :nth-of-type(6) { transform: rotate(225deg) translate(10em) rotate(-225deg);
}
.circle-container > :nth-of-type(7) { transform: rotate(270deg) translate(10em) rotate(-270deg);
}
.circle-container > :nth-of-type(8) { transform: rotate(315deg) translate(10em) rotate(-315deg);
}
.circle-container img { display: block; width: 100%; border-radius: 50%; filter: grayscale(100%);
}
.circle-container img:hover { filter: grayscale(0);
} </style> <script src="https://cdnjs.cloudflare.com/ajax/libs/prefixfree/1.0.7/prefixfree.min.js"></script>
</head>
<body> <ul class='circle-container'> <li><img src='http://lorempixel.com/100/100/city'></li> <li><img src='http://lorempixel.com/100/100/nature'></li> <li><img src='http://lorempixel.com/100/100/abstract'></li> <li><img src='http://lorempixel.com/100/100/cats'></li> <li><img src='http://lorempixel.com/100/100/food'></li> <li><img src='http://lorempixel.com/100/100/animals'></li> <li><img src='http://lorempixel.com/100/100/business'></li> <li><img src='http://lorempixel.com/100/100/people'></li>
</ul> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script>
</body>
</html>

Items on circle - Script Codes CSS Codes

.circle-container { position: relative; /* 1 */ width: 20em; height: 20em; padding: 0; border-radius: 50%; list-style: none; /* 2 */ box-sizing: content-box; /* 3 */ margin: 5em auto 0; border: solid 5px tomato;
}
.circle-container > * { /* 4 */ display: block; position: absolute; top: 50%; left: 50%; width: 6em; height: 6em; margin: -3em;
}
.circle-container > :nth-of-type(1) { transform: rotate(0deg) translate(10em) rotate(0deg);
}
.circle-container > :nth-of-type(2) { transform: rotate(45deg) translate(10em) rotate(-45deg);
}
.circle-container > :nth-of-type(3) { transform: rotate(90deg) translate(10em) rotate(-90deg);
}
.circle-container > :nth-of-type(4) { transform: rotate(135deg) translate(10em) rotate(-135deg);
}
.circle-container > :nth-of-type(5) { transform: rotate(180deg) translate(10em) rotate(-180deg);
}
.circle-container > :nth-of-type(6) { transform: rotate(225deg) translate(10em) rotate(-225deg);
}
.circle-container > :nth-of-type(7) { transform: rotate(270deg) translate(10em) rotate(-270deg);
}
.circle-container > :nth-of-type(8) { transform: rotate(315deg) translate(10em) rotate(-315deg);
}
.circle-container img { display: block; width: 100%; border-radius: 50%; filter: grayscale(100%);
}
.circle-container img:hover { filter: grayscale(0);
}
Items on circle - Script Codes
Items on circle - Script Codes
Home Page Home
Developer Hugo Giraudel
Username HugoGiraudel
Uploaded August 09, 2022
Rating 4.5
Size 3,437 Kb
Views 40,480
Do you need developer help for Items on circle?

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!

Hugo Giraudel (HugoGiraudel) Script Codes
Create amazing SEO content 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!