ui improvements and fixed a slight bug due to ui