Commit 46d40480 authored by JC Brand's avatar JC Brand

Upgrade bootstrap.native to 2.0.24

parent 7753177c
...@@ -3403,7 +3403,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -3403,7 +3403,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
/*! no static exports found */ /*! no static exports found */
/***/ (function(module, exports, __webpack_require__) { /***/ (function(module, exports, __webpack_require__) {
/* WEBPACK VAR INJECTION */(function(global) {var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// Native Javascript for Bootstrap 4 v2.0.23 | © dnp_theme | MIT-License /* WEBPACK VAR INJECTION */(function(global) {var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// Native Javascript for Bootstrap 4 v2.0.24 | © dnp_theme | MIT-License
(function (root, factory) { (function (root, factory) {
if (true) { if (true) {
// AMD support: // AMD support:
...@@ -3707,7 +3707,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -3707,7 +3707,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
arrowLeft && (arrow[style][left] = arrowLeft + 'px'); arrowLeft && (arrow[style][left] = arrowLeft + 'px');
}; };
BSN.version = '2.0.23'; BSN.version = '2.0.24';
/* Native Javascript for Bootstrap 4 | Alert /* Native Javascript for Bootstrap 4 | Alert
-------------------------------------------*/ -------------------------------------------*/
...@@ -3893,7 +3893,8 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -3893,7 +3893,8 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
this[interval] = typeof intervalOption === 'number' ? intervalOption this[interval] = typeof intervalOption === 'number' ? intervalOption
: intervalOption === false || intervalData === 0 || intervalData === false ? 0 : intervalOption === false || intervalData === 0 || intervalData === false ? 0
: 5000; // bootstrap carousel default interval : isNaN(intervalData) ? 5000 // bootstrap carousel default interval
: intervalData;
// bind, event targets // bind, event targets
var self = this, index = element.index = 0, timer = element.timer = 0, var self = this, index = element.index = 0, timer = element.timer = 0,
...@@ -3909,13 +3910,13 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -3909,13 +3910,13 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
var pauseHandler = function () { var pauseHandler = function () {
if ( self[interval] !==false && !hasClass(element,paused) ) { if ( self[interval] !==false && !hasClass(element,paused) ) {
addClass(element,paused); addClass(element,paused);
!isSliding && clearInterval( timer ); !isSliding && ( clearInterval(timer), timer = null );
} }
}, },
resumeHandler = function() { resumeHandler = function() {
if ( self[interval] !== false && hasClass(element,paused) ) { if ( self[interval] !== false && hasClass(element,paused) ) {
removeClass(element,paused); removeClass(element,paused);
!isSliding && clearInterval( timer ); !isSliding && ( clearInterval(timer), timer = null );
!isSliding && self.cycle(); !isSliding && self.cycle();
} }
}, },
...@@ -3974,6 +3975,11 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -3974,6 +3975,11 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
// public methods // public methods
this.cycle = function() { this.cycle = function() {
if (timer) {
clearInterval(timer);
timer = null;
}
timer = setInterval(function() { timer = setInterval(function() {
isElementInScrollRange() && (index++, self.slideTo( index ) ); isElementInScrollRange() && (index++, self.slideTo( index ) );
}, this[interval]); }, this[interval]);
...@@ -3984,8 +3990,11 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -3984,8 +3990,11 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
var activeItem = this.getActiveIndex(), // the current active var activeItem = this.getActiveIndex(), // the current active
orientation; orientation;
// determine slideDirection first // first return if we're on the same item #227
if ( (activeItem < next ) || (activeItem === 0 && next === total -1 ) ) { if ( activeItem === next ) {
return;
// or determine slideDirection
} else if ( (activeItem < next ) || (activeItem === 0 && next === total -1 ) ) {
slideDirection = self[direction] = left; // next slideDirection = self[direction] = left; // next
} else if ( (activeItem > next) || (activeItem === total - 1 && next === 0 ) ) { } else if ( (activeItem > next) || (activeItem === total - 1 && next === 0 ) ) {
slideDirection = self[direction] = right; // prev slideDirection = self[direction] = right; // prev
...@@ -3993,7 +4002,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -3993,7 +4002,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
// find the right next index // find the right next index
if ( next < 0 ) { next = total - 1; } if ( next < 0 ) { next = total - 1; }
else if ( next === total ){ next = 0; } else if ( next >= total ){ next = 0; }
// update index // update index
index = next; index = next;
...@@ -4003,6 +4012,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -4003,6 +4012,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
isSliding = true; isSliding = true;
clearInterval(timer); clearInterval(timer);
timer = null;
setActivePage( next ); setActivePage( next );
if ( supportTransitions && hasClass(element,'slide') ) { if ( supportTransitions && hasClass(element,'slide') ) {
...@@ -4282,7 +4292,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -4282,7 +4292,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
bootstrapCustomEvent.call(parent, showEvent, component, relatedTarget); bootstrapCustomEvent.call(parent, showEvent, component, relatedTarget);
addClass(menu,showClass); addClass(menu,showClass);
addClass(parent,showClass); addClass(parent,showClass);
menu[setAttribute](ariaExpanded,true); element[setAttribute](ariaExpanded,true);
bootstrapCustomEvent.call(parent, shownEvent, component, relatedTarget); bootstrapCustomEvent.call(parent, shownEvent, component, relatedTarget);
element[open] = true; element[open] = true;
off(element, clickEvent, clickHandler); off(element, clickEvent, clickHandler);
...@@ -4295,7 +4305,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod ...@@ -4295,7 +4305,7 @@ backbone.nativeview = __webpack_require__(/*! backbone.nativeview */ "./node_mod
bootstrapCustomEvent.call(parent, hideEvent, component, relatedTarget); bootstrapCustomEvent.call(parent, hideEvent, component, relatedTarget);
removeClass(menu,showClass); removeClass(menu,showClass);
removeClass(parent,showClass); removeClass(parent,showClass);
menu[setAttribute](ariaExpanded,false); element[setAttribute](ariaExpanded,false);
bootstrapCustomEvent.call(parent, hiddenEvent, component, relatedTarget); bootstrapCustomEvent.call(parent, hiddenEvent, component, relatedTarget);
element[open] = false; element[open] = false;
toggleDismiss(); toggleDismiss();
...@@ -3500,9 +3500,9 @@ ...@@ -3500,9 +3500,9 @@
"dev": true "dev": true
}, },
"bootstrap.native": { "bootstrap.native": {
"version": "2.0.23", "version": "2.0.24",
"resolved": "https://registry.npmjs.org/bootstrap.native/-/bootstrap.native-2.0.23.tgz", "resolved": "https://registry.npmjs.org/bootstrap.native/-/bootstrap.native-2.0.24.tgz",
"integrity": "sha512-bcbVgqIjRkyiHd6DN8Y18BYjJTKvvnN3Msb7Yh6K5vGGsjRT3gV0IFKR3rcEYgJ5Kvg1egL9exIfN/Hvwn4wNA==", "integrity": "sha512-yJZNOE9i3W7/yWtidaPGYDRMs5cyOn5W08jfyOV5e4DRm8APF8BiEkEZDsu3xtrNm/fBzUIf+K+u4Qs1qadjxw==",
"dev": true "dev": true
}, },
"bourbon": { "bourbon": {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment