PHP code example of johncarter / filament-focal-point-picker

1. Go to this page and download the library: Download johncarter/filament-focal-point-picker library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

johncarter / filament-focal-point-picker example snippets


FileUpload::make('my_image_field')->maxFiles(1),
FocalPointPicker::make('focal_point')
    ->default('10% 25%') // default: "50% 50%"
    ->imageField('my_image_field')
    // Or, return an image url from a closure on the image() method
    // ->image(function() {
    //     return 'https://www.example.com/images/image1.jpg'
    // })
bash
php artisan vendor:publish --tag="filament-focal-point-picker-views"