This is a pre-rendered dialog, which means that $mdDialog doesn't compile its
template on each opening.
The Dialog Element is a static element in the DOM, which is just visually hidden.
Once the dialog opens, we just fetch the element from the DOM into our dialog and upon close
we restore the element back into its old DOM position.