One small problem with this. I breaks both the popup.html and the dialog.html partials.