Set formData on an Infolist action form

I have the following infolist action form (excerpt)

TextEntry::make('user.details')
    ->suffixActions([
      Action::make('editDetails')
            ->form([
                TextInput::make('name'),
                Select::make('title')
            ])
            ->formData([]) // Cant set this
            ->action(function (array $data, $record) {
                $record->details()->update($data);
            }),
    ])

How can I pre-fill this form? I tried doing the following

$details = $this->getRecord()->details->attributesToArray();

...

->formData($details)


but it doesn't work.

Is this possible? Am I doing something wrong?
Solution
Nvm, I'm an idiot. There's a ->fillForm method that does what I want.
Was this page helpful?