fixed some layout issues with the search and add some commenting