Fix hidden dialog when called from Bootstrap modal.

closes #47