Fixed some dialogs getting stuck on close animation, poisoning future dialogs

closes #63
This commit is contained in:
Stefan Zermatten
2017-05-05 10:44:16 +02:00
parent 5ee1f0a169
commit a9256fed05

View File

@@ -174,7 +174,7 @@ const dialogCloseAnimation = ({element, returnElement, dialog, callback}) => {
const stackCompensation = dialogs._array.length ? 16 : 0;
// Insert clone before its progenitor so it can inherit css correctly
element.parentNode.insertBefore(clone, element);
element.parentNode && element.parentNode.insertBefore(clone, element);
// Polymer messes up fixed positioning, measure and compensate
startingRect = clone.getBoundingClientRect();