Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <style>
- #music-player {
- display: flex;
- align-items: center;
- justify-content: center;
- }
- #music-player {
- height: 2em;
- width: 2em;
- font-size: 2em;
- padding: 0.125em;
- background: #FF6961;
- border-radius: 50%;
- border: 4px dotted #732931;
- color: #fff;
- -webkit-animation: spin 2s linear infinite;
- -webkit-animation: spin 4s linear infinite;
- -moz-animation: spin 4s linear infinite;
- animation: spin 4s linear infinite;
- }
- @-moz-keyframes spin {
- 100% {
- -moz-transform: rotate(360deg);
- }
- }
- @-webkit-keyframes spin {
- 100% {
- -webkit-transform: rotate(360deg);
- }
- }
- @keyframes spin {
- 100% {
- -webkit-transform: rotate(360deg);
- transform: rotate(360deg);
- }
- }
- #music-player:hover {
- -webkit-animation: pop 0.3s ease;
- }
- </style>
- <div id="music-player">♫</div>
- <script>
- document.getElementById("music-player").onclick = function() {
- var audio = document.getElementById("audio");
- if (audio.paused)
- audio.play();
- else
- audio.pause();
- }
- ;
- </script>
- <!---add ur music link here, tut on codes.crd.co--->
- <audio id="audio" loop src="https://cdn.discordapp.com/attachments/965819507794907138/993727387323871272/Jack_Antonoff_Never_Fall_In_Love.mp3"></audio>
Advertisement
Add Comment
Please, Sign In to add comment