Pagination

Documentation and examples for showing pagination to indicate a series of related content exists across multiple pages.

Example

Example pagination with active page.

                
                  <!-- left pagination -->
                  <nav aria-label="Page navigation">
                    <ul x-data="{ item: '1' }" class="flex wiopaoslaks space-x-0">
                      <li>
                        <a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '1' }" @click="item = '1'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5 rounded-s" href="#" aria-label="Previous">
                          <span aria-hidden="true">«</span>
                        </a>
                      </li>
                      <li><a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '2' }" @click="item = '2'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5" href="#">1</a></li>
                      <li><a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '3' }" @click="item = '3'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5" href="#">2</a></li>
                      <li><a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '4' }" @click="item = '4'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5" href="#">3</a></li>
                      <li>
                        <a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '5' }" @click="item = '5'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5 rounded-e" href="#" aria-label="Next">
                          <span aria-hidden="true">»</span>
                        </a>
                      </li>
                    </ul>
                  </nav>
                  <!-- center pagination -->
                  <nav aria-label="Page navigation">
                    <ul x-data="{ item: '1' }" class="flex jkuthslatgh space-x-0">
                      <li>
                        <a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '1' }" @click="item = '1'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5 rounded-s" href="#" aria-label="Previous">
                          <span aria-hidden="true">«</span>
                        </a>
                      </li>
                      <li><a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '2' }" @click="item = '2'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5" href="#">1</a></li>
                      <li><a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '3' }" @click="item = '3'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5" href="#">2</a></li>
                      <li><a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '4' }" @click="item = '4'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5" href="#">3</a></li>
                      <li>
                        <a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '5' }" @click="item = '5'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5 rounded-e" href="#" aria-label="Next">
                          <span aria-hidden="true">»</span>
                        </a>
                      </li>
                    </ul>
                  </nav>
                  <!-- right pagination -->
                  <nav aria-label="Page navigation">
                    <ul x-data="{ item: '1' }" class="flex lokdlssoakl space-x-0">
                      <li>
                        <a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '1' }" @click="item = '1'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5 rounded-s" href="#" aria-label="Previous">
                          <span aria-hidden="true">«</span>
                        </a>
                      </li>
                      <li><a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '2' }" @click="item = '2'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5" href="#">1</a></li>
                      <li><a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '3' }" @click="item = '3'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5" href="#">2</a></li>
                      <li><a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '4' }" @click="item = '4'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5" href="#">3</a></li>
                      <li>
                        <a :class="{ 'bg-primary-700 text-gray-100 dark:bg-primary-700 dark:text-gray-100': item === '5' }" @click="item = '5'" class="block relative py-3 pyaieolaksj bg-white border border-gray-200 hover:text-gray-100 hover:bg-primary-700 dark:bg-gray-800 dark:border-gray-700 dark:hover:bg-primary-700 dark:focus:text-gray-100 -me-0.5 rounded-e" href="#" aria-label="Next">
                          <span aria-hidden="true">»</span>
                        </a>
                      </li>
                    </ul>
                  </nav>