ShellAction class
Slot generici che una pagina pubblica verso lo shell. Lo shell li RICOLLOCA
per breakpoint (header desktop/tablet, header compatto + bottom mobile) ma
NON conosce il dominio: un sort/filtro è solo una ShellAction con icona e
onTap che chiama il controller della pagina. Niente tipi di dominio qui →
lo shell resta un layout primitive riusabile in altri progetti.
Binding sempre per RIFERIMENTO al controller della pagina (closure / oggetti
plain), mai widget vivi: così i controlli costruiti dallo shell funzionano
pur essendo, nell'albero, sopra la pagina (nessun context.read rotto).
- Annotations
Constructors
- ShellAction({IconData? icon, String? label, VoidCallback? onTap, String? tooltip, bool isPrimary = false, bool enabled = true, WidgetBuilder? builder})
-
const
Properties
- builder → WidgetBuilder?
-
Escape hatch: se presente, lo shell rende questo widget invece del bottone
generico. Serve a preservare azioni con logica propria (es.
PageAction.toWidgetcon conferme/colori) senza che lo shell le conosca.final - enabled → bool
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- icon → IconData?
-
final
- isPrimary → bool
-
Azione primaria (es. "+ Aggiungi") → resa come pulsante con testo.
final
- label → String?
-
final
- onTap → VoidCallback?
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- tooltip → String?
-
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited