US5: User Interface JS part refactored