Skip to content

AisPagination ​

AisPagination is a custom input component that provides a current page number input control. The value should be bound via v-model in your app. Page numbers are indexed from 1. The number of pages is computed from the provided prop values for total-rows and per-page.

Selected Page = [5]

Size ​

Selected Page = [5]

Align ​

start
center
end
fill
Selected Page = [5]

Custom Text ​

Selected Page = [5]

Hide Ellipsis ​

Selected Page = [5]

Goto First/Last Buttons ​

Selected Page = [5]

Slots ​

Selected Page = [5]

Rounded ​

rounded-none
rounded-sm
rounded
rounded-md
rounded-xl
rounded-2xl
rounded-3xl
rounded-full
Selected Page = [5]

Variants ​

primary
secondary
default
info
success
warning
danger
primary outline
secondary outline
default outline
info outline
success outline
warning outline
danger outline
Selected Page = [5]

Component Reference ​

Props ​

Property
Type(s)
Required
Default
Description
Deprecated
align
String
'center'
Alignment of the pagination buttons
Valid values:
start, left, center, end, right, fill
false
ariaControls
String
''
ID of the element or component that this controls. Value is placed in the aria-controls attribute
false
ariaLabel
String
'Pagination'
Value to place in the aria-label attribute of the pagination control
false
disabled
Boolean
false
When set to true, disables the component's functionality and places it in a disabled state
false
ellipsisClass
Array, Object, String
''
Class(es) to apply to the 'ellipsis' placeholders
false
ellipsisText
String
undefined
Content to place in the ellipsis placeholder
false
firstClass
Array, Object, String
null
Class(es) to apply to the 'Go to first page' button
false
firstNumber
Boolean
false
Display first page number instead of Goto First button
false
firstText
String
undefined
Content to place in the goto first page button
false
hideEllipsis
Boolean
false
Do not show ellipsis buttons
false
hideGotoEndButtons
Boolean
false
Hides the goto first and goto last page buttons
false
labelFirstPage
String
'Go to first page'
Value to place in the aria-label attribute of the goto first page button
false
labelLastPage
String
'Go to last page'
Value to place in the aria-label attribute of the goto last page button
false
labelNextPage
String
'Go to next page'
Value to place in the aria-label attribute of the goto next page button
false
labelPage
Func, String
'Go to page'
Value to place in the aria-label attribute of the goto page button. Page number will be appended automatically
false
labelPrevPage
String
'Go to previous page'
Value to place in the aria-label attribute of the goto previous page button
false
lastClass
Array, Object, String
''
Class(es) to apply to the 'Go to last page' button
false
lastNumber
Boolean
false
Display last page number instead of 'Goto Last' button
false
lastText
String
undefined
Content to place in the goto last page button
false
limit
Number, String
5
Maximum number of buttons to show (including ellipsis if shown, but excluding the bookend buttons)
false
modelValue
Number
1
The current page number
false
nextClass
Array, Object, String
''
Class(es) to apply to the 'Go to next page' button
false
nextText
String
undefined
Content to place in the goto next page button
false
outline
Boolean
false
Applies one of the theme color variants to the border instead of the background. This replaces the deprecated alternate prop
false
pageClass
Array, Object, String
''
Class(es) to apply to the 'Go to page #' buttons
false
perPage
Number, String
10
Number of rows per page
false
pills
Boolean
false
Applies pill styling to the pagination buttons
false
prevClass
Array, Object, String
null
Class(es) to apply to the 'Go to previous page' button
false
prevText
String
undefined
Content to place in the goto previous page button
false
rounded
Boolean, String
undefined
Applies rounded corners using TailwindCSS's rounded classes
false
size
String
'sm'
Size of the rendered buttons
Valid values:
xs, sm, md, lg, xl
false
totalRows
Number, String
0
Total number of rows in the dataset
false
variant
String
'default'
Applies one of the theme color variants to the component.
false

Slots ​

Name
Scoped
Description
ellipsis-text
No
The '...' indicator content
first-text
No
The "go to first page" button content
last-text
No
The "go to last page" button content
next-text
No
The "go to next page" button content
prev-text
No
The "go to previous page" button content

Events ​

Event
Arguments
Description
change
  • page
    number
    -
    The current page
Emitted when the page changes
input
  • page
    number
    -
    The current page
Emitted when the page changes
update:modelValue
  • page
    number
    -
    The current page
Emitted when the page changes