36 lines
990 B
PHP
36 lines
990 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Filament\Resources\Links\Schemas;
|
|
|
|
use Filament\Forms\Components\TextInput;
|
|
use Filament\Forms\Components\Toggle;
|
|
use Filament\Schemas\Schema;
|
|
|
|
class LinkForm
|
|
{
|
|
public static function configure(Schema $schema): Schema
|
|
{
|
|
return $schema
|
|
->components([
|
|
TextInput::make('name')
|
|
->label(__('link.name'))
|
|
->required(),
|
|
TextInput::make('url')
|
|
->label(__('link.url'))
|
|
->url()
|
|
->required(),
|
|
TextInput::make('note')
|
|
->label(__('link.note')),
|
|
TextInput::make('display_order')
|
|
->label(__('link.display_order'))
|
|
->required()
|
|
->numeric()
|
|
->default(0),
|
|
Toggle::make('visible')
|
|
->label(__('link.visible')),
|
|
]);
|
|
}
|
|
}
|