ihrz
Version:
iHrz in ts!
92 lines (81 loc) • 2.27 kB
HTML
<html>
<head>
<meta charset="UTF-8">
<style>
body {
margin: 0;
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
background: linear-gradient(45deg, {color1}, {color2});
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
color: white;
}
.player {
background: rgba(255, 255, 255, 0.1);
backdrop-filter: blur(10px);
padding: 2rem;
border-radius: 20px;
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
width: 300px;
text-align: center;
}
.album-cover {
border-radius: 10px;
margin-bottom: 1.5rem;
box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
/* No forced dimensions - image keeps its natural size */
max-width: 100%;
height: auto;
display: block;
margin-left: auto;
margin-right: auto;
}
.song-title {
font-size: 1.5rem;
margin: 0;
font-weight: bold;
}
.artist {
font-size: 1.1rem;
color: #ccc;
margin: 0.5rem 0 1.5rem 0;
}
.progress-container {
background: rgba(255, 255, 255, 0.1);
height: 5px;
border-radius: 3px;
margin: 1rem 0;
cursor: pointer;
}
.progress-bar {
background: #4CAF50;
height: 100%;
border-radius: 3px;
width: {time0}%;
}
.time {
display: flex;
justify-content: space-between;
font-size: 0.9rem;
color: #ccc;
}
</style>
</head>
<body>
<div class="player">
<img src="{album_cover}" alt="Album Cover" class="album-cover">
<h2 class="song-title">{song_title}</h2>
<p class="artist">{song_author}</p>
<div class="progress-container" id="progressContainer">
<div class="progress-bar" id="progressBar"></div>
</div>
<div class="time">
<span id="currentTime">{time1}</span>
<span id="totalTime">{time2}</span>
</div>
</div>
</body>
</html>