Previously there's a hack for showing and hiding the dialog. Change it to use channels to emulate async/await
I think this will be the one.