organized ui code and created settings tab