Skip to content

fix(library) - Do The Alphabet Dance - #1075

Merged
RadicalMuffinMan merged 2 commits into
Moonfin-Client:mainfrom
mattsigal:fix/alphabet-jump-single-press
Aug 7, 2026
Merged

fix(library) - Do The Alphabet Dance#1075
RadicalMuffinMan merged 2 commits into
Moonfin-Client:mainfrom
mattsigal:fix/alphabet-jump-single-press

Conversation

@mattsigal

Copy link
Copy Markdown
Collaborator

Pull Request

Summary

Resolves the two-press requirement when performing an alphabetical quick jump in library screens, and optimizes cold-start letter scanning performance by chunking prefix page fetches.

Related Issues

Link related issues or tickets separated by commas.

  • Closes #
  • Fixes #
  • Related to #

Type of Change

  • Bug fix
  • New feature
  • Refactor
  • Performance improvement
  • UI/UX update
  • Documentation update
  • Build/CI change
  • Other (describe):

Changes Made

List the key changes included in this PR.

  • library_browse_screen.dart: Implemented a multi-frame scroll convergence loop in _jumpToLetter to iteratively jump and settle frame layouts until targetOffset is reached, ensuring maxScrollExtent lazy sliver expansion completes in 1-3 frames before requesting item focus.
  • library_browse_view_model.dart: Added optional pageSizeOverride parameter to loadMore and _fetchPage, and configured ensureItemsLoadedForPrefix to fetch in 300-item page chunks instead of 48-item pages during letter scans (reducing cold-start prefix scan times from ~30s to <1.5s).

Platform

  • Android
  • iOS
  • tvOS
  • Web
  • macOS
  • Windows
  • Linux
  • All / Shared code

Testing

Describe how this change was tested.

  • Tested on emulator / simulator
  • Tested on physical device
  • Manual testing completed
  • Not tested (explain why):

Test Steps

  1. Open any library screen (Movies, TV Shows, Audio, etc.) with a large number of items.
  2. Select any letter on the Alphabet quick jump bar.
  3. Verify that the grid scrolls directly to the target letter row and focuses the first item in 1 single press.
  4. Verify on a fresh install / cold boot that jumping to letters far down the alphabet (e.g. T, W, Z) completes in ~1 second instead of waiting ~30 seconds for 48-item serial page loads.

Screenshots (if applicable)

Include screenshots or recordings for UI changes.

PXL_20260807_184032099.mp4

Checklist

  • Code builds successfully
  • Code follows project style and conventions
  • No unnecessary commented-out code
  • No new warnings introduced

…art prefix scan

- Implement multi-frame layout convergence loop in _jumpToLetter (library_browse_screen.dart) to handle progressive maxScrollExtent expansion of lazy slivers.
- Add pageSizeOverride parameter in loadMore/fetchPage and use 300-item page chunks in ensureItemsLoadedForPrefix (library_browse_view_model.dart) to optimize cold-start prefix scan speed.
@RadicalMuffinMan
RadicalMuffinMan merged commit 1fa755f into Moonfin-Client:main Aug 7, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants