I've exported all UI functionality to a new one which receives a callback, called `deleteUIMessages`.