feat: progress bar, more realiable reconnects
This commit is contained in:
parent
bcc1bce743
commit
7e8f6786fe
5 changed files with 305 additions and 30 deletions
File diff suppressed because one or more lines are too long
|
@ -8,6 +8,10 @@
|
|||
<meta http-equiv="refresh" content="900"> <!-- Refresh page every 15 minutes to prevent memory issues -->
|
||||
</head>
|
||||
<body>
|
||||
<div id="loading-overlay">
|
||||
<div class="spinner"></div>
|
||||
<p>Loading jukebox data...</p>
|
||||
</div>
|
||||
<div class="container">
|
||||
<header>
|
||||
<h1>Discord Jukebox</h1>
|
||||
|
@ -61,4 +65,4 @@
|
|||
|
||||
<script src="/static/app.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
|
|
@ -5,6 +5,42 @@
|
|||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
/* Loading overlay */
|
||||
#loading-overlay {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background-color: rgba(255, 255, 255, 0.9);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
z-index: 1000;
|
||||
transition: opacity 0.3s ease-out;
|
||||
}
|
||||
|
||||
#loading-overlay.hidden {
|
||||
opacity: 0;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.spinner {
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
border: 5px solid #f3f3f3;
|
||||
border-top: 5px solid #5865F2;
|
||||
border-radius: 50%;
|
||||
animation: spin 1s linear infinite;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
@keyframes spin {
|
||||
0% { transform: rotate(0deg); }
|
||||
100% { transform: rotate(360deg); }
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
|
||||
line-height: 1.6;
|
||||
|
@ -115,6 +151,34 @@ h3 {
|
|||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
.progress-container {
|
||||
margin-top: 15px;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
|
||||
.progress-bar-wrapper {
|
||||
height: 8px;
|
||||
background-color: #eee;
|
||||
border-radius: 4px;
|
||||
overflow: hidden;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
.progress-bar {
|
||||
height: 100%;
|
||||
background-color: #5865F2;
|
||||
width: 0%;
|
||||
transition: width 1s linear;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.progress-times {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 0.85em;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.additional-info {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
|
@ -188,7 +252,7 @@ h3 {
|
|||
}
|
||||
|
||||
/* Not Playing Section */
|
||||
#not-playing {
|
||||
#not-playing, #connection-error {
|
||||
text-align: center;
|
||||
padding: 40px 20px;
|
||||
background-color: #f9f9f9;
|
||||
|
@ -197,6 +261,15 @@ h3 {
|
|||
flex-grow: 1;
|
||||
}
|
||||
|
||||
/* Error message */
|
||||
.error-message {
|
||||
border-left: 4px solid #f04747;
|
||||
background-color: #fff;
|
||||
padding: 15px;
|
||||
border-radius: 4px;
|
||||
box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.message {
|
||||
max-width: 400px;
|
||||
margin: 0 auto;
|
||||
|
@ -250,6 +323,14 @@ footer {
|
|||
max-width: 150px;
|
||||
}
|
||||
|
||||
.progress-bar-wrapper {
|
||||
height: 6px;
|
||||
}
|
||||
|
||||
.progress-times {
|
||||
font-size: 0.8em;
|
||||
}
|
||||
|
||||
.history-item {
|
||||
padding: 8px;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue