feat: sleep timer, A-B loop, related panel, smart playlists, history delete/search, batch ops, auto-backup

This commit is contained in:
Jonathan Sykes
2026-06-21 18:43:26 +08:00
parent 3ad2e40606
commit 20cd2f29ba
3 changed files with 662 additions and 9 deletions

View File

@@ -1353,3 +1353,148 @@ input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.25); }
transition-duration: 0.001ms !important;
}
}
/* ============================================================================
* Seek wrap + A-B markers
* ========================================================================== */
.seek-wrap { position: relative; flex: 1; display: flex; flex-direction: column; gap: 4px; }
.seek-wrap .seek { width: 100%; flex: none; }
.ab-indicator {
display: flex; align-items: center; padding: 0 2px;
font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: 0.05em;
}
.ab-label { color: var(--text-dim); transition: color 0.16s; }
.ab-label.active { color: var(--accent); }
.ab-ctrl { font-family: var(--mono); font-size: 12px; font-weight: 800; min-width: 34px; }
.ab-ctrl.active {
color: #fff;
background: linear-gradient(145deg, var(--accent-bright), var(--accent-deep));
border-color: transparent;
box-shadow: 0 6px 16px -8px var(--accent-glow);
}
/* ============================================================================
* Sleep timer status bar
* ========================================================================== */
.sleep-status {
display: flex; align-items: center; gap: 12px;
padding: 8px 16px; margin-top: 10px;
background: rgba(255,75,50,0.07);
border: 1px solid rgba(255,75,50,0.22);
border-radius: var(--radius-sm);
}
.sleep-countdown {
font-family: var(--mono); font-size: 12px; font-weight: 600;
color: var(--accent); flex: 1;
}
.sleep-cancel {
background: transparent; border: 1px solid rgba(255,75,50,0.35);
color: var(--accent); border-radius: 7px;
padding: 5px 10px; cursor: pointer; font-size: 12px; font-weight: 600;
transition: all 0.16s;
}
.sleep-cancel:hover { background: rgba(255,75,50,0.14); }
.ctrl.sleep-active {
color: #fff;
background: linear-gradient(145deg, var(--accent-bright), var(--accent-deep));
border-color: transparent;
}
/* ============================================================================
* Related videos panel
* ========================================================================== */
.related-panel {
margin-top: 16px;
background: linear-gradient(180deg, var(--bg-2), var(--bg-1));
border: 1px solid var(--line);
border-radius: var(--radius);
overflow: hidden;
}
.related-header {
display: flex; align-items: center; justify-content: space-between;
padding: 10px 16px;
border-bottom: 1px solid var(--line-soft);
}
.related-label {
font-family: var(--mono); font-size: 10px; font-weight: 700;
text-transform: uppercase; letter-spacing: 0.16em; color: var(--text-dim);
}
.related-toggle-btn {
background: transparent; border: none; color: var(--text-dim);
font-size: 16px; cursor: pointer; padding: 0 4px; line-height: 1;
transition: color 0.16s;
}
.related-toggle-btn:hover { color: var(--text); }
.related-list {
display: flex; flex-direction: column; gap: 4px;
padding: 8px 10px; max-height: 280px; overflow-y: auto;
}
.related-item {
display: flex; gap: 10px; padding: 6px 8px;
border-radius: 9px; cursor: pointer;
border: 1px solid transparent;
transition: background 0.16s, border-color 0.16s;
}
.related-item:hover { background: var(--bg-3); border-color: var(--line); }
.related-item img { width: 80px; aspect-ratio: 16/9; border-radius: 6px; object-fit: cover; background: #000; flex-shrink: 0; }
.related-item .ri-info { min-width: 0; display: flex; flex-direction: column; justify-content: center; }
.related-item .ri-title {
font-size: 12.5px; font-weight: 600; line-height: 1.3;
display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.related-item .ri-channel { font-size: 11px; color: var(--text-dim); margin-top: 3px; }
/* ============================================================================
* Smart / auto playlists in sidebar
* ========================================================================== */
.smart-pl-header { opacity: 0.75; margin-top: 8px; padding-top: 6px; border-top: 1px solid var(--line-soft); }
.smart-pl-list { flex: 0 0 auto !important; margin-bottom: 6px; }
.smart-item .pl-name::before { content: "◈ "; color: var(--text-dim); font-size: 9px; }
.smart-item.active .pl-name::before { color: var(--accent); }
/* ============================================================================
* List filter bar
* ========================================================================== */
.list-filter-bar { padding: 0 14px 8px; }
.list-filter-bar input {
width: 100%; background: var(--bg-2); border: 1px solid var(--line);
border-radius: 9px; padding: 8px 12px;
color: var(--text); font-family: var(--ui); font-size: 13px;
outline: none; transition: border-color 0.16s, box-shadow 0.16s;
}
.list-filter-bar input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255,75,50,0.1); }
.list-filter-bar input::placeholder { color: var(--text-dim); }
/* ============================================================================
* Batch selection bar
* ========================================================================== */
.batch-bar {
display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
padding: 8px 14px;
background: rgba(255,75,50,0.07);
border-bottom: 1px solid rgba(255,75,50,0.18);
}
.batch-count { font-family: var(--mono); font-size: 12px; font-weight: 700; color: var(--accent); flex: 1; }
.batch-btn {
background: var(--bg-3); border: 1px solid var(--line); color: var(--text-2);
border-radius: 7px; padding: 6px 11px; cursor: pointer;
font-family: var(--ui); font-size: 12px; font-weight: 600; transition: all 0.16s;
}
.batch-btn:hover { color: var(--text); border-color: var(--accent); }
.batch-danger { color: #ff8a7a !important; border-color: rgba(255,75,50,0.28) !important; }
.batch-danger:hover { background: rgba(255,75,50,0.12) !important; }
/* Batch checkboxes on cards */
.card .batch-check {
display: none; position: absolute; left: 8px; top: 8px; z-index: 3;
width: 20px; height: 20px; border-radius: 6px;
border: 2px solid var(--line); background: var(--bg-1);
align-items: center; justify-content: center;
font-size: 12px; font-weight: 800; transition: all 0.14s;
pointer-events: none;
}
.cards.select-mode .card .batch-check { display: flex; }
.cards.select-mode .card { cursor: pointer; }
.card.selected .batch-check { background: var(--accent); border-color: var(--accent); color: #fff; }
.card.selected .batch-check::after { content: "✓"; }
.card.selected { border-color: var(--accent) !important; background: var(--bg-2); }