Skip to content

Fix Expanded Home Rows focus and visibility with mouse scroll#570

Merged
RadicalMuffinMan merged 1 commit into
Moonfin-Client:mainfrom
mattsigal:feature/expanded-rows-scroll-fix
Jun 18, 2026
Merged

Fix Expanded Home Rows focus and visibility with mouse scroll#570
RadicalMuffinMan merged 1 commit into
Moonfin-Client:mainfrom
mattsigal:feature/expanded-rows-scroll-fix

Conversation

@mattsigal

Copy link
Copy Markdown
Collaborator

Pull Request

Summary

This PR addresses focus management and tile expansion issues on Desktop and Web platforms when scrolling the Home Screen using a mouse wheel. Previously, mouse wheel scrolling could leave focus indicators on tiles that moved off-screen, or keep home row tiles expanded and cut off. This is resolved by bypassing auto-focus on desktop start-up, hiding focus rings during mouse wheel scroll by shifting focus to the global shortcut handler, tracking the active row top offsets dynamically, and restoring focus to the correct row when keyboard activity is detected.

Related Issues

Link related issues or tickets separated by commas.

Type of Change

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

Changes Made

  • Bypassed row auto-focus on startup on Desktop/Web so focus begins off-screen and no tiles expand unnecessarily.
  • Shifted focus to the global shortcut focus node (hiding visible focus rings) when mouse wheel scrolling starts.
  • Tracked active row top offset for Classic/Modern rows in the scroll listener to dynamically update the active focused row index.
  • Wrapped row items in a MouseRegion to automatically track mouse hover and update the row's focused memory index dynamically.
  • Registered a global hardware keyboard event listener on the Home Screen to restore focus to the active row (or first row) when a key is pressed, ensuring keyboard navigation seamlessly resumes at the exact tile last hovered/focused by the mouse in that row.

Platform

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

Testing

Describe how this change was tested.

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

Test Steps

  1. Start the app on a Desktop platform.
  2. Confirm that on startup, focus does not auto-activate on the first row tile (no tiles expand automatically).
  3. Scroll down using the mouse wheel; confirm that focus rings disappear instantly.
  4. Stop scrolling; confirm the active row matches the scrolled position.
  5. Press any directional/navigation key on the keyboard; confirm focus is restored to the active row at the scroll offset.

Screenshots (if applicable)

Include screenshots or recordings for UI changes.

Checklist

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

- Bypass row auto-focus on startup on Desktop/Web so focus begins off-screen and no tiles expand.
- Shift focus to globalShortcutFocusNode when mouse wheel scroll starts, hiding any visible focus rings instantly.
- Track active row top offset for both Classic and Modern rows inside scroll listener.
- Listen to hardware keyboard keys globally on home screen to restore focus to active row when key is pressed.
@RadicalMuffinMan
RadicalMuffinMan merged commit d63bcfc into Moonfin-Client:main Jun 18, 2026
8 checks passed
@mattsigal
mattsigal deleted the feature/expanded-rows-scroll-fix branch June 23, 2026 20:33
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