@if ($paginator->hasPages())
    <div class="pages">

        {{-- Previous Page Link --}}
        @if ($paginator->onFirstPage())
            <a href="#" style="pointer-events: none;">上一页</a>
        @else
            <a href="{{ $paginator->previousPageUrl() }}">上一页</a>
        @endif

        {{-- Pagination Elements --}}
        @foreach ($elements as $element)
            {{-- Array Of Links --}}
            @if (is_array($element))
                @foreach ($element as $page => $url)
                    @if ($page == $paginator->currentPage())
                        <a href="{{ $url }}" class="show">{{ $page }}</a>
                    @else
                        <a href="{{ $url }}">{{ $page }}</a>
                    @endif
                @endforeach
            @endif
        @endforeach

        {{-- Next Page Link --}}
        @if ($paginator->hasMorePages())
            <a href="{{ $paginator->nextPageUrl() }}">下一页</a>
        @else
            <a href="#" style="pointer-events: none;" disabled="">下一页</a>
        @endif
    </div>
@endif
