updates example to add wait state and some styling - remove extraneous code