FilamentF
Filament3y ago
Noxo

Section - headerEnd

Is there a way to place an action to the headerEnd slot of Section?


I tried to do it like this, but it didn't work. Maybe there is another way?

Forms\Components\Section::make()
    ->heading('Heading')
    ->description('Description')
    ->extraAlpineAttributes([
        'headerEnd' => fn () => Forms\Components\Actions\Action::make('active')
            ->action(function () {
                //
            }),
    ], merge: true)
    ->schema([
        Forms\Components\TextInput::make('price')
            ->minValue(0)
            ->maxValue(config('constants.MYSQL_INT_UNSIGNED_MAX'))
            ->numeric()
            ->suffix(config('app.currency'))
            ->required(),
    ])
    ->compact()
    ->columnSpan(1),
Screenshot_2023-09-18_at_08.40.09.png
Was this page helpful?