Refactoring to remove bootstrap and use plain javascript dialogs again