Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@GRusar
Copy link

@GRusar GRusar commented Oct 6, 2025

Overview

  • Adds pagination autoscroll for tables and forms that use lazy loading.
  • Extends the zod schema to accept new autoscroll fields.
  • Implements three modes: forward, backward, and alternate.
  • Supports optional page refresh at boundaries via URL parameter updates.
  • Ensures timers are cleared when components are destroyed.

How to configure

  1. Provide the new options in lazyLoad.pagination:
    • autoscroll_seconds — interval (seconds) between page switches (>0 enables autoscroll).
    • autoscroll_directionforward, backward, or alternate (forward by default).
    • autoscroll_refresh — set to true to force a page reload at the boundary (uses window.location.replace).
  2. The client consumes these parameters and starts the autoscroll timer automatically.
  3. Autoscroll updates the __p query param, so manual navigation stays consistent with the current page.
  4. When a component unmounts or the view mode changes, timers are cleared to avoid leaks.

@GRusar GRusar changed the title Autoscroll Autoscroll in lazyLoad.pagination Oct 6, 2025
@GRusar GRusar changed the title Autoscroll in lazyLoad.pagination Autoscroll (lazyLoad.pagination) Oct 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants