@@ -10,8 +10,8 @@ if (typeof jQuery === 'undefined') {
1010
1111+ function ( $ ) {
1212 var version = $ . fn . jquery . split ( ' ' ) [ 0 ] . split ( '.' )
13- if ( version [ 0 ] ! == '2' ) {
14- throw new Error ( 'Bootstrap\'s JavaScript requires jQuery version 2.x.x ' )
13+ if ( ( version [ 0 ] < 2 && version [ 1 ] < 9 ) || ( version [ 0 ] == 1 && version [ 1 ] == 9 && version [ 2 ] < 1 ) || ( version [ 0 ] >= 3 ) ) {
14+ throw new Error ( 'Bootstrap\'s JavaScript requires at least jQuery v1.9.1 but less than v3.0.0 ' )
1515 }
1616} ( jQuery ) ;
1717
@@ -1786,7 +1786,7 @@ var Modal = (function ($) {
17861786 $ ( this . _dialog ) . on ( Event . MOUSEDOWN_DISMISS , function ( ) {
17871787 $ ( _this7 . _element ) . one ( Event . MOUSEUP_DISMISS , function ( event ) {
17881788 if ( $ ( event . target ) . is ( _this7 . _element ) ) {
1789- that . _ignoreBackdropClick = true ;
1789+ _this7 . _ignoreBackdropClick = true ;
17901790 }
17911791 } ) ;
17921792 } ) ;
@@ -2753,6 +2753,8 @@ var Tab = (function ($) {
27532753 return Tab ;
27542754} ) ( jQuery ) ;
27552755
2756+ /* global Tether */
2757+
27562758/**
27572759 * --------------------------------------------------------------------------
27582760 * Bootstrap (v4.0.0): tooltip.js
@@ -2762,6 +2764,14 @@ var Tab = (function ($) {
27622764
27632765var Tooltip = ( function ( $ ) {
27642766
2767+ /**
2768+ * Check for Tether dependency
2769+ * Tether - http://github.hubspot.com/tether/
2770+ */
2771+ if ( window . Tether === undefined ) {
2772+ throw new Error ( 'Bootstrap tooltips require Tether (http://github.hubspot.com/tether/)' ) ;
2773+ }
2774+
27652775 /**
27662776 * ------------------------------------------------------------------------
27672777 * Constants
@@ -2997,7 +3007,8 @@ var Tooltip = (function ($) {
29973007 classes : TetherClass ,
29983008 classPrefix : CLASS_PREFIX ,
29993009 offset : this . config . offset ,
3000- constraints : this . config . constraints
3010+ constraints : this . config . constraints ,
3011+ addTargetClasses : false
30013012 } ) ;
30023013
30033014 Util . reflow ( tip ) ;
@@ -3119,12 +3130,6 @@ var Tooltip = (function ($) {
31193130 value : function cleanupTether ( ) {
31203131 if ( this . _tether ) {
31213132 this . _tether . destroy ( ) ;
3122-
3123- // clean up after tether's junk classes
3124- // remove after they fix issue
3125- // (https://github.com/HubSpot/tether/issues/36)
3126- $ ( this . element ) . removeClass ( this . _removeTetherClasses ) ;
3127- $ ( this . tip ) . removeClass ( this . _removeTetherClasses ) ;
31283133 }
31293134 }
31303135
@@ -3162,11 +3167,6 @@ var Tooltip = (function ($) {
31623167 this . _fixTitle ( ) ;
31633168 }
31643169 }
3165- } , {
3166- key : '_removeTetherClasses' ,
3167- value : function _removeTetherClasses ( i , css ) {
3168- return ( ( css . baseVal || css ) . match ( new RegExp ( '(^|\\s)' + CLASS_PREFIX + '-\\S+' , 'g' ) ) || [ ] ) . join ( ' ' ) ;
3169- }
31703170 } , {
31713171 key : '_fixTitle' ,
31723172 value : function _fixTitle ( ) {
0 commit comments