cleanup
envelope view refactoring