How can I re-use the filament boolean icon in more places?

I'm thinking something like this:
TextEntry::make('phone_verified_at')
->icon(static fn (User $record) => $record->phone_verified_at ? 'filament-boolean-true' : 'filament-boolean-false')
->label('Verified At')
->dateTime('F j, Y, g:i a')
->placeholder('Not Verified'),
TextEntry::make('phone_verified_at')
->icon(static fn (User $record) => $record->phone_verified_at ? 'filament-boolean-true' : 'filament-boolean-false')
->label('Verified At')
->dateTime('F j, Y, g:i a')
->placeholder('Not Verified'),
But not just here also other places like generally in the UI. Is there a default component that I can invoke, that way if filament ever changes the icon or colors my checkmark icons will change as well? Hoping to keep things consistent.
1 Reply
Citizen
CitizenOP3mo ago
I found the icon documentary page but maybe I'm doing something wrong here: ->icon(static fn (User $record) => $record->phone_verified_at ? 'infolists::components.icon-entry.true' : 'infolists::components.icon-entry.true')

Did you find this page helpful?