added widget functionality