Suffix Action Position on InfoList Builder

I have a View Resource page with an infolist. I wanted to allow inline editing on specific fields, the closest I could (easily) come up with is an suffixAction to open a modal with a form field. However the action is way off as far right as it can. Is there a way to position it to be immediately next to the text value?
No description
1 Reply
X7Ryan
X7RyanOP3w ago
For the record, this is what I have so far.
Infolists\Components\TextEntry::make('name')
->suffixAction(Action::make('updateName')
->form([
TextInput::make('name')
])
->label('Edit')
->link()
->action(function (array $data, Organization $record):
void {
$record->name = $data['name'];
$record->save();
})),
Infolists\Components\TextEntry::make('name')
->suffixAction(Action::make('updateName')
->form([
TextInput::make('name')
])
->label('Edit')
->link()
->action(function (array $data, Organization $record):
void {
$record->name = $data['name'];
$record->save();
})),

Did you find this page helpful?