Add Resume button, Surprise Me random pick, and bulk select

Three quality-of-life additions to the Library browser and course
pages:

- A course page shows a "Resume: <lesson>" button when there's a
  last-visited lesson, using Course.last_accessed_path (already
  populated by apply_progress_to_tree, just not surfaced before) -
  no more scrolling the tree to find where you left off.

- "Surprise Me" picks a random not-yet-fully-watched course and loads
  it, for when there's too much library to decide what to watch.
  Reuses the already-cached get_all_course_dirs() and the same
  per-course completed/total shape _scan_library_activity() already
  computes for Stale Courses - no new scanning.

- A select-mode toggle in the Library browser adds checkboxes to every
  row/card (list and grid) with a bulk-action bar to hide or queue
  several courses/folders at once, via two new endpoints
  (/api/hidden-paths/bulk, /api/next-up/bulk) that reuse the existing
  single-item set_path_hidden()/set_path_queued() in a loop. Selection
  is scoped to the current folder view and clears on navigation.

Also fixes runTranscriptSearch() going silently blank on zero results
instead of showing a "no matches" message, and updates the Help page
to cover all of this.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-08-23 15:06:29 -04:00
co-authored by Claude Sonnet 5
parent 8f6b00280f
commit 9e7dc85558
3 changed files with 277 additions and 15 deletions
+56 -8
View File
@@ -142,22 +142,70 @@
<h1>Help</h1>
<div class="card">
<h3>How to Use OfflineU</h3>
<h3>Getting Started</h3>
<ul>
<li><strong>Prepare your course files</strong> in a directory structure</li>
<li><strong>Browse your library</strong> from the main page, or enter a path manually</li>
<li><strong>Click a course</strong> to load it</li>
<li><strong>Start learning!</strong> Your progress will be saved automatically</li>
<li><strong>Browse your library</strong> from the main page, or enter a path manually in Settings</li>
<li><strong>Click a course</strong> to load it - folders drill down, courses open directly</li>
<li><strong>Start learning!</strong> Progress, notes, and completion are all saved automatically</li>
<li>Not sure what to watch? <strong>🎲 Surprise Me</strong> at the top of the dashboard picks a random course you haven't finished</li>
</ul>
</div>
<div class="card">
<h3>Watching a Lesson</h3>
<ul>
<li><strong>Space</strong> - play/pause</li>
<li><strong>← / →</strong> - seek back/forward 10 seconds</li>
<li><strong>↑ / ↓</strong> - volume up/down</li>
<li><strong>N</strong> - jump into the quick-capture note box (pauses the video)</li>
<li>Drag the video's bottom-right corner to resize it, and pick a default playback speed in Settings - both are remembered</li>
<li>Reopening a lesson resumes from where you left off, and the <strong>▶ Resume</strong> button at the top of a loaded course jumps straight back to the last lesson you had open</li>
<li>The <strong>Lessons in this section</strong> list under the player jumps between other lessons in the same folder without leaving the page</li>
</ul>
</div>
<div class="card">
<h3>Notes</h3>
<ul>
<li>Every note is stamped with the video's timestamp when you save it - click a timestamp to jump straight to that moment</li>
<li>Press <strong>N</strong> anywhere on a lesson page to capture one without reaching for the mouse</li>
<li>Edit or delete any note from the floating panel at the bottom of the lesson page</li>
<li><strong>Notes</strong> (in the footer) collects every note across your whole library in one searchable list</li>
<li><strong>Download Study Guide</strong> on a loaded course exports every note as one markdown file, organized by section</li>
<li>If you use <a href="/settings">Outline</a>, pick a topic on a lesson's notes to push them there automatically when you navigate away</li>
</ul>
</div>
<div class="card">
<h3>Finding Things</h3>
<ul>
<li>Search courses by name from the Library browser on the main page</li>
<li>Check <strong>Also search transcripts</strong> to search inside subtitle files (.srt/.vtt) too, if your courses have them</li>
<li>Switch between list and grid (poster) view with the toggle next to the search box - handy for browsing a folder with lots of courses by thumbnail</li>
<li><strong>Hide</strong> a course or whole folder from Settings → Manage Library without touching anything on disk</li>
<li>The ☑ button in the Library browser turns on <strong>select mode</strong> - pick several courses or folders at once to hide or add to Next Up together</li>
<li><strong>Bulk Rename</strong> (Settings) finds and replaces text across every course/folder name at once - useful for stripping a release-group suffix off a batch of downloads</li>
</ul>
</div>
<div class="card">
<h3>Settings</h3>
<ul>
<li>Pick a built-in theme or set a custom accent color, corner style, and card style</li>
<li>Adjust font, text size, page width, and spacing density</li>
<li>Set the default library folder, and use <strong>Refresh Library</strong> if you've just added or removed files directly on disk and don't want to wait for it to notice</li>
<li><strong>Download Backup</strong> exports your settings, hidden-path choices, recently-viewed history, and every course's progress/notes as a zip - not the course files themselves</li>
</ul>
</div>
<div class="card">
<h3>Supported File Types</h3>
<ul>
<li><strong>Videos:</strong> .mp4, .mkv, .avi, .mov, .webm</li>
<li><strong>Audio:</strong> .mp3, .wav, .m4a, .aac</li>
<li><strong>Documents:</strong> .txt, .md, .html, .pdf</li>
<li><strong>Subtitles:</strong> .srt, .vtt</li>
<li><strong>Videos:</strong> .mp4, .mkv, .avi, .mov, .webm, .m4v, .flv, .wmv</li>
<li><strong>Audio:</strong> .mp3, .wav, .m4a, .aac, .ogg, .flac</li>
<li><strong>Documents:</strong> .txt, .md, .html, .htm, .pdf, .docx, .doc, .rtf</li>
<li><strong>Subtitles:</strong> .srt, .vtt, .ass, .sub, .sbv</li>
</ul>
</div>
</div>