Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] Laravel Pagination Style - Don't work with Argon #124

Open
felloz opened this issue Oct 26, 2020 · 3 comments
Open

[Bug] Laravel Pagination Style - Don't work with Argon #124

felloz opened this issue Oct 26, 2020 · 3 comments

Comments

@felloz
Copy link

felloz commented Oct 26, 2020

Version

Laravel 8.x

Reproduction link

https://i.imgur.com/Na8iTPH.png

Operating System

CentOS 8

Device

PC

Browser & Version

Last Version

Steps to reproduce

When I paste the laravel url to reproduce the pagination it looks awful {{ $users->links()}}

What is expected?

That looks like it should

What is actually happening?

The pagination get distortioned


Solution

I dont have one

Additional comments

Please help me with this :-(

This is how it looks: https://i.imgur.com/Na8iTPH.png

@felloz
Copy link
Author

felloz commented Oct 26, 2020

Using this bootstrap 4 clases it looks small but still awful :(

<div class="d-flex justify-content-center">
     {!! $users->links() !!}
</div>

image

@rarestoma
Copy link
Contributor

Hi @felloz,

Thank you for working with our products.

Please try with our pagination style available here: https://demos.creative-tim.com/argon-design-system/docs/components/pagination.html?

I hope it helps.

Thank you,
Rares

@felloz
Copy link
Author

felloz commented Oct 28, 2020

This is how I fixed the problem.

https://laracasts.com/discuss/channels/laravel/argon-dashboard-pagination-looks-bad?page=1#reply=658345

Laravel 8 use tailwind for paginator, Argon use bootstrap instead. The only thing that I had to do is add Paginator::useBootstrap(); to my AppServiceProvider

<?php

namespace App\Providers;

use Illuminate\Pagination\Paginator;
use Illuminate\Support\ServiceProvider;

class AppServiceProvider extends ServiceProvider
{
    /**
     * Register any application services.
     *
     * @return void
     */
    public function register()
    {
        //
    }

    /**
     * Bootstrap any application services.
     *
     * @return void
     */
    public function boot()
    {
        Paginator::useBootstrap();
    }
}

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

No branches or pull requests

2 participants