3D Rotating Animation using Html CSS and JavaScript

image css,html,css animation,javascript,html tutorial for beginners,css animation effects,html css,css tutorial for beginners,css animation tutorial,online tutorials,html and css tutorial for beginners,css 3d animation,html coding,css 3d effects,animation,3d animation,css tutorial,css 3d tutorial,3d cube animation css,css 3d,3d,css 3d design,css 3d rotation effect,css animation project,3d box animation pure css,3d cube animation

Please subscribe our channel and support me.
Please like and 1 comment this video.

If you are visiting my channel for the first time then please subscribe
Go to my Youtube channel : https://www.youtube.com

Html Code

<div class="container"> <div class="items"> <div class="item a">A</div> <div class="item b">B</div> <div class="item c">C</div> <div class="item d">D</div> <div class="item e">E</div> <div class="item f">F</div> </div> </div> <div class="controll-button"> <div class="next">Next</div> <div class="prev">Prev</div> </div>

CSS Code

body{ background-color: #333333; font: 15px/20px sans-serif; display: flex; align-items: center; height: 90vh; justify-content: center; } .container{ margin: 0 auto; width: 250px; height: 160px; position: relative; perspective: 1000px; } .items{ height: 100%; width: 100%; position: absolute; transform-style: preserve-3d; transition: transform 1s; } .item{ display: block; position: absolute; background: #000; width: 250px; height: 160px; line-height: 160px; font-size: 5em; text-align: center; color: #fff; opacity: 0.95; border-radius: 8px; } .items .a{ transform: rotateY(0deg) translateZ(250px); background: #ed1c24; } .items .b{ transform: rotateY(60deg) translateZ(250px); background: #1c1fed; } .items .c{ transform: rotateY(120deg) translateZ(250px); background: #73ed1c; } .items .d{ transform: rotateY(180deg) translateZ(250px); background: #e03f00; } .items .e{ transform: rotateY(240deg) translateZ(250px); background: #570003; } .items .f{ transform: rotateY(300deg) translateZ(250px); background: #e6ed1c; } .next, .prev{ color: #444; position: absolute; padding: 6px 18px; background: #ccc; cursor: pointer; border-radius: 5px; border-top: 1px solid #fff; transition: box-shadow 0.1s, top 0.1s; user-select: none; top: 48%; } .next:hover, .prev:hover{ color: #000; } .next:active, .prev:active{ background: #a3a3a3; box-shadow: 0 3px 10px #0008; } .next{ right: 4em; } .prev{left: 4em;}

Javascript Code

var currdeg = 0; document.querySelector('.next').addEventListener('click', rotate); document.querySelector('.prev').addEventListener('click', rotate); function rotate(e) { if (e.target.className == 'next') { currdeg = currdeg - 60; } if (e.target.className == 'prev') { currdeg = currdeg + 60; } document.querySelector('.items').style.transform = 'rotateY(' + currdeg + 'deg)'; }

Source Code : Your link is creating. Please wait..


I will remove the timer if 1000 subscriber on my channel and All video source code without timer, will be provided.

@ Recommendations Videos

blogger theme design : https://youtu.be/DAIJTjRzxLk

Login Form : https://youtu.be/HWbAr1XN3Lc

Forms design : https://youtu.be/M2ERkDXjEuw

Responsive CSS card : https://youtu.be/Ol9_5cYtAaw

Navigation design : https://youtu.be/LNEgZBdWPGM

Disclaimer video is for educational purpose only. Copyright Disclaimer Under Section 107 of the Copyright Act 1976, allowance is made for "fair use" for purposes such as criticism, comment, news reporting, teaching, scholarship, and research. Fair use is a use permitted by copyright statute that might otherwise be infringing. Non-profit, educational or personal use tips the balance in favor of fair use .

Thanks..