Section heading text color

Is it possible to change "section" heading text color based on record?
2 Replies
Patrick Boivin
Hi @alexander7479, one option would be to add a custom CSS class on the section :
Section::make('A Section')
->schema([ ... ])
->extraAttributes(fn ($record) => ['class' => $record ? "section-{$record->type}" : ""]),
Section::make('A Section')
->schema([ ... ])
->extraAttributes(fn ($record) => ['class' => $record ? "section-{$record->type}" : ""]),
AlexAnder
AlexAnderOP2y ago
Thanks
Want results from more Discord servers?
Add your server