Co-authored-by: jon brookes <marshyon@gmail.com> Reviewed-on: https://codeberg.org/headshed/share-lt/pulls/18
24 lines
647 B
PHP
24 lines
647 B
PHP
<?php
|
|
|
|
namespace App\Filament\Resources\Assets\Schemas;
|
|
|
|
use Filament\Forms\Components\TextInput;
|
|
use Filament\Forms\Components\SpatieMediaLibraryFileUpload;
|
|
use Filament\Schemas\Schema;
|
|
|
|
class AssetForm
|
|
{
|
|
public static function configure(Schema $schema): Schema
|
|
{
|
|
return $schema
|
|
->components([
|
|
TextInput::make('alt_text'),
|
|
SpatieMediaLibraryFileUpload::make('image')
|
|
->collection('default')
|
|
->image()
|
|
->disk('s3')
|
|
->visibility('public')
|
|
->label('Upload Image'),
|
|
]);
|
|
}
|
|
}
|