updateFromRoute method
Chiamato ad ogni cambio route: aggiorna il tema E allinea la sidebar.
Implementation
void updateFromRoute(String path) {
final newModule = _moduleFromPath(path);
bool changed = false;
if (newModule != _currentModule) {
_transitionTimer?.cancel();
_currentModule = newModule;
_invalidateCache();
changed = true;
}
if (newModule != _selectedModule) {
_selectedModule = newModule;
changed = true;
}
if (changed) notifyListeners();
}