fixing details view and view height
modularizing and testing