hiding navigation when graph is not active