diff --git a/bower.json b/bower.json index 431fa2a..0db1c2d 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "aurelia-ui-virtualization", - "version": "0.4.3", + "version": "0.4.4", "description": "A plugin that provides a virtualized repeater and other virtualization services.", "keywords": [ "aurelia", diff --git a/dist/amd/utilities.js b/dist/amd/utilities.js index d8d3b1f..0252f6f 100644 --- a/dist/amd/utilities.js +++ b/dist/amd/utilities.js @@ -23,7 +23,13 @@ define(['exports', 'aurelia-templating-resources/repeat-utilities'], function (e var viewStart = view.firstChild; var element = viewStart.nextSibling; var viewEnd = view.lastChild; - var parentElement = bottomBuffer.parentElement; + var parentElement = void 0; + + if (bottomBuffer.parentElement) { + parentElement = bottomBuffer.parentElement; + } else if (bottomBuffer.parentNode) { + parentElement = bottomBuffer.parentNode; + } parentElement.insertBefore(viewEnd, bottomBuffer); parentElement.insertBefore(element, viewEnd); diff --git a/dist/aurelia-ui-virtualization.js b/dist/aurelia-ui-virtualization.js index bd000dd..eaec254 100644 --- a/dist/aurelia-ui-virtualization.js +++ b/dist/aurelia-ui-virtualization.js @@ -36,7 +36,13 @@ export function insertBeforeNode(view: View, bottomBuffer: number): void { let viewStart = view.firstChild; let element = viewStart.nextSibling; let viewEnd = view.lastChild; - let parentElement = bottomBuffer.parentElement; + let parentElement; + + if (bottomBuffer.parentElement) { + parentElement = bottomBuffer.parentElement; + } else if (bottomBuffer.parentNode) { + parentElement = bottomBuffer.parentNode; + } parentElement.insertBefore(viewEnd, bottomBuffer); parentElement.insertBefore(element, viewEnd); diff --git a/dist/commonjs/utilities.js b/dist/commonjs/utilities.js index 0317020..37d2098 100644 --- a/dist/commonjs/utilities.js +++ b/dist/commonjs/utilities.js @@ -25,7 +25,13 @@ function insertBeforeNode(view, bottomBuffer) { var viewStart = view.firstChild; var element = viewStart.nextSibling; var viewEnd = view.lastChild; - var parentElement = bottomBuffer.parentElement; + var parentElement = void 0; + + if (bottomBuffer.parentElement) { + parentElement = bottomBuffer.parentElement; + } else if (bottomBuffer.parentNode) { + parentElement = bottomBuffer.parentNode; + } parentElement.insertBefore(viewEnd, bottomBuffer); parentElement.insertBefore(element, viewEnd); diff --git a/dist/es2015/utilities.js b/dist/es2015/utilities.js index f2865f1..237870a 100644 --- a/dist/es2015/utilities.js +++ b/dist/es2015/utilities.js @@ -12,7 +12,13 @@ export function insertBeforeNode(view, bottomBuffer) { let viewStart = view.firstChild; let element = viewStart.nextSibling; let viewEnd = view.lastChild; - let parentElement = bottomBuffer.parentElement; + let parentElement; + + if (bottomBuffer.parentElement) { + parentElement = bottomBuffer.parentElement; + } else if (bottomBuffer.parentNode) { + parentElement = bottomBuffer.parentNode; + } parentElement.insertBefore(viewEnd, bottomBuffer); parentElement.insertBefore(element, viewEnd); diff --git a/dist/system/utilities.js b/dist/system/utilities.js index 79ebde3..2c051bf 100644 --- a/dist/system/utilities.js +++ b/dist/system/utilities.js @@ -21,7 +21,13 @@ System.register(['aurelia-templating-resources/repeat-utilities'], function (_ex var viewStart = view.firstChild; var element = viewStart.nextSibling; var viewEnd = view.lastChild; - var parentElement = bottomBuffer.parentElement; + var parentElement = void 0; + + if (bottomBuffer.parentElement) { + parentElement = bottomBuffer.parentElement; + } else if (bottomBuffer.parentNode) { + parentElement = bottomBuffer.parentNode; + } parentElement.insertBefore(viewEnd, bottomBuffer); parentElement.insertBefore(element, viewEnd); diff --git a/dist/temp/aurelia-ui-virtualization.js b/dist/temp/aurelia-ui-virtualization.js index 236d4c7..441f595 100644 --- a/dist/temp/aurelia-ui-virtualization.js +++ b/dist/temp/aurelia-ui-virtualization.js @@ -116,7 +116,13 @@ function insertBeforeNode(view, bottomBuffer) { var viewStart = view.firstChild; var element = viewStart.nextSibling; var viewEnd = view.lastChild; - var parentElement = bottomBuffer.parentElement; + var parentElement = void 0; + + if (bottomBuffer.parentElement) { + parentElement = bottomBuffer.parentElement; + } else if (bottomBuffer.parentNode) { + parentElement = bottomBuffer.parentNode; + } parentElement.insertBefore(viewEnd, bottomBuffer); parentElement.insertBefore(element, viewEnd); diff --git a/doc/CHANGELOG.md b/doc/CHANGELOG.md index 68d3eb0..bb8898b 100644 --- a/doc/CHANGELOG.md +++ b/doc/CHANGELOG.md @@ -1,3 +1,11 @@ +### 0.4.4 (2016-04-28) + + +#### Bug Fixes + +* **utilities:** undefined parentElement in IE11 ([c7bb7857](http://github.com/aurelia/ui-virtualization/commit/c7bb78576cf584c203cddb2e9374ff9df4284caf)) + + ### 0.4.3 (2016-04-21) diff --git a/package.json b/package.json index 53aa8d0..43d9218 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "aurelia-ui-virtualization", - "version": "0.4.3", + "version": "0.4.4", "description": "A plugin that provides a virtualized repeater and other virtualization services.", "keywords": [ "aurelia",