2017 © Pedro Peláez
 

metapackage fact

This is the fact generator package

image

ghorbannezhad/fact

This is the fact generator package

  • Monday, July 16, 2018
  • by Ghorbannezhad
  • Repository
  • 1 Watchers
  • 0 Stars
  • 20 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Fact Generator

Fact generator is a simple laravel package which generate fact image. You only need to define your desired image, logo and text to generate sample fact image. It support English and Persian., (*1)

Install

1- Install the package with composer, (*2)

composer require --dev ghorbannezhad/fact

2- Publish config file, (*3)

php artisan vendor:publish --provider="Ghorbannezhad\Fact\FactServiceProvider"

Usage

1- Add service provider to config/app.php, (*4)

'providers' => [
    ...
    Ghorbannezhad\Fact\FactServiceProvider::class,
]

2- Call fact facade in controller, (*5)

    $image = public_path('/address/to/image.jpg');
    $text= 'Lorem ipsum';
    $fact = FactFacade::create($image,$text);

3- Set language and font in config file, (*6)

return [
    'logo'=>$logo,
    'style'=>[
        'margin_top'=>10,        //in percent
        'margin_left'=>10,      //in percent
        'margin_bottom'=>10,   //in percent
        'margin_right'=>10,   //in percent
        'font_size'=>24,
        'line_height'=>50,
        'logo_from_bottom'=> 10,  //in percent
        'font'=>$font,
        'text_align'=>'center' //supported: center|right|left
    ],
    'lang'=>'fa', //supported: fa | en
    'save_path'=>$save_path,

];

Contributers

License

FactGenerator is licensed under the MIT License - see the LICENSE file for details, (*7)

The Versions

16/07 2018

dev-master

9999999-dev

This is the fact generator package

  Sources   Download

MIT

The Requires

 

by Faezeh Ghorbannezhad

16/07 2018

v1.0

1.0.0.0

This is the fact generator package

  Sources   Download

MIT

The Requires

 

by Faezeh Ghorbannezhad