[Enhancement]: Persistent ‘Random’ Sort Order #1225

Open
opened 2026-04-24 23:54:20 +02:00 by adam · 0 comments
Owner

Originally created by @stauby22 on GitHub (Jun 7, 2025).

Describe the Feature/Enhancement

When I pick Sort ➜ Randomly in my library, Audiobookshelf should shuffle once and keep that order until I say otherwise.

Ideal flow

  1. Library view ➜ Sort ➜ Random → list shuffles.
  2. I open a book, read the description or sample a chapter.
  3. I hit “Back” → I land on the exact same list in the same order and scroll position.
  4. The list only re‑shuffles if I manually refresh, switch sort options, or leave the library tab to a different tab.

Why would this be helpful?

• My library is gigantic (~6000 titles). Alphabetical browsing means I stall in the Cs every time.
• Random sort surfaces forgotten gems and fights decision fatigue.
• Right now, every time I back out of a book the list reshuffles, so I can’t compare a few contenders side‑by‑side.
• Persisting the order lets users bounce around, sample, and pick a book—making discovery smoother without adding UI clutter.

Future Implementation (Screenshot)

Option A – Quick toggle
Add a second item in the sort menu:
• “Random (locked)” – one‑time shuffle, persists
• “Random (reshuffle)” – current behavior

Option B – Sensible default
Keep the existing “Random” label but cache the shuffle until:
• user pulls to refresh, or
• user changes sort criteria.

Either way, no extra screens are needed. A tiny tooltip (“Tap pull‑to‑refresh to re‑randomize”) could clarify the behavior.

Audiobookshelf App Version

iOS App - 0.9.81

Current Implementation (Screenshot)

When you select Sort → Random in Audiobookshelf, the app performs a fresh shuffle every time the library view is re‑rendered. That means:

  • The random order is not stored—there’s no session‑level cache or identifier tying that shuffle to your current browsing session.
  • Navigating into a book’s detail page triggers a full library reload when you press “Back,” so the list is re‑shuffled immediately.
  • Scroll position is lost and any mental shortlist you were forming disappears, forcing you to restart the discovery process from scratch.

In short, “Random” is currently a stateless shuffle applied on each view refresh rather than a persistent ordering you can explore until you choose to re‑randomize.

Originally created by @stauby22 on GitHub (Jun 7, 2025). ### Describe the Feature/Enhancement When I pick **Sort ➜ Randomly** in my library, Audiobookshelf should shuffle once and keep that order until I say otherwise. Ideal flow 1. Library view ➜ Sort ➜ Random → list shuffles. 2. I open a book, read the description or sample a chapter. 3. I hit “Back” → I land on the exact same list in the same order and scroll position. 4. The list only re‑shuffles if I manually refresh, switch sort options, or leave the library tab to a different tab. ### Why would this be helpful? • My library is gigantic (~6000 titles). Alphabetical browsing means I stall in the Cs every time. • Random sort surfaces forgotten gems and fights decision fatigue. • Right now, every time I back out of a book the list reshuffles, so I can’t compare a few contenders side‑by‑side. • Persisting the order lets users bounce around, sample, and pick a book—making discovery smoother without adding UI clutter. ### Future Implementation (Screenshot) Option A – Quick toggle Add a second item in the sort menu: • “Random (locked)” – one‑time shuffle, persists • “Random (reshuffle)” – current behavior Option B – Sensible default Keep the existing “Random” label but cache the shuffle until: • user pulls to refresh, or • user changes sort criteria. Either way, no extra screens are needed. A tiny tooltip (“Tap pull‑to‑refresh to re‑randomize”) could clarify the behavior. ### Audiobookshelf App Version iOS App - 0.9.81 ### Current Implementation (Screenshot) When you select Sort → Random in Audiobookshelf, the app performs a fresh shuffle every time the library view is re‑rendered. That means: - The random order is not stored—there’s no session‑level cache or identifier tying that shuffle to your current browsing session. - Navigating into a book’s detail page triggers a full library reload when you press “Back,” so the list is re‑shuffled immediately. - Scroll position is lost and any mental shortlist you were forming disappears, forcing you to restart the discovery process from scratch. In short, “Random” is currently a stateless shuffle applied on each view refresh rather than a persistent ordering you can explore until you choose to re‑randomize.
adam added the enhancement label 2026-04-24 23:54:20 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/audiobookshelf-app#1225