update weather widget code for react