Skip to content

Commit

Permalink
chore(all): prepare release 1.0.0-beta.6
Browse files Browse the repository at this point in the history
  • Loading branch information
EisenbergEffect committed Mar 28, 2019
1 parent 0143114 commit 64e591c
Show file tree
Hide file tree
Showing 11 changed files with 120 additions and 26 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "aurelia-ui-virtualization",
"version": "1.0.0-beta.5",
"version": "1.0.0-beta.6",
"description": "A plugin that provides a virtualized repeater and other virtualization services.",
"keywords": [
"aurelia",
Expand Down
16 changes: 13 additions & 3 deletions dist/amd/aurelia-ui-virtualization.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,16 @@ define(['exports', 'aurelia-binding', 'aurelia-templating', 'aurelia-templating-
var Math$floor = Math.floor;
var $isNaN = isNaN;

var getScrollContainer = function (element) {
var current = element.parentNode;
while (current !== null && current !== document) {
if (hasOverflowScroll(current)) {
return current;
}
current = current.parentNode;
}
return document.documentElement;
};
var getElementDistanceToTopOfDocument = function (element) {
var box = element.getBoundingClientRect();
var documentElement = document.documentElement;
Expand All @@ -77,8 +87,8 @@ define(['exports', 'aurelia-binding', 'aurelia-templating', 'aurelia-templating-
return Math$round(top);
};
var hasOverflowScroll = function (element) {
var style = element.style;
return style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto';
var style = window.getComputedStyle(element);
return style && (style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto');
};
var getStyleValues = function (element) {
var styles = [];
Expand Down Expand Up @@ -453,7 +463,7 @@ define(['exports', 'aurelia-binding', 'aurelia-templating', 'aurelia-templating-
function DefaultTemplateStrategy() {
}
DefaultTemplateStrategy.prototype.getScrollContainer = function (element) {
return element.parentNode;
return getScrollContainer(element);
};
DefaultTemplateStrategy.prototype.moveViewFirst = function (view, topBuffer) {
insertBeforeNode(view, aureliaPal.DOM.nextElementSibling(topBuffer));
Expand Down
16 changes: 13 additions & 3 deletions dist/commonjs/aurelia-ui-virtualization.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,16 @@ var Math$round = Math.round;
var Math$floor = Math.floor;
var $isNaN = isNaN;

var getScrollContainer = function (element) {
var current = element.parentNode;
while (current !== null && current !== document) {
if (hasOverflowScroll(current)) {
return current;
}
current = current.parentNode;
}
return document.documentElement;
};
var getElementDistanceToTopOfDocument = function (element) {
var box = element.getBoundingClientRect();
var documentElement = document.documentElement;
Expand All @@ -85,8 +95,8 @@ var getElementDistanceToTopOfDocument = function (element) {
return Math$round(top);
};
var hasOverflowScroll = function (element) {
var style = element.style;
return style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto';
var style = window.getComputedStyle(element);
return style && (style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto');
};
var getStyleValues = function (element) {
var styles = [];
Expand Down Expand Up @@ -461,7 +471,7 @@ var DefaultTemplateStrategy = (function () {
function DefaultTemplateStrategy() {
}
DefaultTemplateStrategy.prototype.getScrollContainer = function (element) {
return element.parentNode;
return getScrollContainer(element);
};
DefaultTemplateStrategy.prototype.moveViewFirst = function (view, topBuffer) {
insertBeforeNode(view, aureliaPal.DOM.nextElementSibling(topBuffer));
Expand Down
16 changes: 13 additions & 3 deletions dist/es2015/aurelia-ui-virtualization.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,16 @@ const Math$round = Math.round;
const Math$floor = Math.floor;
const $isNaN = isNaN;

const getScrollContainer = (element) => {
let current = element.parentNode;
while (current !== null && current !== document) {
if (hasOverflowScroll(current)) {
return current;
}
current = current.parentNode;
}
return document.documentElement;
};
const getElementDistanceToTopOfDocument = (element) => {
let box = element.getBoundingClientRect();
let documentElement = document.documentElement;
Expand All @@ -52,8 +62,8 @@ const getElementDistanceToTopOfDocument = (element) => {
return Math$round(top);
};
const hasOverflowScroll = (element) => {
let style = element.style;
return style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto';
const style = window.getComputedStyle(element);
return style && (style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto');
};
const getStyleValues = (element, ...styles) => {
let currentStyle = window.getComputedStyle(element);
Expand Down Expand Up @@ -410,7 +420,7 @@ class VirtualRepeatStrategyLocator {

class DefaultTemplateStrategy {
getScrollContainer(element) {
return element.parentNode;
return getScrollContainer(element);
}
moveViewFirst(view, topBuffer) {
insertBeforeNode(view, DOM.nextElementSibling(topBuffer));
Expand Down
16 changes: 13 additions & 3 deletions dist/es2017/aurelia-ui-virtualization.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,16 @@ const Math$round = Math.round;
const Math$floor = Math.floor;
const $isNaN = isNaN;

const getScrollContainer = (element) => {
let current = element.parentNode;
while (current !== null && current !== document) {
if (hasOverflowScroll(current)) {
return current;
}
current = current.parentNode;
}
return document.documentElement;
};
const getElementDistanceToTopOfDocument = (element) => {
let box = element.getBoundingClientRect();
let documentElement = document.documentElement;
Expand All @@ -52,8 +62,8 @@ const getElementDistanceToTopOfDocument = (element) => {
return Math$round(top);
};
const hasOverflowScroll = (element) => {
let style = element.style;
return style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto';
const style = window.getComputedStyle(element);
return style && (style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto');
};
const getStyleValues = (element, ...styles) => {
let currentStyle = window.getComputedStyle(element);
Expand Down Expand Up @@ -410,7 +420,7 @@ class VirtualRepeatStrategyLocator {

class DefaultTemplateStrategy {
getScrollContainer(element) {
return element.parentNode;
return getScrollContainer(element);
}
moveViewFirst(view, topBuffer) {
insertBeforeNode(view, DOM.nextElementSibling(topBuffer));
Expand Down
16 changes: 13 additions & 3 deletions dist/native-modules/aurelia-ui-virtualization.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,16 @@ var Math$round = Math.round;
var Math$floor = Math.floor;
var $isNaN = isNaN;

var getScrollContainer = function (element) {
var current = element.parentNode;
while (current !== null && current !== document) {
if (hasOverflowScroll(current)) {
return current;
}
current = current.parentNode;
}
return document.documentElement;
};
var getElementDistanceToTopOfDocument = function (element) {
var box = element.getBoundingClientRect();
var documentElement = document.documentElement;
Expand All @@ -81,8 +91,8 @@ var getElementDistanceToTopOfDocument = function (element) {
return Math$round(top);
};
var hasOverflowScroll = function (element) {
var style = element.style;
return style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto';
var style = window.getComputedStyle(element);
return style && (style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto');
};
var getStyleValues = function (element) {
var styles = [];
Expand Down Expand Up @@ -457,7 +467,7 @@ var DefaultTemplateStrategy = (function () {
function DefaultTemplateStrategy() {
}
DefaultTemplateStrategy.prototype.getScrollContainer = function (element) {
return element.parentNode;
return getScrollContainer(element);
};
DefaultTemplateStrategy.prototype.moveViewFirst = function (view, topBuffer) {
insertBeforeNode(view, DOM.nextElementSibling(topBuffer));
Expand Down
16 changes: 13 additions & 3 deletions dist/system/aurelia-ui-virtualization.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,16 @@ System.register(['aurelia-binding', 'aurelia-templating', 'aurelia-templating-re
var Math$floor = Math.floor;
var $isNaN = isNaN;

var getScrollContainer = function (element) {
var current = element.parentNode;
while (current !== null && current !== document) {
if (hasOverflowScroll(current)) {
return current;
}
current = current.parentNode;
}
return document.documentElement;
};
var getElementDistanceToTopOfDocument = function (element) {
var box = element.getBoundingClientRect();
var documentElement = document.documentElement;
Expand All @@ -109,8 +119,8 @@ System.register(['aurelia-binding', 'aurelia-templating', 'aurelia-templating-re
return Math$round(top);
};
var hasOverflowScroll = function (element) {
var style = element.style;
return style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto';
var style = window.getComputedStyle(element);
return style && (style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto');
};
var getStyleValues = function (element) {
var styles = [];
Expand Down Expand Up @@ -485,7 +495,7 @@ System.register(['aurelia-binding', 'aurelia-templating', 'aurelia-templating-re
function DefaultTemplateStrategy() {
}
DefaultTemplateStrategy.prototype.getScrollContainer = function (element) {
return element.parentNode;
return getScrollContainer(element);
};
DefaultTemplateStrategy.prototype.moveViewFirst = function (view, topBuffer) {
insertBeforeNode(view, DOM.nextElementSibling(topBuffer));
Expand Down
16 changes: 13 additions & 3 deletions dist/umd-es2015/aurelia-ui-virtualization.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,16 @@
const Math$floor = Math.floor;
const $isNaN = isNaN;

const getScrollContainer = (element) => {
let current = element.parentNode;
while (current !== null && current !== document) {
if (hasOverflowScroll(current)) {
return current;
}
current = current.parentNode;
}
return document.documentElement;
};
const getElementDistanceToTopOfDocument = (element) => {
let box = element.getBoundingClientRect();
let documentElement = document.documentElement;
Expand All @@ -52,8 +62,8 @@
return Math$round(top);
};
const hasOverflowScroll = (element) => {
let style = element.style;
return style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto';
const style = window.getComputedStyle(element);
return style && (style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto');
};
const getStyleValues = (element, ...styles) => {
let currentStyle = window.getComputedStyle(element);
Expand Down Expand Up @@ -410,7 +420,7 @@

class DefaultTemplateStrategy {
getScrollContainer(element) {
return element.parentNode;
return getScrollContainer(element);
}
moveViewFirst(view, topBuffer) {
insertBeforeNode(view, aureliaPal.DOM.nextElementSibling(topBuffer));
Expand Down
16 changes: 13 additions & 3 deletions dist/umd/aurelia-ui-virtualization.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,16 @@
var Math$floor = Math.floor;
var $isNaN = isNaN;

var getScrollContainer = function (element) {
var current = element.parentNode;
while (current !== null && current !== document) {
if (hasOverflowScroll(current)) {
return current;
}
current = current.parentNode;
}
return document.documentElement;
};
var getElementDistanceToTopOfDocument = function (element) {
var box = element.getBoundingClientRect();
var documentElement = document.documentElement;
Expand All @@ -81,8 +91,8 @@
return Math$round(top);
};
var hasOverflowScroll = function (element) {
var style = element.style;
return style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto';
var style = window.getComputedStyle(element);
return style && (style.overflowY === 'scroll' || style.overflow === 'scroll' || style.overflowY === 'auto' || style.overflow === 'auto');
};
var getStyleValues = function (element) {
var styles = [];
Expand Down Expand Up @@ -457,7 +467,7 @@
function DefaultTemplateStrategy() {
}
DefaultTemplateStrategy.prototype.getScrollContainer = function (element) {
return element.parentNode;
return getScrollContainer(element);
};
DefaultTemplateStrategy.prototype.moveViewFirst = function (view, topBuffer) {
insertBeforeNode(view, aureliaPal.DOM.nextElementSibling(topBuffer));
Expand Down
14 changes: 14 additions & 0 deletions doc/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
# [1.0.0-beta.6](https://github.com/aurelia/ui-virtualization/compare/1.0.0-beta.5...1.0.0-beta.6) (2019-03-28)


### Bug Fixes

* **utilities-dom:** use window.getComputedStyle for hasOverflowScroll ([4b015d2](https://github.com/aurelia/ui-virtualization/commit/4b015d2))


### Features

* **template-strategy-default:** walk up the DOM tree and determine what element will be scroller for virtual repeat ([6ebf907](https://github.com/aurelia/ui-virtualization/commit/6ebf907))



# [1.0.0-beta.5](https://github.com/aurelia/ui-virtualization/compare/1.0.0-beta.4...1.0.0-beta.5) (2019-03-27)


Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "aurelia-ui-virtualization",
"version": "1.0.0-beta.5",
"version": "1.0.0-beta.6",
"description": "A plugin that provides a virtualized repeater and other virtualization services.",
"keywords": [
"aurelia",
Expand Down

0 comments on commit 64e591c

Please sign in to comment.