updates markup and adds new elements