NavItem class
Item de navegação do menu. Pode ser clicável (com route/onTap) ou expansível (quando tem children — submenu, estilo accordion).
Constructors
-
const
Properties
- badge → int?
-
Contador opcional exibido como badge (ex.: itens não lidos).
final
-
children
→ List<
NavItem> -
Subitens — se não vazio, o item vira expansível.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- icon → IconData
-
final
- isExpandable → bool
-
no setter
- label → String
-
final
- onTap → VoidCallback?
-
Ação direta ao clicar (alternativa a route).
final
- permission → String?
-
Permissão exigida para ver o item (nula = sempre visível). Combina com o
papel do usuário (ver
AppRole/FlenxAdminApp.role).final - route → String?
-
Rota associada (para navegação por rota).
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
withChildren(
List< NavItem> items) → NavItem - Cópia com novos children (usado ao filtrar submenus por permissão).
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited