F
Filament2mo ago
AJN

Filament TextInput Clickable External link

I have an action and I want to make a TextInput field clickable so it opens the link of the tab, is there anyway to do this? I read the docs but didn't find anything
public function clubAction(): Action
{
return ViewAction::make('viewClub')
->record(function (array $arguments) {
return Club::find($arguments['id']);
})->label("Run Club In The DMV")
->form([
TextInput::make('name')->url(fn (string $record): string => 'https//:www.google.com')
->openUrlInNewTab()
,
TextInput::make('website')
,
TextInput::make('instagram')
]);

}
public function clubAction(): Action
{
return ViewAction::make('viewClub')
->record(function (array $arguments) {
return Club::find($arguments['id']);
})->label("Run Club In The DMV")
->form([
TextInput::make('name')->url(fn (string $record): string => 'https//:www.google.com')
->openUrlInNewTab()
,
TextInput::make('website')
,
TextInput::make('instagram')
]);

}
1 Reply
dissto
dissto2mo ago
Maybe an affix action or a hint action would be more suitable for your use case? 🤔
Want results from more Discord servers?
Add your server