Add a jumbotron images with title and description to the pages of your Laravel application.
The titles and descriptions support multilanguage.
You can install the package via composer:
composer require davide-casiraghi/laravel-jumbotron-images
php artisan vendor:publish --force
php artisan migrate
require('./vendor/laravel-jumbotron-images/jquery.stellar');
require('./vendor/laravel-jumbotron-images/laravel-jumbotron-images');
@import 'vendor/laravel-jumbotron-images/laravel-jumbotron-images';
Once you have published the package you can go to this route to manage your jumbotrons:
/jumbotron-images
Include the facade in your controller:
use DavideCasiraghi\LaravelJumbotronImages\Facades\LaravelJumbotronImages;
In the controller, pass to the view the Jumbotron datas. (In this case we want to show the jumbotron with id = 1)
$jumbotronImage = LaravelJumbotronImages::getJumbotronImage(1);
return view('welcome', [
'jumbotronImage' => $jumbotronImage,
'jumbotronImageParameters' => LaravelJumbotronImages::getParametersArray($jumbotronImage),
]);
Then include in the view the jumbotron view.
@include('vendor.laravel-jumbotron-images.show-jumbotron-image', $jumbotronImage)
The library replace all the occurrences of this kind of snippet
{# jumbotron id=[1] #}
You can run unit tests checking the code coverage using this command.
./vendor/bin/phpunit --coverage-html=html
So you can find the reports about the code coverage in this file /html/index.html
Please see CHANGELOG for more information what has changed recently.
Please see CONTRIBUTING for details.
If you discover any security related issues, please email [email protected] instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.
This package was generated using the Laravel Package Boilerplate.