F
Filamentβ€’13mo ago
harps

Inliine infolist entries

Is there a way to display Infolists\Components\TextEntry inline with each other. Each Text entry is wrapped in a lot of divs with grid classes etc. I have this:
Infolists\Components\Section::make([
StatusRow::make('status_row')
->Label(false),
Infolists\Components\TextEntry::make('completed')
->label(false)
->visible( fn (PipeSurvey $record): bool => $record->completed_at !== null),
Infolists\Components\TextEntry::make('exported')
->label(false)
->visible( fn (PipeSurvey $record): bool => $record->completed_at !== null),
Infolists\Components\TextEntry::make('type')
->label(false)
->badge(),
Infolists\Components\TextEntry::make('batch.batch_name')
->label(false)
->icon('heroicon-s-rectangle-stack')
->url(fn (PipeSurvey $record): string => $record->batch ? PipeBatchResource::getUrl('view', ['record' => $record->batch]) : ''),
Infolists\Components\TextEntry::make('assigned.name')
->label(false)
->icon('heroicon-s-user'),
]),
Infolists\Components\Section::make([
StatusRow::make('status_row')
->Label(false),
Infolists\Components\TextEntry::make('completed')
->label(false)
->visible( fn (PipeSurvey $record): bool => $record->completed_at !== null),
Infolists\Components\TextEntry::make('exported')
->label(false)
->visible( fn (PipeSurvey $record): bool => $record->completed_at !== null),
Infolists\Components\TextEntry::make('type')
->label(false)
->badge(),
Infolists\Components\TextEntry::make('batch.batch_name')
->label(false)
->icon('heroicon-s-rectangle-stack')
->url(fn (PipeSurvey $record): string => $record->batch ? PipeBatchResource::getUrl('view', ['record' => $record->batch]) : ''),
Infolists\Components\TextEntry::make('assigned.name')
->label(false)
->icon('heroicon-s-user'),
]),
Which renders all the fields in the correct format, but not inline. I've played around with columns and column spans but the spacing never looks right. The first component is a custom one I was experimenting with to get them lined up. Cheers Dan
No description
No description
2 Replies
harps
harpsOPβ€’13mo ago
Hi @awcodes the first entry I have is a custom entry, I've just been outputting raw values. I was wondering if there was a way to not have the entry components not wrapped divs with grid classes but I guess not. I'll just output them manually. πŸ‘
Want results from more Discord servers?
Add your server