Merge pull request 'develop' (#1) from develop into main
Reviewed-on: #1
This commit was merged in pull request #1.
This commit is contained in:
31
README.md
31
README.md
@@ -92,6 +92,25 @@ docker run -d \
|
||||
|
||||
3. **Access the dashboard** at `http://your-server:3001`
|
||||
|
||||
### Using Environment Variables (Alternative to .env file)
|
||||
|
||||
All configuration can be passed directly as environment variables instead of mounting a `.env` file. This is the preferred approach for orchestrated deployments (Docker Compose, Kubernetes, Portainer, etc).
|
||||
|
||||
```bash
|
||||
docker run -d \
|
||||
--name sofarr \
|
||||
--restart unless-stopped \
|
||||
-p 3001:3001 \
|
||||
-e EMBY_URL=http://emby.local:8096 \
|
||||
-e EMBY_API_KEY=your-emby-api-key \
|
||||
-e SONARR_INSTANCES='[{"name":"main","url":"http://sonarr:8989","apiKey":"your-key"}]' \
|
||||
-e RADARR_INSTANCES='[{"name":"main","url":"http://radarr:7878","apiKey":"your-key"}]' \
|
||||
-e SABNZBD_INSTANCES='[{"name":"main","url":"http://sabnzbd:8080","apiKey":"your-key"}]' \
|
||||
-e QBITTORRENT_INSTANCES='[{"name":"main","url":"http://qbit:8080","username":"admin","password":"pass"}]' \
|
||||
-e LOG_LEVEL=info \
|
||||
docker.i3omb.com/sofarr:latest
|
||||
```
|
||||
|
||||
### Docker Compose
|
||||
|
||||
```yaml
|
||||
@@ -103,10 +122,18 @@ services:
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "3001:3001"
|
||||
volumes:
|
||||
- /opt/sofarr/.env:/app/.env
|
||||
environment:
|
||||
- EMBY_URL=http://emby:8096
|
||||
- EMBY_API_KEY=your-emby-api-key
|
||||
- SONARR_INSTANCES=[{"name":"main","url":"http://sonarr:8989","apiKey":"your-key"}]
|
||||
- RADARR_INSTANCES=[{"name":"main","url":"http://radarr:7878","apiKey":"your-key"}]
|
||||
- SABNZBD_INSTANCES=[{"name":"main","url":"http://sabnzbd:8080","apiKey":"your-key"}]
|
||||
- QBITTORRENT_INSTANCES=[{"name":"main","url":"http://qbit:8080","username":"admin","password":"pass"}]
|
||||
- LOG_LEVEL=info
|
||||
```
|
||||
|
||||
> **Tip:** You can also use a combination — mount a `.env` file for base config, and override specific values with `-e` flags. Environment variables always take precedence.
|
||||
|
||||
### Available Tags
|
||||
|
||||
| Tag | Description |
|
||||
|
||||
@@ -3,15 +3,38 @@ let downloads = [];
|
||||
let refreshInterval = null;
|
||||
let currentRefreshRate = 5000; // default 5 seconds
|
||||
|
||||
// Apply saved theme immediately (before DOMContentLoaded to avoid flash)
|
||||
(function() {
|
||||
const saved = localStorage.getItem('sofarr-theme') || 'light';
|
||||
document.documentElement.setAttribute('data-theme', saved);
|
||||
})();
|
||||
|
||||
// Check authentication on load
|
||||
document.addEventListener('DOMContentLoaded', () => {
|
||||
checkAuthentication();
|
||||
initThemeSwitcher();
|
||||
|
||||
document.getElementById('login-form').addEventListener('submit', handleLogin);
|
||||
document.getElementById('logout-btn').addEventListener('click', handleLogout);
|
||||
document.getElementById('refresh-rate').addEventListener('change', handleRefreshRateChange);
|
||||
});
|
||||
|
||||
function initThemeSwitcher() {
|
||||
const saved = localStorage.getItem('sofarr-theme') || 'light';
|
||||
document.querySelectorAll('.theme-btn').forEach(btn => {
|
||||
btn.classList.toggle('active', btn.dataset.theme === saved);
|
||||
btn.addEventListener('click', () => setTheme(btn.dataset.theme));
|
||||
});
|
||||
}
|
||||
|
||||
function setTheme(theme) {
|
||||
document.documentElement.setAttribute('data-theme', theme);
|
||||
localStorage.setItem('sofarr-theme', theme);
|
||||
document.querySelectorAll('.theme-btn').forEach(btn => {
|
||||
btn.classList.toggle('active', btn.dataset.theme === theme);
|
||||
});
|
||||
}
|
||||
|
||||
function startAutoRefresh() {
|
||||
if (refreshInterval) clearInterval(refreshInterval);
|
||||
if (currentRefreshRate > 0) {
|
||||
|
||||
@@ -32,6 +32,11 @@
|
||||
<header class="app-header">
|
||||
<h1>sofarr</h1>
|
||||
<div class="header-controls">
|
||||
<div class="theme-switcher">
|
||||
<button class="theme-btn active" data-theme="light">Light</button>
|
||||
<button class="theme-btn" data-theme="dark">Dark</button>
|
||||
<button class="theme-btn" data-theme="mono">Mono</button>
|
||||
</div>
|
||||
<div class="refresh-control">
|
||||
<label for="refresh-rate">Refresh:</label>
|
||||
<select id="refresh-rate">
|
||||
|
||||
625
public/style.css
625
public/style.css
@@ -1,3 +1,113 @@
|
||||
/* ===== Theme Variables ===== */
|
||||
:root, [data-theme="light"] {
|
||||
--bg-gradient-start: #667eea;
|
||||
--bg-gradient-end: #764ba2;
|
||||
--surface: #ffffff;
|
||||
--surface-alt: #f5f5f5;
|
||||
--text-primary: #333333;
|
||||
--text-secondary: #666666;
|
||||
--text-muted: #999999;
|
||||
--border: #e0e0e0;
|
||||
--accent: #667eea;
|
||||
--accent-hover: #5568d3;
|
||||
--accent-light: #e8eaf6;
|
||||
--series-color: #667eea;
|
||||
--series-bg: #e8eaf6;
|
||||
--movie-color: #e040a0;
|
||||
--movie-bg: #fce4ec;
|
||||
--torrent-color: #26a69a;
|
||||
--torrent-bg: #e0f2f1;
|
||||
--success: #4caf50;
|
||||
--success-bg: #e8f5e9;
|
||||
--info: #2196f3;
|
||||
--info-bg: #e3f2fd;
|
||||
--danger: #f44336;
|
||||
--danger-bg: #ffebee;
|
||||
--danger-border: #ffcdd2;
|
||||
--progress-bg: #ffebee;
|
||||
--progress-border: #ffcdd2;
|
||||
--progress-fill-start: #4caf50;
|
||||
--progress-fill-end: #66bb6a;
|
||||
--shadow: rgba(0, 0, 0, 0.1);
|
||||
--shadow-strong: rgba(0, 0, 0, 0.15);
|
||||
--footer-text: rgba(255, 255, 255, 0.9);
|
||||
--input-bg: #ffffff;
|
||||
--select-bg: #ffffff;
|
||||
}
|
||||
|
||||
[data-theme="dark"] {
|
||||
--bg-gradient-start: #1a1a2e;
|
||||
--bg-gradient-end: #16213e;
|
||||
--surface: #1e1e2f;
|
||||
--surface-alt: #2a2a3d;
|
||||
--text-primary: #e0e0e0;
|
||||
--text-secondary: #a0a0b0;
|
||||
--text-muted: #707080;
|
||||
--border: #3a3a4d;
|
||||
--accent: #7c8cf0;
|
||||
--accent-hover: #6b7ce0;
|
||||
--accent-light: #2a2a4d;
|
||||
--series-color: #7c8cf0;
|
||||
--series-bg: #2a2a4d;
|
||||
--movie-color: #f080c0;
|
||||
--movie-bg: #3d2035;
|
||||
--torrent-color: #4dd0c8;
|
||||
--torrent-bg: #1a3d3a;
|
||||
--success: #66bb6a;
|
||||
--success-bg: #1a3d1e;
|
||||
--info: #64b5f6;
|
||||
--info-bg: #1a2d3d;
|
||||
--danger: #ef5350;
|
||||
--danger-bg: #3d1a1a;
|
||||
--danger-border: #5a2a2a;
|
||||
--progress-bg: #2a2020;
|
||||
--progress-border: #4a3030;
|
||||
--progress-fill-start: #66bb6a;
|
||||
--progress-fill-end: #81c784;
|
||||
--shadow: rgba(0, 0, 0, 0.3);
|
||||
--shadow-strong: rgba(0, 0, 0, 0.4);
|
||||
--footer-text: rgba(200, 200, 220, 0.8);
|
||||
--input-bg: #2a2a3d;
|
||||
--select-bg: #2a2a3d;
|
||||
}
|
||||
|
||||
[data-theme="mono"] {
|
||||
--bg-gradient-start: #222222;
|
||||
--bg-gradient-end: #333333;
|
||||
--surface: #1a1a1a;
|
||||
--surface-alt: #252525;
|
||||
--text-primary: #d0d0d0;
|
||||
--text-secondary: #909090;
|
||||
--text-muted: #606060;
|
||||
--border: #404040;
|
||||
--accent: #b0b0b0;
|
||||
--accent-hover: #c8c8c8;
|
||||
--accent-light: #303030;
|
||||
--series-color: #c0c0c0;
|
||||
--series-bg: #303030;
|
||||
--movie-color: #c0c0c0;
|
||||
--movie-bg: #303030;
|
||||
--torrent-color: #c0c0c0;
|
||||
--torrent-bg: #303030;
|
||||
--success: #a0a0a0;
|
||||
--success-bg: #2a2a2a;
|
||||
--info: #a0a0a0;
|
||||
--info-bg: #2a2a2a;
|
||||
--danger: #909090;
|
||||
--danger-bg: #2a2a2a;
|
||||
--danger-border: #484848;
|
||||
--progress-bg: #2a2a2a;
|
||||
--progress-border: #404040;
|
||||
--progress-fill-start: #808080;
|
||||
--progress-fill-end: #a0a0a0;
|
||||
--shadow: rgba(0, 0, 0, 0.4);
|
||||
--shadow-strong: rgba(0, 0, 0, 0.5);
|
||||
--footer-text: rgba(180, 180, 180, 0.7);
|
||||
--input-bg: #252525;
|
||||
--select-bg: #252525;
|
||||
}
|
||||
|
||||
/* ===== Base ===== */
|
||||
* {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
@@ -10,130 +120,217 @@ body {
|
||||
sans-serif;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
||||
background: linear-gradient(135deg, var(--bg-gradient-start) 0%, var(--bg-gradient-end) 100%);
|
||||
min-height: 100vh;
|
||||
transition: background 0.3s;
|
||||
}
|
||||
|
||||
.app {
|
||||
min-height: 100vh;
|
||||
padding: 20px;
|
||||
padding: 16px;
|
||||
max-width: 1200px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
/* ===== Header ===== */
|
||||
.app-header {
|
||||
background: white;
|
||||
padding: 30px;
|
||||
border-radius: 10px;
|
||||
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
|
||||
margin-bottom: 20px;
|
||||
background: var(--surface);
|
||||
padding: 14px 20px;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0 2px 4px var(--shadow);
|
||||
margin-bottom: 12px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
gap: 20px;
|
||||
gap: 12px;
|
||||
transition: background 0.3s;
|
||||
}
|
||||
|
||||
.app-header h1 {
|
||||
color: #333;
|
||||
font-size: 2rem;
|
||||
color: var(--text-primary);
|
||||
font-size: 1.4rem;
|
||||
}
|
||||
|
||||
.header-controls {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 14px;
|
||||
}
|
||||
|
||||
.user-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
background: #f0f0f0;
|
||||
padding: 10px 20px;
|
||||
border-radius: 20px;
|
||||
}
|
||||
|
||||
.logout-btn {
|
||||
padding: 5px 15px;
|
||||
background: #f44336;
|
||||
color: white;
|
||||
border: none;
|
||||
border-radius: 5px;
|
||||
cursor: pointer;
|
||||
font-size: 0.9rem;
|
||||
transition: background 0.3s;
|
||||
}
|
||||
|
||||
.logout-btn:hover {
|
||||
background: #d32f2f;
|
||||
gap: 8px;
|
||||
background: var(--surface-alt);
|
||||
padding: 6px 14px;
|
||||
border-radius: 16px;
|
||||
font-size: 0.85rem;
|
||||
}
|
||||
|
||||
.user-label {
|
||||
color: #666;
|
||||
color: var(--text-muted);
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.user-name {
|
||||
color: #667eea;
|
||||
color: var(--accent);
|
||||
font-weight: bold;
|
||||
font-size: 1.1rem;
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.logout-btn {
|
||||
padding: 4px 12px;
|
||||
background: var(--danger);
|
||||
color: white;
|
||||
border: none;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
font-size: 0.8rem;
|
||||
transition: opacity 0.2s;
|
||||
}
|
||||
|
||||
.logout-btn:hover {
|
||||
opacity: 0.85;
|
||||
}
|
||||
|
||||
/* ===== Theme Switcher ===== */
|
||||
.theme-switcher {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
background: var(--surface-alt);
|
||||
padding: 3px;
|
||||
border-radius: 16px;
|
||||
}
|
||||
|
||||
.theme-btn {
|
||||
padding: 4px 10px;
|
||||
border: none;
|
||||
border-radius: 14px;
|
||||
cursor: pointer;
|
||||
font-size: 0.75rem;
|
||||
background: transparent;
|
||||
color: var(--text-muted);
|
||||
transition: all 0.2s;
|
||||
}
|
||||
|
||||
.theme-btn.active {
|
||||
background: var(--accent);
|
||||
color: white;
|
||||
}
|
||||
|
||||
.theme-btn:hover:not(.active) {
|
||||
color: var(--text-primary);
|
||||
}
|
||||
|
||||
/* ===== Refresh Control ===== */
|
||||
.refresh-control {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
.refresh-control label {
|
||||
color: var(--text-muted);
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.refresh-control select {
|
||||
padding: 4px 8px;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 4px;
|
||||
background: var(--select-bg);
|
||||
color: var(--text-primary);
|
||||
cursor: pointer;
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
/* ===== Error / Loading ===== */
|
||||
.error-message {
|
||||
background: #fee;
|
||||
color: #c33;
|
||||
padding: 15px;
|
||||
border-radius: 10px;
|
||||
margin-bottom: 20px;
|
||||
border-left: 4px solid #c33;
|
||||
background: var(--danger-bg);
|
||||
color: var(--danger);
|
||||
padding: 10px 14px;
|
||||
border-radius: 6px;
|
||||
margin-bottom: 12px;
|
||||
border-left: 3px solid var(--danger);
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.loading {
|
||||
text-align: center;
|
||||
padding: 40px;
|
||||
color: white;
|
||||
font-size: 1.2rem;
|
||||
padding: 30px;
|
||||
color: var(--footer-text);
|
||||
font-size: 1rem;
|
||||
}
|
||||
|
||||
/* ===== Downloads Container ===== */
|
||||
.downloads-container {
|
||||
background: white;
|
||||
padding: 30px;
|
||||
border-radius: 10px;
|
||||
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
|
||||
background: var(--surface);
|
||||
padding: 16px 20px;
|
||||
border-radius: 8px;
|
||||
box-shadow: 0 2px 4px var(--shadow);
|
||||
transition: background 0.3s;
|
||||
}
|
||||
|
||||
.downloads-container h2 {
|
||||
color: #333;
|
||||
margin-bottom: 20px;
|
||||
font-size: 1.5rem;
|
||||
color: var(--text-primary);
|
||||
margin-bottom: 12px;
|
||||
font-size: 1.1rem;
|
||||
}
|
||||
|
||||
.no-downloads {
|
||||
text-align: center;
|
||||
padding: 40px;
|
||||
color: #666;
|
||||
padding: 30px;
|
||||
color: var(--text-secondary);
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.no-downloads p {
|
||||
margin: 10px 0;
|
||||
margin: 6px 0;
|
||||
}
|
||||
|
||||
.downloads-list {
|
||||
display: grid;
|
||||
gap: 20px;
|
||||
}
|
||||
|
||||
.download-card {
|
||||
border: 2px solid #e0e0e0;
|
||||
border-radius: 10px;
|
||||
padding: 20px;
|
||||
transition: transform 0.2s, box-shadow 0.2s;
|
||||
display: flex;
|
||||
gap: 20px;
|
||||
align-items: flex-start;
|
||||
flex-direction: column;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
/* ===== Download Card (Compact) ===== */
|
||||
.download-card {
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 6px;
|
||||
padding: 10px 14px;
|
||||
display: flex;
|
||||
gap: 12px;
|
||||
align-items: flex-start;
|
||||
transition: box-shadow 0.2s, background 0.3s;
|
||||
background: var(--surface);
|
||||
}
|
||||
|
||||
.download-card:hover {
|
||||
box-shadow: 0 2px 8px var(--shadow);
|
||||
}
|
||||
|
||||
.download-card.series {
|
||||
border-left: 3px solid var(--series-color);
|
||||
}
|
||||
|
||||
.download-card.movie {
|
||||
border-left: 3px solid var(--movie-color);
|
||||
}
|
||||
|
||||
.download-card.torrent {
|
||||
border-left: 3px solid var(--torrent-color);
|
||||
}
|
||||
|
||||
/* ===== Cover Art ===== */
|
||||
.download-cover {
|
||||
flex-shrink: 0;
|
||||
width: 80px;
|
||||
border-radius: 6px;
|
||||
width: 50px;
|
||||
border-radius: 4px;
|
||||
overflow: hidden;
|
||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
|
||||
box-shadow: 0 1px 4px var(--shadow-strong);
|
||||
}
|
||||
|
||||
.download-cover img {
|
||||
@@ -142,126 +339,175 @@ body {
|
||||
display: block;
|
||||
}
|
||||
|
||||
/* ===== Download Info ===== */
|
||||
.download-info {
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.download-card:hover {
|
||||
transform: translateY(-2px);
|
||||
box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.download-card.series {
|
||||
border-left: 4px solid #667eea;
|
||||
}
|
||||
|
||||
.download-card.movie {
|
||||
border-left: 4px solid #f093fb;
|
||||
}
|
||||
|
||||
.download-header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
.download-type {
|
||||
padding: 5px 15px;
|
||||
border-radius: 20px;
|
||||
font-size: 0.9rem;
|
||||
font-weight: 500;
|
||||
padding: 2px 8px;
|
||||
border-radius: 10px;
|
||||
font-size: 0.7rem;
|
||||
font-weight: 600;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.3px;
|
||||
}
|
||||
|
||||
.download-type.series {
|
||||
background: #e8eaf6;
|
||||
color: #667eea;
|
||||
background: var(--series-bg);
|
||||
color: var(--series-color);
|
||||
}
|
||||
|
||||
.download-type.movie {
|
||||
background: #fce4ec;
|
||||
color: #f093fb;
|
||||
background: var(--movie-bg);
|
||||
color: var(--movie-color);
|
||||
}
|
||||
|
||||
.download-type.torrent {
|
||||
background: #e0f2f1;
|
||||
color: #26a69a;
|
||||
background: var(--torrent-bg);
|
||||
color: var(--torrent-color);
|
||||
}
|
||||
|
||||
.download-status {
|
||||
padding: 5px 15px;
|
||||
border-radius: 20px;
|
||||
font-size: 0.9rem;
|
||||
font-weight: 500;
|
||||
padding: 2px 8px;
|
||||
border-radius: 10px;
|
||||
font-size: 0.7rem;
|
||||
font-weight: 600;
|
||||
text-transform: capitalize;
|
||||
}
|
||||
|
||||
.download-status.downloading {
|
||||
background: #e8f5e9;
|
||||
color: #4caf50;
|
||||
.download-status.downloading,
|
||||
.download-status.Downloading {
|
||||
background: var(--success-bg);
|
||||
color: var(--success);
|
||||
}
|
||||
|
||||
.download-status.completed {
|
||||
background: #e3f2fd;
|
||||
color: #2196f3;
|
||||
.download-status.completed,
|
||||
.download-status.Completed {
|
||||
background: var(--info-bg);
|
||||
color: var(--info);
|
||||
}
|
||||
|
||||
.download-status.failed {
|
||||
background: #ffebee;
|
||||
color: #f44336;
|
||||
.download-status.failed,
|
||||
.download-status.Failed {
|
||||
background: var(--danger-bg);
|
||||
color: var(--danger);
|
||||
}
|
||||
|
||||
.download-title {
|
||||
color: #333;
|
||||
margin-bottom: 10px;
|
||||
font-size: 1.2rem;
|
||||
color: var(--text-primary);
|
||||
margin-bottom: 2px;
|
||||
font-size: 0.9rem;
|
||||
font-weight: 600;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.download-series,
|
||||
.download-movie {
|
||||
color: #666;
|
||||
margin-bottom: 15px;
|
||||
color: var(--text-secondary);
|
||||
margin-bottom: 6px;
|
||||
font-style: italic;
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
/* ===== Detail Row (Inline) ===== */
|
||||
.download-details {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
|
||||
gap: 15px;
|
||||
padding-top: 15px;
|
||||
border-top: 1px solid #e0e0e0;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 4px 14px;
|
||||
padding-top: 6px;
|
||||
border-top: 1px solid var(--border);
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.detail-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 5px;
|
||||
align-items: baseline;
|
||||
gap: 4px;
|
||||
font-size: 0.78rem;
|
||||
}
|
||||
|
||||
.detail-label {
|
||||
color: #999;
|
||||
font-size: 0.85rem;
|
||||
color: var(--text-muted);
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.5px;
|
||||
letter-spacing: 0.3px;
|
||||
font-size: 0.65rem;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.detail-value {
|
||||
color: #333;
|
||||
color: var(--text-primary);
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
/* ===== Progress Bar (Compact) ===== */
|
||||
.progress-item {
|
||||
flex-basis: 100%;
|
||||
}
|
||||
|
||||
.progress-container {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.progress-bar {
|
||||
flex: 1;
|
||||
height: 10px;
|
||||
background: var(--progress-bg);
|
||||
border-radius: 5px;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
border: 1px solid var(--progress-border);
|
||||
}
|
||||
|
||||
.progress-segment {
|
||||
height: 100%;
|
||||
transition: width 0.3s ease;
|
||||
}
|
||||
|
||||
.progress-segment.downloaded {
|
||||
background: linear-gradient(90deg, var(--progress-fill-start) 0%, var(--progress-fill-end) 100%);
|
||||
float: left;
|
||||
}
|
||||
|
||||
.progress-text {
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
font-size: 0.78rem;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.missing-text {
|
||||
color: var(--danger);
|
||||
font-size: 0.72rem;
|
||||
font-weight: 500;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
/* ===== Footer ===== */
|
||||
.app-footer {
|
||||
margin-top: 20px;
|
||||
margin-top: 12px;
|
||||
text-align: center;
|
||||
color: white;
|
||||
font-size: 0.9rem;
|
||||
color: var(--footer-text);
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.app-footer p {
|
||||
opacity: 0.9;
|
||||
opacity: 0.8;
|
||||
}
|
||||
|
||||
/* ===== Login ===== */
|
||||
.login-container {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
@@ -271,142 +517,93 @@ body {
|
||||
}
|
||||
|
||||
.login-box {
|
||||
background: white;
|
||||
padding: 40px;
|
||||
background: var(--surface);
|
||||
padding: 36px;
|
||||
border-radius: 10px;
|
||||
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
|
||||
box-shadow: 0 4px 6px var(--shadow);
|
||||
width: 100%;
|
||||
max-width: 400px;
|
||||
max-width: 380px;
|
||||
transition: background 0.3s;
|
||||
}
|
||||
|
||||
.login-box h2 {
|
||||
color: #333;
|
||||
margin-bottom: 30px;
|
||||
color: var(--text-primary);
|
||||
margin-bottom: 24px;
|
||||
text-align: center;
|
||||
font-size: 1.8rem;
|
||||
font-size: 1.5rem;
|
||||
}
|
||||
|
||||
.form-group {
|
||||
margin-bottom: 20px;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.form-group label {
|
||||
display: block;
|
||||
color: #333;
|
||||
color: var(--text-primary);
|
||||
font-weight: 500;
|
||||
margin-bottom: 8px;
|
||||
margin-bottom: 6px;
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.form-group input {
|
||||
width: 100%;
|
||||
padding: 12px;
|
||||
border: 2px solid #e0e0e0;
|
||||
border-radius: 5px;
|
||||
font-size: 1rem;
|
||||
padding: 10px;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 4px;
|
||||
font-size: 0.95rem;
|
||||
background: var(--input-bg);
|
||||
color: var(--text-primary);
|
||||
}
|
||||
|
||||
.form-group input:focus {
|
||||
outline: none;
|
||||
border-color: #667eea;
|
||||
border-color: var(--accent);
|
||||
}
|
||||
|
||||
.login-btn {
|
||||
width: 100%;
|
||||
padding: 12px;
|
||||
background: #667eea;
|
||||
padding: 10px;
|
||||
background: var(--accent);
|
||||
color: white;
|
||||
border: none;
|
||||
border-radius: 5px;
|
||||
cursor: pointer;
|
||||
font-size: 1rem;
|
||||
font-size: 0.95rem;
|
||||
font-weight: 500;
|
||||
transition: background 0.3s;
|
||||
transition: background 0.2s;
|
||||
}
|
||||
|
||||
.login-btn:hover {
|
||||
background: #5568d3;
|
||||
}
|
||||
|
||||
/* Progress bar with missing pieces */
|
||||
.progress-item {
|
||||
grid-column: 1 / -1;
|
||||
}
|
||||
|
||||
.progress-container {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 5px;
|
||||
}
|
||||
|
||||
.progress-bar {
|
||||
width: 100%;
|
||||
height: 20px;
|
||||
background: #ffebee;
|
||||
border-radius: 10px;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
border: 1px solid #ffcdd2;
|
||||
}
|
||||
|
||||
.progress-segment {
|
||||
height: 100%;
|
||||
transition: width 0.3s ease;
|
||||
}
|
||||
|
||||
.progress-segment.downloaded {
|
||||
background: linear-gradient(90deg, #4caf50 0%, #66bb6a 100%);
|
||||
float: left;
|
||||
}
|
||||
|
||||
.progress-text {
|
||||
font-weight: bold;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.missing-text {
|
||||
color: #f44336;
|
||||
font-size: 0.9rem;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
/* Refresh control styles */
|
||||
.header-controls {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 20px;
|
||||
}
|
||||
|
||||
.refresh-control {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.refresh-control label {
|
||||
color: #666;
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.refresh-control select {
|
||||
padding: 5px 10px;
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 5px;
|
||||
background: white;
|
||||
cursor: pointer;
|
||||
background: var(--accent-hover);
|
||||
}
|
||||
|
||||
/* ===== Mobile ===== */
|
||||
@media (max-width: 768px) {
|
||||
.app-header {
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
padding: 12px 14px;
|
||||
}
|
||||
|
||||
.controls {
|
||||
flex-direction: column;
|
||||
align-items: stretch;
|
||||
.header-controls {
|
||||
flex-wrap: wrap;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.download-card {
|
||||
padding: 8px 10px;
|
||||
}
|
||||
|
||||
.download-cover {
|
||||
width: 40px;
|
||||
}
|
||||
|
||||
.download-details {
|
||||
grid-template-columns: 1fr;
|
||||
flex-direction: column;
|
||||
gap: 2px;
|
||||
}
|
||||
|
||||
.progress-container {
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user