Skip to content

Commit d635e90

Browse files
committed
added a music card using html and css
1 parent c3b882d commit d635e90

File tree

3 files changed

+74
-1
lines changed

3 files changed

+74
-1
lines changed

UI Snippets/music/music.html

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<link rel="stylesheet" type="text/css" href="styles.css">
5+
</head>
6+
<body>
7+
<div class="music-image-container">
8+
<img src="https://img.freepik.com/premium-photo/concept-eternal-theme-about-eternity-music-musical-instruments-good-mood-ascended-aspiration-action-treble-clef-sheet-music_771426-4115.jpg" alt="Music Note" class="music-image">
9+
</div>
10+
</body>
11+
</html>

UI Snippets/music/style.css

+55
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
body {
2+
margin: 0;
3+
padding: 0;
4+
overflow: hidden;
5+
display: flex;
6+
justify-content: center;
7+
align-items: center;
8+
height: 100%;
9+
}
10+
11+
.music-image-container {
12+
animation: moveMusicImage 2s ease-in-out infinite;
13+
}
14+
15+
.music-image {
16+
width: 100%;
17+
height: 100%;
18+
}
19+
20+
@keyframes moveMusicImage {
21+
0%, 100% {
22+
transform: translateY(0);
23+
}
24+
50% {
25+
transform: translateY(-20px);
26+
}
27+
}
28+
@keyframes moveMusicImage {
29+
0%, 100% {
30+
transform: translateY(0);
31+
opacity: 1;
32+
}
33+
25%, 75% {
34+
transform: translateY(20px);
35+
opacity: 5;
36+
}
37+
50% {
38+
transform: translateY(40px);
39+
opacity: 5;
40+
}
41+
}
42+
@keyframes moveMusicImage {
43+
0%, 100% {
44+
transform: translateY(0) scale(1);
45+
opacity: 1;
46+
}
47+
25%, 75% {
48+
transform: translateY(-20px) scale(1.1);
49+
opacity: 0.5;
50+
}
51+
50% {
52+
transform: translateY(-40px) scale(1);
53+
opacity: 0;
54+
}
55+
}

snippets.json

+8-1
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,13 @@
109109
"codepen-link": "https://codepen.io/Swathi-Singh/pen/dywjqoz",
110110
"image-link": "https://wpassets.adda247.com/wp-content/uploads/multisite/sites/5/2020/04/11132345/Helpline.jpg",
111111
"folder-link": "https://github.com/Swathi1203/CSS-Is-Fun/tree/add-new-tablecontent/UI%20Snippets/Helpline",
112-
"author": "swathi singh"
112+
"author": "Deveesh-Shetty"
113+
},
114+
{
115+
"name": "Music",
116+
"codepen-link": "https://codepen.io/Swathi-Singh/pen/QWYjvvB",
117+
"image-link": "https://img.freepik.com/premium-photo/concept-eternal-theme-about-eternity-music-musical-instruments-good-mood-ascended-aspiration-action-treble-clef-sheet-music_771426-4115.jpg",
118+
"folder-link": "https://github.com/Swathi1203/CSS-Is-Fun/tree/add-new-tablecontent/UI%20Snippets/Helpline",
119+
"author": "Deveesh-Shetty"
113120
}
114121
]

0 commit comments

Comments
 (0)