added logic and icon of trash to nav bar