FPagination constructor

const FPagination({
  1. FPaginationController? controller,
  2. FPaginationStyle style(
    1. FPaginationStyle
    )?,
  3. Widget? previous,
  4. Widget? next,
  5. int? initialPage,
  6. int? pages,
  7. ValueChanged<int>? onChange,
  8. Key? key,
})

Creates an FPagination.

Implementation

const FPagination({
  this.controller,
  this.style,
  this.previous,
  this.next,
  this.initialPage,
  this.pages,
  this.onChange,
  super.key,
}) : assert(
       controller == null || initialPage == null,
       'Cannot provide both controller and initialPage. To fix, set the page directly in the controller.',
     ),
     assert(
       controller == null || pages == null,
       'Cannot provide both controller and pages. To fix, set the pages directly in the controller.',
     ),
     assert(initialPage == null || initialPage >= 0, 'initialPage ($initialPage) must be >= 0'),
     assert(
       initialPage == null || pages == null || initialPage < pages,
       'initialPage ($initialPage) must be < pages ($pages)',
     ),
     assert(pages == null || pages > 0, 'pages ($pages) must be > 0');