F
Filament3mo ago
lbar

NavigationGroup translate and icons

I'm struggling with the translation of NavigationGroup. Basically what i'm going to do is:
->navigationGroups([
NavigationGroup::make(__('contests.races'))
->icon('heroicon-s-squares-plus')
->collapsed(),
[...]
->navigationGroups([
NavigationGroup::make(__('contests.races'))
->icon('heroicon-s-squares-plus')
->collapsed(),
[...]
and then in the related resource:
[...]
public static function getNavigationGroup(): ?string
{
return __('contests.races');
}
[...]
[...]
public static function getNavigationGroup(): ?string
{
return __('contests.races');
}
[...]
and works. But for I reason that i don't known and that drive me crazy, the ->icon('heroicon-s-squares-plus') is visible only on one translation, and not on the others. It's just me that i wrong something, or is a kind of bug? ty
1 Reply
Lara Zeus
Lara Zeus5w ago
is the code: ->navigationGroups([ on the panel provider? you should do:
NavigationGroup::make(fn()=>__('contests.races'))
NavigationGroup::make(fn()=>__('contests.races'))

Did you find this page helpful?