Skip to content

[BUG] Refresh scroll indicators after switching usage views #44

Open

Description

@Wikijito7

Describe the bug
The /usage dialog keeps stale more above and/or more below indicators after switching between content views. This affects regular usage, trends, and session views. The indicators can remain visible even when the newly displayed content does not scroll.

To Reproduce

  1. Open /usage.
  2. Display a period with enough content to produce scroll indicators, or scroll within the dialog.
  3. Switch to trends with g, session view with s, or another usage mode/period with m or the arrow keys.
  4. Observe the scroll indicators for the newly displayed content.

Expected behavior
Scroll position and scrollability should be recalculated from the content currently rendered in the scrollbox after every view, mode, period, and data transition. Indicators should only appear when the current view actually overflows, and switching views should reset the scroll position appropriately.

Media

Additional context
The current usage dialog derives the indicators from data.models.length > 5, which does not describe trends or session content. The shared scroll state already exposes checkOverflow(), but it is not refreshed for every content transition.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions