adding ui functionality