MDL-64887 theme_boost: update bootstrap to 4.3.1
authorBas Brands <bas@moodle.com>
Mon, 18 Feb 2019 13:03:08 +0000 (14:03 +0100)
committerBas Brands <bas@moodle.com>
Mon, 22 Jul 2019 06:57:04 +0000 (08:57 +0200)
116 files changed:
.eslintignore
.stylelintignore
theme/boost/amd/build/alert.min.js
theme/boost/amd/build/button.min.js
theme/boost/amd/build/carousel.min.js
theme/boost/amd/build/collapse.min.js
theme/boost/amd/build/dropdown.min.js
theme/boost/amd/build/index.min.js [new file with mode: 0644]
theme/boost/amd/build/modal.min.js
theme/boost/amd/build/pending.min.js
theme/boost/amd/build/popover.min.js
theme/boost/amd/build/sanitizer.min.js [new file with mode: 0644]
theme/boost/amd/build/scrollspy.min.js
theme/boost/amd/build/tab.min.js
theme/boost/amd/build/toast.min.js [new file with mode: 0644]
theme/boost/amd/build/tooltip.min.js
theme/boost/amd/build/util.min.js
theme/boost/amd/src/alert.js
theme/boost/amd/src/button.js
theme/boost/amd/src/carousel.js
theme/boost/amd/src/collapse.js
theme/boost/amd/src/dropdown.js
theme/boost/amd/src/index.js [new file with mode: 0644]
theme/boost/amd/src/modal.js
theme/boost/amd/src/pending.js
theme/boost/amd/src/popover.js
theme/boost/amd/src/sanitizer.js [new file with mode: 0644]
theme/boost/amd/src/scrollspy.js
theme/boost/amd/src/tab.js
theme/boost/amd/src/toast.js [new file with mode: 0644]
theme/boost/amd/src/tooltip.js
theme/boost/amd/src/util.js
theme/boost/readme_moodle.txt
theme/boost/scss/bootstrap/LICENSE [deleted file]
theme/boost/scss/bootstrap/_alert.scss
theme/boost/scss/bootstrap/_badge.scss
theme/boost/scss/bootstrap/_breadcrumb.scss
theme/boost/scss/bootstrap/_button-group.scss
theme/boost/scss/bootstrap/_buttons.scss
theme/boost/scss/bootstrap/_card.scss
theme/boost/scss/bootstrap/_carousel.scss
theme/boost/scss/bootstrap/_close.scss
theme/boost/scss/bootstrap/_code.scss
theme/boost/scss/bootstrap/_custom-forms.scss
theme/boost/scss/bootstrap/_dropdown.scss
theme/boost/scss/bootstrap/_forms.scss
theme/boost/scss/bootstrap/_functions.scss
theme/boost/scss/bootstrap/_images.scss
theme/boost/scss/bootstrap/_input-group.scss
theme/boost/scss/bootstrap/_jumbotron.scss
theme/boost/scss/bootstrap/_list-group.scss
theme/boost/scss/bootstrap/_mixins.scss
theme/boost/scss/bootstrap/_modal.scss
theme/boost/scss/bootstrap/_nav.scss
theme/boost/scss/bootstrap/_navbar.scss
theme/boost/scss/bootstrap/_pagination.scss
theme/boost/scss/bootstrap/_popover.scss
theme/boost/scss/bootstrap/_print.scss
theme/boost/scss/bootstrap/_progress.scss
theme/boost/scss/bootstrap/_reboot.scss
theme/boost/scss/bootstrap/_spinners.scss [new file with mode: 0644]
theme/boost/scss/bootstrap/_tables.scss
theme/boost/scss/bootstrap/_toasts.scss [new file with mode: 0644]
theme/boost/scss/bootstrap/_tooltip.scss
theme/boost/scss/bootstrap/_transitions.scss
theme/boost/scss/bootstrap/_type.scss
theme/boost/scss/bootstrap/_utilities.scss
theme/boost/scss/bootstrap/_variables.scss
theme/boost/scss/bootstrap/bootstrap-grid.scss
theme/boost/scss/bootstrap/bootstrap-reboot.scss
theme/boost/scss/bootstrap/bootstrap.scss
theme/boost/scss/bootstrap/mixins/_badge.scss
theme/boost/scss/bootstrap/mixins/_border-radius.scss
theme/boost/scss/bootstrap/mixins/_box-shadow.scss
theme/boost/scss/bootstrap/mixins/_breakpoints.scss
theme/boost/scss/bootstrap/mixins/_buttons.scss
theme/boost/scss/bootstrap/mixins/_caret.scss
theme/boost/scss/bootstrap/mixins/_deprecate.scss [new file with mode: 0644]
theme/boost/scss/bootstrap/mixins/_float.scss
theme/boost/scss/bootstrap/mixins/_forms.scss
theme/boost/scss/bootstrap/mixins/_gradients.scss
theme/boost/scss/bootstrap/mixins/_grid-framework.scss
theme/boost/scss/bootstrap/mixins/_grid.scss
theme/boost/scss/bootstrap/mixins/_hover.scss
theme/boost/scss/bootstrap/mixins/_image.scss
theme/boost/scss/bootstrap/mixins/_list-group.scss
theme/boost/scss/bootstrap/mixins/_nav-divider.scss
theme/boost/scss/bootstrap/mixins/_navbar-align.scss [deleted file]
theme/boost/scss/bootstrap/mixins/_pagination.scss
theme/boost/scss/bootstrap/mixins/_reset-text.scss
theme/boost/scss/bootstrap/mixins/_screen-reader.scss
theme/boost/scss/bootstrap/mixins/_size.scss
theme/boost/scss/bootstrap/mixins/_table-row.scss
theme/boost/scss/bootstrap/mixins/_text-emphasis.scss
theme/boost/scss/bootstrap/mixins/_text-hide.scss
theme/boost/scss/bootstrap/mixins/_transition.scss
theme/boost/scss/bootstrap/mixins/_visibility.scss
theme/boost/scss/bootstrap/utilities/_borders.scss
theme/boost/scss/bootstrap/utilities/_display.scss
theme/boost/scss/bootstrap/utilities/_embed.scss
theme/boost/scss/bootstrap/utilities/_flex.scss
theme/boost/scss/bootstrap/utilities/_float.scss
theme/boost/scss/bootstrap/utilities/_overflow.scss [new file with mode: 0644]
theme/boost/scss/bootstrap/utilities/_position.scss
theme/boost/scss/bootstrap/utilities/_shadows.scss [new file with mode: 0644]
theme/boost/scss/bootstrap/utilities/_sizing.scss
theme/boost/scss/bootstrap/utilities/_spacing.scss
theme/boost/scss/bootstrap/utilities/_stretched-link.scss [new file with mode: 0644]
theme/boost/scss/bootstrap/utilities/_text.scss
theme/boost/scss/bootstrap/utilities/_visibility.scss
theme/boost/scss/bootstrap/vendor/_rfs.scss [new file with mode: 0644]
theme/boost/scss/moodle/bs4alphacompat.scss
theme/boost/scss/moodle/core.scss
theme/boost/style/moodle.css
theme/boost/thirdpartylibs.xml
theme/classic/style/moodle.css

index bb36d0c..343a402 100644 (file)
@@ -74,10 +74,13 @@ theme/boost/amd/src/button.js
 theme/boost/amd/src/carousel.js
 theme/boost/amd/src/collapse.js
 theme/boost/amd/src/dropdown.js
+theme/boost/amd/src/index.js
 theme/boost/amd/src/modal.js
 theme/boost/amd/src/popover.js
+theme/boost/amd/src/sanitizer.js
 theme/boost/amd/src/scrollspy.js
 theme/boost/amd/src/tab.js
+theme/boost/amd/src/toast.js
 theme/boost/amd/src/tooltip.js
 theme/boost/amd/src/util.js
 theme/boost/amd/src/tether.js
index adf95b6..2754b7a 100644 (file)
@@ -75,10 +75,13 @@ theme/boost/amd/src/button.js
 theme/boost/amd/src/carousel.js
 theme/boost/amd/src/collapse.js
 theme/boost/amd/src/dropdown.js
+theme/boost/amd/src/index.js
 theme/boost/amd/src/modal.js
 theme/boost/amd/src/popover.js
+theme/boost/amd/src/sanitizer.js
 theme/boost/amd/src/scrollspy.js
 theme/boost/amd/src/tab.js
+theme/boost/amd/src/toast.js
 theme/boost/amd/src/tooltip.js
 theme/boost/amd/src/util.js
 theme/boost/amd/src/tether.js
index 353d0e1..7e5873b 100644 (file)
Binary files a/theme/boost/amd/build/alert.min.js and b/theme/boost/amd/build/alert.min.js differ
index c6accae..662e61d 100644 (file)
Binary files a/theme/boost/amd/build/button.min.js and b/theme/boost/amd/build/button.min.js differ
index 01e27a3..5aeb51d 100644 (file)
Binary files a/theme/boost/amd/build/carousel.min.js and b/theme/boost/amd/build/carousel.min.js differ
index 8a8c513..720ace9 100644 (file)
Binary files a/theme/boost/amd/build/collapse.min.js and b/theme/boost/amd/build/collapse.min.js differ
index a16ef02..2c6fd0c 100644 (file)
Binary files a/theme/boost/amd/build/dropdown.min.js and b/theme/boost/amd/build/dropdown.min.js differ
diff --git a/theme/boost/amd/build/index.min.js b/theme/boost/amd/build/index.min.js
new file mode 100644 (file)
index 0000000..577f992
Binary files /dev/null and b/theme/boost/amd/build/index.min.js differ
index 9488c37..033d933 100644 (file)
Binary files a/theme/boost/amd/build/modal.min.js and b/theme/boost/amd/build/modal.min.js differ
index 9174b51..4c54a93 100644 (file)
Binary files a/theme/boost/amd/build/pending.min.js and b/theme/boost/amd/build/pending.min.js differ
index 62618d7..37938c7 100644 (file)
Binary files a/theme/boost/amd/build/popover.min.js and b/theme/boost/amd/build/popover.min.js differ
diff --git a/theme/boost/amd/build/sanitizer.min.js b/theme/boost/amd/build/sanitizer.min.js
new file mode 100644 (file)
index 0000000..f318ed7
Binary files /dev/null and b/theme/boost/amd/build/sanitizer.min.js differ
index fa81832..9178603 100644 (file)
Binary files a/theme/boost/amd/build/scrollspy.min.js and b/theme/boost/amd/build/scrollspy.min.js differ
index 60751e6..7fbaecf 100644 (file)
Binary files a/theme/boost/amd/build/tab.min.js and b/theme/boost/amd/build/tab.min.js differ
diff --git a/theme/boost/amd/build/toast.min.js b/theme/boost/amd/build/toast.min.js
new file mode 100644 (file)
index 0000000..eccf5d2
Binary files /dev/null and b/theme/boost/amd/build/toast.min.js differ
index 01e07a1..40e96b3 100644 (file)
Binary files a/theme/boost/amd/build/tooltip.min.js and b/theme/boost/amd/build/tooltip.min.js differ
index 3ecdb77..6398795 100644 (file)
Binary files a/theme/boost/amd/build/util.min.js and b/theme/boost/amd/build/util.min.js differ
index 4d3065e..a1f927f 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   "use strict";
 
@@ -38,179 +40,174 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): alert.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var Alert = function ($) {
+  var NAME = 'alert';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.alert';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var DATA_API_KEY = '.data-api';
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var Selector = {
+    DISMISS: '[data-dismiss="alert"]'
+  };
+  var Event = {
+    CLOSE: "close".concat(EVENT_KEY),
+    CLOSED: "closed".concat(EVENT_KEY),
+    CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
+  };
+  var ClassName = {
+    ALERT: 'alert',
+    FADE: 'fade',
+    SHOW: 'show'
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'alert';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.alert';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var DATA_API_KEY = '.data-api';
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var TRANSITION_DURATION = 150;
-    var Selector = {
-      DISMISS: '[data-dismiss="alert"]'
-    };
-    var Event = {
-      CLOSE: "close".concat(EVENT_KEY),
-      CLOSED: "closed".concat(EVENT_KEY),
-      CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
-    };
-    var ClassName = {
-      ALERT: 'alert',
-      FADE: 'fade',
-      SHOW: 'show'
-      /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
-       */
-
-    };
 
-    var Alert = function () {
-      function Alert(element) {
-        _classCallCheck(this, Alert);
+  };
 
-        this._element = element;
-      } // Getters
+  var Alert = function () {
+    function Alert(element) {
+      _classCallCheck(this, Alert);
 
+      this._element = element;
+    } // Getters
 
-      _createClass(Alert, [{
-        key: "close",
-        value: function close(element) {
-          element = element || this._element;
 
-          var rootElement = this._getRootElement(element);
+    _createClass(Alert, [{
+      key: "close",
+      value: function close(element) {
+        var rootElement = this._element;
 
-          var customEvent = this._triggerCloseEvent(rootElement);
+        if (element) {
+          rootElement = this._getRootElement(element);
+        }
 
-          if (customEvent.isDefaultPrevented()) {
-            return;
-          }
+        var customEvent = this._triggerCloseEvent(rootElement);
 
-          this._removeElement(rootElement);
-        }
-      }, {
-        key: "dispose",
-        value: function dispose() {
-          $.removeData(this._element, DATA_KEY);
-          this._element = null;
+        if (customEvent.isDefaultPrevented()) {
+          return;
         }
-      }, {
-        key: "_getRootElement",
-        value: function _getRootElement(element) {
-          var selector = _util2.default.getSelectorFromElement(element);
 
-          var parent = false;
+        this._removeElement(rootElement);
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        _jquery2.default.removeData(this._element, DATA_KEY);
 
-          if (selector) {
-            parent = $(selector)[0];
-          }
+        this._element = null;
+      }
+    }, {
+      key: "_getRootElement",
+      value: function _getRootElement(element) {
+        var selector = _util2.default.getSelectorFromElement(element);
 
-          if (!parent) {
-            parent = $(element).closest(".".concat(ClassName.ALERT))[0];
-          }
+        var parent = false;
 
-          return parent;
+        if (selector) {
+          parent = document.querySelector(selector);
         }
-      }, {
-        key: "_triggerCloseEvent",
-        value: function _triggerCloseEvent(element) {
-          var closeEvent = $.Event(Event.CLOSE);
-          $(element).trigger(closeEvent);
-          return closeEvent;
+
+        if (!parent) {
+          parent = (0, _jquery2.default)(element).closest(".".concat(ClassName.ALERT))[0];
         }
-      }, {
-        key: "_removeElement",
-        value: function _removeElement(element) {
-          var _this = this;
 
-          $(element).removeClass(ClassName.SHOW);
+        return parent;
+      }
+    }, {
+      key: "_triggerCloseEvent",
+      value: function _triggerCloseEvent(element) {
+        var closeEvent = _jquery2.default.Event(Event.CLOSE);
 
-          if (!_util2.default.supportsTransitionEnd() || !$(element).hasClass(ClassName.FADE)) {
-            this._destroyElement(element);
+        (0, _jquery2.default)(element).trigger(closeEvent);
+        return closeEvent;
+      }
+    }, {
+      key: "_removeElement",
+      value: function _removeElement(element) {
+        var _this = this;
 
-            return;
-          }
+        (0, _jquery2.default)(element).removeClass(ClassName.SHOW);
 
-          $(element).one(_util2.default.TRANSITION_END, function (event) {
-            return _this._destroyElement(element, event);
-          }).emulateTransitionEnd(TRANSITION_DURATION);
-        }
-      }, {
-        key: "_destroyElement",
-        value: function _destroyElement(element) {
-          $(element).detach().trigger(Event.CLOSED).remove();
-        }
-      }], [{
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config) {
-          return this.each(function () {
-            var $element = $(this);
-            var data = $element.data(DATA_KEY);
-
-            if (!data) {
-              data = new Alert(this);
-              $element.data(DATA_KEY, data);
-            }
-
-            if (config === 'close') {
-              data[config](this);
-            }
-          });
-        }
-      }, {
-        key: "_handleDismiss",
-        value: function _handleDismiss(alertInstance) {
-          return function (event) {
-            if (event) {
-              event.preventDefault();
-            }
-
-            alertInstance.close(this);
-          };
-        }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
-        }
-      }]);
+        if (!(0, _jquery2.default)(element).hasClass(ClassName.FADE)) {
+          this._destroyElement(element);
 
-      return Alert;
-    }();
+          return;
+        }
 
-    /**
-     * ------------------------------------------------------------------------
-     * Data Api implementation
-     * ------------------------------------------------------------------------
-     */
-    $(document).on(Event.CLICK_DATA_API, Selector.DISMISS, Alert._handleDismiss(new Alert()));
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
+        var transitionDuration = _util2.default.getTransitionDurationFromElement(element);
+
+        (0, _jquery2.default)(element).one(_util2.default.TRANSITION_END, function (event) {
+          return _this._destroyElement(element, event);
+        }).emulateTransitionEnd(transitionDuration);
+      }
+    }, {
+      key: "_destroyElement",
+      value: function _destroyElement(element) {
+        (0, _jquery2.default)(element).detach().trigger(Event.CLOSED).remove();
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var $element = (0, _jquery2.default)(this);
+          var data = $element.data(DATA_KEY);
+
+          if (!data) {
+            data = new Alert(this);
+            $element.data(DATA_KEY, data);
+          }
 
-    $.fn[NAME] = Alert._jQueryInterface;
-    $.fn[NAME].Constructor = Alert;
+          if (config === 'close') {
+            data[config](this);
+          }
+        });
+      }
+    }, {
+      key: "_handleDismiss",
+      value: function _handleDismiss(alertInstance) {
+        return function (event) {
+          if (event) {
+            event.preventDefault();
+          }
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return Alert._jQueryInterface;
-    };
+          alertInstance.close(this);
+        };
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }]);
 
     return Alert;
-  }(_jquery2.default);
+  }();
+
+  /**
+   * ------------------------------------------------------------------------
+   * Data Api implementation
+   * ------------------------------------------------------------------------
+   */
+  (0, _jquery2.default)(document).on(Event.CLICK_DATA_API, Selector.DISMISS, Alert._handleDismiss(new Alert()));
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
+
+  _jquery2.default.fn[NAME] = Alert._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Alert;
+
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Alert._jQueryInterface;
+  };
 
   exports.default = Alert;
 });
\ No newline at end of file
index 00a407a..7cb7f69 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery"], function (exports, _jquery) {
   "use strict";
 
@@ -36,165 +38,156 @@ define(["exports", "jquery"], function (exports, _jquery) {
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): button.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var Button = function ($) {
+  var NAME = 'button';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.button';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var DATA_API_KEY = '.data-api';
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var ClassName = {
+    ACTIVE: 'active',
+    BUTTON: 'btn',
+    FOCUS: 'focus'
+  };
+  var Selector = {
+    DATA_TOGGLE_CARROT: '[data-toggle^="button"]',
+    DATA_TOGGLE: '[data-toggle="buttons"]',
+    INPUT: 'input:not([type="hidden"])',
+    ACTIVE: '.active',
+    BUTTON: '.btn'
+  };
+  var Event = {
+    CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY),
+    FOCUS_BLUR_DATA_API: "focus".concat(EVENT_KEY).concat(DATA_API_KEY, " ") + "blur".concat(EVENT_KEY).concat(DATA_API_KEY)
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'button';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.button';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var DATA_API_KEY = '.data-api';
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var ClassName = {
-      ACTIVE: 'active',
-      BUTTON: 'btn',
-      FOCUS: 'focus'
-    };
-    var Selector = {
-      DATA_TOGGLE_CARROT: '[data-toggle^="button"]',
-      DATA_TOGGLE: '[data-toggle="buttons"]',
-      INPUT: 'input',
-      ACTIVE: '.active',
-      BUTTON: '.btn'
-    };
-    var Event = {
-      CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY),
-      FOCUS_BLUR_DATA_API: "focus".concat(EVENT_KEY).concat(DATA_API_KEY, " ") + "blur".concat(EVENT_KEY).concat(DATA_API_KEY)
-      /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
-       */
 
-    };
+  };
 
-    var Button = function () {
-      function Button(element) {
-        _classCallCheck(this, Button);
+  var Button = function () {
+    function Button(element) {
+      _classCallCheck(this, Button);
 
-        this._element = element;
-      } // Getters
+      this._element = element;
+    } // Getters
 
 
-      _createClass(Button, [{
-        key: "toggle",
-        value: function toggle() {
-          var triggerChangeEvent = true;
-          var addAriaPressed = true;
-          var rootElement = $(this._element).closest(Selector.DATA_TOGGLE)[0];
+    _createClass(Button, [{
+      key: "toggle",
+      value: function toggle() {
+        var triggerChangeEvent = true;
+        var addAriaPressed = true;
+        var rootElement = (0, _jquery2.default)(this._element).closest(Selector.DATA_TOGGLE)[0];
 
-          if (rootElement) {
-            var input = $(this._element).find(Selector.INPUT)[0];
+        if (rootElement) {
+          var input = this._element.querySelector(Selector.INPUT);
 
-            if (input) {
-              if (input.type === 'radio') {
-                if (input.checked && $(this._element).hasClass(ClassName.ACTIVE)) {
-                  triggerChangeEvent = false;
-                } else {
-                  var activeElement = $(rootElement).find(Selector.ACTIVE)[0];
+          if (input) {
+            if (input.type === 'radio') {
+              if (input.checked && this._element.classList.contains(ClassName.ACTIVE)) {
+                triggerChangeEvent = false;
+              } else {
+                var activeElement = rootElement.querySelector(Selector.ACTIVE);
 
-                  if (activeElement) {
-                    $(activeElement).removeClass(ClassName.ACTIVE);
-                  }
+                if (activeElement) {
+                  (0, _jquery2.default)(activeElement).removeClass(ClassName.ACTIVE);
                 }
               }
+            }
 
-              if (triggerChangeEvent) {
-                if (input.hasAttribute('disabled') || rootElement.hasAttribute('disabled') || input.classList.contains('disabled') || rootElement.classList.contains('disabled')) {
-                  return;
-                }
-
-                input.checked = !$(this._element).hasClass(ClassName.ACTIVE);
-                $(input).trigger('change');
+            if (triggerChangeEvent) {
+              if (input.hasAttribute('disabled') || rootElement.hasAttribute('disabled') || input.classList.contains('disabled') || rootElement.classList.contains('disabled')) {
+                return;
               }
 
-              input.focus();
-              addAriaPressed = false;
+              input.checked = !this._element.classList.contains(ClassName.ACTIVE);
+              (0, _jquery2.default)(input).trigger('change');
             }
-          }
-
-          if (addAriaPressed) {
-            this._element.setAttribute('aria-pressed', !$(this._element).hasClass(ClassName.ACTIVE));
-          }
 
-          if (triggerChangeEvent) {
-            $(this._element).toggleClass(ClassName.ACTIVE);
+            input.focus();
+            addAriaPressed = false;
           }
         }
-      }, {
-        key: "dispose",
-        value: function dispose() {
-          $.removeData(this._element, DATA_KEY);
-          this._element = null;
-        }
-      }], [{
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config) {
-          return this.each(function () {
-            var data = $(this).data(DATA_KEY);
-
-            if (!data) {
-              data = new Button(this);
-              $(this).data(DATA_KEY, data);
-            }
 
-            if (config === 'toggle') {
-              data[config]();
-            }
-          });
+        if (addAriaPressed) {
+          this._element.setAttribute('aria-pressed', !this._element.classList.contains(ClassName.ACTIVE));
         }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
-        }
-      }]);
 
-      return Button;
-    }();
+        if (triggerChangeEvent) {
+          (0, _jquery2.default)(this._element).toggleClass(ClassName.ACTIVE);
+        }
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        _jquery2.default.removeData(this._element, DATA_KEY);
 
-    /**
-     * ------------------------------------------------------------------------
-     * Data Api implementation
-     * ------------------------------------------------------------------------
-     */
-    $(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE_CARROT, function (event) {
-      event.preventDefault();
-      var button = event.target;
+        this._element = null;
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var data = (0, _jquery2.default)(this).data(DATA_KEY);
+
+          if (!data) {
+            data = new Button(this);
+            (0, _jquery2.default)(this).data(DATA_KEY, data);
+          }
 
-      if (!$(button).hasClass(ClassName.BUTTON)) {
-        button = $(button).closest(Selector.BUTTON);
+          if (config === 'toggle') {
+            data[config]();
+          }
+        });
       }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }]);
 
-      Button._jQueryInterface.call($(button), 'toggle');
-    }).on(Event.FOCUS_BLUR_DATA_API, Selector.DATA_TOGGLE_CARROT, function (event) {
-      var button = $(event.target).closest(Selector.BUTTON)[0];
-      $(button).toggleClass(ClassName.FOCUS, /^focus(in)?$/.test(event.type));
-    });
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
+    return Button;
+  }();
 
-    $.fn[NAME] = Button._jQueryInterface;
-    $.fn[NAME].Constructor = Button;
+  /**
+   * ------------------------------------------------------------------------
+   * Data Api implementation
+   * ------------------------------------------------------------------------
+   */
+  (0, _jquery2.default)(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE_CARROT, function (event) {
+    event.preventDefault();
+    var button = event.target;
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return Button._jQueryInterface;
-    };
+    if (!(0, _jquery2.default)(button).hasClass(ClassName.BUTTON)) {
+      button = (0, _jquery2.default)(button).closest(Selector.BUTTON);
+    }
 
-    return Button;
-  }(_jquery2.default);
+    Button._jQueryInterface.call((0, _jquery2.default)(button), 'toggle');
+  }).on(Event.FOCUS_BLUR_DATA_API, Selector.DATA_TOGGLE_CARROT, function (event) {
+    var button = (0, _jquery2.default)(event.target).closest(Selector.BUTTON)[0];
+    (0, _jquery2.default)(button).toggleClass(ClassName.FOCUS, /^focus(in)?$/.test(event.type));
+  });
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
+
+  _jquery2.default.fn[NAME] = Button._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Button;
+
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Button._jQueryInterface;
+  };
 
   exports.default = Button;
 });
\ No newline at end of file
index c1a9e67..cb712f9 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   "use strict";
 
@@ -29,22 +31,38 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
     return _typeof(obj);
   }
 
-  function _extends() {
-    _extends = Object.assign || function (target) {
-      for (var i = 1; i < arguments.length; i++) {
-        var source = arguments[i];
+  function _objectSpread(target) {
+    for (var i = 1; i < arguments.length; i++) {
+      var source = arguments[i] != null ? arguments[i] : {};
+      var ownKeys = Object.keys(source);
 
-        for (var key in source) {
-          if (Object.prototype.hasOwnProperty.call(source, key)) {
-            target[key] = source[key];
-          }
-        }
+      if (typeof Object.getOwnPropertySymbols === 'function') {
+        ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
+          return Object.getOwnPropertyDescriptor(source, sym).enumerable;
+        }));
       }
 
-      return target;
-    };
+      ownKeys.forEach(function (key) {
+        _defineProperty(target, key, source[key]);
+      });
+    }
+
+    return target;
+  }
+
+  function _defineProperty(obj, key, value) {
+    if (key in obj) {
+      Object.defineProperty(obj, key, {
+        value: value,
+        enumerable: true,
+        configurable: true,
+        writable: true
+      });
+    } else {
+      obj[key] = value;
+    }
 
-    return _extends.apply(this, arguments);
+    return obj;
   }
 
   function _classCallCheck(instance, Constructor) {
@@ -70,520 +88,625 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): carousel.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var Carousel = function ($) {
+  var NAME = 'carousel';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.carousel';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var DATA_API_KEY = '.data-api';
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var ARROW_LEFT_KEYCODE = 37; // KeyboardEvent.which value for left arrow key
+
+  var ARROW_RIGHT_KEYCODE = 39; // KeyboardEvent.which value for right arrow key
+
+  var TOUCHEVENT_COMPAT_WAIT = 500; // Time for mouse compat events to fire after touch
+
+  var SWIPE_THRESHOLD = 40;
+  var Default = {
+    interval: 5000,
+    keyboard: true,
+    slide: false,
+    pause: 'hover',
+    wrap: true,
+    touch: true
+  };
+  var DefaultType = {
+    interval: '(number|boolean)',
+    keyboard: 'boolean',
+    slide: '(boolean|string)',
+    pause: '(string|boolean)',
+    wrap: 'boolean',
+    touch: 'boolean'
+  };
+  var Direction = {
+    NEXT: 'next',
+    PREV: 'prev',
+    LEFT: 'left',
+    RIGHT: 'right'
+  };
+  var Event = {
+    SLIDE: "slide".concat(EVENT_KEY),
+    SLID: "slid".concat(EVENT_KEY),
+    KEYDOWN: "keydown".concat(EVENT_KEY),
+    MOUSEENTER: "mouseenter".concat(EVENT_KEY),
+    MOUSELEAVE: "mouseleave".concat(EVENT_KEY),
+    TOUCHSTART: "touchstart".concat(EVENT_KEY),
+    TOUCHMOVE: "touchmove".concat(EVENT_KEY),
+    TOUCHEND: "touchend".concat(EVENT_KEY),
+    POINTERDOWN: "pointerdown".concat(EVENT_KEY),
+    POINTERUP: "pointerup".concat(EVENT_KEY),
+    DRAG_START: "dragstart".concat(EVENT_KEY),
+    LOAD_DATA_API: "load".concat(EVENT_KEY).concat(DATA_API_KEY),
+    CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
+  };
+  var ClassName = {
+    CAROUSEL: 'carousel',
+    ACTIVE: 'active',
+    SLIDE: 'slide',
+    RIGHT: 'carousel-item-right',
+    LEFT: 'carousel-item-left',
+    NEXT: 'carousel-item-next',
+    PREV: 'carousel-item-prev',
+    ITEM: 'carousel-item',
+    POINTER_EVENT: 'pointer-event'
+  };
+  var Selector = {
+    ACTIVE: '.active',
+    ACTIVE_ITEM: '.active.carousel-item',
+    ITEM: '.carousel-item',
+    ITEM_IMG: '.carousel-item img',
+    NEXT_PREV: '.carousel-item-next, .carousel-item-prev',
+    INDICATORS: '.carousel-indicators',
+    DATA_SLIDE: '[data-slide], [data-slide-to]',
+    DATA_RIDE: '[data-ride="carousel"]'
+  };
+  var PointerType = {
+    TOUCH: 'touch',
+    PEN: 'pen'
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'carousel';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.carousel';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var DATA_API_KEY = '.data-api';
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var TRANSITION_DURATION = 600;
-    var ARROW_LEFT_KEYCODE = 37; // KeyboardEvent.which value for left arrow key
-
-    var ARROW_RIGHT_KEYCODE = 39; // KeyboardEvent.which value for right arrow key
-
-    var TOUCHEVENT_COMPAT_WAIT = 500; // Time for mouse compat events to fire after touch
-
-    var Default = {
-      interval: 5000,
-      keyboard: true,
-      slide: false,
-      pause: 'hover',
-      wrap: true
-    };
-    var DefaultType = {
-      interval: '(number|boolean)',
-      keyboard: 'boolean',
-      slide: '(boolean|string)',
-      pause: '(string|boolean)',
-      wrap: 'boolean'
-    };
-    var Direction = {
-      NEXT: 'next',
-      PREV: 'prev',
-      LEFT: 'left',
-      RIGHT: 'right'
-    };
-    var Event = {
-      SLIDE: "slide".concat(EVENT_KEY),
-      SLID: "slid".concat(EVENT_KEY),
-      KEYDOWN: "keydown".concat(EVENT_KEY),
-      MOUSEENTER: "mouseenter".concat(EVENT_KEY),
-      MOUSELEAVE: "mouseleave".concat(EVENT_KEY),
-      TOUCHEND: "touchend".concat(EVENT_KEY),
-      LOAD_DATA_API: "load".concat(EVENT_KEY).concat(DATA_API_KEY),
-      CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
-    };
-    var ClassName = {
-      CAROUSEL: 'carousel',
-      ACTIVE: 'active',
-      SLIDE: 'slide',
-      RIGHT: 'carousel-item-right',
-      LEFT: 'carousel-item-left',
-      NEXT: 'carousel-item-next',
-      PREV: 'carousel-item-prev',
-      ITEM: 'carousel-item'
-    };
-    var Selector = {
-      ACTIVE: '.active',
-      ACTIVE_ITEM: '.active.carousel-item',
-      ITEM: '.carousel-item',
-      NEXT_PREV: '.carousel-item-next, .carousel-item-prev',
-      INDICATORS: '.carousel-indicators',
-      DATA_SLIDE: '[data-slide], [data-slide-to]',
-      DATA_RIDE: '[data-ride="carousel"]'
-      /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
-       */
 
-    };
+  };
+
+  var Carousel = function () {
+    function Carousel(element, config) {
+      _classCallCheck(this, Carousel);
+
+      this._items = null;
+      this._interval = null;
+      this._activeElement = null;
+      this._isPaused = false;
+      this._isSliding = false;
+      this.touchTimeout = null;
+      this.touchStartX = 0;
+      this.touchDeltaX = 0;
+      this._config = this._getConfig(config);
+      this._element = element;
+      this._indicatorsElement = this._element.querySelector(Selector.INDICATORS);
+      this._touchSupported = 'ontouchstart' in document.documentElement || navigator.maxTouchPoints > 0;
+      this._pointerEvent = Boolean(window.PointerEvent || window.MSPointerEvent);
+
+      this._addEventListeners();
+    } // Getters
+
+
+    _createClass(Carousel, [{
+      key: "next",
+      value: function next() {
+        if (!this._isSliding) {
+          this._slide(Direction.NEXT);
+        }
+      }
+    }, {
+      key: "nextWhenVisible",
+      value: function nextWhenVisible() {
+        // Don't call next when the page isn't visible
+        // or the carousel or its parent isn't visible
+        if (!document.hidden && (0, _jquery2.default)(this._element).is(':visible') && (0, _jquery2.default)(this._element).css('visibility') !== 'hidden') {
+          this.next();
+        }
+      }
+    }, {
+      key: "prev",
+      value: function prev() {
+        if (!this._isSliding) {
+          this._slide(Direction.PREV);
+        }
+      }
+    }, {
+      key: "pause",
+      value: function pause(event) {
+        if (!event) {
+          this._isPaused = true;
+        }
 
-    var Carousel = function () {
-      function Carousel(element, config) {
-        _classCallCheck(this, Carousel);
+        if (this._element.querySelector(Selector.NEXT_PREV)) {
+          _util2.default.triggerTransitionEnd(this._element);
 
-        this._items = null;
+          this.cycle(true);
+        }
+
+        clearInterval(this._interval);
         this._interval = null;
-        this._activeElement = null;
-        this._isPaused = false;
-        this._isSliding = false;
-        this.touchTimeout = null;
-        this._config = this._getConfig(config);
-        this._element = $(element)[0];
-        this._indicatorsElement = $(this._element).find(Selector.INDICATORS)[0];
-
-        this._addEventListeners();
-      } // Getters
-
-
-      _createClass(Carousel, [{
-        key: "next",
-        value: function next() {
-          if (!this._isSliding) {
-            this._slide(Direction.NEXT);
-          }
+      }
+    }, {
+      key: "cycle",
+      value: function cycle(event) {
+        if (!event) {
+          this._isPaused = false;
         }
-      }, {
-        key: "nextWhenVisible",
-        value: function nextWhenVisible() {
-          // Don't call next when the page isn't visible
-          // or the carousel or its parent isn't visible
-          if (!document.hidden && $(this._element).is(':visible') && $(this._element).css('visibility') !== 'hidden') {
-            this.next();
-          }
+
+        if (this._interval) {
+          clearInterval(this._interval);
+          this._interval = null;
         }
-      }, {
-        key: "prev",
-        value: function prev() {
-          if (!this._isSliding) {
-            this._slide(Direction.PREV);
-          }
+
+        if (this._config.interval && !this._isPaused) {
+          this._interval = setInterval((document.visibilityState ? this.nextWhenVisible : this.next).bind(this), this._config.interval);
         }
-      }, {
-        key: "pause",
-        value: function pause(event) {
-          if (!event) {
-            this._isPaused = true;
-          }
+      }
+    }, {
+      key: "to",
+      value: function to(index) {
+        var _this = this;
 
-          if ($(this._element).find(Selector.NEXT_PREV)[0] && _util2.default.supportsTransitionEnd()) {
-            _util2.default.triggerTransitionEnd(this._element);
+        this._activeElement = this._element.querySelector(Selector.ACTIVE_ITEM);
 
-            this.cycle(true);
-          }
+        var activeIndex = this._getItemIndex(this._activeElement);
 
-          clearInterval(this._interval);
-          this._interval = null;
+        if (index > this._items.length - 1 || index < 0) {
+          return;
         }
-      }, {
-        key: "cycle",
-        value: function cycle(event) {
-          if (!event) {
-            this._isPaused = false;
-          }
 
-          if (this._interval) {
-            clearInterval(this._interval);
-            this._interval = null;
-          }
+        if (this._isSliding) {
+          (0, _jquery2.default)(this._element).one(Event.SLID, function () {
+            return _this.to(index);
+          });
+          return;
+        }
 
-          if (this._config.interval && !this._isPaused) {
-            this._interval = setInterval((document.visibilityState ? this.nextWhenVisible : this.next).bind(this), this._config.interval);
-          }
+        if (activeIndex === index) {
+          this.pause();
+          this.cycle();
+          return;
         }
-      }, {
-        key: "to",
-        value: function to(index) {
-          var _this = this;
 
-          this._activeElement = $(this._element).find(Selector.ACTIVE_ITEM)[0];
+        var direction = index > activeIndex ? Direction.NEXT : Direction.PREV;
 
-          var activeIndex = this._getItemIndex(this._activeElement);
+        this._slide(direction, this._items[index]);
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        (0, _jquery2.default)(this._element).off(EVENT_KEY);
 
-          if (index > this._items.length - 1 || index < 0) {
-            return;
-          }
+        _jquery2.default.removeData(this._element, DATA_KEY);
 
-          if (this._isSliding) {
-            $(this._element).one(Event.SLID, function () {
-              return _this.to(index);
-            });
-            return;
-          }
+        this._items = null;
+        this._config = null;
+        this._element = null;
+        this._interval = null;
+        this._isPaused = null;
+        this._isSliding = null;
+        this._activeElement = null;
+        this._indicatorsElement = null;
+      }
+    }, {
+      key: "_getConfig",
+      value: function _getConfig(config) {
+        config = _objectSpread({}, Default, config);
 
-          if (activeIndex === index) {
-            this.pause();
-            this.cycle();
-            return;
-          }
+        _util2.default.typeCheckConfig(NAME, config, DefaultType);
 
-          var direction = index > activeIndex ? Direction.NEXT : Direction.PREV;
+        return config;
+      }
+    }, {
+      key: "_handleSwipe",
+      value: function _handleSwipe() {
+        var absDeltax = Math.abs(this.touchDeltaX);
 
-          this._slide(direction, this._items[index]);
+        if (absDeltax <= SWIPE_THRESHOLD) {
+          return;
         }
-      }, {
-        key: "dispose",
-        value: function dispose() {
-          $(this._element).off(EVENT_KEY);
-          $.removeData(this._element, DATA_KEY);
-          this._items = null;
-          this._config = null;
-          this._element = null;
-          this._interval = null;
-          this._isPaused = null;
-          this._isSliding = null;
-          this._activeElement = null;
-          this._indicatorsElement = null;
+
+        var direction = absDeltax / this.touchDeltaX; // swipe left
+
+        if (direction > 0) {
+          this.prev();
+        } // swipe right
+
+
+        if (direction < 0) {
+          this.next();
+        }
+      }
+    }, {
+      key: "_addEventListeners",
+      value: function _addEventListeners() {
+        var _this2 = this;
+
+        if (this._config.keyboard) {
+          (0, _jquery2.default)(this._element).on(Event.KEYDOWN, function (event) {
+            return _this2._keydown(event);
+          });
         }
-      }, {
-        key: "_getConfig",
-        value: function _getConfig(config) {
-          config = _extends({}, Default, config);
 
-          _util2.default.typeCheckConfig(NAME, config, DefaultType);
+        if (this._config.pause === 'hover') {
+          (0, _jquery2.default)(this._element).on(Event.MOUSEENTER, function (event) {
+            return _this2.pause(event);
+          }).on(Event.MOUSELEAVE, function (event) {
+            return _this2.cycle(event);
+          });
+        }
 
-          return config;
+        if (this._config.touch) {
+          this._addTouchEventListeners();
         }
-      }, {
-        key: "_addEventListeners",
-        value: function _addEventListeners() {
-          var _this2 = this;
+      }
+    }, {
+      key: "_addTouchEventListeners",
+      value: function _addTouchEventListeners() {
+        var _this3 = this;
 
-          if (this._config.keyboard) {
-            $(this._element).on(Event.KEYDOWN, function (event) {
-              return _this2._keydown(event);
-            });
+        if (!this._touchSupported) {
+          return;
+        }
+
+        var start = function start(event) {
+          if (_this3._pointerEvent && PointerType[event.originalEvent.pointerType.toUpperCase()]) {
+            _this3.touchStartX = event.originalEvent.clientX;
+          } else if (!_this3._pointerEvent) {
+            _this3.touchStartX = event.originalEvent.touches[0].clientX;
           }
+        };
 
-          if (this._config.pause === 'hover') {
-            $(this._element).on(Event.MOUSEENTER, function (event) {
-              return _this2.pause(event);
-            }).on(Event.MOUSELEAVE, function (event) {
-              return _this2.cycle(event);
-            });
-
-            if ('ontouchstart' in document.documentElement) {
-              // If it's a touch-enabled device, mouseenter/leave are fired as
-              // part of the mouse compatibility events on first tap - the carousel
-              // would stop cycling until user tapped out of it;
-              // here, we listen for touchend, explicitly pause the carousel
-              // (as if it's the second time we tap on it, mouseenter compat event
-              // is NOT fired) and after a timeout (to allow for mouse compatibility
-              // events to fire) we explicitly restart cycling
-              $(this._element).on(Event.TOUCHEND, function () {
-                _this2.pause();
-
-                if (_this2.touchTimeout) {
-                  clearTimeout(_this2.touchTimeout);
-                }
-
-                _this2.touchTimeout = setTimeout(function (event) {
-                  return _this2.cycle(event);
-                }, TOUCHEVENT_COMPAT_WAIT + _this2._config.interval);
-              });
-            }
+        var move = function move(event) {
+          // ensure swiping with one touch and not pinching
+          if (event.originalEvent.touches && event.originalEvent.touches.length > 1) {
+            _this3.touchDeltaX = 0;
+          } else {
+            _this3.touchDeltaX = event.originalEvent.touches[0].clientX - _this3.touchStartX;
           }
-        }
-      }, {
-        key: "_keydown",
-        value: function _keydown(event) {
-          if (/input|textarea/i.test(event.target.tagName)) {
-            return;
+        };
+
+        var end = function end(event) {
+          if (_this3._pointerEvent && PointerType[event.originalEvent.pointerType.toUpperCase()]) {
+            _this3.touchDeltaX = event.originalEvent.clientX - _this3.touchStartX;
           }
 
-          switch (event.which) {
-            case ARROW_LEFT_KEYCODE:
-              event.preventDefault();
-              this.prev();
-              break;
+          _this3._handleSwipe();
+
+          if (_this3._config.pause === 'hover') {
+            // If it's a touch-enabled device, mouseenter/leave are fired as
+            // part of the mouse compatibility events on first tap - the carousel
+            // would stop cycling until user tapped out of it;
+            // here, we listen for touchend, explicitly pause the carousel
+            // (as if it's the second time we tap on it, mouseenter compat event
+            // is NOT fired) and after a timeout (to allow for mouse compatibility
+            // events to fire) we explicitly restart cycling
+            _this3.pause();
 
-            case ARROW_RIGHT_KEYCODE:
-              event.preventDefault();
-              this.next();
-              break;
+            if (_this3.touchTimeout) {
+              clearTimeout(_this3.touchTimeout);
+            }
 
-            default:
+            _this3.touchTimeout = setTimeout(function (event) {
+              return _this3.cycle(event);
+            }, TOUCHEVENT_COMPAT_WAIT + _this3._config.interval);
           }
+        };
+
+        (0, _jquery2.default)(this._element.querySelectorAll(Selector.ITEM_IMG)).on(Event.DRAG_START, function (e) {
+          return e.preventDefault();
+        });
+
+        if (this._pointerEvent) {
+          (0, _jquery2.default)(this._element).on(Event.POINTERDOWN, function (event) {
+            return start(event);
+          });
+          (0, _jquery2.default)(this._element).on(Event.POINTERUP, function (event) {
+            return end(event);
+          });
+
+          this._element.classList.add(ClassName.POINTER_EVENT);
+        } else {
+          (0, _jquery2.default)(this._element).on(Event.TOUCHSTART, function (event) {
+            return start(event);
+          });
+          (0, _jquery2.default)(this._element).on(Event.TOUCHMOVE, function (event) {
+            return move(event);
+          });
+          (0, _jquery2.default)(this._element).on(Event.TOUCHEND, function (event) {
+            return end(event);
+          });
         }
-      }, {
-        key: "_getItemIndex",
-        value: function _getItemIndex(element) {
-          this._items = $.makeArray($(element).parent().find(Selector.ITEM));
-          return this._items.indexOf(element);
+      }
+    }, {
+      key: "_keydown",
+      value: function _keydown(event) {
+        if (/input|textarea/i.test(event.target.tagName)) {
+          return;
         }
-      }, {
-        key: "_getItemByDirection",
-        value: function _getItemByDirection(direction, activeElement) {
-          var isNextDirection = direction === Direction.NEXT;
-          var isPrevDirection = direction === Direction.PREV;
 
-          var activeIndex = this._getItemIndex(activeElement);
+        switch (event.which) {
+          case ARROW_LEFT_KEYCODE:
+            event.preventDefault();
+            this.prev();
+            break;
 
-          var lastItemIndex = this._items.length - 1;
-          var isGoingToWrap = isPrevDirection && activeIndex === 0 || isNextDirection && activeIndex === lastItemIndex;
-
-          if (isGoingToWrap && !this._config.wrap) {
-            return activeElement;
-          }
+          case ARROW_RIGHT_KEYCODE:
+            event.preventDefault();
+            this.next();
+            break;
 
-          var delta = direction === Direction.PREV ? -1 : 1;
-          var itemIndex = (activeIndex + delta) % this._items.length;
-          return itemIndex === -1 ? this._items[this._items.length - 1] : this._items[itemIndex];
+          default:
         }
-      }, {
-        key: "_triggerSlideEvent",
-        value: function _triggerSlideEvent(relatedTarget, eventDirectionName) {
-          var targetIndex = this._getItemIndex(relatedTarget);
+      }
+    }, {
+      key: "_getItemIndex",
+      value: function _getItemIndex(element) {
+        this._items = element && element.parentNode ? [].slice.call(element.parentNode.querySelectorAll(Selector.ITEM)) : [];
+        return this._items.indexOf(element);
+      }
+    }, {
+      key: "_getItemByDirection",
+      value: function _getItemByDirection(direction, activeElement) {
+        var isNextDirection = direction === Direction.NEXT;
+        var isPrevDirection = direction === Direction.PREV;
 
-          var fromIndex = this._getItemIndex($(this._element).find(Selector.ACTIVE_ITEM)[0]);
+        var activeIndex = this._getItemIndex(activeElement);
 
-          var slideEvent = $.Event(Event.SLIDE, {
-            relatedTarget: relatedTarget,
-            direction: eventDirectionName,
-            from: fromIndex,
-            to: targetIndex
-          });
-          $(this._element).trigger(slideEvent);
-          return slideEvent;
+        var lastItemIndex = this._items.length - 1;
+        var isGoingToWrap = isPrevDirection && activeIndex === 0 || isNextDirection && activeIndex === lastItemIndex;
+
+        if (isGoingToWrap && !this._config.wrap) {
+          return activeElement;
         }
-      }, {
-        key: "_setActiveIndicatorElement",
-        value: function _setActiveIndicatorElement(element) {
-          if (this._indicatorsElement) {
-            $(this._indicatorsElement).find(Selector.ACTIVE).removeClass(ClassName.ACTIVE);
 
-            var nextIndicator = this._indicatorsElement.children[this._getItemIndex(element)];
+        var delta = direction === Direction.PREV ? -1 : 1;
+        var itemIndex = (activeIndex + delta) % this._items.length;
+        return itemIndex === -1 ? this._items[this._items.length - 1] : this._items[itemIndex];
+      }
+    }, {
+      key: "_triggerSlideEvent",
+      value: function _triggerSlideEvent(relatedTarget, eventDirectionName) {
+        var targetIndex = this._getItemIndex(relatedTarget);
+
+        var fromIndex = this._getItemIndex(this._element.querySelector(Selector.ACTIVE_ITEM));
+
+        var slideEvent = _jquery2.default.Event(Event.SLIDE, {
+          relatedTarget: relatedTarget,
+          direction: eventDirectionName,
+          from: fromIndex,
+          to: targetIndex
+        });
+
+        (0, _jquery2.default)(this._element).trigger(slideEvent);
+        return slideEvent;
+      }
+    }, {
+      key: "_setActiveIndicatorElement",
+      value: function _setActiveIndicatorElement(element) {
+        if (this._indicatorsElement) {
+          var indicators = [].slice.call(this._indicatorsElement.querySelectorAll(Selector.ACTIVE));
+          (0, _jquery2.default)(indicators).removeClass(ClassName.ACTIVE);
 
-            if (nextIndicator) {
-              $(nextIndicator).addClass(ClassName.ACTIVE);
-            }
+          var nextIndicator = this._indicatorsElement.children[this._getItemIndex(element)];
+
+          if (nextIndicator) {
+            (0, _jquery2.default)(nextIndicator).addClass(ClassName.ACTIVE);
           }
         }
-      }, {
-        key: "_slide",
-        value: function _slide(direction, element) {
-          var _this3 = this;
+      }
+    }, {
+      key: "_slide",
+      value: function _slide(direction, element) {
+        var _this4 = this;
 
-          var activeElement = $(this._element).find(Selector.ACTIVE_ITEM)[0];
+        var activeElement = this._element.querySelector(Selector.ACTIVE_ITEM);
 
-          var activeElementIndex = this._getItemIndex(activeElement);
+        var activeElementIndex = this._getItemIndex(activeElement);
 
-          var nextElement = element || activeElement && this._getItemByDirection(direction, activeElement);
+        var nextElement = element || activeElement && this._getItemByDirection(direction, activeElement);
 
-          var nextElementIndex = this._getItemIndex(nextElement);
+        var nextElementIndex = this._getItemIndex(nextElement);
 
-          var isCycling = Boolean(this._interval);
-          var directionalClassName;
-          var orderClassName;
-          var eventDirectionName;
+        var isCycling = Boolean(this._interval);
+        var directionalClassName;
+        var orderClassName;
+        var eventDirectionName;
 
-          if (direction === Direction.NEXT) {
-            directionalClassName = ClassName.LEFT;
-            orderClassName = ClassName.NEXT;
-            eventDirectionName = Direction.LEFT;
-          } else {
-            directionalClassName = ClassName.RIGHT;
-            orderClassName = ClassName.PREV;
-            eventDirectionName = Direction.RIGHT;
-          }
+        if (direction === Direction.NEXT) {
+          directionalClassName = ClassName.LEFT;
+          orderClassName = ClassName.NEXT;
+          eventDirectionName = Direction.LEFT;
+        } else {
+          directionalClassName = ClassName.RIGHT;
+          orderClassName = ClassName.PREV;
+          eventDirectionName = Direction.RIGHT;
+        }
 
-          if (nextElement && $(nextElement).hasClass(ClassName.ACTIVE)) {
-            this._isSliding = false;
-            return;
-          }
+        if (nextElement && (0, _jquery2.default)(nextElement).hasClass(ClassName.ACTIVE)) {
+          this._isSliding = false;
+          return;
+        }
 
-          var slideEvent = this._triggerSlideEvent(nextElement, eventDirectionName);
+        var slideEvent = this._triggerSlideEvent(nextElement, eventDirectionName);
 
-          if (slideEvent.isDefaultPrevented()) {
-            return;
-          }
+        if (slideEvent.isDefaultPrevented()) {
+          return;
+        }
 
-          if (!activeElement || !nextElement) {
-            // Some weirdness is happening, so we bail
-            return;
-          }
+        if (!activeElement || !nextElement) {
+          // Some weirdness is happening, so we bail
+          return;
+        }
 
-          this._isSliding = true;
+        this._isSliding = true;
 
-          if (isCycling) {
-            this.pause();
-          }
+        if (isCycling) {
+          this.pause();
+        }
 
-          this._setActiveIndicatorElement(nextElement);
+        this._setActiveIndicatorElement(nextElement);
 
-          var slidEvent = $.Event(Event.SLID, {
-            relatedTarget: nextElement,
-            direction: eventDirectionName,
-            from: activeElementIndex,
-            to: nextElementIndex
-          });
+        var slidEvent = _jquery2.default.Event(Event.SLID, {
+          relatedTarget: nextElement,
+          direction: eventDirectionName,
+          from: activeElementIndex,
+          to: nextElementIndex
+        });
+
+        if ((0, _jquery2.default)(this._element).hasClass(ClassName.SLIDE)) {
+          (0, _jquery2.default)(nextElement).addClass(orderClassName);
+
+          _util2.default.reflow(nextElement);
 
-          if (_util2.default.supportsTransitionEnd() && $(this._element).hasClass(ClassName.SLIDE)) {
-            $(nextElement).addClass(orderClassName);
-
-            _util2.default.reflow(nextElement);
-
-            $(activeElement).addClass(directionalClassName);
-            $(nextElement).addClass(directionalClassName);
-            $(activeElement).one(_util2.default.TRANSITION_END, function () {
-              $(nextElement).removeClass("".concat(directionalClassName, " ").concat(orderClassName)).addClass(ClassName.ACTIVE);
-              $(activeElement).removeClass("".concat(ClassName.ACTIVE, " ").concat(orderClassName, " ").concat(directionalClassName));
-              _this3._isSliding = false;
-              setTimeout(function () {
-                return $(_this3._element).trigger(slidEvent);
-              }, 0);
-            }).emulateTransitionEnd(TRANSITION_DURATION);
+          (0, _jquery2.default)(activeElement).addClass(directionalClassName);
+          (0, _jquery2.default)(nextElement).addClass(directionalClassName);
+          var nextElementInterval = parseInt(nextElement.getAttribute('data-interval'), 10);
+
+          if (nextElementInterval) {
+            this._config.defaultInterval = this._config.defaultInterval || this._config.interval;
+            this._config.interval = nextElementInterval;
           } else {
-            $(activeElement).removeClass(ClassName.ACTIVE);
-            $(nextElement).addClass(ClassName.ACTIVE);
-            this._isSliding = false;
-            $(this._element).trigger(slidEvent);
+            this._config.interval = this._config.defaultInterval || this._config.interval;
           }
 
-          if (isCycling) {
-            this.cycle();
-          }
+          var transitionDuration = _util2.default.getTransitionDurationFromElement(activeElement);
+
+          (0, _jquery2.default)(activeElement).one(_util2.default.TRANSITION_END, function () {
+            (0, _jquery2.default)(nextElement).removeClass("".concat(directionalClassName, " ").concat(orderClassName)).addClass(ClassName.ACTIVE);
+            (0, _jquery2.default)(activeElement).removeClass("".concat(ClassName.ACTIVE, " ").concat(orderClassName, " ").concat(directionalClassName));
+            _this4._isSliding = false;
+            setTimeout(function () {
+              return (0, _jquery2.default)(_this4._element).trigger(slidEvent);
+            }, 0);
+          }).emulateTransitionEnd(transitionDuration);
+        } else {
+          (0, _jquery2.default)(activeElement).removeClass(ClassName.ACTIVE);
+          (0, _jquery2.default)(nextElement).addClass(ClassName.ACTIVE);
+          this._isSliding = false;
+          (0, _jquery2.default)(this._element).trigger(slidEvent);
         }
-      }], [{
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config) {
-          return this.each(function () {
-            var data = $(this).data(DATA_KEY);
 
-            var _config = _extends({}, Default, $(this).data());
-
-            if (_typeof(config) === 'object') {
-              _config = _extends({}, _config, config);
-            }
+        if (isCycling) {
+          this.cycle();
+        }
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var data = (0, _jquery2.default)(this).data(DATA_KEY);
 
-            var action = typeof config === 'string' ? config : _config.slide;
+          var _config = _objectSpread({}, Default, (0, _jquery2.default)(this).data());
 
-            if (!data) {
-              data = new Carousel(this, _config);
-              $(this).data(DATA_KEY, data);
-            }
+          if (_typeof(config) === 'object') {
+            _config = _objectSpread({}, _config, config);
+          }
 
-            if (typeof config === 'number') {
-              data.to(config);
-            } else if (typeof action === 'string') {
-              if (typeof data[action] === 'undefined') {
-                throw new TypeError("No method named \"".concat(action, "\""));
-              }
-
-              data[action]();
-            } else if (_config.interval) {
-              data.pause();
-              data.cycle();
-            }
-          });
-        }
-      }, {
-        key: "_dataApiClickHandler",
-        value: function _dataApiClickHandler(event) {
-          var selector = _util2.default.getSelectorFromElement(this);
+          var action = typeof config === 'string' ? config : _config.slide;
 
-          if (!selector) {
-            return;
+          if (!data) {
+            data = new Carousel(this, _config);
+            (0, _jquery2.default)(this).data(DATA_KEY, data);
           }
 
-          var target = $(selector)[0];
+          if (typeof config === 'number') {
+            data.to(config);
+          } else if (typeof action === 'string') {
+            if (typeof data[action] === 'undefined') {
+              throw new TypeError("No method named \"".concat(action, "\""));
+            }
 
-          if (!target || !$(target).hasClass(ClassName.CAROUSEL)) {
-            return;
+            data[action]();
+          } else if (_config.interval && _config.ride) {
+            data.pause();
+            data.cycle();
           }
+        });
+      }
+    }, {
+      key: "_dataApiClickHandler",
+      value: function _dataApiClickHandler(event) {
+        var selector = _util2.default.getSelectorFromElement(this);
 
-          var config = _extends({}, $(target).data(), $(this).data());
+        if (!selector) {
+          return;
+        }
 
-          var slideIndex = this.getAttribute('data-slide-to');
+        var target = (0, _jquery2.default)(selector)[0];
 
-          if (slideIndex) {
-            config.interval = false;
-          }
+        if (!target || !(0, _jquery2.default)(target).hasClass(ClassName.CAROUSEL)) {
+          return;
+        }
 
-          Carousel._jQueryInterface.call($(target), config);
+        var config = _objectSpread({}, (0, _jquery2.default)(target).data(), (0, _jquery2.default)(this).data());
 
-          if (slideIndex) {
-            $(target).data(DATA_KEY).to(slideIndex);
-          }
+        var slideIndex = this.getAttribute('data-slide-to');
 
-          event.preventDefault();
+        if (slideIndex) {
+          config.interval = false;
         }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
-        }
-      }, {
-        key: "Default",
-        get: function get() {
-          return Default;
+
+        Carousel._jQueryInterface.call((0, _jquery2.default)(target), config);
+
+        if (slideIndex) {
+          (0, _jquery2.default)(target).data(DATA_KEY).to(slideIndex);
         }
-      }]);
 
-      return Carousel;
-    }();
+        event.preventDefault();
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }, {
+      key: "Default",
+      get: function get() {
+        return Default;
+      }
+    }]);
+
+    return Carousel;
+  }();
 
-    /**
-     * ------------------------------------------------------------------------
-     * Data Api implementation
-     * ------------------------------------------------------------------------
-     */
-    $(document).on(Event.CLICK_DATA_API, Selector.DATA_SLIDE, Carousel._dataApiClickHandler);
-    $(window).on(Event.LOAD_DATA_API, function () {
-      $(Selector.DATA_RIDE).each(function () {
-        var $carousel = $(this);
+  /**
+   * ------------------------------------------------------------------------
+   * Data Api implementation
+   * ------------------------------------------------------------------------
+   */
+  (0, _jquery2.default)(document).on(Event.CLICK_DATA_API, Selector.DATA_SLIDE, Carousel._dataApiClickHandler);
+  (0, _jquery2.default)(window).on(Event.LOAD_DATA_API, function () {
+    var carousels = [].slice.call(document.querySelectorAll(Selector.DATA_RIDE));
 
-        Carousel._jQueryInterface.call($carousel, $carousel.data());
-      });
-    });
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
+    for (var i = 0, len = carousels.length; i < len; i++) {
+      var $carousel = (0, _jquery2.default)(carousels[i]);
 
-    $.fn[NAME] = Carousel._jQueryInterface;
-    $.fn[NAME].Constructor = Carousel;
+      Carousel._jQueryInterface.call($carousel, $carousel.data());
+    }
+  });
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return Carousel._jQueryInterface;
-    };
+  _jquery2.default.fn[NAME] = Carousel._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Carousel;
 
-    return Carousel;
-  }(_jquery2.default);
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Carousel._jQueryInterface;
+  };
 
   exports.default = Carousel;
 });
\ No newline at end of file
index 636cd5f..415633d 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   "use strict";
 
@@ -29,22 +31,38 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
     return _typeof(obj);
   }
 
-  function _extends() {
-    _extends = Object.assign || function (target) {
-      for (var i = 1; i < arguments.length; i++) {
-        var source = arguments[i];
+  function _objectSpread(target) {
+    for (var i = 1; i < arguments.length; i++) {
+      var source = arguments[i] != null ? arguments[i] : {};
+      var ownKeys = Object.keys(source);
 
-        for (var key in source) {
-          if (Object.prototype.hasOwnProperty.call(source, key)) {
-            target[key] = source[key];
-          }
-        }
+      if (typeof Object.getOwnPropertySymbols === 'function') {
+        ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
+          return Object.getOwnPropertyDescriptor(source, sym).enumerable;
+        }));
       }
 
-      return target;
-    };
+      ownKeys.forEach(function (key) {
+        _defineProperty(target, key, source[key]);
+      });
+    }
+
+    return target;
+  }
 
-    return _extends.apply(this, arguments);
+  function _defineProperty(obj, key, value) {
+    if (key in obj) {
+      Object.defineProperty(obj, key, {
+        value: value,
+        enumerable: true,
+        configurable: true,
+        writable: true
+      });
+    } else {
+      obj[key] = value;
+    }
+
+    return obj;
   }
 
   function _classCallCheck(instance, Constructor) {
@@ -70,386 +88,384 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): collapse.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var Collapse = function ($) {
+  var NAME = 'collapse';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.collapse';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var DATA_API_KEY = '.data-api';
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var Default = {
+    toggle: true,
+    parent: ''
+  };
+  var DefaultType = {
+    toggle: 'boolean',
+    parent: '(string|element)'
+  };
+  var Event = {
+    SHOW: "show".concat(EVENT_KEY),
+    SHOWN: "shown".concat(EVENT_KEY),
+    HIDE: "hide".concat(EVENT_KEY),
+    HIDDEN: "hidden".concat(EVENT_KEY),
+    CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
+  };
+  var ClassName = {
+    SHOW: 'show',
+    COLLAPSE: 'collapse',
+    COLLAPSING: 'collapsing',
+    COLLAPSED: 'collapsed'
+  };
+  var Dimension = {
+    WIDTH: 'width',
+    HEIGHT: 'height'
+  };
+  var Selector = {
+    ACTIVES: '.show, .collapsing',
+    DATA_TOGGLE: '[data-toggle="collapse"]'
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'collapse';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.collapse';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var DATA_API_KEY = '.data-api';
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var TRANSITION_DURATION = 600;
-    var Default = {
-      toggle: true,
-      parent: ''
-    };
-    var DefaultType = {
-      toggle: 'boolean',
-      parent: '(string|element)'
-    };
-    var Event = {
-      SHOW: "show".concat(EVENT_KEY),
-      SHOWN: "shown".concat(EVENT_KEY),
-      HIDE: "hide".concat(EVENT_KEY),
-      HIDDEN: "hidden".concat(EVENT_KEY),
-      CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
-    };
-    var ClassName = {
-      SHOW: 'show',
-      COLLAPSE: 'collapse',
-      COLLAPSING: 'collapsing',
-      COLLAPSED: 'collapsed'
-    };
-    var Dimension = {
-      WIDTH: 'width',
-      HEIGHT: 'height'
-    };
-    var Selector = {
-      ACTIVES: '.show, .collapsing',
-      DATA_TOGGLE: '[data-toggle="collapse"]'
-      /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
-       */
 
-    };
+  };
 
-    var Collapse = function () {
-      function Collapse(element, config) {
-        _classCallCheck(this, Collapse);
+  var Collapse = function () {
+    function Collapse(element, config) {
+      _classCallCheck(this, Collapse);
 
-        this._isTransitioning = false;
-        this._element = element;
-        this._config = this._getConfig(config);
-        this._triggerArray = $.makeArray($("[data-toggle=\"collapse\"][href=\"#".concat(element.id, "\"],") + "[data-toggle=\"collapse\"][data-target=\"#".concat(element.id, "\"]")));
-        var tabToggles = $(Selector.DATA_TOGGLE);
+      this._isTransitioning = false;
+      this._element = element;
+      this._config = this._getConfig(config);
+      this._triggerArray = [].slice.call(document.querySelectorAll("[data-toggle=\"collapse\"][href=\"#".concat(element.id, "\"],") + "[data-toggle=\"collapse\"][data-target=\"#".concat(element.id, "\"]")));
+      var toggleList = [].slice.call(document.querySelectorAll(Selector.DATA_TOGGLE));
 
-        for (var i = 0; i < tabToggles.length; i++) {
-          var elem = tabToggles[i];
+      for (var i = 0, len = toggleList.length; i < len; i++) {
+        var elem = toggleList[i];
 
-          var selector = _util2.default.getSelectorFromElement(elem);
+        var selector = _util2.default.getSelectorFromElement(elem);
 
-          if (selector !== null && $(selector).filter(element).length > 0) {
-            this._selector = selector;
+        var filterElement = [].slice.call(document.querySelectorAll(selector)).filter(function (foundElem) {
+          return foundElem === element;
+        });
 
-            this._triggerArray.push(elem);
-          }
+        if (selector !== null && filterElement.length > 0) {
+          this._selector = selector;
+
+          this._triggerArray.push(elem);
         }
+      }
 
-        this._parent = this._config.parent ? this._getParent() : null;
+      this._parent = this._config.parent ? this._getParent() : null;
 
-        if (!this._config.parent) {
-          this._addAriaAndCollapsedClass(this._element, this._triggerArray);
-        }
+      if (!this._config.parent) {
+        this._addAriaAndCollapsedClass(this._element, this._triggerArray);
+      }
 
-        if (this._config.toggle) {
-          this.toggle();
-        }
-      } // Getters
+      if (this._config.toggle) {
+        this.toggle();
+      }
+    } // Getters
 
 
-      _createClass(Collapse, [{
-        key: "toggle",
-        value: function toggle() {
-          if ($(this._element).hasClass(ClassName.SHOW)) {
-            this.hide();
-          } else {
-            this.show();
-          }
+    _createClass(Collapse, [{
+      key: "toggle",
+      value: function toggle() {
+        if ((0, _jquery2.default)(this._element).hasClass(ClassName.SHOW)) {
+          this.hide();
+        } else {
+          this.show();
         }
-      }, {
-        key: "show",
-        value: function show() {
-          var _this = this;
-
-          if (this._isTransitioning || $(this._element).hasClass(ClassName.SHOW)) {
-            return;
-          }
+      }
+    }, {
+      key: "show",
+      value: function show() {
+        var _this = this;
 
-          var actives;
-          var activesData;
+        if (this._isTransitioning || (0, _jquery2.default)(this._element).hasClass(ClassName.SHOW)) {
+          return;
+        }
 
-          if (this._parent) {
-            actives = $.makeArray($(this._parent).find(Selector.ACTIVES).filter("[data-parent=\"".concat(this._config.parent, "\"]")));
+        var actives;
+        var activesData;
 
-            if (actives.length === 0) {
-              actives = null;
+        if (this._parent) {
+          actives = [].slice.call(this._parent.querySelectorAll(Selector.ACTIVES)).filter(function (elem) {
+            if (typeof _this._config.parent === 'string') {
+              return elem.getAttribute('data-parent') === _this._config.parent;
             }
-          }
 
-          if (actives) {
-            activesData = $(actives).not(this._selector).data(DATA_KEY);
+            return elem.classList.contains(ClassName.COLLAPSE);
+          });
 
-            if (activesData && activesData._isTransitioning) {
-              return;
-            }
+          if (actives.length === 0) {
+            actives = null;
           }
+        }
 
-          var startEvent = $.Event(Event.SHOW);
-          $(this._element).trigger(startEvent);
+        if (actives) {
+          activesData = (0, _jquery2.default)(actives).not(this._selector).data(DATA_KEY);
 
-          if (startEvent.isDefaultPrevented()) {
+          if (activesData && activesData._isTransitioning) {
             return;
           }
+        }
 
-          if (actives) {
-            Collapse._jQueryInterface.call($(actives).not(this._selector), 'hide');
+        var startEvent = _jquery2.default.Event(Event.SHOW);
 
-            if (!activesData) {
-              $(actives).data(DATA_KEY, null);
-            }
-          }
+        (0, _jquery2.default)(this._element).trigger(startEvent);
 
-          var dimension = this._getDimension();
+        if (startEvent.isDefaultPrevented()) {
+          return;
+        }
 
-          $(this._element).removeClass(ClassName.COLLAPSE).addClass(ClassName.COLLAPSING);
-          this._element.style[dimension] = 0;
+        if (actives) {
+          Collapse._jQueryInterface.call((0, _jquery2.default)(actives).not(this._selector), 'hide');
 
-          if (this._triggerArray.length > 0) {
-            $(this._triggerArray).removeClass(ClassName.COLLAPSED).attr('aria-expanded', true);
+          if (!activesData) {
+            (0, _jquery2.default)(actives).data(DATA_KEY, null);
           }
+        }
 
-          this.setTransitioning(true);
+        var dimension = this._getDimension();
 
-          var complete = function complete() {
-            $(_this._element).removeClass(ClassName.COLLAPSING).addClass(ClassName.COLLAPSE).addClass(ClassName.SHOW);
-            _this._element.style[dimension] = '';
+        (0, _jquery2.default)(this._element).removeClass(ClassName.COLLAPSE).addClass(ClassName.COLLAPSING);
+        this._element.style[dimension] = 0;
 
-            _this.setTransitioning(false);
+        if (this._triggerArray.length) {
+          (0, _jquery2.default)(this._triggerArray).removeClass(ClassName.COLLAPSED).attr('aria-expanded', true);
+        }
 
-            $(_this._element).trigger(Event.SHOWN);
-          };
+        this.setTransitioning(true);
 
-          if (!_util2.default.supportsTransitionEnd()) {
-            complete();
-            return;
-          }
+        var complete = function complete() {
+          (0, _jquery2.default)(_this._element).removeClass(ClassName.COLLAPSING).addClass(ClassName.COLLAPSE).addClass(ClassName.SHOW);
+          _this._element.style[dimension] = '';
+
+          _this.setTransitioning(false);
+
+          (0, _jquery2.default)(_this._element).trigger(Event.SHOWN);
+        };
+
+        var capitalizedDimension = dimension[0].toUpperCase() + dimension.slice(1);
+        var scrollSize = "scroll".concat(capitalizedDimension);
+
+        var transitionDuration = _util2.default.getTransitionDurationFromElement(this._element);
+
+        (0, _jquery2.default)(this._element).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
+        this._element.style[dimension] = "".concat(this._element[scrollSize], "px");
+      }
+    }, {
+      key: "hide",
+      value: function hide() {
+        var _this2 = this;
 
-          var capitalizedDimension = dimension[0].toUpperCase() + dimension.slice(1);
-          var scrollSize = "scroll".concat(capitalizedDimension);
-          $(this._element).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(TRANSITION_DURATION);
-          this._element.style[dimension] = "".concat(this._element[scrollSize], "px");
+        if (this._isTransitioning || !(0, _jquery2.default)(this._element).hasClass(ClassName.SHOW)) {
+          return;
         }
-      }, {
-        key: "hide",
-        value: function hide() {
-          var _this2 = this;
 
-          if (this._isTransitioning || !$(this._element).hasClass(ClassName.SHOW)) {
-            return;
-          }
+        var startEvent = _jquery2.default.Event(Event.HIDE);
 
-          var startEvent = $.Event(Event.HIDE);
-          $(this._element).trigger(startEvent);
+        (0, _jquery2.default)(this._element).trigger(startEvent);
 
-          if (startEvent.isDefaultPrevented()) {
-            return;
-          }
+        if (startEvent.isDefaultPrevented()) {
+          return;
+        }
 
-          var dimension = this._getDimension();
+        var dimension = this._getDimension();
 
-          this._element.style[dimension] = "".concat(this._element.getBoundingClientRect()[dimension], "px");
+        this._element.style[dimension] = "".concat(this._element.getBoundingClientRect()[dimension], "px");
 
-          _util2.default.reflow(this._element);
+        _util2.default.reflow(this._element);
 
-          $(this._element).addClass(ClassName.COLLAPSING).removeClass(ClassName.COLLAPSE).removeClass(ClassName.SHOW);
+        (0, _jquery2.default)(this._element).addClass(ClassName.COLLAPSING).removeClass(ClassName.COLLAPSE).removeClass(ClassName.SHOW);
+        var triggerArrayLength = this._triggerArray.length;
 
-          if (this._triggerArray.length > 0) {
-            for (var i = 0; i < this._triggerArray.length; i++) {
-              var trigger = this._triggerArray[i];
+        if (triggerArrayLength > 0) {
+          for (var i = 0; i < triggerArrayLength; i++) {
+            var trigger = this._triggerArray[i];
 
-              var selector = _util2.default.getSelectorFromElement(trigger);
+            var selector = _util2.default.getSelectorFromElement(trigger);
 
-              if (selector !== null) {
-                var $elem = $(selector);
+            if (selector !== null) {
+              var $elem = (0, _jquery2.default)([].slice.call(document.querySelectorAll(selector)));
 
-                if (!$elem.hasClass(ClassName.SHOW)) {
-                  $(trigger).addClass(ClassName.COLLAPSED).attr('aria-expanded', false);
-                }
+              if (!$elem.hasClass(ClassName.SHOW)) {
+                (0, _jquery2.default)(trigger).addClass(ClassName.COLLAPSED).attr('aria-expanded', false);
               }
             }
           }
+        }
 
-          this.setTransitioning(true);
+        this.setTransitioning(true);
 
-          var complete = function complete() {
-            _this2.setTransitioning(false);
+        var complete = function complete() {
+          _this2.setTransitioning(false);
 
-            $(_this2._element).removeClass(ClassName.COLLAPSING).addClass(ClassName.COLLAPSE).trigger(Event.HIDDEN);
-          };
+          (0, _jquery2.default)(_this2._element).removeClass(ClassName.COLLAPSING).addClass(ClassName.COLLAPSE).trigger(Event.HIDDEN);
+        };
 
-          this._element.style[dimension] = '';
+        this._element.style[dimension] = '';
 
-          if (!_util2.default.supportsTransitionEnd()) {
-            complete();
-            return;
-          }
+        var transitionDuration = _util2.default.getTransitionDurationFromElement(this._element);
 
-          $(this._element).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(TRANSITION_DURATION);
-        }
-      }, {
-        key: "setTransitioning",
-        value: function setTransitioning(isTransitioning) {
-          this._isTransitioning = isTransitioning;
-        }
-      }, {
-        key: "dispose",
-        value: function dispose() {
-          $.removeData(this._element, DATA_KEY);
-          this._config = null;
-          this._parent = null;
-          this._element = null;
-          this._triggerArray = null;
-          this._isTransitioning = null;
-        }
-      }, {
-        key: "_getConfig",
-        value: function _getConfig(config) {
-          config = _extends({}, Default, config);
-          config.toggle = Boolean(config.toggle); // Coerce string values
-
-          _util2.default.typeCheckConfig(NAME, config, DefaultType);
+        (0, _jquery2.default)(this._element).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
+      }
+    }, {
+      key: "setTransitioning",
+      value: function setTransitioning(isTransitioning) {
+        this._isTransitioning = isTransitioning;
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        _jquery2.default.removeData(this._element, DATA_KEY);
+
+        this._config = null;
+        this._parent = null;
+        this._element = null;
+        this._triggerArray = null;
+        this._isTransitioning = null;
+      }
+    }, {
+      key: "_getConfig",
+      value: function _getConfig(config) {
+        config = _objectSpread({}, Default, config);
+        config.toggle = Boolean(config.toggle); // Coerce string values
 
-          return config;
-        }
-      }, {
-        key: "_getDimension",
-        value: function _getDimension() {
-          var hasWidth = $(this._element).hasClass(Dimension.WIDTH);
-          return hasWidth ? Dimension.WIDTH : Dimension.HEIGHT;
-        }
-      }, {
-        key: "_getParent",
-        value: function _getParent() {
-          var _this3 = this;
+        _util2.default.typeCheckConfig(NAME, config, DefaultType);
 
-          var parent = null;
+        return config;
+      }
+    }, {
+      key: "_getDimension",
+      value: function _getDimension() {
+        var hasWidth = (0, _jquery2.default)(this._element).hasClass(Dimension.WIDTH);
+        return hasWidth ? Dimension.WIDTH : Dimension.HEIGHT;
+      }
+    }, {
+      key: "_getParent",
+      value: function _getParent() {
+        var _this3 = this;
 
-          if (_util2.default.isElement(this._config.parent)) {
-            parent = this._config.parent; // It's a jQuery object
+        var parent;
 
-            if (typeof this._config.parent.jquery !== 'undefined') {
-              parent = this._config.parent[0];
-            }
-          } else {
-            parent = $(this._config.parent)[0];
-          }
+        if (_util2.default.isElement(this._config.parent)) {
+          parent = this._config.parent; // It's a jQuery object
 
-          var selector = "[data-toggle=\"collapse\"][data-parent=\"".concat(this._config.parent, "\"]");
-          $(parent).find(selector).each(function (i, element) {
-            _this3._addAriaAndCollapsedClass(Collapse._getTargetFromElement(element), [element]);
-          });
-          return parent;
-        }
-      }, {
-        key: "_addAriaAndCollapsedClass",
-        value: function _addAriaAndCollapsedClass(element, triggerArray) {
-          if (element) {
-            var isOpen = $(element).hasClass(ClassName.SHOW);
-
-            if (triggerArray.length > 0) {
-              $(triggerArray).toggleClass(ClassName.COLLAPSED, !isOpen).attr('aria-expanded', isOpen);
-            }
+          if (typeof this._config.parent.jquery !== 'undefined') {
+            parent = this._config.parent[0];
           }
+        } else {
+          parent = document.querySelector(this._config.parent);
         }
-      }], [{
-        key: "_getTargetFromElement",
-        value: function _getTargetFromElement(element) {
-          var selector = _util2.default.getSelectorFromElement(element);
 
-          return selector ? $(selector)[0] : null;
+        var selector = "[data-toggle=\"collapse\"][data-parent=\"".concat(this._config.parent, "\"]");
+        var children = [].slice.call(parent.querySelectorAll(selector));
+        (0, _jquery2.default)(children).each(function (i, element) {
+          _this3._addAriaAndCollapsedClass(Collapse._getTargetFromElement(element), [element]);
+        });
+        return parent;
+      }
+    }, {
+      key: "_addAriaAndCollapsedClass",
+      value: function _addAriaAndCollapsedClass(element, triggerArray) {
+        var isOpen = (0, _jquery2.default)(element).hasClass(ClassName.SHOW);
+
+        if (triggerArray.length) {
+          (0, _jquery2.default)(triggerArray).toggleClass(ClassName.COLLAPSED, !isOpen).attr('aria-expanded', isOpen);
         }
-      }, {
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config) {
-          return this.each(function () {
-            var $this = $(this);
-            var data = $this.data(DATA_KEY);
+      }
+    }], [{
+      key: "_getTargetFromElement",
+      value: function _getTargetFromElement(element) {
+        var selector = _util2.default.getSelectorFromElement(element);
 
-            var _config = _extends({}, Default, $this.data(), _typeof(config) === 'object' && config);
+        return selector ? document.querySelector(selector) : null;
+      }
+    }, {
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var $this = (0, _jquery2.default)(this);
+          var data = $this.data(DATA_KEY);
 
-            if (!data && _config.toggle && /show|hide/.test(config)) {
-              _config.toggle = false;
-            }
+          var _config = _objectSpread({}, Default, $this.data(), _typeof(config) === 'object' && config ? config : {});
 
-            if (!data) {
-              data = new Collapse(this, _config);
-              $this.data(DATA_KEY, data);
-            }
+          if (!data && _config.toggle && /show|hide/.test(config)) {
+            _config.toggle = false;
+          }
 
-            if (typeof config === 'string') {
-              if (typeof data[config] === 'undefined') {
-                throw new TypeError("No method named \"".concat(config, "\""));
-              }
+          if (!data) {
+            data = new Collapse(this, _config);
+            $this.data(DATA_KEY, data);
+          }
 
-              data[config]();
+          if (typeof config === 'string') {
+            if (typeof data[config] === 'undefined') {
+              throw new TypeError("No method named \"".concat(config, "\""));
             }
-          });
-        }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
-        }
-      }, {
-        key: "Default",
-        get: function get() {
-          return Default;
-        }
-      }]);
 
-      return Collapse;
-    }();
-
-    /**
-     * ------------------------------------------------------------------------
-     * Data Api implementation
-     * ------------------------------------------------------------------------
-     */
-    $(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
-      // preventDefault only for <a> elements (which change the URL) not inside the collapsible element
-      if (event.currentTarget.tagName === 'A') {
-        event.preventDefault();
+            data[config]();
+          }
+        });
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
       }
+    }, {
+      key: "Default",
+      get: function get() {
+        return Default;
+      }
+    }]);
 
-      var $trigger = $(this);
+    return Collapse;
+  }();
 
-      var selector = _util2.default.getSelectorFromElement(this);
+  /**
+   * ------------------------------------------------------------------------
+   * Data Api implementation
+   * ------------------------------------------------------------------------
+   */
+  (0, _jquery2.default)(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
+    // preventDefault only for <a> elements (which change the URL) not inside the collapsible element
+    if (event.currentTarget.tagName === 'A') {
+      event.preventDefault();
+    }
 
-      $(selector).each(function () {
-        var $target = $(this);
-        var data = $target.data(DATA_KEY);
-        var config = data ? 'toggle' : $trigger.data();
+    var $trigger = (0, _jquery2.default)(this);
 
-        Collapse._jQueryInterface.call($target, config);
-      });
-    });
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
+    var selector = _util2.default.getSelectorFromElement(this);
 
-    $.fn[NAME] = Collapse._jQueryInterface;
-    $.fn[NAME].Constructor = Collapse;
+    var selectors = [].slice.call(document.querySelectorAll(selector));
+    (0, _jquery2.default)(selectors).each(function () {
+      var $target = (0, _jquery2.default)(this);
+      var data = $target.data(DATA_KEY);
+      var config = data ? 'toggle' : $trigger.data();
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return Collapse._jQueryInterface;
-    };
+      Collapse._jQueryInterface.call($target, config);
+    });
+  });
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
 
-    return Collapse;
-  }(_jquery2.default);
+  _jquery2.default.fn[NAME] = Collapse._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Collapse;
+
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Collapse._jQueryInterface;
+  };
 
   exports.default = Collapse;
 });
\ No newline at end of file
index 6940589..6465bec 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery", "core/popper", "./util"], function (exports, _jquery, _popper, _util) {
   "use strict";
 
@@ -31,22 +33,38 @@ define(["exports", "jquery", "core/popper", "./util"], function (exports, _jquer
     return _typeof(obj);
   }
 
-  function _extends() {
-    _extends = Object.assign || function (target) {
-      for (var i = 1; i < arguments.length; i++) {
-        var source = arguments[i];
+  function _objectSpread(target) {
+    for (var i = 1; i < arguments.length; i++) {
+      var source = arguments[i] != null ? arguments[i] : {};
+      var ownKeys = Object.keys(source);
 
-        for (var key in source) {
-          if (Object.prototype.hasOwnProperty.call(source, key)) {
-            target[key] = source[key];
-          }
-        }
+      if (typeof Object.getOwnPropertySymbols === 'function') {
+        ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
+          return Object.getOwnPropertyDescriptor(source, sym).enumerable;
+        }));
       }
 
-      return target;
-    };
+      ownKeys.forEach(function (key) {
+        _defineProperty(target, key, source[key]);
+      });
+    }
 
-    return _extends.apply(this, arguments);
+    return target;
+  }
+
+  function _defineProperty(obj, key, value) {
+    if (key in obj) {
+      Object.defineProperty(obj, key, {
+        value: value,
+        enumerable: true,
+        configurable: true,
+        writable: true
+      });
+    } else {
+      obj[key] = value;
+    }
+
+    return obj;
   }
 
   function _classCallCheck(instance, Constructor) {
@@ -72,478 +90,547 @@ define(["exports", "jquery", "core/popper", "./util"], function (exports, _jquer
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): dropdown.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var Dropdown = function ($) {
+  var NAME = 'dropdown';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.dropdown';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var DATA_API_KEY = '.data-api';
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var ESCAPE_KEYCODE = 27; // KeyboardEvent.which value for Escape (Esc) key
+
+  var SPACE_KEYCODE = 32; // KeyboardEvent.which value for space key
+
+  var TAB_KEYCODE = 9; // KeyboardEvent.which value for tab key
+
+  var ARROW_UP_KEYCODE = 38; // KeyboardEvent.which value for up arrow key
+
+  var ARROW_DOWN_KEYCODE = 40; // KeyboardEvent.which value for down arrow key
+
+  var RIGHT_MOUSE_BUTTON_WHICH = 3; // MouseEvent.which value for the right button (assuming a right-handed mouse)
+
+  var REGEXP_KEYDOWN = new RegExp("".concat(ARROW_UP_KEYCODE, "|").concat(ARROW_DOWN_KEYCODE, "|").concat(ESCAPE_KEYCODE));
+  var Event = {
+    HIDE: "hide".concat(EVENT_KEY),
+    HIDDEN: "hidden".concat(EVENT_KEY),
+    SHOW: "show".concat(EVENT_KEY),
+    SHOWN: "shown".concat(EVENT_KEY),
+    CLICK: "click".concat(EVENT_KEY),
+    CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY),
+    KEYDOWN_DATA_API: "keydown".concat(EVENT_KEY).concat(DATA_API_KEY),
+    KEYUP_DATA_API: "keyup".concat(EVENT_KEY).concat(DATA_API_KEY)
+  };
+  var ClassName = {
+    DISABLED: 'disabled',
+    SHOW: 'show',
+    DROPUP: 'dropup',
+    DROPRIGHT: 'dropright',
+    DROPLEFT: 'dropleft',
+    MENURIGHT: 'dropdown-menu-right',
+    MENULEFT: 'dropdown-menu-left',
+    POSITION_STATIC: 'position-static'
+  };
+  var Selector = {
+    DATA_TOGGLE: '[data-toggle="dropdown"]',
+    FORM_CHILD: '.dropdown form',
+    MENU: '.dropdown-menu',
+    NAVBAR_NAV: '.navbar-nav',
+    VISIBLE_ITEMS: '.dropdown-menu .dropdown-item:not(.disabled):not(:disabled)'
+  };
+  var AttachmentMap = {
+    TOP: 'top-start',
+    TOPEND: 'top-end',
+    BOTTOM: 'bottom-start',
+    BOTTOMEND: 'bottom-end',
+    RIGHT: 'right-start',
+    RIGHTEND: 'right-end',
+    LEFT: 'left-start',
+    LEFTEND: 'left-end'
+  };
+  var Default = {
+    offset: 0,
+    flip: true,
+    boundary: 'scrollParent',
+    reference: 'toggle',
+    display: 'dynamic'
+  };
+  var DefaultType = {
+    offset: '(number|string|function)',
+    flip: 'boolean',
+    boundary: '(string|element)',
+    reference: '(string|element)',
+    display: 'string'
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'dropdown';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.dropdown';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var DATA_API_KEY = '.data-api';
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var ESCAPE_KEYCODE = 27; // KeyboardEvent.which value for Escape (Esc) key
-
-    var SPACE_KEYCODE = 32; // KeyboardEvent.which value for space key
-
-    var TAB_KEYCODE = 9; // KeyboardEvent.which value for tab key
-
-    var ARROW_UP_KEYCODE = 38; // KeyboardEvent.which value for up arrow key
-
-    var ARROW_DOWN_KEYCODE = 40; // KeyboardEvent.which value for down arrow key
-
-    var RIGHT_MOUSE_BUTTON_WHICH = 3; // MouseEvent.which value for the right button (assuming a right-handed mouse)
-
-    var REGEXP_KEYDOWN = new RegExp("".concat(ARROW_UP_KEYCODE, "|").concat(ARROW_DOWN_KEYCODE, "|").concat(ESCAPE_KEYCODE));
-    var Event = {
-      HIDE: "hide".concat(EVENT_KEY),
-      HIDDEN: "hidden".concat(EVENT_KEY),
-      SHOW: "show".concat(EVENT_KEY),
-      SHOWN: "shown".concat(EVENT_KEY),
-      CLICK: "click".concat(EVENT_KEY),
-      CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY),
-      KEYDOWN_DATA_API: "keydown".concat(EVENT_KEY).concat(DATA_API_KEY),
-      KEYUP_DATA_API: "keyup".concat(EVENT_KEY).concat(DATA_API_KEY)
-    };
-    var ClassName = {
-      DISABLED: 'disabled',
-      SHOW: 'show',
-      DROPUP: 'dropup',
-      DROPRIGHT: 'dropright',
-      DROPLEFT: 'dropleft',
-      MENURIGHT: 'dropdown-menu-right',
-      MENULEFT: 'dropdown-menu-left',
-      POSITION_STATIC: 'position-static'
-    };
-    var Selector = {
-      DATA_TOGGLE: '[data-toggle="dropdown"]',
-      FORM_CHILD: '.dropdown form',
-      MENU: '.dropdown-menu',
-      NAVBAR_NAV: '.navbar-nav',
-      VISIBLE_ITEMS: '.dropdown-menu .dropdown-item:not(.disabled)'
-    };
-    var AttachmentMap = {
-      TOP: 'top-start',
-      TOPEND: 'top-end',
-      BOTTOM: 'bottom-start',
-      BOTTOMEND: 'bottom-end',
-      RIGHT: 'right-start',
-      RIGHTEND: 'right-end',
-      LEFT: 'left-start',
-      LEFTEND: 'left-end'
-    };
-    var Default = {
-      offset: 0,
-      flip: false,
-      boundary: 'scrollParent'
-    };
-    var DefaultType = {
-      offset: '(number|string|function)',
-      flip: 'boolean',
-      boundary: '(string|element)'
-      /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
-       */
 
-    };
+  };
 
-    var Dropdown = function () {
-      function Dropdown(element, config) {
-        _classCallCheck(this, Dropdown);
+  var Dropdown = function () {
+    function Dropdown(element, config) {
+      _classCallCheck(this, Dropdown);
 
-        this._element = element;
-        this._popper = null;
-        this._config = this._getConfig(config);
-        this._menu = this._getMenuElement();
-        this._inNavbar = this._detectNavbar();
+      this._element = element;
+      this._popper = null;
+      this._config = this._getConfig(config);
+      this._menu = this._getMenuElement();
+      this._inNavbar = this._detectNavbar();
 
-        this._addEventListeners();
-      } // Getters
+      this._addEventListeners();
+    } // Getters
 
 
-      _createClass(Dropdown, [{
-        key: "toggle",
-        value: function toggle() {
-          if (this._element.disabled || $(this._element).hasClass(ClassName.DISABLED)) {
-            return;
-          }
+    _createClass(Dropdown, [{
+      key: "toggle",
+      value: function toggle() {
+        if (this._element.disabled || (0, _jquery2.default)(this._element).hasClass(ClassName.DISABLED)) {
+          return;
+        }
 
-          var parent = Dropdown._getParentFromElement(this._element);
+        var parent = Dropdown._getParentFromElement(this._element);
 
-          var isActive = $(this._menu).hasClass(ClassName.SHOW);
+        var isActive = (0, _jquery2.default)(this._menu).hasClass(ClassName.SHOW);
 
-          Dropdown._clearMenus();
+        Dropdown._clearMenus();
 
-          if (isActive) {
-            return;
-          }
+        if (isActive) {
+          return;
+        }
 
-          var relatedTarget = {
-            relatedTarget: this._element
-          };
-          var showEvent = $.Event(Event.SHOW, relatedTarget);
-          $(parent).trigger(showEvent);
+        var relatedTarget = {
+          relatedTarget: this._element
+        };
 
-          if (showEvent.isDefaultPrevented()) {
-            return;
-          } // Disable totally Popper.js for Dropdown in Navbar
+        var showEvent = _jquery2.default.Event(Event.SHOW, relatedTarget);
 
+        (0, _jquery2.default)(parent).trigger(showEvent);
 
-          if (!this._inNavbar) {
-            /**
-             * Check for Popper dependency
-             * Popper - https://popper.js.org
-             */
-            if (typeof _popper2.default === 'undefined') {
-              throw new TypeError('Bootstrap dropdown require Popper.js (https://popper.js.org)');
-            }
+        if (showEvent.isDefaultPrevented()) {
+          return;
+        } // Disable totally Popper.js for Dropdown in Navbar
 
-            var element = this._element; // For dropup with alignment we use the parent as popper container
 
-            if ($(parent).hasClass(ClassName.DROPUP)) {
-              if ($(this._menu).hasClass(ClassName.MENULEFT) || $(this._menu).hasClass(ClassName.MENURIGHT)) {
-                element = parent;
-              }
-            } // If boundary is not `scrollParent`, then set position to `static`
-            // to allow the menu to "escape" the scroll parent's boundaries
-            // https://github.com/twbs/bootstrap/issues/24251
+        if (!this._inNavbar) {
+          /**
+           * Check for Popper dependency
+           * Popper - https://popper.js.org
+           */
+          if (typeof _popper2.default === 'undefined') {
+            throw new TypeError('Bootstrap\'s dropdowns require Popper.js (https://popper.js.org/)');
+          }
 
+          var referenceElement = this._element;
 
-            if (this._config.boundary !== 'scrollParent') {
-              $(parent).addClass(ClassName.POSITION_STATIC);
-            }
+          if (this._config.reference === 'parent') {
+            referenceElement = parent;
+          } else if (_util2.default.isElement(this._config.reference)) {
+            referenceElement = this._config.reference; // Check if it's jQuery element
 
-            this._popper = new _popper2.default(element, this._menu, this._getPopperConfig());
-          } // If this is a touch-enabled device we add extra
-          // empty mouseover listeners to the body's immediate children;
-          // only needed because of broken event delegation on iOS
-          // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html
+            if (typeof this._config.reference.jquery !== 'undefined') {
+              referenceElement = this._config.reference[0];
+            }
+          } // If boundary is not `scrollParent`, then set position to `static`
+          // to allow the menu to "escape" the scroll parent's boundaries
+          // https://github.com/twbs/bootstrap/issues/24251
 
 
-          if ('ontouchstart' in document.documentElement && $(parent).closest(Selector.NAVBAR_NAV).length === 0) {
-            $('body').children().on('mouseover', null, $.noop);
+          if (this._config.boundary !== 'scrollParent') {
+            (0, _jquery2.default)(parent).addClass(ClassName.POSITION_STATIC);
           }
 
-          this._element.focus();
+          this._popper = new _popper2.default(referenceElement, this._menu, this._getPopperConfig());
+        } // If this is a touch-enabled device we add extra
+        // empty mouseover listeners to the body's immediate children;
+        // only needed because of broken event delegation on iOS
+        // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html
 
-          this._element.setAttribute('aria-expanded', true);
 
-          $(this._menu).toggleClass(ClassName.SHOW);
-          $(parent).toggleClass(ClassName.SHOW).trigger($.Event(Event.SHOWN, relatedTarget));
-        }
-      }, {
-        key: "dispose",
-        value: function dispose() {
-          $.removeData(this._element, DATA_KEY);
-          $(this._element).off(EVENT_KEY);
-          this._element = null;
-          this._menu = null;
-
-          if (this._popper !== null) {
-            this._popper.destroy();
-
-            this._popper = null;
-          }
+        if ('ontouchstart' in document.documentElement && (0, _jquery2.default)(parent).closest(Selector.NAVBAR_NAV).length === 0) {
+          (0, _jquery2.default)(document.body).children().on('mouseover', null, _jquery2.default.noop);
         }
-      }, {
-        key: "update",
-        value: function update() {
-          this._inNavbar = this._detectNavbar();
 
-          if (this._popper !== null) {
-            this._popper.scheduleUpdate();
-          }
-        }
-      }, {
-        key: "_addEventListeners",
-        value: function _addEventListeners() {
-          var _this = this;
+        this._element.focus();
 
-          $(this._element).on(Event.CLICK, function (event) {
-            event.preventDefault();
-            event.stopPropagation();
+        this._element.setAttribute('aria-expanded', true);
 
-            _this.toggle();
-          });
+        (0, _jquery2.default)(this._menu).toggleClass(ClassName.SHOW);
+        (0, _jquery2.default)(parent).toggleClass(ClassName.SHOW).trigger(_jquery2.default.Event(Event.SHOWN, relatedTarget));
+      }
+    }, {
+      key: "show",
+      value: function show() {
+        if (this._element.disabled || (0, _jquery2.default)(this._element).hasClass(ClassName.DISABLED) || (0, _jquery2.default)(this._menu).hasClass(ClassName.SHOW)) {
+          return;
         }
-      }, {
-        key: "_getConfig",
-        value: function _getConfig(config) {
-          config = _extends({}, this.constructor.Default, $(this._element).data(), config);
 
-          _util2.default.typeCheckConfig(NAME, config, this.constructor.DefaultType);
+        var relatedTarget = {
+          relatedTarget: this._element
+        };
 
-          return config;
-        }
-      }, {
-        key: "_getMenuElement",
-        value: function _getMenuElement() {
-          if (!this._menu) {
-            var parent = Dropdown._getParentFromElement(this._element);
+        var showEvent = _jquery2.default.Event(Event.SHOW, relatedTarget);
 
-            this._menu = $(parent).find(Selector.MENU)[0];
-          }
+        var parent = Dropdown._getParentFromElement(this._element);
+
+        (0, _jquery2.default)(parent).trigger(showEvent);
 
-          return this._menu;
+        if (showEvent.isDefaultPrevented()) {
+          return;
         }
-      }, {
-        key: "_getPlacement",
-        value: function _getPlacement() {
-          var $parentDropdown = $(this._element).parent();
-          var placement = AttachmentMap.BOTTOM; // Handle dropup
 
-          if ($parentDropdown.hasClass(ClassName.DROPUP)) {
-            placement = AttachmentMap.TOP;
+        (0, _jquery2.default)(this._menu).toggleClass(ClassName.SHOW);
+        (0, _jquery2.default)(parent).toggleClass(ClassName.SHOW).trigger(_jquery2.default.Event(Event.SHOWN, relatedTarget));
+      }
+    }, {
+      key: "hide",
+      value: function hide() {
+        if (this._element.disabled || (0, _jquery2.default)(this._element).hasClass(ClassName.DISABLED) || !(0, _jquery2.default)(this._menu).hasClass(ClassName.SHOW)) {
+          return;
+        }
 
-            if ($(this._menu).hasClass(ClassName.MENURIGHT)) {
-              placement = AttachmentMap.TOPEND;
-            }
-          } else if ($parentDropdown.hasClass(ClassName.DROPRIGHT)) {
-            placement = AttachmentMap.RIGHT;
-          } else if ($parentDropdown.hasClass(ClassName.DROPLEFT)) {
-            placement = AttachmentMap.LEFT;
-          } else if ($(this._menu).hasClass(ClassName.MENURIGHT)) {
-            placement = AttachmentMap.BOTTOMEND;
-          }
+        var relatedTarget = {
+          relatedTarget: this._element
+        };
+
+        var hideEvent = _jquery2.default.Event(Event.HIDE, relatedTarget);
+
+        var parent = Dropdown._getParentFromElement(this._element);
 
-          return placement;
+        (0, _jquery2.default)(parent).trigger(hideEvent);
+
+        if (hideEvent.isDefaultPrevented()) {
+          return;
         }
-      }, {
-        key: "_detectNavbar",
-        value: function _detectNavbar() {
-          return $(this._element).closest('.navbar').length > 0;
+
+        (0, _jquery2.default)(this._menu).toggleClass(ClassName.SHOW);
+        (0, _jquery2.default)(parent).toggleClass(ClassName.SHOW).trigger(_jquery2.default.Event(Event.HIDDEN, relatedTarget));
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        _jquery2.default.removeData(this._element, DATA_KEY);
+
+        (0, _jquery2.default)(this._element).off(EVENT_KEY);
+        this._element = null;
+        this._menu = null;
+
+        if (this._popper !== null) {
+          this._popper.destroy();
+
+          this._popper = null;
         }
-      }, {
-        key: "_getPopperConfig",
-        value: function _getPopperConfig() {
-          var _this2 = this;
-
-          var offsetConf = {};
-
-          if (typeof this._config.offset === 'function') {
-            offsetConf.fn = function (data) {
-              data.offsets = _extends({}, data.offsets, _this2._config.offset(data.offsets) || {});
-              return data;
-            };
-          } else {
-            offsetConf.offset = this._config.offset;
-          }
+      }
+    }, {
+      key: "update",
+      value: function update() {
+        this._inNavbar = this._detectNavbar();
 
-          var popperConfig = {
-            placement: this._getPlacement(),
-            modifiers: {
-              offset: offsetConf,
-              flip: {
-                enabled: this._config.flip
-              },
-              preventOverflow: {
-                boundariesElement: this._config.boundary
-              }
-            }
-          };
-          return popperConfig;
+        if (this._popper !== null) {
+          this._popper.scheduleUpdate();
         }
-      }], [{
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config) {
-          return this.each(function () {
-            var data = $(this).data(DATA_KEY);
+      }
+    }, {
+      key: "_addEventListeners",
+      value: function _addEventListeners() {
+        var _this = this;
 
-            var _config = _typeof(config) === 'object' ? config : null;
+        (0, _jquery2.default)(this._element).on(Event.CLICK, function (event) {
+          event.preventDefault();
+          event.stopPropagation();
 
-            if (!data) {
-              data = new Dropdown(this, _config);
-              $(this).data(DATA_KEY, data);
-            }
+          _this.toggle();
+        });
+      }
+    }, {
+      key: "_getConfig",
+      value: function _getConfig(config) {
+        config = _objectSpread({}, this.constructor.Default, (0, _jquery2.default)(this._element).data(), config);
 
-            if (typeof config === 'string') {
-              if (typeof data[config] === 'undefined') {
-                throw new TypeError("No method named \"".concat(config, "\""));
-              }
+        _util2.default.typeCheckConfig(NAME, config, this.constructor.DefaultType);
 
-              data[config]();
-            }
-          });
-        }
-      }, {
-        key: "_clearMenus",
-        value: function _clearMenus(event) {
-          if (event && (event.which === RIGHT_MOUSE_BUTTON_WHICH || event.type === 'keyup' && event.which !== TAB_KEYCODE)) {
-            return;
+        return config;
+      }
+    }, {
+      key: "_getMenuElement",
+      value: function _getMenuElement() {
+        if (!this._menu) {
+          var parent = Dropdown._getParentFromElement(this._element);
+
+          if (parent) {
+            this._menu = parent.querySelector(Selector.MENU);
           }
+        }
+
+        return this._menu;
+      }
+    }, {
+      key: "_getPlacement",
+      value: function _getPlacement() {
+        var $parentDropdown = (0, _jquery2.default)(this._element.parentNode);
+        var placement = AttachmentMap.BOTTOM; // Handle dropup
 
-          var toggles = $.makeArray($(Selector.DATA_TOGGLE));
+        if ($parentDropdown.hasClass(ClassName.DROPUP)) {
+          placement = AttachmentMap.TOP;
 
-          for (var i = 0; i < toggles.length; i++) {
-            var parent = Dropdown._getParentFromElement(toggles[i]);
+          if ((0, _jquery2.default)(this._menu).hasClass(ClassName.MENURIGHT)) {
+            placement = AttachmentMap.TOPEND;
+          }
+        } else if ($parentDropdown.hasClass(ClassName.DROPRIGHT)) {
+          placement = AttachmentMap.RIGHT;
+        } else if ($parentDropdown.hasClass(ClassName.DROPLEFT)) {
+          placement = AttachmentMap.LEFT;
+        } else if ((0, _jquery2.default)(this._menu).hasClass(ClassName.MENURIGHT)) {
+          placement = AttachmentMap.BOTTOMEND;
+        }
 
-            var context = $(toggles[i]).data(DATA_KEY);
-            var relatedTarget = {
-              relatedTarget: toggles[i]
-            };
+        return placement;
+      }
+    }, {
+      key: "_detectNavbar",
+      value: function _detectNavbar() {
+        return (0, _jquery2.default)(this._element).closest('.navbar').length > 0;
+      }
+    }, {
+      key: "_getOffset",
+      value: function _getOffset() {
+        var _this2 = this;
 
-            if (!context) {
-              continue;
-            }
+        var offset = {};
 
-            var dropdownMenu = context._menu;
+        if (typeof this._config.offset === 'function') {
+          offset.fn = function (data) {
+            data.offsets = _objectSpread({}, data.offsets, _this2._config.offset(data.offsets, _this2._element) || {});
+            return data;
+          };
+        } else {
+          offset.offset = this._config.offset;
+        }
 
-            if (!$(parent).hasClass(ClassName.SHOW)) {
-              continue;
+        return offset;
+      }
+    }, {
+      key: "_getPopperConfig",
+      value: function _getPopperConfig() {
+        var popperConfig = {
+          placement: this._getPlacement(),
+          modifiers: {
+            offset: this._getOffset(),
+            flip: {
+              enabled: this._config.flip
+            },
+            preventOverflow: {
+              boundariesElement: this._config.boundary
             }
+          } // Disable Popper.js if we have a static display
 
-            if (event && (event.type === 'click' && /input|textarea/i.test(event.target.tagName) || event.type === 'keyup' && event.which === TAB_KEYCODE) && $.contains(parent, event.target)) {
-              continue;
-            }
+        };
 
-            var hideEvent = $.Event(Event.HIDE, relatedTarget);
-            $(parent).trigger(hideEvent);
+        if (this._config.display === 'static') {
+          popperConfig.modifiers.applyStyle = {
+            enabled: false
+          };
+        }
+
+        return popperConfig;
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var data = (0, _jquery2.default)(this).data(DATA_KEY);
 
-            if (hideEvent.isDefaultPrevented()) {
-              continue;
-            } // If this is a touch-enabled device we remove the extra
-            // empty mouseover listeners we added for iOS support
+          var _config = _typeof(config) === 'object' ? config : null;
 
+          if (!data) {
+            data = new Dropdown(this, _config);
+            (0, _jquery2.default)(this).data(DATA_KEY, data);
+          }
 
-            if ('ontouchstart' in document.documentElement) {
-              $('body').children().off('mouseover', null, $.noop);
+          if (typeof config === 'string') {
+            if (typeof data[config] === 'undefined') {
+              throw new TypeError("No method named \"".concat(config, "\""));
             }
 
-            toggles[i].setAttribute('aria-expanded', 'false');
-            $(dropdownMenu).removeClass(ClassName.SHOW);
-            $(parent).removeClass(ClassName.SHOW).trigger($.Event(Event.HIDDEN, relatedTarget));
+            data[config]();
           }
+        });
+      }
+    }, {
+      key: "_clearMenus",
+      value: function _clearMenus(event) {
+        if (event && (event.which === RIGHT_MOUSE_BUTTON_WHICH || event.type === 'keyup' && event.which !== TAB_KEYCODE)) {
+          return;
         }
-      }, {
-        key: "_getParentFromElement",
-        value: function _getParentFromElement(element) {
-          var parent;
 
-          var selector = _util2.default.getSelectorFromElement(element);
+        var toggles = [].slice.call(document.querySelectorAll(Selector.DATA_TOGGLE));
 
-          if (selector) {
-            parent = $(selector)[0];
+        for (var i = 0, len = toggles.length; i < len; i++) {
+          var parent = Dropdown._getParentFromElement(toggles[i]);
+
+          var context = (0, _jquery2.default)(toggles[i]).data(DATA_KEY);
+          var relatedTarget = {
+            relatedTarget: toggles[i]
+          };
+
+          if (event && event.type === 'click') {
+            relatedTarget.clickEvent = event;
           }
 
-          return parent || element.parentNode;
-        }
-      }, {
-        key: "_dataApiKeydownHandler",
-        value: function _dataApiKeydownHandler(event) {
-          // If not input/textarea:
-          //  - And not a key in REGEXP_KEYDOWN => not a dropdown command
-          // If input/textarea:
-          //  - If space key => not a dropdown command
-          //  - If key is other than escape
-          //    - If key is not up or down => not a dropdown command
-          //    - If trigger inside the menu => not a dropdown command
-          if (/input|textarea/i.test(event.target.tagName) ? event.which === SPACE_KEYCODE || event.which !== ESCAPE_KEYCODE && (event.which !== ARROW_DOWN_KEYCODE && event.which !== ARROW_UP_KEYCODE || $(event.target).closest(Selector.MENU).length) : !REGEXP_KEYDOWN.test(event.which)) {
-            return;
+          if (!context) {
+            continue;
           }
 
-          event.preventDefault();
-          event.stopPropagation();
+          var dropdownMenu = context._menu;
 
-          if (this.disabled || $(this).hasClass(ClassName.DISABLED)) {
-            return;
+          if (!(0, _jquery2.default)(parent).hasClass(ClassName.SHOW)) {
+            continue;
           }
 
-          var parent = Dropdown._getParentFromElement(this);
+          if (event && (event.type === 'click' && /input|textarea/i.test(event.target.tagName) || event.type === 'keyup' && event.which === TAB_KEYCODE) && _jquery2.default.contains(parent, event.target)) {
+            continue;
+          }
 
-          var isActive = $(parent).hasClass(ClassName.SHOW);
+          var hideEvent = _jquery2.default.Event(Event.HIDE, relatedTarget);
 
-          if (!isActive && (event.which !== ESCAPE_KEYCODE || event.which !== SPACE_KEYCODE) || isActive && (event.which === ESCAPE_KEYCODE || event.which === SPACE_KEYCODE)) {
-            if (event.which === ESCAPE_KEYCODE) {
-              var toggle = $(parent).find(Selector.DATA_TOGGLE)[0];
-              $(toggle).trigger('focus');
-            }
+          (0, _jquery2.default)(parent).trigger(hideEvent);
 
-            $(this).trigger('click');
-            return;
-          }
+          if (hideEvent.isDefaultPrevented()) {
+            continue;
+          } // If this is a touch-enabled device we remove the extra
+          // empty mouseover listeners we added for iOS support
 
-          var items = $(parent).find(Selector.VISIBLE_ITEMS).get();
 
-          if (items.length === 0) {
-            return;
+          if ('ontouchstart' in document.documentElement) {
+            (0, _jquery2.default)(document.body).children().off('mouseover', null, _jquery2.default.noop);
           }
 
-          var index = items.indexOf(event.target);
+          toggles[i].setAttribute('aria-expanded', 'false');
+          (0, _jquery2.default)(dropdownMenu).removeClass(ClassName.SHOW);
+          (0, _jquery2.default)(parent).removeClass(ClassName.SHOW).trigger(_jquery2.default.Event(Event.HIDDEN, relatedTarget));
+        }
+      }
+    }, {
+      key: "_getParentFromElement",
+      value: function _getParentFromElement(element) {
+        var parent;
 
-          if (event.which === ARROW_UP_KEYCODE && index > 0) {
-            // Up
-            index--;
-          }
+        var selector = _util2.default.getSelectorFromElement(element);
 
-          if (event.which === ARROW_DOWN_KEYCODE && index < items.length - 1) {
-            // Down
-            index++;
-          }
+        if (selector) {
+          parent = document.querySelector(selector);
+        }
+
+        return parent || element.parentNode;
+      }
+    }, {
+      key: "_dataApiKeydownHandler",
+      value: function _dataApiKeydownHandler(event) {
+        // If not input/textarea:
+        //  - And not a key in REGEXP_KEYDOWN => not a dropdown command
+        // If input/textarea:
+        //  - If space key => not a dropdown command
+        //  - If key is other than escape
+        //    - If key is not up or down => not a dropdown command
+        //    - If trigger inside the menu => not a dropdown command
+        if (/input|textarea/i.test(event.target.tagName) ? event.which === SPACE_KEYCODE || event.which !== ESCAPE_KEYCODE && (event.which !== ARROW_DOWN_KEYCODE && event.which !== ARROW_UP_KEYCODE || (0, _jquery2.default)(event.target).closest(Selector.MENU).length) : !REGEXP_KEYDOWN.test(event.which)) {
+          return;
+        }
 
-          if (index < 0) {
-            index = 0;
+        event.preventDefault();
+        event.stopPropagation();
+
+        if (this.disabled || (0, _jquery2.default)(this).hasClass(ClassName.DISABLED)) {
+          return;
+        }
+
+        var parent = Dropdown._getParentFromElement(this);
+
+        var isActive = (0, _jquery2.default)(parent).hasClass(ClassName.SHOW);
+
+        if (!isActive || isActive && (event.which === ESCAPE_KEYCODE || event.which === SPACE_KEYCODE)) {
+          if (event.which === ESCAPE_KEYCODE) {
+            var toggle = parent.querySelector(Selector.DATA_TOGGLE);
+            (0, _jquery2.default)(toggle).trigger('focus');
           }
 
-          items[index].focus();
+          (0, _jquery2.default)(this).trigger('click');
+          return;
         }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
+
+        var items = [].slice.call(parent.querySelectorAll(Selector.VISIBLE_ITEMS));
+
+        if (items.length === 0) {
+          return;
         }
-      }, {
-        key: "Default",
-        get: function get() {
-          return Default;
+
+        var index = items.indexOf(event.target);
+
+        if (event.which === ARROW_UP_KEYCODE && index > 0) {
+          // Up
+          index--;
         }
-      }, {
-        key: "DefaultType",
-        get: function get() {
-          return DefaultType;
+
+        if (event.which === ARROW_DOWN_KEYCODE && index < items.length - 1) {
+          // Down
+          index++;
         }
-      }]);
 
-      return Dropdown;
-    }();
+        if (index < 0) {
+          index = 0;
+        }
 
-    /**
-     * ------------------------------------------------------------------------
-     * Data Api implementation
-     * ------------------------------------------------------------------------
-     */
-    $(document).on(Event.KEYDOWN_DATA_API, Selector.DATA_TOGGLE, Dropdown._dataApiKeydownHandler).on(Event.KEYDOWN_DATA_API, Selector.MENU, Dropdown._dataApiKeydownHandler).on("".concat(Event.CLICK_DATA_API, " ").concat(Event.KEYUP_DATA_API), Dropdown._clearMenus).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
-      event.preventDefault();
-      event.stopPropagation();
-
-      Dropdown._jQueryInterface.call($(this), 'toggle');
-    }).on(Event.CLICK_DATA_API, Selector.FORM_CHILD, function (e) {
-      e.stopPropagation();
-    });
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
+        items[index].focus();
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }, {
+      key: "Default",
+      get: function get() {
+        return Default;
+      }
+    }, {
+      key: "DefaultType",
+      get: function get() {
+        return DefaultType;
+      }
+    }]);
 
-    $.fn[NAME] = Dropdown._jQueryInterface;
-    $.fn[NAME].Constructor = Dropdown;
+    return Dropdown;
+  }();
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return Dropdown._jQueryInterface;
-    };
+  /**
+   * ------------------------------------------------------------------------
+   * Data Api implementation
+   * ------------------------------------------------------------------------
+   */
+  (0, _jquery2.default)(document).on(Event.KEYDOWN_DATA_API, Selector.DATA_TOGGLE, Dropdown._dataApiKeydownHandler).on(Event.KEYDOWN_DATA_API, Selector.MENU, Dropdown._dataApiKeydownHandler).on("".concat(Event.CLICK_DATA_API, " ").concat(Event.KEYUP_DATA_API), Dropdown._clearMenus).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
+    event.preventDefault();
+    event.stopPropagation();
 
-    return Dropdown;
-  }(_jquery2.default, _popper2.default);
+    Dropdown._jQueryInterface.call((0, _jquery2.default)(this), 'toggle');
+  }).on(Event.CLICK_DATA_API, Selector.FORM_CHILD, function (e) {
+    e.stopPropagation();
+  });
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
+
+  _jquery2.default.fn[NAME] = Dropdown._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Dropdown;
+
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Dropdown._jQueryInterface;
+  };
 
   exports.default = Dropdown;
 });
\ No newline at end of file
diff --git a/theme/boost/amd/src/index.js b/theme/boost/amd/src/index.js
new file mode 100644 (file)
index 0000000..5ecfad5
--- /dev/null
@@ -0,0 +1,79 @@
+"use strict";
+
+define(["exports", "jquery", "./alert", "./button", "./carousel", "./collapse", "./dropdown", "./modal", "./popover", "./scrollspy", "./tab", "./toast", "./tooltip", "./util"], function (exports, _jquery, _alert, _button, _carousel, _collapse, _dropdown, _modal, _popover, _scrollspy, _tab, _toast, _tooltip, _util) {
+  "use strict";
+
+  Object.defineProperty(exports, "__esModule", {
+    value: true
+  });
+  exports.Tooltip = exports.Toast = exports.Tab = exports.Scrollspy = exports.Popover = exports.Modal = exports.Dropdown = exports.Collapse = exports.Carousel = exports.Button = exports.Alert = exports.Util = undefined;
+
+  var _jquery2 = _interopRequireDefault(_jquery);
+
+  var _alert2 = _interopRequireDefault(_alert);
+
+  var _button2 = _interopRequireDefault(_button);
+
+  var _carousel2 = _interopRequireDefault(_carousel);
+
+  var _collapse2 = _interopRequireDefault(_collapse);
+
+  var _dropdown2 = _interopRequireDefault(_dropdown);
+
+  var _modal2 = _interopRequireDefault(_modal);
+
+  var _popover2 = _interopRequireDefault(_popover);
+
+  var _scrollspy2 = _interopRequireDefault(_scrollspy);
+
+  var _tab2 = _interopRequireDefault(_tab);
+
+  var _toast2 = _interopRequireDefault(_toast);
+
+  var _tooltip2 = _interopRequireDefault(_tooltip);
+
+  var _util2 = _interopRequireDefault(_util);
+
+  function _interopRequireDefault(obj) {
+    return obj && obj.__esModule ? obj : {
+      default: obj
+    };
+  }
+
+  /**
+   * --------------------------------------------------------------------------
+   * Bootstrap (v4.3.1): index.js
+   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+   * --------------------------------------------------------------------------
+   */
+  (function () {
+    if (typeof _jquery2.default === 'undefined') {
+      throw new TypeError('Bootstrap\'s JavaScript requires jQuery. jQuery must be included before Bootstrap\'s JavaScript.');
+    }
+
+    var version = _jquery2.default.fn.jquery.split(' ')[0].split('.');
+
+    var minMajor = 1;
+    var ltMajor = 2;
+    var minMinor = 9;
+    var minPatch = 1;
+    var maxMajor = 4;
+
+    if (version[0] < ltMajor && version[1] < minMinor || version[0] === minMajor && version[1] === minMinor && version[2] < minPatch || version[0] >= maxMajor) {
+      throw new Error('Bootstrap\'s JavaScript requires at least jQuery v1.9.1 but less than v4.0.0');
+    }
+  })();
+
+  exports.Util = _util2.default;
+  exports.Alert = _alert2.default;
+  exports.Button = _button2.default;
+  exports.Carousel = _carousel2.default;
+  exports.Collapse = _collapse2.default;
+  exports.Dropdown = _dropdown2.default;
+  exports.Modal = _modal2.default;
+  exports.Popover = _popover2.default;
+  exports.Scrollspy = _scrollspy2.default;
+  exports.Tab = _tab2.default;
+  exports.Toast = _toast2.default;
+  exports.Tooltip = _tooltip2.default;
+});
\ No newline at end of file
index e173538..8a4fabd 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   "use strict";
 
@@ -29,22 +31,38 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
     return _typeof(obj);
   }
 
-  function _extends() {
-    _extends = Object.assign || function (target) {
-      for (var i = 1; i < arguments.length; i++) {
-        var source = arguments[i];
+  function _objectSpread(target) {
+    for (var i = 1; i < arguments.length; i++) {
+      var source = arguments[i] != null ? arguments[i] : {};
+      var ownKeys = Object.keys(source);
 
-        for (var key in source) {
-          if (Object.prototype.hasOwnProperty.call(source, key)) {
-            target[key] = source[key];
-          }
-        }
+      if (typeof Object.getOwnPropertySymbols === 'function') {
+        ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
+          return Object.getOwnPropertyDescriptor(source, sym).enumerable;
+        }));
       }
 
-      return target;
-    };
+      ownKeys.forEach(function (key) {
+        _defineProperty(target, key, source[key]);
+      });
+    }
+
+    return target;
+  }
+
+  function _defineProperty(obj, key, value) {
+    if (key in obj) {
+      Object.defineProperty(obj, key, {
+        value: value,
+        enumerable: true,
+        configurable: true,
+        writable: true
+      });
+    } else {
+      obj[key] = value;
+    }
 
-    return _extends.apply(this, arguments);
+    return obj;
   }
 
   function _classCallCheck(instance, Constructor) {
@@ -70,593 +88,605 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): modal.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var Modal = function ($) {
+  var NAME = 'modal';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.modal';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var DATA_API_KEY = '.data-api';
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var ESCAPE_KEYCODE = 27; // KeyboardEvent.which value for Escape (Esc) key
+
+  var Default = {
+    backdrop: true,
+    keyboard: true,
+    focus: true,
+    show: true
+  };
+  var DefaultType = {
+    backdrop: '(boolean|string)',
+    keyboard: 'boolean',
+    focus: 'boolean',
+    show: 'boolean'
+  };
+  var Event = {
+    HIDE: "hide".concat(EVENT_KEY),
+    HIDDEN: "hidden".concat(EVENT_KEY),
+    SHOW: "show".concat(EVENT_KEY),
+    SHOWN: "shown".concat(EVENT_KEY),
+    FOCUSIN: "focusin".concat(EVENT_KEY),
+    RESIZE: "resize".concat(EVENT_KEY),
+    CLICK_DISMISS: "click.dismiss".concat(EVENT_KEY),
+    KEYDOWN_DISMISS: "keydown.dismiss".concat(EVENT_KEY),
+    MOUSEUP_DISMISS: "mouseup.dismiss".concat(EVENT_KEY),
+    MOUSEDOWN_DISMISS: "mousedown.dismiss".concat(EVENT_KEY),
+    CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
+  };
+  var ClassName = {
+    SCROLLABLE: 'modal-dialog-scrollable',
+    SCROLLBAR_MEASURER: 'modal-scrollbar-measure',
+    BACKDROP: 'modal-backdrop',
+    OPEN: 'modal-open',
+    FADE: 'fade',
+    SHOW: 'show'
+  };
+  var Selector = {
+    DIALOG: '.modal-dialog',
+    MODAL_BODY: '.modal-body',
+    DATA_TOGGLE: '[data-toggle="modal"]',
+    DATA_DISMISS: '[data-dismiss="modal"]',
+    FIXED_CONTENT: '.fixed-top, .fixed-bottom, .is-fixed, .sticky-top',
+    STICKY_CONTENT: '.sticky-top'
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'modal';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.modal';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var DATA_API_KEY = '.data-api';
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var TRANSITION_DURATION = 300;
-    var BACKDROP_TRANSITION_DURATION = 150;
-    var ESCAPE_KEYCODE = 27; // KeyboardEvent.which value for Escape (Esc) key
-
-    var Default = {
-      backdrop: true,
-      keyboard: true,
-      focus: true,
-      show: true
-    };
-    var DefaultType = {
-      backdrop: '(boolean|string)',
-      keyboard: 'boolean',
-      focus: 'boolean',
-      show: 'boolean'
-    };
-    var Event = {
-      HIDE: "hide".concat(EVENT_KEY),
-      HIDDEN: "hidden".concat(EVENT_KEY),
-      SHOW: "show".concat(EVENT_KEY),
-      SHOWN: "shown".concat(EVENT_KEY),
-      FOCUSIN: "focusin".concat(EVENT_KEY),
-      RESIZE: "resize".concat(EVENT_KEY),
-      CLICK_DISMISS: "click.dismiss".concat(EVENT_KEY),
-      KEYDOWN_DISMISS: "keydown.dismiss".concat(EVENT_KEY),
-      MOUSEUP_DISMISS: "mouseup.dismiss".concat(EVENT_KEY),
-      MOUSEDOWN_DISMISS: "mousedown.dismiss".concat(EVENT_KEY),
-      CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
-    };
-    var ClassName = {
-      SCROLLBAR_MEASURER: 'modal-scrollbar-measure',
-      BACKDROP: 'modal-backdrop',
-      OPEN: 'modal-open',
-      FADE: 'fade',
-      SHOW: 'show'
-    };
-    var Selector = {
-      DIALOG: '.modal-dialog',
-      DATA_TOGGLE: '[data-toggle="modal"]',
-      DATA_DISMISS: '[data-dismiss="modal"]',
-      FIXED_CONTENT: '.fixed-top, .fixed-bottom, .is-fixed, .sticky-top',
-      STICKY_CONTENT: '.sticky-top',
-      NAVBAR_TOGGLER: '.navbar-toggler'
-      /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
-       */
 
-    };
+  };
 
-    var Modal = function () {
-      function Modal(element, config) {
-        _classCallCheck(this, Modal);
+  var Modal = function () {
+    function Modal(element, config) {
+      _classCallCheck(this, Modal);
 
-        this._config = this._getConfig(config);
-        this._element = element;
-        this._dialog = $(element).find(Selector.DIALOG)[0];
-        this._backdrop = null;
-        this._isShown = false;
-        this._isBodyOverflowing = false;
-        this._ignoreBackdropClick = false;
-        this._originalBodyPadding = 0;
-        this._scrollbarWidth = 0;
-      } // Getters
+      this._config = this._getConfig(config);
+      this._element = element;
+      this._dialog = element.querySelector(Selector.DIALOG);
+      this._backdrop = null;
+      this._isShown = false;
+      this._isBodyOverflowing = false;
+      this._ignoreBackdropClick = false;
+      this._isTransitioning = false;
+      this._scrollbarWidth = 0;
+    } // Getters
 
 
-      _createClass(Modal, [{
-        key: "toggle",
-        value: function toggle(relatedTarget) {
-          return this._isShown ? this.hide() : this.show(relatedTarget);
-        }
-      }, {
-        key: "show",
-        value: function show(relatedTarget) {
-          var _this = this;
+    _createClass(Modal, [{
+      key: "toggle",
+      value: function toggle(relatedTarget) {
+        return this._isShown ? this.hide() : this.show(relatedTarget);
+      }
+    }, {
+      key: "show",
+      value: function show(relatedTarget) {
+        var _this = this;
 
-          if (this._isTransitioning || this._isShown) {
-            return;
-          }
+        if (this._isShown || this._isTransitioning) {
+          return;
+        }
 
-          if (_util2.default.supportsTransitionEnd() && $(this._element).hasClass(ClassName.FADE)) {
-            this._isTransitioning = true;
-          }
+        if ((0, _jquery2.default)(this._element).hasClass(ClassName.FADE)) {
+          this._isTransitioning = true;
+        }
 
-          var showEvent = $.Event(Event.SHOW, {
-            relatedTarget: relatedTarget
-          });
-          $(this._element).trigger(showEvent);
+        var showEvent = _jquery2.default.Event(Event.SHOW, {
+          relatedTarget: relatedTarget
+        });
 
-          if (this._isShown || showEvent.isDefaultPrevented()) {
-            return;
-          }
+        (0, _jquery2.default)(this._element).trigger(showEvent);
 
-          this._isShown = true;
+        if (this._isShown || showEvent.isDefaultPrevented()) {
+          return;
+        }
 
-          this._checkScrollbar();
+        this._isShown = true;
 
-          this._setScrollbar();
+        this._checkScrollbar();
 
-          this._adjustDialog();
+        this._setScrollbar();
 
-          $(document.body).addClass(ClassName.OPEN);
+        this._adjustDialog();
 
-          this._setEscapeEvent();
+        this._setEscapeEvent();
 
-          this._setResizeEvent();
+        this._setResizeEvent();
 
-          $(this._element).on(Event.CLICK_DISMISS, Selector.DATA_DISMISS, function (event) {
-            return _this.hide(event);
-          });
-          $(this._dialog).on(Event.MOUSEDOWN_DISMISS, function () {
-            $(_this._element).one(Event.MOUSEUP_DISMISS, function (event) {
-              if ($(event.target).is(_this._element)) {
-                _this._ignoreBackdropClick = true;
-              }
-            });
+        (0, _jquery2.default)(this._element).on(Event.CLICK_DISMISS, Selector.DATA_DISMISS, function (event) {
+          return _this.hide(event);
+        });
+        (0, _jquery2.default)(this._dialog).on(Event.MOUSEDOWN_DISMISS, function () {
+          (0, _jquery2.default)(_this._element).one(Event.MOUSEUP_DISMISS, function (event) {
+            if ((0, _jquery2.default)(event.target).is(_this._element)) {
+              _this._ignoreBackdropClick = true;
+            }
           });
+        });
 
-          this._showBackdrop(function () {
-            return _this._showElement(relatedTarget);
-          });
+        this._showBackdrop(function () {
+          return _this._showElement(relatedTarget);
+        });
+      }
+    }, {
+      key: "hide",
+      value: function hide(event) {
+        var _this2 = this;
+
+        if (event) {
+          event.preventDefault();
         }
-      }, {
-        key: "hide",
-        value: function hide(event) {
-          var _this2 = this;
 
-          if (event) {
-            event.preventDefault();
-          }
+        if (!this._isShown || this._isTransitioning) {
+          return;
+        }
 
-          if (this._isTransitioning || !this._isShown) {
-            return;
-          }
+        var hideEvent = _jquery2.default.Event(Event.HIDE);
 
-          var hideEvent = $.Event(Event.HIDE);
-          $(this._element).trigger(hideEvent);
+        (0, _jquery2.default)(this._element).trigger(hideEvent);
 
-          if (!this._isShown || hideEvent.isDefaultPrevented()) {
-            return;
-          }
+        if (!this._isShown || hideEvent.isDefaultPrevented()) {
+          return;
+        }
 
-          this._isShown = false;
-          var transition = _util2.default.supportsTransitionEnd() && $(this._element).hasClass(ClassName.FADE);
+        this._isShown = false;
+        var transition = (0, _jquery2.default)(this._element).hasClass(ClassName.FADE);
 
-          if (transition) {
-            this._isTransitioning = true;
-          }
+        if (transition) {
+          this._isTransitioning = true;
+        }
 
-          this._setEscapeEvent();
+        this._setEscapeEvent();
 
-          this._setResizeEvent();
+        this._setResizeEvent();
 
-          $(document).off(Event.FOCUSIN);
-          $(this._element).removeClass(ClassName.SHOW);
-          $(this._element).off(Event.CLICK_DISMISS);
-          $(this._dialog).off(Event.MOUSEDOWN_DISMISS);
+        (0, _jquery2.default)(document).off(Event.FOCUSIN);
+        (0, _jquery2.default)(this._element).removeClass(ClassName.SHOW);
+        (0, _jquery2.default)(this._element).off(Event.CLICK_DISMISS);
+        (0, _jquery2.default)(this._dialog).off(Event.MOUSEDOWN_DISMISS);
 
-          if (transition) {
-            $(this._element).one(_util2.default.TRANSITION_END, function (event) {
-              return _this2._hideModal(event);
-            }).emulateTransitionEnd(TRANSITION_DURATION);
-          } else {
-            this._hideModal();
-          }
-        }
-      }, {
-        key: "dispose",
-        value: function dispose() {
-          $.removeData(this._element, DATA_KEY);
-          $(window, document, this._element, this._backdrop).off(EVENT_KEY);
-          this._config = null;
-          this._element = null;
-          this._dialog = null;
-          this._backdrop = null;
-          this._isShown = null;
-          this._isBodyOverflowing = null;
-          this._ignoreBackdropClick = null;
-          this._scrollbarWidth = null;
-        }
-      }, {
-        key: "handleUpdate",
-        value: function handleUpdate() {
-          this._adjustDialog();
+        if (transition) {
+          var transitionDuration = _util2.default.getTransitionDurationFromElement(this._element);
+
+          (0, _jquery2.default)(this._element).one(_util2.default.TRANSITION_END, function (event) {
+            return _this2._hideModal(event);
+          }).emulateTransitionEnd(transitionDuration);
+        } else {
+          this._hideModal();
         }
-      }, {
-        key: "_getConfig",
-        value: function _getConfig(config) {
-          config = _extends({}, Default, config);
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        [window, this._element, this._dialog].forEach(function (htmlElement) {
+          return (0, _jquery2.default)(htmlElement).off(EVENT_KEY);
+        });
+        /**
+         * `document` has 2 events `Event.FOCUSIN` and `Event.CLICK_DATA_API`
+         * Do not move `document` in `htmlElements` array
+         * It will remove `Event.CLICK_DATA_API` event that should remain
+         */
 
-          _util2.default.typeCheckConfig(NAME, config, DefaultType);
+        (0, _jquery2.default)(document).off(Event.FOCUSIN);
 
-          return config;
-        }
-      }, {
-        key: "_showElement",
-        value: function _showElement(relatedTarget) {
-          var _this3 = this;
+        _jquery2.default.removeData(this._element, DATA_KEY);
 
-          var transition = _util2.default.supportsTransitionEnd() && $(this._element).hasClass(ClassName.FADE);
+        this._config = null;
+        this._element = null;
+        this._dialog = null;
+        this._backdrop = null;
+        this._isShown = null;
+        this._isBodyOverflowing = null;
+        this._ignoreBackdropClick = null;
+        this._isTransitioning = null;
+        this._scrollbarWidth = null;
+      }
+    }, {
+      key: "handleUpdate",
+      value: function handleUpdate() {
+        this._adjustDialog();
+      }
+    }, {
+      key: "_getConfig",
+      value: function _getConfig(config) {
+        config = _objectSpread({}, Default, config);
 
-          if (!this._element.parentNode || this._element.parentNode.nodeType !== Node.ELEMENT_NODE) {
-            // Don't move modal's DOM position
-            document.body.appendChild(this._element);
-          }
+        _util2.default.typeCheckConfig(NAME, config, DefaultType);
 
-          this._element.style.display = 'block';
+        return config;
+      }
+    }, {
+      key: "_showElement",
+      value: function _showElement(relatedTarget) {
+        var _this3 = this;
 
-          this._element.removeAttribute('aria-hidden');
+        var transition = (0, _jquery2.default)(this._element).hasClass(ClassName.FADE);
 
-          this._element.scrollTop = 0;
+        if (!this._element.parentNode || this._element.parentNode.nodeType !== Node.ELEMENT_NODE) {
+          // Don't move modal's DOM position
+          document.body.appendChild(this._element);
+        }
 
-          if (transition) {
-            _util2.default.reflow(this._element);
-          }
+        this._element.style.display = 'block';
 
-          $(this._element).addClass(ClassName.SHOW);
+        this._element.removeAttribute('aria-hidden');
 
-          if (this._config.focus) {
-            this._enforceFocus();
-          }
+        this._element.setAttribute('aria-modal', true);
 
-          var shownEvent = $.Event(Event.SHOWN, {
-            relatedTarget: relatedTarget
-          });
+        if ((0, _jquery2.default)(this._dialog).hasClass(ClassName.SCROLLABLE)) {
+          this._dialog.querySelector(Selector.MODAL_BODY).scrollTop = 0;
+        } else {
+          this._element.scrollTop = 0;
+        }
 
-          var transitionComplete = function transitionComplete() {
-            if (_this3._config.focus) {
-              _this3._element.focus();
-            }
+        if (transition) {
+          _util2.default.reflow(this._element);
+        }
 
-            _this3._isTransitioning = false;
-            $(_this3._element).trigger(shownEvent);
-          };
+        (0, _jquery2.default)(this._element).addClass(ClassName.SHOW);
 
-          if (transition) {
-            $(this._dialog).one(_util2.default.TRANSITION_END, transitionComplete).emulateTransitionEnd(TRANSITION_DURATION);
-          } else {
-            transitionComplete();
+        if (this._config.focus) {
+          this._enforceFocus();
+        }
+
+        var shownEvent = _jquery2.default.Event(Event.SHOWN, {
+          relatedTarget: relatedTarget
+        });
+
+        var transitionComplete = function transitionComplete() {
+          if (_this3._config.focus) {
+            _this3._element.focus();
           }
+
+          _this3._isTransitioning = false;
+          (0, _jquery2.default)(_this3._element).trigger(shownEvent);
+        };
+
+        if (transition) {
+          var transitionDuration = _util2.default.getTransitionDurationFromElement(this._dialog);
+
+          (0, _jquery2.default)(this._dialog).one(_util2.default.TRANSITION_END, transitionComplete).emulateTransitionEnd(transitionDuration);
+        } else {
+          transitionComplete();
         }
-      }, {
-        key: "_enforceFocus",
-        value: function _enforceFocus() {
-          var _this4 = this;
-
-          $(document).off(Event.FOCUSIN) // Guard against infinite focus loop
-          .on(Event.FOCUSIN, function (event) {
-            if (document !== event.target && _this4._element !== event.target && $(_this4._element).has(event.target).length === 0) {
-              _this4._element.focus();
+      }
+    }, {
+      key: "_enforceFocus",
+      value: function _enforceFocus() {
+        var _this4 = this;
+
+        (0, _jquery2.default)(document).off(Event.FOCUSIN) // Guard against infinite focus loop
+        .on(Event.FOCUSIN, function (event) {
+          if (document !== event.target && _this4._element !== event.target && (0, _jquery2.default)(_this4._element).has(event.target).length === 0) {
+            _this4._element.focus();
+          }
+        });
+      }
+    }, {
+      key: "_setEscapeEvent",
+      value: function _setEscapeEvent() {
+        var _this5 = this;
+
+        if (this._isShown && this._config.keyboard) {
+          (0, _jquery2.default)(this._element).on(Event.KEYDOWN_DISMISS, function (event) {
+            if (event.which === ESCAPE_KEYCODE) {
+              event.preventDefault();
+
+              _this5.hide();
             }
           });
+        } else if (!this._isShown) {
+          (0, _jquery2.default)(this._element).off(Event.KEYDOWN_DISMISS);
         }
-      }, {
-        key: "_setEscapeEvent",
-        value: function _setEscapeEvent() {
-          var _this5 = this;
-
-          if (this._isShown && this._config.keyboard) {
-            $(this._element).on(Event.KEYDOWN_DISMISS, function (event) {
-              if (event.which === ESCAPE_KEYCODE) {
-                event.preventDefault();
-
-                _this5.hide();
-              }
-            });
-          } else if (!this._isShown) {
-            $(this._element).off(Event.KEYDOWN_DISMISS);
-          }
-        }
-      }, {
-        key: "_setResizeEvent",
-        value: function _setResizeEvent() {
-          var _this6 = this;
-
-          if (this._isShown) {
-            $(window).on(Event.RESIZE, function (event) {
-              return _this6.handleUpdate(event);
-            });
-          } else {
-            $(window).off(Event.RESIZE);
-          }
+      }
+    }, {
+      key: "_setResizeEvent",
+      value: function _setResizeEvent() {
+        var _this6 = this;
+
+        if (this._isShown) {
+          (0, _jquery2.default)(window).on(Event.RESIZE, function (event) {
+            return _this6.handleUpdate(event);
+          });
+        } else {
+          (0, _jquery2.default)(window).off(Event.RESIZE);
         }
-      }, {
-        key: "_hideModal",
-        value: function _hideModal() {
-          var _this7 = this;
+      }
+    }, {
+      key: "_hideModal",
+      value: function _hideModal() {
+        var _this7 = this;
 
-          this._element.style.display = 'none';
+        this._element.style.display = 'none';
 
-          this._element.setAttribute('aria-hidden', true);
+        this._element.setAttribute('aria-hidden', true);
 
-          this._isTransitioning = false;
+        this._element.removeAttribute('aria-modal');
 
-          this._showBackdrop(function () {
-            $(document.body).removeClass(ClassName.OPEN);
+        this._isTransitioning = false;
 
-            _this7._resetAdjustments();
+        this._showBackdrop(function () {
+          (0, _jquery2.default)(document.body).removeClass(ClassName.OPEN);
 
-            _this7._resetScrollbar();
+          _this7._resetAdjustments();
 
-            $(_this7._element).trigger(Event.HIDDEN);
-          });
-        }
-      }, {
-        key: "_removeBackdrop",
-        value: function _removeBackdrop() {
-          if (this._backdrop) {
-            $(this._backdrop).remove();
-            this._backdrop = null;
-          }
+          _this7._resetScrollbar();
+
+          (0, _jquery2.default)(_this7._element).trigger(Event.HIDDEN);
+        });
+      }
+    }, {
+      key: "_removeBackdrop",
+      value: function _removeBackdrop() {
+        if (this._backdrop) {
+          (0, _jquery2.default)(this._backdrop).remove();
+          this._backdrop = null;
         }
-      }, {
-        key: "_showBackdrop",
-        value: function _showBackdrop(callback) {
-          var _this8 = this;
+      }
+    }, {
+      key: "_showBackdrop",
+      value: function _showBackdrop(callback) {
+        var _this8 = this;
 
-          var animate = $(this._element).hasClass(ClassName.FADE) ? ClassName.FADE : '';
+        var animate = (0, _jquery2.default)(this._element).hasClass(ClassName.FADE) ? ClassName.FADE : '';
 
-          if (this._isShown && this._config.backdrop) {
-            var doAnimate = _util2.default.supportsTransitionEnd() && animate;
-            this._backdrop = document.createElement('div');
-            this._backdrop.className = ClassName.BACKDROP;
+        if (this._isShown && this._config.backdrop) {
+          this._backdrop = document.createElement('div');
+          this._backdrop.className = ClassName.BACKDROP;
 
-            if (animate) {
-              $(this._backdrop).addClass(animate);
-            }
+          if (animate) {
+            this._backdrop.classList.add(animate);
+          }
 
-            $(this._backdrop).appendTo(document.body);
-            $(this._element).on(Event.CLICK_DISMISS, function (event) {
-              if (_this8._ignoreBackdropClick) {
-                _this8._ignoreBackdropClick = false;
-                return;
-              }
-
-              if (event.target !== event.currentTarget) {
-                return;
-              }
-
-              if (_this8._config.backdrop === 'static') {
-                _this8._element.focus();
-              } else {
-                _this8.hide();
-              }
-            });
-
-            if (doAnimate) {
-              _util2.default.reflow(this._backdrop);
+          (0, _jquery2.default)(this._backdrop).appendTo(document.body);
+          (0, _jquery2.default)(this._element).on(Event.CLICK_DISMISS, function (event) {
+            if (_this8._ignoreBackdropClick) {
+              _this8._ignoreBackdropClick = false;
+              return;
             }
 
-            $(this._backdrop).addClass(ClassName.SHOW);
-
-            if (!callback) {
+            if (event.target !== event.currentTarget) {
               return;
             }
 
-            if (!doAnimate) {
-              callback();
-              return;
+            if (_this8._config.backdrop === 'static') {
+              _this8._element.focus();
+            } else {
+              _this8.hide();
             }
+          });
 
-            $(this._backdrop).one(_util2.default.TRANSITION_END, callback).emulateTransitionEnd(BACKDROP_TRANSITION_DURATION);
-          } else if (!this._isShown && this._backdrop) {
-            $(this._backdrop).removeClass(ClassName.SHOW);
+          if (animate) {
+            _util2.default.reflow(this._backdrop);
+          }
 
-            var callbackRemove = function callbackRemove() {
-              _this8._removeBackdrop();
+          (0, _jquery2.default)(this._backdrop).addClass(ClassName.SHOW);
 
-              if (callback) {
-                callback();
-              }
-            };
+          if (!callback) {
+            return;
+          }
 
-            if (_util2.default.supportsTransitionEnd() && $(this._element).hasClass(ClassName.FADE)) {
-              $(this._backdrop).one(_util2.default.TRANSITION_END, callbackRemove).emulateTransitionEnd(BACKDROP_TRANSITION_DURATION);
-            } else {
-              callbackRemove();
-            }
-          } else if (callback) {
+          if (!animate) {
             callback();
+            return;
           }
-        }
-      }, {
-        key: "_adjustDialog",
-        value: function _adjustDialog() {
-          var isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight;
 
-          if (!this._isBodyOverflowing && isModalOverflowing) {
-            this._element.style.paddingLeft = "".concat(this._scrollbarWidth, "px");
-          }
+          var backdropTransitionDuration = _util2.default.getTransitionDurationFromElement(this._backdrop);
+
+          (0, _jquery2.default)(this._backdrop).one(_util2.default.TRANSITION_END, callback).emulateTransitionEnd(backdropTransitionDuration);
+        } else if (!this._isShown && this._backdrop) {
+          (0, _jquery2.default)(this._backdrop).removeClass(ClassName.SHOW);
+
+          var callbackRemove = function callbackRemove() {
+            _this8._removeBackdrop();
 
-          if (this._isBodyOverflowing && !isModalOverflowing) {
-            this._element.style.paddingRight = "".concat(this._scrollbarWidth, "px");
+            if (callback) {
+              callback();
+            }
+          };
+
+          if ((0, _jquery2.default)(this._element).hasClass(ClassName.FADE)) {
+            var _backdropTransitionDuration = _util2.default.getTransitionDurationFromElement(this._backdrop);
+
+            (0, _jquery2.default)(this._backdrop).one(_util2.default.TRANSITION_END, callbackRemove).emulateTransitionEnd(_backdropTransitionDuration);
+          } else {
+            callbackRemove();
           }
+        } else if (callback) {
+          callback();
         }
-      }, {
-        key: "_resetAdjustments",
-        value: function _resetAdjustments() {
-          this._element.style.paddingLeft = '';
-          this._element.style.paddingRight = '';
+      }
+    }, {
+      key: "_adjustDialog",
+      value: function _adjustDialog() {
+        var isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight;
+
+        if (!this._isBodyOverflowing && isModalOverflowing) {
+          this._element.style.paddingLeft = "".concat(this._scrollbarWidth, "px");
         }
-      }, {
-        key: "_checkScrollbar",
-        value: function _checkScrollbar() {
-          var rect = document.body.getBoundingClientRect();
-          this._isBodyOverflowing = rect.left + rect.right < window.innerWidth;
-          this._scrollbarWidth = this._getScrollbarWidth();
+
+        if (this._isBodyOverflowing && !isModalOverflowing) {
+          this._element.style.paddingRight = "".concat(this._scrollbarWidth, "px");
         }
-      }, {
-        key: "_setScrollbar",
-        value: function _setScrollbar() {
-          var _this9 = this;
-
-          if (this._isBodyOverflowing) {
-            // Note: DOMNode.style.paddingRight returns the actual value or '' if not set
-            //   while $(DOMNode).css('padding-right') returns the calculated value or 0 if not set
-            // Adjust fixed content padding
-            $(Selector.FIXED_CONTENT).each(function (index, element) {
-              var actualPadding = $(element)[0].style.paddingRight;
-              var calculatedPadding = $(element).css('padding-right');
-              $(element).data('padding-right', actualPadding).css('padding-right', "".concat(parseFloat(calculatedPadding) + _this9._scrollbarWidth, "px"));
-            }); // Adjust sticky content margin
-
-            $(Selector.STICKY_CONTENT).each(function (index, element) {
-              var actualMargin = $(element)[0].style.marginRight;
-              var calculatedMargin = $(element).css('margin-right');
-              $(element).data('margin-right', actualMargin).css('margin-right', "".concat(parseFloat(calculatedMargin) - _this9._scrollbarWidth, "px"));
-            }); // Adjust navbar-toggler margin
-
-            $(Selector.NAVBAR_TOGGLER).each(function (index, element) {
-              var actualMargin = $(element)[0].style.marginRight;
-              var calculatedMargin = $(element).css('margin-right');
-              $(element).data('margin-right', actualMargin).css('margin-right', "".concat(parseFloat(calculatedMargin) + _this9._scrollbarWidth, "px"));
-            }); // Adjust body padding
-
-            var actualPadding = document.body.style.paddingRight;
-            var calculatedPadding = $('body').css('padding-right');
-            $('body').data('padding-right', actualPadding).css('padding-right', "".concat(parseFloat(calculatedPadding) + this._scrollbarWidth, "px"));
-          }
+      }
+    }, {
+      key: "_resetAdjustments",
+      value: function _resetAdjustments() {
+        this._element.style.paddingLeft = '';
+        this._element.style.paddingRight = '';
+      }
+    }, {
+      key: "_checkScrollbar",
+      value: function _checkScrollbar() {
+        var rect = document.body.getBoundingClientRect();
+        this._isBodyOverflowing = rect.left + rect.right < window.innerWidth;
+        this._scrollbarWidth = this._getScrollbarWidth();
+      }
+    }, {
+      key: "_setScrollbar",
+      value: function _setScrollbar() {
+        var _this9 = this;
+
+        if (this._isBodyOverflowing) {
+          // Note: DOMNode.style.paddingRight returns the actual value or '' if not set
+          //   while $(DOMNode).css('padding-right') returns the calculated value or 0 if not set
+          var fixedContent = [].slice.call(document.querySelectorAll(Selector.FIXED_CONTENT));
+          var stickyContent = [].slice.call(document.querySelectorAll(Selector.STICKY_CONTENT)); // Adjust fixed content padding
+
+          (0, _jquery2.default)(fixedContent).each(function (index, element) {
+            var actualPadding = element.style.paddingRight;
+            var calculatedPadding = (0, _jquery2.default)(element).css('padding-right');
+            (0, _jquery2.default)(element).data('padding-right', actualPadding).css('padding-right', "".concat(parseFloat(calculatedPadding) + _this9._scrollbarWidth, "px"));
+          }); // Adjust sticky content margin
+
+          (0, _jquery2.default)(stickyContent).each(function (index, element) {
+            var actualMargin = element.style.marginRight;
+            var calculatedMargin = (0, _jquery2.default)(element).css('margin-right');
+            (0, _jquery2.default)(element).data('margin-right', actualMargin).css('margin-right', "".concat(parseFloat(calculatedMargin) - _this9._scrollbarWidth, "px"));
+          }); // Adjust body padding
+
+          var actualPadding = document.body.style.paddingRight;
+          var calculatedPadding = (0, _jquery2.default)(document.body).css('padding-right');
+          (0, _jquery2.default)(document.body).data('padding-right', actualPadding).css('padding-right', "".concat(parseFloat(calculatedPadding) + this._scrollbarWidth, "px"));
         }
-      }, {
-        key: "_resetScrollbar",
-        value: function _resetScrollbar() {
-          // Restore fixed content padding
-          $(Selector.FIXED_CONTENT).each(function (index, element) {
-            var padding = $(element).data('padding-right');
-
-            if (typeof padding !== 'undefined') {
-              $(element).css('padding-right', padding).removeData('padding-right');
-            }
-          }); // Restore sticky content and navbar-toggler margin
 
-          $("".concat(Selector.STICKY_CONTENT, ", ").concat(Selector.NAVBAR_TOGGLER)).each(function (index, element) {
-            var margin = $(element).data('margin-right');
+        (0, _jquery2.default)(document.body).addClass(ClassName.OPEN);
+      }
+    }, {
+      key: "_resetScrollbar",
+      value: function _resetScrollbar() {
+        // Restore fixed content padding
+        var fixedContent = [].slice.call(document.querySelectorAll(Selector.FIXED_CONTENT));
+        (0, _jquery2.default)(fixedContent).each(function (index, element) {
+          var padding = (0, _jquery2.default)(element).data('padding-right');
+          (0, _jquery2.default)(element).removeData('padding-right');
+          element.style.paddingRight = padding ? padding : '';
+        }); // Restore sticky content
+
+        var elements = [].slice.call(document.querySelectorAll("".concat(Selector.STICKY_CONTENT)));
+        (0, _jquery2.default)(elements).each(function (index, element) {
+          var margin = (0, _jquery2.default)(element).data('margin-right');
+
+          if (typeof margin !== 'undefined') {
+            (0, _jquery2.default)(element).css('margin-right', margin).removeData('margin-right');
+          }
+        }); // Restore body padding
 
-            if (typeof margin !== 'undefined') {
-              $(element).css('margin-right', margin).removeData('margin-right');
-            }
-          }); // Restore body padding
+        var padding = (0, _jquery2.default)(document.body).data('padding-right');
+        (0, _jquery2.default)(document.body).removeData('padding-right');
+        document.body.style.paddingRight = padding ? padding : '';
+      }
+    }, {
+      key: "_getScrollbarWidth",
+      value: function _getScrollbarWidth() {
+        // thx d.walsh
+        var scrollDiv = document.createElement('div');
+        scrollDiv.className = ClassName.SCROLLBAR_MEASURER;
+        document.body.appendChild(scrollDiv);
+        var scrollbarWidth = scrollDiv.getBoundingClientRect().width - scrollDiv.clientWidth;
+        document.body.removeChild(scrollDiv);
+        return scrollbarWidth;
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config, relatedTarget) {
+        return this.each(function () {
+          var data = (0, _jquery2.default)(this).data(DATA_KEY);
 
-          var padding = $('body').data('padding-right');
+          var _config = _objectSpread({}, Default, (0, _jquery2.default)(this).data(), _typeof(config) === 'object' && config ? config : {});
 
-          if (typeof padding !== 'undefined') {
-            $('body').css('padding-right', padding).removeData('padding-right');
+          if (!data) {
+            data = new Modal(this, _config);
+            (0, _jquery2.default)(this).data(DATA_KEY, data);
           }
-        }
-      }, {
-        key: "_getScrollbarWidth",
-        value: function _getScrollbarWidth() {
-          // thx d.walsh
-          var scrollDiv = document.createElement('div');
-          scrollDiv.className = ClassName.SCROLLBAR_MEASURER;
-          document.body.appendChild(scrollDiv);
-          var scrollbarWidth = scrollDiv.getBoundingClientRect().width - scrollDiv.clientWidth;
-          document.body.removeChild(scrollDiv);
-          return scrollbarWidth;
-        }
-      }], [{
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config, relatedTarget) {
-          return this.each(function () {
-            var data = $(this).data(DATA_KEY);
-
-            var _config = _extends({}, Modal.Default, $(this).data(), _typeof(config) === 'object' && config);
 
-            if (!data) {
-              data = new Modal(this, _config);
-              $(this).data(DATA_KEY, data);
+          if (typeof config === 'string') {
+            if (typeof data[config] === 'undefined') {
+              throw new TypeError("No method named \"".concat(config, "\""));
             }
 
-            if (typeof config === 'string') {
-              if (typeof data[config] === 'undefined') {
-                throw new TypeError("No method named \"".concat(config, "\""));
-              }
+            data[config](relatedTarget);
+          } else if (_config.show) {
+            data.show(relatedTarget);
+          }
+        });
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }, {
+      key: "Default",
+      get: function get() {
+        return Default;
+      }
+    }]);
 
-              data[config](relatedTarget);
-            } else if (_config.show) {
-              data.show(relatedTarget);
-            }
-          });
-        }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
-        }
-      }, {
-        key: "Default",
-        get: function get() {
-          return Default;
-        }
-      }]);
+    return Modal;
+  }();
 
-      return Modal;
-    }();
+  /**
+   * ------------------------------------------------------------------------
+   * Data Api implementation
+   * ------------------------------------------------------------------------
+   */
+  (0, _jquery2.default)(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
+    var _this10 = this;
 
-    /**
-     * ------------------------------------------------------------------------
-     * Data Api implementation
-     * ------------------------------------------------------------------------
-     */
-    $(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
-      var _this10 = this;
+    var target;
 
-      var target;
+    var selector = _util2.default.getSelectorFromElement(this);
 
-      var selector = _util2.default.getSelectorFromElement(this);
+    if (selector) {
+      target = document.querySelector(selector);
+    }
 
-      if (selector) {
-        target = $(selector)[0];
-      }
+    var config = (0, _jquery2.default)(target).data(DATA_KEY) ? 'toggle' : _objectSpread({}, (0, _jquery2.default)(target).data(), (0, _jquery2.default)(this).data());
 
-      var config = $(target).data(DATA_KEY) ? 'toggle' : _extends({}, $(target).data(), $(this).data());
+    if (this.tagName === 'A' || this.tagName === 'AREA') {
+      event.preventDefault();
+    }
 
-      if (this.tagName === 'A' || this.tagName === 'AREA') {
-        event.preventDefault();
+    var $target = (0, _jquery2.default)(target).one(Event.SHOW, function (showEvent) {
+      if (showEvent.isDefaultPrevented()) {
+        // Only register focus restorer if modal will actually get shown
+        return;
       }
 
-      var $target = $(target).one(Event.SHOW, function (showEvent) {
-        if (showEvent.isDefaultPrevented()) {
-          // Only register focus restorer if modal will actually get shown
-          return;
+      $target.one(Event.HIDDEN, function () {
+        if ((0, _jquery2.default)(_this10).is(':visible')) {
+          _this10.focus();
         }
-
-        $target.one(Event.HIDDEN, function () {
-          if ($(_this10).is(':visible')) {
-            _this10.focus();
-          }
-        });
       });
-
-      Modal._jQueryInterface.call($(target), config, this);
     });
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
 
-    $.fn[NAME] = Modal._jQueryInterface;
-    $.fn[NAME].Constructor = Modal;
+    Modal._jQueryInterface.call((0, _jquery2.default)(target), config, this);
+  });
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return Modal._jQueryInterface;
-    };
+  _jquery2.default.fn[NAME] = Modal._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Modal;
 
-    return Modal;
-  }(_jquery2.default);
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Modal._jQueryInterface;
+  };
 
   exports.default = Modal;
 });
\ No newline at end of file
index 1878a0b..2e25c81 100644 (file)
@@ -92,6 +92,17 @@ define(['jquery'], function($) {
             },
         ],
 
+        toast: [
+            {
+                start: 'hide',
+                end: 'hidden',
+            },
+            {
+                start: 'show',
+                end: 'shown',
+            },
+        ],
+
         tooltip: [
             {
                 start: 'hide',
index bc88d80..b9a2638 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery", "./tooltip"], function (exports, _jquery, _tooltip) {
   "use strict";
 
@@ -56,6 +58,10 @@ define(["exports", "jquery", "./tooltip"], function (exports, _jquery, _tooltip)
       return call;
     }
 
+    return _assertThisInitialized(self);
+  }
+
+  function _assertThisInitialized(self) {
     if (self === void 0) {
       throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
     }
@@ -71,227 +77,241 @@ define(["exports", "jquery", "./tooltip"], function (exports, _jquery, _tooltip)
     subClass.prototype = Object.create(superClass && superClass.prototype, {
       constructor: {
         value: subClass,
-        enumerable: false,
         writable: true,
         configurable: true
       }
     });
-    if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass;
+    if (superClass) _setPrototypeOf(subClass, superClass);
   }
 
-  function _extends() {
-    _extends = Object.assign || function (target) {
-      for (var i = 1; i < arguments.length; i++) {
-        var source = arguments[i];
+  function _setPrototypeOf(o, p) {
+    _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
+      o.__proto__ = p;
+      return o;
+    };
 
-        for (var key in source) {
-          if (Object.prototype.hasOwnProperty.call(source, key)) {
-            target[key] = source[key];
-          }
-        }
+    return _setPrototypeOf(o, p);
+  }
+
+  function _objectSpread(target) {
+    for (var i = 1; i < arguments.length; i++) {
+      var source = arguments[i] != null ? arguments[i] : {};
+      var ownKeys = Object.keys(source);
+
+      if (typeof Object.getOwnPropertySymbols === 'function') {
+        ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
+          return Object.getOwnPropertyDescriptor(source, sym).enumerable;
+        }));
       }
 
-      return target;
-    };
+      ownKeys.forEach(function (key) {
+        _defineProperty(target, key, source[key]);
+      });
+    }
 
-    return _extends.apply(this, arguments);
+    return target;
+  }
+
+  function _defineProperty(obj, key, value) {
+    if (key in obj) {
+      Object.defineProperty(obj, key, {
+        value: value,
+        enumerable: true,
+        configurable: true,
+        writable: true
+      });
+    } else {
+      obj[key] = value;
+    }
+
+    return obj;
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): popover.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var Popover = function ($) {
+  var NAME = 'popover';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.popover';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var CLASS_PREFIX = 'bs-popover';
+  var BSCLS_PREFIX_REGEX = new RegExp("(^|\\s)".concat(CLASS_PREFIX, "\\S+"), 'g');
+
+  var Default = _objectSpread({}, _tooltip2.default.Default, {
+    placement: 'right',
+    trigger: 'click',
+    content: '',
+    template: '<div class="popover" role="tooltip">' + '<div class="arrow"></div>' + '<h3 class="popover-header"></h3>' + '<div class="popover-body"></div></div>'
+  });
+
+  var DefaultType = _objectSpread({}, _tooltip2.default.DefaultType, {
+    content: '(string|element|function)'
+  });
+
+  var ClassName = {
+    FADE: 'fade',
+    SHOW: 'show'
+  };
+  var Selector = {
+    TITLE: '.popover-header',
+    CONTENT: '.popover-body'
+  };
+  var Event = {
+    HIDE: "hide".concat(EVENT_KEY),
+    HIDDEN: "hidden".concat(EVENT_KEY),
+    SHOW: "show".concat(EVENT_KEY),
+    SHOWN: "shown".concat(EVENT_KEY),
+    INSERTED: "inserted".concat(EVENT_KEY),
+    CLICK: "click".concat(EVENT_KEY),
+    FOCUSIN: "focusin".concat(EVENT_KEY),
+    FOCUSOUT: "focusout".concat(EVENT_KEY),
+    MOUSEENTER: "mouseenter".concat(EVENT_KEY),
+    MOUSELEAVE: "mouseleave".concat(EVENT_KEY)
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'popover';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.popover';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var CLASS_PREFIX = 'bs-popover';
-    var BSCLS_PREFIX_REGEX = new RegExp("(^|\\s)".concat(CLASS_PREFIX, "\\S+"), 'g');
-
-    var Default = _extends({}, _tooltip2.default.Default, {
-      placement: 'right',
-      trigger: 'click',
-      content: '',
-      template: '<div class="popover" role="tooltip">' + '<div class="arrow"></div>' + '<h3 class="popover-header"></h3>' + '<div class="popover-body"></div></div>'
-    });
 
-    var DefaultType = _extends({}, _tooltip2.default.DefaultType, {
-      content: '(string|element|function)'
-    });
+  };
 
-    var ClassName = {
-      FADE: 'fade',
-      SHOW: 'show'
-    };
-    var Selector = {
-      TITLE: '.popover-header',
-      CONTENT: '.popover-body'
-    };
-    var Event = {
-      HIDE: "hide".concat(EVENT_KEY),
-      HIDDEN: "hidden".concat(EVENT_KEY),
-      SHOW: "show".concat(EVENT_KEY),
-      SHOWN: "shown".concat(EVENT_KEY),
-      INSERTED: "inserted".concat(EVENT_KEY),
-      CLICK: "click".concat(EVENT_KEY),
-      FOCUSIN: "focusin".concat(EVENT_KEY),
-      FOCUSOUT: "focusout".concat(EVENT_KEY),
-      MOUSEENTER: "mouseenter".concat(EVENT_KEY),
-      MOUSELEAVE: "mouseleave".concat(EVENT_KEY)
-      /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
-       */
-
-    };
+  var Popover = function (_Tooltip) {
+    _inherits(Popover, _Tooltip);
 
-    var Popover = function (_Tooltip) {
-      _inherits(Popover, _Tooltip);
+    function Popover() {
+      _classCallCheck(this, Popover);
 
-      function Popover() {
-        _classCallCheck(this, Popover);
+      return _possibleConstructorReturn(this, (Popover.__proto__ || Object.getPrototypeOf(Popover)).apply(this, arguments));
+    }
 
-        return _possibleConstructorReturn(this, (Popover.__proto__ || Object.getPrototypeOf(Popover)).apply(this, arguments));
+    _createClass(Popover, [{
+      key: "isWithContent",
+      value: function isWithContent() {
+        return this.getTitle() || this._getContent();
       }
+    }, {
+      key: "addAttachmentClass",
+      value: function addAttachmentClass(attachment) {
+        (0, _jquery2.default)(this.getTipElement()).addClass("".concat(CLASS_PREFIX, "-").concat(attachment));
+      }
+    }, {
+      key: "getTipElement",
+      value: function getTipElement() {
+        this.tip = this.tip || (0, _jquery2.default)(this.config.template)[0];
+        return this.tip;
+      }
+    }, {
+      key: "setContent",
+      value: function setContent() {
+        var $tip = (0, _jquery2.default)(this.getTipElement()); // We use append for html objects to maintain js events
 
-      _createClass(Popover, [{
-        key: "isWithContent",
-        value: function isWithContent() {
-          return this.getTitle() || this._getContent();
-        }
-      }, {
-        key: "addAttachmentClass",
-        value: function addAttachmentClass(attachment) {
-          $(this.getTipElement()).addClass("".concat(CLASS_PREFIX, "-").concat(attachment));
-        }
-      }, {
-        key: "getTipElement",
-        value: function getTipElement() {
-          this.tip = this.tip || $(this.config.template)[0];
-          return this.tip;
-        }
-      }, {
-        key: "setContent",
-        value: function setContent() {
-          var $tip = $(this.getTipElement()); // We use append for html objects to maintain js events
-
-          this.setElementContent($tip.find(Selector.TITLE), this.getTitle());
-
-          var content = this._getContent();
+        this.setElementContent($tip.find(Selector.TITLE), this.getTitle());
 
-          if (typeof content === 'function') {
-            content = content.call(this.element);
-          }
+        var content = this._getContent();
 
-          this.setElementContent($tip.find(Selector.CONTENT), content);
-          $tip.removeClass("".concat(ClassName.FADE, " ").concat(ClassName.SHOW));
-        }
-      }, {
-        key: "_getContent",
-        value: function _getContent() {
-          return this.element.getAttribute('data-content') || this.config.content;
+        if (typeof content === 'function') {
+          content = content.call(this.element);
         }
-      }, {
-        key: "_cleanTipClass",
-        value: function _cleanTipClass() {
-          var $tip = $(this.getTipElement());
-          var tabClass = $tip.attr('class').match(BSCLS_PREFIX_REGEX);
-
-          if (tabClass !== null && tabClass.length > 0) {
-            $tip.removeClass(tabClass.join(''));
-          }
-        }
-      }], [{
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config) {
-          return this.each(function () {
-            var data = $(this).data(DATA_KEY);
 
-            var _config = _typeof(config) === 'object' ? config : null;
+        this.setElementContent($tip.find(Selector.CONTENT), content);
+        $tip.removeClass("".concat(ClassName.FADE, " ").concat(ClassName.SHOW));
+      }
+    }, {
+      key: "_getContent",
+      value: function _getContent() {
+        return this.element.getAttribute('data-content') || this.config.content;
+      }
+    }, {
+      key: "_cleanTipClass",
+      value: function _cleanTipClass() {
+        var $tip = (0, _jquery2.default)(this.getTipElement());
+        var tabClass = $tip.attr('class').match(BSCLS_PREFIX_REGEX);
+
+        if (tabClass !== null && tabClass.length > 0) {
+          $tip.removeClass(tabClass.join(''));
+        }
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var data = (0, _jquery2.default)(this).data(DATA_KEY);
 
-            if (!data && /destroy|hide/.test(config)) {
-              return;
-            }
+          var _config = _typeof(config) === 'object' ? config : null;
 
-            if (!data) {
-              data = new Popover(this, _config);
-              $(this).data(DATA_KEY, data);
-            }
+          if (!data && /dispose|hide/.test(config)) {
+            return;
+          }
 
-            if (typeof config === 'string') {
-              if (typeof data[config] === 'undefined') {
-                throw new TypeError("No method named \"".concat(config, "\""));
-              }
+          if (!data) {
+            data = new Popover(this, _config);
+            (0, _jquery2.default)(this).data(DATA_KEY, data);
+          }
 
-              data[config]();
+          if (typeof config === 'string') {
+            if (typeof data[config] === 'undefined') {
+              throw new TypeError("No method named \"".concat(config, "\""));
             }
-          });
-        }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
-        }
-      }, {
-        key: "Default",
-        get: function get() {
-          return Default;
-        }
-      }, {
-        key: "NAME",
-        get: function get() {
-          return NAME;
-        }
-      }, {
-        key: "DATA_KEY",
-        get: function get() {
-          return DATA_KEY;
-        }
-      }, {
-        key: "Event",
-        get: function get() {
-          return Event;
-        }
-      }, {
-        key: "EVENT_KEY",
-        get: function get() {
-          return EVENT_KEY;
-        }
-      }, {
-        key: "DefaultType",
-        get: function get() {
-          return DefaultType;
-        }
-      }]);
 
-      return Popover;
-    }(_tooltip2.default);
+            data[config]();
+          }
+        });
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }, {
+      key: "Default",
+      get: function get() {
+        return Default;
+      }
+    }, {
+      key: "NAME",
+      get: function get() {
+        return NAME;
+      }
+    }, {
+      key: "DATA_KEY",
+      get: function get() {
+        return DATA_KEY;
+      }
+    }, {
+      key: "Event",
+      get: function get() {
+        return Event;
+      }
+    }, {
+      key: "EVENT_KEY",
+      get: function get() {
+        return EVENT_KEY;
+      }
+    }, {
+      key: "DefaultType",
+      get: function get() {
+        return DefaultType;
+      }
+    }]);
 
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
-    $.fn[NAME] = Popover._jQueryInterface;
-    $.fn[NAME].Constructor = Popover;
+    return Popover;
+  }(_tooltip2.default);
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return Popover._jQueryInterface;
-    };
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
+  _jquery2.default.fn[NAME] = Popover._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Popover;
 
-    return Popover;
-  }(_jquery2.default);
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Popover._jQueryInterface;
+  };
 
   exports.default = Popover;
 });
\ No newline at end of file
diff --git a/theme/boost/amd/src/sanitizer.js b/theme/boost/amd/src/sanitizer.js
new file mode 100644 (file)
index 0000000..b457529
--- /dev/null
@@ -0,0 +1,131 @@
+"use strict";
+
+define(["exports"], function (exports) {
+  "use strict";
+
+  Object.defineProperty(exports, "__esModule", {
+    value: true
+  });
+  exports.sanitizeHtml = sanitizeHtml;
+
+  /**
+   * --------------------------------------------------------------------------
+   * Bootstrap (v4.3.1): tools/sanitizer.js
+   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+   * --------------------------------------------------------------------------
+   */
+  var uriAttrs = ['background', 'cite', 'href', 'itemtype', 'longdesc', 'poster', 'src', 'xlink:href'];
+  var ARIA_ATTRIBUTE_PATTERN = /^aria-[\w-]*$/i;
+  var DefaultWhitelist = exports.DefaultWhitelist = {
+    // Global attributes allowed on any supplied element below.
+    '*': ['class', 'dir', 'id', 'lang', 'role', ARIA_ATTRIBUTE_PATTERN],
+    a: ['target', 'href', 'title', 'rel'],
+    area: [],
+    b: [],
+    br: [],
+    col: [],
+    code: [],
+    div: [],
+    em: [],
+    hr: [],
+    h1: [],
+    h2: [],
+    h3: [],
+    h4: [],
+    h5: [],
+    h6: [],
+    i: [],
+    img: ['src', 'alt', 'title', 'width', 'height'],
+    li: [],
+    ol: [],
+    p: [],
+    pre: [],
+    s: [],
+    small: [],
+    span: [],
+    sub: [],
+    sup: [],
+    strong: [],
+    u: [],
+    ul: []
+    /**
+     * A pattern that recognizes a commonly useful subset of URLs that are safe.
+     *
+     * Shoutout to Angular 7 https://github.com/angular/angular/blob/7.2.4/packages/core/src/sanitization/url_sanitizer.ts
+     */
+
+  };
+  var SAFE_URL_PATTERN = /^(?:(?:https?|mailto|ftp|tel|file):|[^&:/?#]*(?:[/?#]|$))/gi;
+  /**
+   * A pattern that matches safe data URLs. Only matches image, video and audio types.
+   *
+   * Shoutout to Angular 7 https://github.com/angular/angular/blob/7.2.4/packages/core/src/sanitization/url_sanitizer.ts
+   */
+
+  var DATA_URL_PATTERN = /^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+/]+=*$/i;
+
+  function allowedAttribute(attr, allowedAttributeList) {
+    var attrName = attr.nodeName.toLowerCase();
+
+    if (allowedAttributeList.indexOf(attrName) !== -1) {
+      if (uriAttrs.indexOf(attrName) !== -1) {
+        return Boolean(attr.nodeValue.match(SAFE_URL_PATTERN) || attr.nodeValue.match(DATA_URL_PATTERN));
+      }
+
+      return true;
+    }
+
+    var regExp = allowedAttributeList.filter(function (attrRegex) {
+      return attrRegex instanceof RegExp;
+    }); // Check if a regular expression validates the attribute.
+
+    for (var i = 0, l = regExp.length; i < l; i++) {
+      if (attrName.match(regExp[i])) {
+        return true;
+      }
+    }
+
+    return false;
+  }
+
+  function sanitizeHtml(unsafeHtml, whiteList, sanitizeFn) {
+    if (unsafeHtml.length === 0) {
+      return unsafeHtml;
+    }
+
+    if (sanitizeFn && typeof sanitizeFn === 'function') {
+      return sanitizeFn(unsafeHtml);
+    }
+
+    var domParser = new window.DOMParser();
+    var createdDocument = domParser.parseFromString(unsafeHtml, 'text/html');
+    var whitelistKeys = Object.keys(whiteList);
+    var elements = [].slice.call(createdDocument.body.querySelectorAll('*'));
+
+    var _loop = function _loop(i, len) {
+      var el = elements[i];
+      var elName = el.nodeName.toLowerCase();
+
+      if (whitelistKeys.indexOf(el.nodeName.toLowerCase()) === -1) {
+        el.parentNode.removeChild(el);
+        return "continue";
+      }
+
+      var attributeList = [].slice.call(el.attributes);
+      var whitelistedAttributes = [].concat(whiteList['*'] || [], whiteList[elName] || []);
+      attributeList.forEach(function (attr) {
+        if (!allowedAttribute(attr, whitelistedAttributes)) {
+          el.removeAttribute(attr.nodeName);
+        }
+      });
+    };
+
+    for (var i = 0, len = elements.length; i < len; i++) {
+      var _ret = _loop(i, len);
+
+      if (_ret === "continue") continue;
+    }
+
+    return createdDocument.body.innerHTML;
+  }
+});
\ No newline at end of file
index dc6f96e..f7ee7e5 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   "use strict";
 
@@ -29,22 +31,38 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
     return _typeof(obj);
   }
 
-  function _extends() {
-    _extends = Object.assign || function (target) {
-      for (var i = 1; i < arguments.length; i++) {
-        var source = arguments[i];
+  function _objectSpread(target) {
+    for (var i = 1; i < arguments.length; i++) {
+      var source = arguments[i] != null ? arguments[i] : {};
+      var ownKeys = Object.keys(source);
 
-        for (var key in source) {
-          if (Object.prototype.hasOwnProperty.call(source, key)) {
-            target[key] = source[key];
-          }
-        }
+      if (typeof Object.getOwnPropertySymbols === 'function') {
+        ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
+          return Object.getOwnPropertyDescriptor(source, sym).enumerable;
+        }));
       }
 
-      return target;
-    };
+      ownKeys.forEach(function (key) {
+        _defineProperty(target, key, source[key]);
+      });
+    }
+
+    return target;
+  }
+
+  function _defineProperty(obj, key, value) {
+    if (key in obj) {
+      Object.defineProperty(obj, key, {
+        value: value,
+        enumerable: true,
+        configurable: true,
+        writable: true
+      });
+    } else {
+      obj[key] = value;
+    }
 
-    return _extends.apply(this, arguments);
+    return obj;
   }
 
   function _classCallCheck(instance, Constructor) {
@@ -70,321 +88,317 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): scrollspy.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var ScrollSpy = function ($) {
+  var NAME = 'scrollspy';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.scrollspy';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var DATA_API_KEY = '.data-api';
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var Default = {
+    offset: 10,
+    method: 'auto',
+    target: ''
+  };
+  var DefaultType = {
+    offset: 'number',
+    method: 'string',
+    target: '(string|element)'
+  };
+  var Event = {
+    ACTIVATE: "activate".concat(EVENT_KEY),
+    SCROLL: "scroll".concat(EVENT_KEY),
+    LOAD_DATA_API: "load".concat(EVENT_KEY).concat(DATA_API_KEY)
+  };
+  var ClassName = {
+    DROPDOWN_ITEM: 'dropdown-item',
+    DROPDOWN_MENU: 'dropdown-menu',
+    ACTIVE: 'active'
+  };
+  var Selector = {
+    DATA_SPY: '[data-spy="scroll"]',
+    ACTIVE: '.active',
+    NAV_LIST_GROUP: '.nav, .list-group',
+    NAV_LINKS: '.nav-link',
+    NAV_ITEMS: '.nav-item',
+    LIST_ITEMS: '.list-group-item',
+    DROPDOWN: '.dropdown',
+    DROPDOWN_ITEMS: '.dropdown-item',
+    DROPDOWN_TOGGLE: '.dropdown-toggle'
+  };
+  var OffsetMethod = {
+    OFFSET: 'offset',
+    POSITION: 'position'
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'scrollspy';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.scrollspy';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var DATA_API_KEY = '.data-api';
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var Default = {
-      offset: 10,
-      method: 'auto',
-      target: ''
-    };
-    var DefaultType = {
-      offset: 'number',
-      method: 'string',
-      target: '(string|element)'
-    };
-    var Event = {
-      ACTIVATE: "activate".concat(EVENT_KEY),
-      SCROLL: "scroll".concat(EVENT_KEY),
-      LOAD_DATA_API: "load".concat(EVENT_KEY).concat(DATA_API_KEY)
-    };
-    var ClassName = {
-      DROPDOWN_ITEM: 'dropdown-item',
-      DROPDOWN_MENU: 'dropdown-menu',
-      ACTIVE: 'active'
-    };
-    var Selector = {
-      DATA_SPY: '[data-spy="scroll"]',
-      ACTIVE: '.active',
-      NAV_LIST_GROUP: '.nav, .list-group',
-      NAV_LINKS: '.nav-link',
-      NAV_ITEMS: '.nav-item',
-      LIST_ITEMS: '.list-group-item',
-      DROPDOWN: '.dropdown',
-      DROPDOWN_ITEMS: '.dropdown-item',
-      DROPDOWN_TOGGLE: '.dropdown-toggle'
-    };
-    var OffsetMethod = {
-      OFFSET: 'offset',
-      POSITION: 'position'
-      /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
-       */
 
-    };
+  };
 
-    var ScrollSpy = function () {
-      function ScrollSpy(element, config) {
-        var _this = this;
+  var ScrollSpy = function () {
+    function ScrollSpy(element, config) {
+      var _this = this;
 
-        _classCallCheck(this, ScrollSpy);
+      _classCallCheck(this, ScrollSpy);
 
-        this._element = element;
-        this._scrollElement = element.tagName === 'BODY' ? window : element;
-        this._config = this._getConfig(config);
-        this._selector = "".concat(this._config.target, " ").concat(Selector.NAV_LINKS, ",") + "".concat(this._config.target, " ").concat(Selector.LIST_ITEMS, ",") + "".concat(this._config.target, " ").concat(Selector.DROPDOWN_ITEMS);
-        this._offsets = [];
-        this._targets = [];
-        this._activeTarget = null;
-        this._scrollHeight = 0;
-        $(this._scrollElement).on(Event.SCROLL, function (event) {
-          return _this._process(event);
-        });
-        this.refresh();
+      this._element = element;
+      this._scrollElement = element.tagName === 'BODY' ? window : element;
+      this._config = this._getConfig(config);
+      this._selector = "".concat(this._config.target, " ").concat(Selector.NAV_LINKS, ",") + "".concat(this._config.target, " ").concat(Selector.LIST_ITEMS, ",") + "".concat(this._config.target, " ").concat(Selector.DROPDOWN_ITEMS);
+      this._offsets = [];
+      this._targets = [];
+      this._activeTarget = null;
+      this._scrollHeight = 0;
+      (0, _jquery2.default)(this._scrollElement).on(Event.SCROLL, function (event) {
+        return _this._process(event);
+      });
+      this.refresh();
 
-        this._process();
-      } // Getters
+      this._process();
+    } // Getters
 
 
-      _createClass(ScrollSpy, [{
-        key: "refresh",
-        value: function refresh() {
-          var _this2 = this;
+    _createClass(ScrollSpy, [{
+      key: "refresh",
+      value: function refresh() {
+        var _this2 = this;
 
-          var autoMethod = this._scrollElement === this._scrollElement.window ? OffsetMethod.OFFSET : OffsetMethod.POSITION;
-          var offsetMethod = this._config.method === 'auto' ? autoMethod : this._config.method;
-          var offsetBase = offsetMethod === OffsetMethod.POSITION ? this._getScrollTop() : 0;
-          this._offsets = [];
-          this._targets = [];
-          this._scrollHeight = this._getScrollHeight();
-          var targets = $.makeArray($(this._selector));
-          targets.map(function (element) {
-            var target;
+        var autoMethod = this._scrollElement === this._scrollElement.window ? OffsetMethod.OFFSET : OffsetMethod.POSITION;
+        var offsetMethod = this._config.method === 'auto' ? autoMethod : this._config.method;
+        var offsetBase = offsetMethod === OffsetMethod.POSITION ? this._getScrollTop() : 0;
+        this._offsets = [];
+        this._targets = [];
+        this._scrollHeight = this._getScrollHeight();
+        var targets = [].slice.call(document.querySelectorAll(this._selector));
+        targets.map(function (element) {
+          var target;
 
-            var targetSelector = _util2.default.getSelectorFromElement(element);
+          var targetSelector = _util2.default.getSelectorFromElement(element);
 
-            if (targetSelector) {
-              target = $(targetSelector)[0];
-            }
+          if (targetSelector) {
+            target = document.querySelector(targetSelector);
+          }
 
-            if (target) {
-              var targetBCR = target.getBoundingClientRect();
+          if (target) {
+            var targetBCR = target.getBoundingClientRect();
 
-              if (targetBCR.width || targetBCR.height) {
-                // TODO (fat): remove sketch reliance on jQuery position/offset
-                return [$(target)[offsetMethod]().top + offsetBase, targetSelector];
-              }
+            if (targetBCR.width || targetBCR.height) {
+              // TODO (fat): remove sketch reliance on jQuery position/offset
+              return [(0, _jquery2.default)(target)[offsetMethod]().top + offsetBase, targetSelector];
             }
+          }
 
-            return null;
-          }).filter(function (item) {
-            return item;
-          }).sort(function (a, b) {
-            return a[0] - b[0];
-          }).forEach(function (item) {
-            _this2._offsets.push(item[0]);
-
-            _this2._targets.push(item[1]);
-          });
-        }
-      }, {
-        key: "dispose",
-        value: function dispose() {
-          $.removeData(this._element, DATA_KEY);
-          $(this._scrollElement).off(EVENT_KEY);
-          this._element = null;
-          this._scrollElement = null;
-          this._config = null;
-          this._selector = null;
-          this._offsets = null;
-          this._targets = null;
-          this._activeTarget = null;
-          this._scrollHeight = null;
-        }
-      }, {
-        key: "_getConfig",
-        value: function _getConfig(config) {
-          config = _extends({}, Default, config);
+          return null;
+        }).filter(function (item) {
+          return item;
+        }).sort(function (a, b) {
+          return a[0] - b[0];
+        }).forEach(function (item) {
+          _this2._offsets.push(item[0]);
 
-          if (typeof config.target !== 'string') {
-            var id = $(config.target).attr('id');
+          _this2._targets.push(item[1]);
+        });
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        _jquery2.default.removeData(this._element, DATA_KEY);
+
+        (0, _jquery2.default)(this._scrollElement).off(EVENT_KEY);
+        this._element = null;
+        this._scrollElement = null;
+        this._config = null;
+        this._selector = null;
+        this._offsets = null;
+        this._targets = null;
+        this._activeTarget = null;
+        this._scrollHeight = null;
+      }
+    }, {
+      key: "_getConfig",
+      value: function _getConfig(config) {
+        config = _objectSpread({}, Default, _typeof(config) === 'object' && config ? config : {});
 
-            if (!id) {
-              id = _util2.default.getUID(NAME);
-              $(config.target).attr('id', id);
-            }
+        if (typeof config.target !== 'string') {
+          var id = (0, _jquery2.default)(config.target).attr('id');
 
-            config.target = "#".concat(id);
+          if (!id) {
+            id = _util2.default.getUID(NAME);
+            (0, _jquery2.default)(config.target).attr('id', id);
           }
 
-          _util2.default.typeCheckConfig(NAME, config, DefaultType);
-
-          return config;
-        }
-      }, {
-        key: "_getScrollTop",
-        value: function _getScrollTop() {
-          return this._scrollElement === window ? this._scrollElement.pageYOffset : this._scrollElement.scrollTop;
+          config.target = "#".concat(id);
         }
-      }, {
-        key: "_getScrollHeight",
-        value: function _getScrollHeight() {
-          return this._scrollElement.scrollHeight || Math.max(document.body.scrollHeight, document.documentElement.scrollHeight);
-        }
-      }, {
-        key: "_getOffsetHeight",
-        value: function _getOffsetHeight() {
-          return this._scrollElement === window ? window.innerHeight : this._scrollElement.getBoundingClientRect().height;
-        }
-      }, {
-        key: "_process",
-        value: function _process() {
-          var scrollTop = this._getScrollTop() + this._config.offset;
 
-          var scrollHeight = this._getScrollHeight();
+        _util2.default.typeCheckConfig(NAME, config, DefaultType);
 
-          var maxScroll = this._config.offset + scrollHeight - this._getOffsetHeight();
+        return config;
+      }
+    }, {
+      key: "_getScrollTop",
+      value: function _getScrollTop() {
+        return this._scrollElement === window ? this._scrollElement.pageYOffset : this._scrollElement.scrollTop;
+      }
+    }, {
+      key: "_getScrollHeight",
+      value: function _getScrollHeight() {
+        return this._scrollElement.scrollHeight || Math.max(document.body.scrollHeight, document.documentElement.scrollHeight);
+      }
+    }, {
+      key: "_getOffsetHeight",
+      value: function _getOffsetHeight() {
+        return this._scrollElement === window ? window.innerHeight : this._scrollElement.getBoundingClientRect().height;
+      }
+    }, {
+      key: "_process",
+      value: function _process() {
+        var scrollTop = this._getScrollTop() + this._config.offset;
 
-          if (this._scrollHeight !== scrollHeight) {
-            this.refresh();
-          }
+        var scrollHeight = this._getScrollHeight();
 
-          if (scrollTop >= maxScroll) {
-            var target = this._targets[this._targets.length - 1];
+        var maxScroll = this._config.offset + scrollHeight - this._getOffsetHeight();
 
-            if (this._activeTarget !== target) {
-              this._activate(target);
-            }
+        if (this._scrollHeight !== scrollHeight) {
+          this.refresh();
+        }
 
-            return;
-          }
+        if (scrollTop >= maxScroll) {
+          var target = this._targets[this._targets.length - 1];
 
-          if (this._activeTarget && scrollTop < this._offsets[0] && this._offsets[0] > 0) {
-            this._activeTarget = null;
+          if (this._activeTarget !== target) {
+            this._activate(target);
+          }
 
-            this._clear();
+          return;
+        }
 
-            return;
-          }
+        if (this._activeTarget && scrollTop < this._offsets[0] && this._offsets[0] > 0) {
+          this._activeTarget = null;
 
-          for (var i = this._offsets.length; i--;) {
-            var isActiveTarget = this._activeTarget !== this._targets[i] && scrollTop >= this._offsets[i] && (typeof this._offsets[i + 1] === 'undefined' || scrollTop < this._offsets[i + 1]);
+          this._clear();
 
-            if (isActiveTarget) {
-              this._activate(this._targets[i]);
-            }
-          }
+          return;
         }
-      }, {
-        key: "_activate",
-        value: function _activate(target) {
-          this._activeTarget = target;
 
-          this._clear();
+        var offsetLength = this._offsets.length;
 
-          var queries = this._selector.split(','); // eslint-disable-next-line arrow-body-style
+        for (var i = offsetLength; i--;) {
+          var isActiveTarget = this._activeTarget !== this._targets[i] && scrollTop >= this._offsets[i] && (typeof this._offsets[i + 1] === 'undefined' || scrollTop < this._offsets[i + 1]);
 
+          if (isActiveTarget) {
+            this._activate(this._targets[i]);
+          }
+        }
+      }
+    }, {
+      key: "_activate",
+      value: function _activate(target) {
+        this._activeTarget = target;
 
-          queries = queries.map(function (selector) {
-            return "".concat(selector, "[data-target=\"").concat(target, "\"],") + "".concat(selector, "[href=\"").concat(target, "\"]");
-          });
-          var $link = $(queries.join(','));
+        this._clear();
 
-          if ($link.hasClass(ClassName.DROPDOWN_ITEM)) {
-            $link.closest(Selector.DROPDOWN).find(Selector.DROPDOWN_TOGGLE).addClass(ClassName.ACTIVE);
-            $link.addClass(ClassName.ACTIVE);
-          } else {
-            // Set triggered link as active
-            $link.addClass(ClassName.ACTIVE); // Set triggered links parents as active
-            // With both <ul> and <nav> markup a parent is the previous sibling of any nav ancestor
+        var queries = this._selector.split(',').map(function (selector) {
+          return "".concat(selector, "[data-target=\"").concat(target, "\"],").concat(selector, "[href=\"").concat(target, "\"]");
+        });
 
-            $link.parents(Selector.NAV_LIST_GROUP).prev("".concat(Selector.NAV_LINKS, ", ").concat(Selector.LIST_ITEMS)).addClass(ClassName.ACTIVE); // Handle special case when .nav-link is inside .nav-item
+        var $link = (0, _jquery2.default)([].slice.call(document.querySelectorAll(queries.join(','))));
 
-            $link.parents(Selector.NAV_LIST_GROUP).prev(Selector.NAV_ITEMS).children(Selector.NAV_LINKS).addClass(ClassName.ACTIVE);
-          }
+        if ($link.hasClass(ClassName.DROPDOWN_ITEM)) {
+          $link.closest(Selector.DROPDOWN).find(Selector.DROPDOWN_TOGGLE).addClass(ClassName.ACTIVE);
+          $link.addClass(ClassName.ACTIVE);
+        } else {
+          // Set triggered link as active
+          $link.addClass(ClassName.ACTIVE); // Set triggered links parents as active
+          // With both <ul> and <nav> markup a parent is the previous sibling of any nav ancestor
 
-          $(this._scrollElement).trigger(Event.ACTIVATE, {
-            relatedTarget: target
-          });
-        }
-      }, {
-        key: "_clear",
-        value: function _clear() {
-          $(this._selector).filter(Selector.ACTIVE).removeClass(ClassName.ACTIVE);
+          $link.parents(Selector.NAV_LIST_GROUP).prev("".concat(Selector.NAV_LINKS, ", ").concat(Selector.LIST_ITEMS)).addClass(ClassName.ACTIVE); // Handle special case when .nav-link is inside .nav-item
+
+          $link.parents(Selector.NAV_LIST_GROUP).prev(Selector.NAV_ITEMS).children(Selector.NAV_LINKS).addClass(ClassName.ACTIVE);
         }
-      }], [{
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config) {
-          return this.each(function () {
-            var data = $(this).data(DATA_KEY);
 
-            var _config = _typeof(config) === 'object' && config;
+        (0, _jquery2.default)(this._scrollElement).trigger(Event.ACTIVATE, {
+          relatedTarget: target
+        });
+      }
+    }, {
+      key: "_clear",
+      value: function _clear() {
+        [].slice.call(document.querySelectorAll(this._selector)).filter(function (node) {
+          return node.classList.contains(ClassName.ACTIVE);
+        }).forEach(function (node) {
+          return node.classList.remove(ClassName.ACTIVE);
+        });
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var data = (0, _jquery2.default)(this).data(DATA_KEY);
 
-            if (!data) {
-              data = new ScrollSpy(this, _config);
-              $(this).data(DATA_KEY, data);
-            }
+          var _config = _typeof(config) === 'object' && config;
 
-            if (typeof config === 'string') {
-              if (typeof data[config] === 'undefined') {
-                throw new TypeError("No method named \"".concat(config, "\""));
-              }
+          if (!data) {
+            data = new ScrollSpy(this, _config);
+            (0, _jquery2.default)(this).data(DATA_KEY, data);
+          }
 
-              data[config]();
+          if (typeof config === 'string') {
+            if (typeof data[config] === 'undefined') {
+              throw new TypeError("No method named \"".concat(config, "\""));
             }
-          });
-        }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
-        }
-      }, {
-        key: "Default",
-        get: function get() {
-          return Default;
-        }
-      }]);
 
-      return ScrollSpy;
-    }();
+            data[config]();
+          }
+        });
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }, {
+      key: "Default",
+      get: function get() {
+        return Default;
+      }
+    }]);
 
-    /**
-     * ------------------------------------------------------------------------
-     * Data Api implementation
-     * ------------------------------------------------------------------------
-     */
-    $(window).on(Event.LOAD_DATA_API, function () {
-      var scrollSpys = $.makeArray($(Selector.DATA_SPY));
+    return ScrollSpy;
+  }();
 
-      for (var i = scrollSpys.length; i--;) {
-        var $spy = $(scrollSpys[i]);
+  /**
+   * ------------------------------------------------------------------------
+   * Data Api implementation
+   * ------------------------------------------------------------------------
+   */
+  (0, _jquery2.default)(window).on(Event.LOAD_DATA_API, function () {
+    var scrollSpys = [].slice.call(document.querySelectorAll(Selector.DATA_SPY));
+    var scrollSpysLength = scrollSpys.length;
 
-        ScrollSpy._jQueryInterface.call($spy, $spy.data());
-      }
-    });
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
+    for (var i = scrollSpysLength; i--;) {
+      var $spy = (0, _jquery2.default)(scrollSpys[i]);
 
-    $.fn[NAME] = ScrollSpy._jQueryInterface;
-    $.fn[NAME].Constructor = ScrollSpy;
+      ScrollSpy._jQueryInterface.call($spy, $spy.data());
+    }
+  });
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return ScrollSpy._jQueryInterface;
-    };
+  _jquery2.default.fn[NAME] = ScrollSpy._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = ScrollSpy;
 
-    return ScrollSpy;
-  }(_jquery2.default);
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return ScrollSpy._jQueryInterface;
+  };
 
   exports.default = ScrollSpy;
 });
\ No newline at end of file
index 8e9db1b..125c4e8 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   "use strict";
 
@@ -38,252 +40,243 @@ define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): tab.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var Tab = function ($) {
+  var NAME = 'tab';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.tab';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var DATA_API_KEY = '.data-api';
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var Event = {
+    HIDE: "hide".concat(EVENT_KEY),
+    HIDDEN: "hidden".concat(EVENT_KEY),
+    SHOW: "show".concat(EVENT_KEY),
+    SHOWN: "shown".concat(EVENT_KEY),
+    CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
+  };
+  var ClassName = {
+    DROPDOWN_MENU: 'dropdown-menu',
+    ACTIVE: 'active',
+    DISABLED: 'disabled',
+    FADE: 'fade',
+    SHOW: 'show'
+  };
+  var Selector = {
+    DROPDOWN: '.dropdown',
+    NAV_LIST_GROUP: '.nav, .list-group',
+    ACTIVE: '.active',
+    ACTIVE_UL: '> li > .active',
+    DATA_TOGGLE: '[data-toggle="tab"], [data-toggle="pill"], [data-toggle="list"]',
+    DROPDOWN_TOGGLE: '.dropdown-toggle',
+    DROPDOWN_ACTIVE_CHILD: '> .dropdown-menu .active'
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'tab';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.tab';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var DATA_API_KEY = '.data-api';
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var TRANSITION_DURATION = 150;
-    var Event = {
-      HIDE: "hide".concat(EVENT_KEY),
-      HIDDEN: "hidden".concat(EVENT_KEY),
-      SHOW: "show".concat(EVENT_KEY),
-      SHOWN: "shown".concat(EVENT_KEY),
-      CLICK_DATA_API: "click".concat(EVENT_KEY).concat(DATA_API_KEY)
-    };
-    var ClassName = {
-      DROPDOWN_MENU: 'dropdown-menu',
-      ACTIVE: 'active',
-      DISABLED: 'disabled',
-      FADE: 'fade',
-      SHOW: 'show'
-    };
-    var Selector = {
-      DROPDOWN: '.dropdown',
-      NAV_LIST_GROUP: '.nav, .list-group',
-      ACTIVE: '.active',
-      ACTIVE_UL: '> li > .active',
-      DATA_TOGGLE: '[data-toggle="tab"], [data-toggle="pill"], [data-toggle="list"]',
-      DROPDOWN_TOGGLE: '.dropdown-toggle',
-      DROPDOWN_ACTIVE_CHILD: '> .dropdown-menu .active'
-      /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
-       */
 
-    };
+  };
 
-    var Tab = function () {
-      function Tab(element) {
-        _classCallCheck(this, Tab);
+  var Tab = function () {
+    function Tab(element) {
+      _classCallCheck(this, Tab);
 
-        this._element = element;
-      } // Getters
+      this._element = element;
+    } // Getters
 
 
-      _createClass(Tab, [{
-        key: "show",
-        value: function show() {
-          var _this = this;
+    _createClass(Tab, [{
+      key: "show",
+      value: function show() {
+        var _this = this;
 
-          if (this._element.parentNode && this._element.parentNode.nodeType === Node.ELEMENT_NODE && $(this._element).hasClass(ClassName.ACTIVE) || $(this._element).hasClass(ClassName.DISABLED)) {
-            return;
-          }
+        if (this._element.parentNode && this._element.parentNode.nodeType === Node.ELEMENT_NODE && (0, _jquery2.default)(this._element).hasClass(ClassName.ACTIVE) || (0, _jquery2.default)(this._element).hasClass(ClassName.DISABLED)) {
+          return;
+        }
 
-          var target;
-          var previous;
-          var listElement = $(this._element).closest(Selector.NAV_LIST_GROUP)[0];
+        var target;
+        var previous;
+        var listElement = (0, _jquery2.default)(this._element).closest(Selector.NAV_LIST_GROUP)[0];
 
-          var selector = _util2.default.getSelectorFromElement(this._element);
+        var selector = _util2.default.getSelectorFromElement(this._element);
 
-          if (listElement) {
-            var itemSelector = listElement.nodeName === 'UL' ? Selector.ACTIVE_UL : Selector.ACTIVE;
-            previous = $.makeArray($(listElement).find(itemSelector));
-            previous = previous[previous.length - 1];
-          }
+        if (listElement) {
+          var itemSelector = listElement.nodeName === 'UL' || listElement.nodeName === 'OL' ? Selector.ACTIVE_UL : Selector.ACTIVE;
+          previous = _jquery2.default.makeArray((0, _jquery2.default)(listElement).find(itemSelector));
+          previous = previous[previous.length - 1];
+        }
 
-          var hideEvent = $.Event(Event.HIDE, {
-            relatedTarget: this._element
-          });
-          var showEvent = $.Event(Event.SHOW, {
-            relatedTarget: previous
-          });
+        var hideEvent = _jquery2.default.Event(Event.HIDE, {
+          relatedTarget: this._element
+        });
 
-          if (previous) {
-            $(previous).trigger(hideEvent);
-          }
+        var showEvent = _jquery2.default.Event(Event.SHOW, {
+          relatedTarget: previous
+        });
 
-          $(this._element).trigger(showEvent);
+        if (previous) {
+          (0, _jquery2.default)(previous).trigger(hideEvent);
+        }
 
-          if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) {
-            return;
-          }
+        (0, _jquery2.default)(this._element).trigger(showEvent);
 
-          if (selector) {
-            target = $(selector)[0];
-          }
-
-          this._activate(this._element, listElement);
-
-          var complete = function complete() {
-            var hiddenEvent = $.Event(Event.HIDDEN, {
-              relatedTarget: _this._element
-            });
-            var shownEvent = $.Event(Event.SHOWN, {
-              relatedTarget: previous
-            });
-            $(previous).trigger(hiddenEvent);
-            $(_this._element).trigger(shownEvent);
-          };
-
-          if (target) {
-            this._activate(target, target.parentNode, complete);
-          } else {
-            complete();
-          }
+        if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) {
+          return;
         }
-      }, {
-        key: "dispose",
-        value: function dispose() {
-          $.removeData(this._element, DATA_KEY);
-          this._element = null;
+
+        if (selector) {
+          target = document.querySelector(selector);
         }
-      }, {
-        key: "_activate",
-        value: function _activate(element, container, callback) {
-          var _this2 = this;
 
-          var activeElements;
+        this._activate(this._element, listElement);
 
-          if (container.nodeName === 'UL') {
-            activeElements = $(container).find(Selector.ACTIVE_UL);
-          } else {
-            activeElements = $(container).children(Selector.ACTIVE);
-          }
+        var complete = function complete() {
+          var hiddenEvent = _jquery2.default.Event(Event.HIDDEN, {
+            relatedTarget: _this._element
+          });
 
-          var active = activeElements[0];
-          var isTransitioning = callback && _util2.default.supportsTransitionEnd() && active && $(active).hasClass(ClassName.FADE);
+          var shownEvent = _jquery2.default.Event(Event.SHOWN, {
+            relatedTarget: previous
+          });
 
-          var complete = function complete() {
-            return _this2._transitionComplete(element, active, callback);
-          };
+          (0, _jquery2.default)(previous).trigger(hiddenEvent);
+          (0, _jquery2.default)(_this._element).trigger(shownEvent);
+        };
 
-          if (active && isTransitioning) {
-            $(active).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(TRANSITION_DURATION);
-          } else {
-            complete();
-          }
+        if (target) {
+          this._activate(target, target.parentNode, complete);
+        } else {
+          complete();
         }
-      }, {
-        key: "_transitionComplete",
-        value: function _transitionComplete(element, active, callback) {
-          if (active) {
-            $(active).removeClass("".concat(ClassName.SHOW, " ").concat(ClassName.ACTIVE));
-            var dropdownChild = $(active.parentNode).find(Selector.DROPDOWN_ACTIVE_CHILD)[0];
-
-            if (dropdownChild) {
-              $(dropdownChild).removeClass(ClassName.ACTIVE);
-            }
-
-            if (active.getAttribute('role') === 'tab') {
-              active.setAttribute('aria-selected', false);
-            }
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        _jquery2.default.removeData(this._element, DATA_KEY);
+
+        this._element = null;
+      }
+    }, {
+      key: "_activate",
+      value: function _activate(element, container, callback) {
+        var _this2 = this;
+
+        var activeElements = container && (container.nodeName === 'UL' || container.nodeName === 'OL') ? (0, _jquery2.default)(container).find(Selector.ACTIVE_UL) : (0, _jquery2.default)(container).children(Selector.ACTIVE);
+        var active = activeElements[0];
+        var isTransitioning = callback && active && (0, _jquery2.default)(active).hasClass(ClassName.FADE);
+
+        var complete = function complete() {
+          return _this2._transitionComplete(element, active, callback);
+        };
+
+        if (active && isTransitioning) {
+          var transitionDuration = _util2.default.getTransitionDurationFromElement(active);
+
+          (0, _jquery2.default)(active).removeClass(ClassName.SHOW).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
+        } else {
+          complete();
+        }
+      }
+    }, {
+      key: "_transitionComplete",
+      value: function _transitionComplete(element, active, callback) {
+        if (active) {
+          (0, _jquery2.default)(active).removeClass(ClassName.ACTIVE);
+          var dropdownChild = (0, _jquery2.default)(active.parentNode).find(Selector.DROPDOWN_ACTIVE_CHILD)[0];
+
+          if (dropdownChild) {
+            (0, _jquery2.default)(dropdownChild).removeClass(ClassName.ACTIVE);
           }
 
-          $(element).addClass(ClassName.ACTIVE);
-
-          if (element.getAttribute('role') === 'tab') {
-            element.setAttribute('aria-selected', true);
+          if (active.getAttribute('role') === 'tab') {
+            active.setAttribute('aria-selected', false);
           }
+        }
 
-          _util2.default.reflow(element);
+        (0, _jquery2.default)(element).addClass(ClassName.ACTIVE);
 
-          $(element).addClass(ClassName.SHOW);
+        if (element.getAttribute('role') === 'tab') {
+          element.setAttribute('aria-selected', true);
+        }
 
-          if (element.parentNode && $(element.parentNode).hasClass(ClassName.DROPDOWN_MENU)) {
-            var dropdownElement = $(element).closest(Selector.DROPDOWN)[0];
+        _util2.default.reflow(element);
 
-            if (dropdownElement) {
-              $(dropdownElement).find(Selector.DROPDOWN_TOGGLE).addClass(ClassName.ACTIVE);
-            }
+        if (element.classList.contains(ClassName.FADE)) {
+          element.classList.add(ClassName.SHOW);
+        }
 
-            element.setAttribute('aria-expanded', true);
-          }
+        if (element.parentNode && (0, _jquery2.default)(element.parentNode).hasClass(ClassName.DROPDOWN_MENU)) {
+          var dropdownElement = (0, _jquery2.default)(element).closest(Selector.DROPDOWN)[0];
 
-          if (callback) {
-            callback();
+          if (dropdownElement) {
+            var dropdownToggleList = [].slice.call(dropdownElement.querySelectorAll(Selector.DROPDOWN_TOGGLE));
+            (0, _jquery2.default)(dropdownToggleList).addClass(ClassName.ACTIVE);
           }
+
+          element.setAttribute('aria-expanded', true);
         }
-      }], [{
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config) {
-          return this.each(function () {
-            var $this = $(this);
-            var data = $this.data(DATA_KEY);
-
-            if (!data) {
-              data = new Tab(this);
-              $this.data(DATA_KEY, data);
-            }
 
-            if (typeof config === 'string') {
-              if (typeof data[config] === 'undefined') {
-                throw new TypeError("No method named \"".concat(config, "\""));
-              }
+        if (callback) {
+          callback();
+        }
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var $this = (0, _jquery2.default)(this);
+          var data = $this.data(DATA_KEY);
+
+          if (!data) {
+            data = new Tab(this);
+            $this.data(DATA_KEY, data);
+          }
 
-              data[config]();
+          if (typeof config === 'string') {
+            if (typeof data[config] === 'undefined') {
+              throw new TypeError("No method named \"".concat(config, "\""));
             }
-          });
-        }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
-        }
-      }]);
 
-      return Tab;
-    }();
+            data[config]();
+          }
+        });
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }]);
 
-    /**
-     * ------------------------------------------------------------------------
-     * Data Api implementation
-     * ------------------------------------------------------------------------
-     */
-    $(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
-      event.preventDefault();
+    return Tab;
+  }();
 
-      Tab._jQueryInterface.call($(this), 'show');
-    });
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
+  /**
+   * ------------------------------------------------------------------------
+   * Data Api implementation
+   * ------------------------------------------------------------------------
+   */
+  (0, _jquery2.default)(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
+    event.preventDefault();
 
-    $.fn[NAME] = Tab._jQueryInterface;
-    $.fn[NAME].Constructor = Tab;
+    Tab._jQueryInterface.call((0, _jquery2.default)(this), 'show');
+  });
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return Tab._jQueryInterface;
-    };
+  _jquery2.default.fn[NAME] = Tab._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Tab;
 
-    return Tab;
-  }(_jquery2.default);
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Tab._jQueryInterface;
+  };
 
   exports.default = Tab;
 });
\ No newline at end of file
diff --git a/theme/boost/amd/src/toast.js b/theme/boost/amd/src/toast.js
new file mode 100644 (file)
index 0000000..3adc308
--- /dev/null
@@ -0,0 +1,312 @@
+"use strict";
+
+define(["exports", "jquery", "./util"], function (exports, _jquery, _util) {
+  "use strict";
+
+  Object.defineProperty(exports, "__esModule", {
+    value: true
+  });
+
+  var _jquery2 = _interopRequireDefault(_jquery);
+
+  var _util2 = _interopRequireDefault(_util);
+
+  function _interopRequireDefault(obj) {
+    return obj && obj.__esModule ? obj : {
+      default: obj
+    };
+  }
+
+  function _typeof(obj) {
+    if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
+      _typeof = function _typeof(obj) {
+        return typeof obj;
+      };
+    } else {
+      _typeof = function _typeof(obj) {
+        return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
+      };
+    }
+
+    return _typeof(obj);
+  }
+
+  function _objectSpread(target) {
+    for (var i = 1; i < arguments.length; i++) {
+      var source = arguments[i] != null ? arguments[i] : {};
+      var ownKeys = Object.keys(source);
+
+      if (typeof Object.getOwnPropertySymbols === 'function') {
+        ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
+          return Object.getOwnPropertyDescriptor(source, sym).enumerable;
+        }));
+      }
+
+      ownKeys.forEach(function (key) {
+        _defineProperty(target, key, source[key]);
+      });
+    }
+
+    return target;
+  }
+
+  function _defineProperty(obj, key, value) {
+    if (key in obj) {
+      Object.defineProperty(obj, key, {
+        value: value,
+        enumerable: true,
+        configurable: true,
+        writable: true
+      });
+    } else {
+      obj[key] = value;
+    }
+
+    return obj;
+  }
+
+  function _classCallCheck(instance, Constructor) {
+    if (!(instance instanceof Constructor)) {
+      throw new TypeError("Cannot call a class as a function");
+    }
+  }
+
+  function _defineProperties(target, props) {
+    for (var i = 0; i < props.length; i++) {
+      var descriptor = props[i];
+      descriptor.enumerable = descriptor.enumerable || false;
+      descriptor.configurable = true;
+      if ("value" in descriptor) descriptor.writable = true;
+      Object.defineProperty(target, descriptor.key, descriptor);
+    }
+  }
+
+  function _createClass(Constructor, protoProps, staticProps) {
+    if (protoProps) _defineProperties(Constructor.prototype, protoProps);
+    if (staticProps) _defineProperties(Constructor, staticProps);
+    return Constructor;
+  }
+
+  /**
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
+   */
+  var NAME = 'toast';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.toast';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var Event = {
+    CLICK_DISMISS: "click.dismiss".concat(EVENT_KEY),
+    HIDE: "hide".concat(EVENT_KEY),
+    HIDDEN: "hidden".concat(EVENT_KEY),
+    SHOW: "show".concat(EVENT_KEY),
+    SHOWN: "shown".concat(EVENT_KEY)
+  };
+  var ClassName = {
+    FADE: 'fade',
+    HIDE: 'hide',
+    SHOW: 'show',
+    SHOWING: 'showing'
+  };
+  var DefaultType = {
+    animation: 'boolean',
+    autohide: 'boolean',
+    delay: 'number'
+  };
+  var Default = {
+    animation: true,
+    autohide: true,
+    delay: 500
+  };
+  var Selector = {
+    DATA_DISMISS: '[data-dismiss="toast"]'
+    /**
+     * ------------------------------------------------------------------------
+     * Class Definition
+     * ------------------------------------------------------------------------
+     */
+
+  };
+
+  var Toast = function () {
+    function Toast(element, config) {
+      _classCallCheck(this, Toast);
+
+      this._element = element;
+      this._config = this._getConfig(config);
+      this._timeout = null;
+
+      this._setListeners();
+    } // Getters
+
+
+    _createClass(Toast, [{
+      key: "show",
+      value: function show() {
+        var _this = this;
+
+        (0, _jquery2.default)(this._element).trigger(Event.SHOW);
+
+        if (this._config.animation) {
+          this._element.classList.add(ClassName.FADE);
+        }
+
+        var complete = function complete() {
+          _this._element.classList.remove(ClassName.SHOWING);
+
+          _this._element.classList.add(ClassName.SHOW);
+
+          (0, _jquery2.default)(_this._element).trigger(Event.SHOWN);
+
+          if (_this._config.autohide) {
+            _this.hide();
+          }
+        };
+
+        this._element.classList.remove(ClassName.HIDE);
+
+        this._element.classList.add(ClassName.SHOWING);
+
+        if (this._config.animation) {
+          var transitionDuration = _util2.default.getTransitionDurationFromElement(this._element);
+
+          (0, _jquery2.default)(this._element).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
+        } else {
+          complete();
+        }
+      }
+    }, {
+      key: "hide",
+      value: function hide(withoutTimeout) {
+        var _this2 = this;
+
+        if (!this._element.classList.contains(ClassName.SHOW)) {
+          return;
+        }
+
+        (0, _jquery2.default)(this._element).trigger(Event.HIDE);
+
+        if (withoutTimeout) {
+          this._close();
+        } else {
+          this._timeout = setTimeout(function () {
+            _this2._close();
+          }, this._config.delay);
+        }
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        clearTimeout(this._timeout);
+        this._timeout = null;
+
+        if (this._element.classList.contains(ClassName.SHOW)) {
+          this._element.classList.remove(ClassName.SHOW);
+        }
+
+        (0, _jquery2.default)(this._element).off(Event.CLICK_DISMISS);
+
+        _jquery2.default.removeData(this._element, DATA_KEY);
+
+        this._element = null;
+        this._config = null;
+      }
+    }, {
+      key: "_getConfig",
+      value: function _getConfig(config) {
+        config = _objectSpread({}, Default, (0, _jquery2.default)(this._element).data(), _typeof(config) === 'object' && config ? config : {});
+
+        _util2.default.typeCheckConfig(NAME, config, this.constructor.DefaultType);
+
+        return config;
+      }
+    }, {
+      key: "_setListeners",
+      value: function _setListeners() {
+        var _this3 = this;
+
+        (0, _jquery2.default)(this._element).on(Event.CLICK_DISMISS, Selector.DATA_DISMISS, function () {
+          return _this3.hide(true);
+        });
+      }
+    }, {
+      key: "_close",
+      value: function _close() {
+        var _this4 = this;
+
+        var complete = function complete() {
+          _this4._element.classList.add(ClassName.HIDE);
+
+          (0, _jquery2.default)(_this4._element).trigger(Event.HIDDEN);
+        };
+
+        this._element.classList.remove(ClassName.SHOW);
+
+        if (this._config.animation) {
+          var transitionDuration = _util2.default.getTransitionDurationFromElement(this._element);
+
+          (0, _jquery2.default)(this._element).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
+        } else {
+          complete();
+        }
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var $element = (0, _jquery2.default)(this);
+          var data = $element.data(DATA_KEY);
+
+          var _config = _typeof(config) === 'object' && config;
+
+          if (!data) {
+            data = new Toast(this, _config);
+            $element.data(DATA_KEY, data);
+          }
+
+          if (typeof config === 'string') {
+            if (typeof data[config] === 'undefined') {
+              throw new TypeError("No method named \"".concat(config, "\""));
+            }
+
+            data[config](this);
+          }
+        });
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }, {
+      key: "DefaultType",
+      get: function get() {
+        return DefaultType;
+      }
+    }, {
+      key: "Default",
+      get: function get() {
+        return Default;
+      }
+    }]);
+
+    return Toast;
+  }();
+
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
+  _jquery2.default.fn[NAME] = Toast._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Toast;
+
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Toast._jQueryInterface;
+  };
+
+  exports.default = Toast;
+});
\ No newline at end of file
index 4ece5a1..5d81dc6 100644 (file)
@@ -1,4 +1,6 @@
-define(["exports", "jquery", "core/popper", "./util"], function (exports, _jquery, _popper, _util) {
+"use strict";
+
+define(["exports", "./sanitizer", "jquery", "core/popper", "./util"], function (exports, _sanitizer, _jquery, _popper, _util) {
   "use strict";
 
   Object.defineProperty(exports, "__esModule", {
@@ -17,22 +19,38 @@ define(["exports", "jquery", "core/popper", "./util"], function (exports, _jquer
     };
   }
 
-  function _extends() {
-    _extends = Object.assign || function (target) {
-      for (var i = 1; i < arguments.length; i++) {
-        var source = arguments[i];
+  function _objectSpread(target) {
+    for (var i = 1; i < arguments.length; i++) {
+      var source = arguments[i] != null ? arguments[i] : {};
+      var ownKeys = Object.keys(source);
 
-        for (var key in source) {
-          if (Object.prototype.hasOwnProperty.call(source, key)) {
-            target[key] = source[key];
-          }
-        }
+      if (typeof Object.getOwnPropertySymbols === 'function') {
+        ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
+          return Object.getOwnPropertyDescriptor(source, sym).enumerable;
+        }));
       }
 
-      return target;
-    };
+      ownKeys.forEach(function (key) {
+        _defineProperty(target, key, source[key]);
+      });
+    }
+
+    return target;
+  }
 
-    return _extends.apply(this, arguments);
+  function _defineProperty(obj, key, value) {
+    if (key in obj) {
+      Object.defineProperty(obj, key, {
+        value: value,
+        enumerable: true,
+        configurable: true,
+        writable: true
+      });
+    } else {
+      obj[key] = value;
+    }
+
+    return obj;
   }
 
   function _typeof(obj) {
@@ -72,691 +90,750 @@ define(["exports", "jquery", "core/popper", "./util"], function (exports, _jquer
   }
 
   /**
-   * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): tooltip.js
-   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
-   * --------------------------------------------------------------------------
+   * ------------------------------------------------------------------------
+   * Constants
+   * ------------------------------------------------------------------------
    */
-  var Tooltip = function ($) {
+  var NAME = 'tooltip';
+  var VERSION = '4.3.1';
+  var DATA_KEY = 'bs.tooltip';
+  var EVENT_KEY = ".".concat(DATA_KEY);
+  var JQUERY_NO_CONFLICT = _jquery2.default.fn[NAME];
+  var CLASS_PREFIX = 'bs-tooltip';
+  var BSCLS_PREFIX_REGEX = new RegExp("(^|\\s)".concat(CLASS_PREFIX, "\\S+"), 'g');
+  var DISALLOWED_ATTRIBUTES = ['sanitize', 'whiteList', 'sanitizeFn'];
+  var DefaultType = {
+    animation: 'boolean',
+    template: 'string',
+    title: '(string|element|function)',
+    trigger: 'string',
+    delay: '(number|object)',
+    html: 'boolean',
+    selector: '(string|boolean)',
+    placement: '(string|function)',
+    offset: '(number|string|function)',
+    container: '(string|element|boolean)',
+    fallbackPlacement: '(string|array)',
+    boundary: '(string|element)',
+    sanitize: 'boolean',
+    sanitizeFn: '(null|function)',
+    whiteList: 'object'
+  };
+  var AttachmentMap = {
+    AUTO: 'auto',
+    TOP: 'top',
+    RIGHT: 'right',
+    BOTTOM: 'bottom',
+    LEFT: 'left'
+  };
+  var Default = {
+    animation: true,
+    template: '<div class="tooltip" role="tooltip">' + '<div class="arrow"></div>' + '<div class="tooltip-inner"></div></div>',
+    trigger: 'hover focus',
+    title: '',
+    delay: 0,
+    html: false,
+    selector: false,
+    placement: 'top',
+    offset: 0,
+    container: false,
+    fallbackPlacement: 'flip',
+    boundary: 'scrollParent',
+    sanitize: true,
+    sanitizeFn: null,
+    whiteList: _sanitizer.DefaultWhitelist
+  };
+  var HoverState = {
+    SHOW: 'show',
+    OUT: 'out'
+  };
+  var Event = {
+    HIDE: "hide".concat(EVENT_KEY),
+    HIDDEN: "hidden".concat(EVENT_KEY),
+    SHOW: "show".concat(EVENT_KEY),
+    SHOWN: "shown".concat(EVENT_KEY),
+    INSERTED: "inserted".concat(EVENT_KEY),
+    CLICK: "click".concat(EVENT_KEY),
+    FOCUSIN: "focusin".concat(EVENT_KEY),
+    FOCUSOUT: "focusout".concat(EVENT_KEY),
+    MOUSEENTER: "mouseenter".concat(EVENT_KEY),
+    MOUSELEAVE: "mouseleave".concat(EVENT_KEY)
+  };
+  var ClassName = {
+    FADE: 'fade',
+    SHOW: 'show'
+  };
+  var Selector = {
+    TOOLTIP: '.tooltip',
+    TOOLTIP_INNER: '.tooltip-inner',
+    ARROW: '.arrow'
+  };
+  var Trigger = {
+    HOVER: 'hover',
+    FOCUS: 'focus',
+    CLICK: 'click',
+    MANUAL: 'manual'
     /**
      * ------------------------------------------------------------------------
-     * Constants
+     * Class Definition
      * ------------------------------------------------------------------------
      */
-    var NAME = 'tooltip';
-    var VERSION = '4.0.0';
-    var DATA_KEY = 'bs.tooltip';
-    var EVENT_KEY = ".".concat(DATA_KEY);
-    var JQUERY_NO_CONFLICT = $.fn[NAME];
-    var TRANSITION_DURATION = 150;
-    var CLASS_PREFIX = 'bs-tooltip';
-    var BSCLS_PREFIX_REGEX = new RegExp("(^|\\s)".concat(CLASS_PREFIX, "\\S+"), 'g');
-    var DefaultType = {
-      animation: 'boolean',
-      template: 'string',
-      title: '(string|element|function)',
-      trigger: 'string',
-      delay: '(number|object)',
-      html: 'boolean',
-      selector: '(string|boolean)',
-      placement: '(string|function)',
-      offset: '(number|string)',
-      container: '(string|element|boolean)',
-      fallbackPlacement: '(string|array)',
-      boundary: '(string|element)'
-    };
-    var AttachmentMap = {
-      AUTO: 'auto',
-      TOP: 'top',
-      RIGHT: 'right',
-      BOTTOM: 'bottom',
-      LEFT: 'left'
-    };
-    var Default = {
-      animation: true,
-      template: '<div class="tooltip" role="tooltip">' + '<div class="arrow"></div>' + '<div class="tooltip-inner"></div></div>',
-      trigger: 'hover focus',
-      title: '',
-      delay: 0,
-      html: false,
-      selector: false,
-      placement: 'top',
-      offset: 0,
-      container: false,
-      fallbackPlacement: 'flip',
-      boundary: 'scrollParent'
-    };
-    var HoverState = {
-      SHOW: 'show',
-      OUT: 'out'
-    };
-    var Event = {
-      HIDE: "hide".concat(EVENT_KEY),
-      HIDDEN: "hidden".concat(EVENT_KEY),
-      SHOW: "show".concat(EVENT_KEY),
-      SHOWN: "shown".concat(EVENT_KEY),
-      INSERTED: "inserted".concat(EVENT_KEY),
-      CLICK: "click".concat(EVENT_KEY),
-      FOCUSIN: "focusin".concat(EVENT_KEY),
-      FOCUSOUT: "focusout".concat(EVENT_KEY),
-      MOUSEENTER: "mouseenter".concat(EVENT_KEY),
-      MOUSELEAVE: "mouseleave".concat(EVENT_KEY)
-    };
-    var ClassName = {
-      FADE: 'fade',
-      SHOW: 'show'
-    };
-    var Selector = {
-      TOOLTIP: '.tooltip',
-      TOOLTIP_INNER: '.tooltip-inner',
-      ARROW: '.arrow'
-    };
-    var Trigger = {
-      HOVER: 'hover',
-      FOCUS: 'focus',
-      CLICK: 'click',
-      MANUAL: 'manual'
+
+  };
+
+  var Tooltip = function () {
+    function Tooltip(element, config) {
+      _classCallCheck(this, Tooltip);
+
       /**
-       * ------------------------------------------------------------------------
-       * Class Definition
-       * ------------------------------------------------------------------------
+       * Check for Popper dependency
+       * Popper - https://popper.js.org
        */
+      if (typeof _popper2.default === 'undefined') {
+        throw new TypeError('Bootstrap\'s tooltips require Popper.js (https://popper.js.org/)');
+      } // private
 
-    };
 
-    var Tooltip = function () {
-      function Tooltip(element, config) {
-        _classCallCheck(this, Tooltip);
+      this._isEnabled = true;
+      this._timeout = 0;
+      this._hoverState = '';
+      this._activeTrigger = {};
+      this._popper = null; // Protected
 
-        /**
-         * Check for Popper dependency
-         * Popper - https://popper.js.org
-         */
-        if (typeof _popper2.default === 'undefined') {
-          throw new TypeError('Bootstrap tooltips require Popper.js (https://popper.js.org)');
-        } // private
+      this.element = element;
+      this.config = this._getConfig(config);
+      this.tip = null;
 
+      this._setListeners();
+    } // Getters
 
+
+    _createClass(Tooltip, [{
+      key: "enable",
+      value: function enable() {
         this._isEnabled = true;
-        this._timeout = 0;
-        this._hoverState = '';
-        this._activeTrigger = {};
-        this._popper = null; // Protected
+      }
+    }, {
+      key: "disable",
+      value: function disable() {
+        this._isEnabled = false;
+      }
+    }, {
+      key: "toggleEnabled",
+      value: function toggleEnabled() {
+        this._isEnabled = !this._isEnabled;
+      }
+    }, {
+      key: "toggle",
+      value: function toggle(event) {
+        if (!this._isEnabled) {
+          return;
+        }
 
-        this.element = element;
-        this.config = this._getConfig(config);
-        this.tip = null;
+        if (event) {
+          var dataKey = this.constructor.DATA_KEY;
+          var context = (0, _jquery2.default)(event.currentTarget).data(dataKey);
 
-        this._setListeners();
-      } // Getters
+          if (!context) {
+            context = new this.constructor(event.currentTarget, this._getDelegateConfig());
+            (0, _jquery2.default)(event.currentTarget).data(dataKey, context);
+          }
 
+          context._activeTrigger.click = !context._activeTrigger.click;
+
+          if (context._isWithActiveTrigger()) {
+            context._enter(null, context);
+          } else {
+            context._leave(null, context);
+          }
+        } else {
+          if ((0, _jquery2.default)(this.getTipElement()).hasClass(ClassName.SHOW)) {
+            this._leave(null, this);
 
-      _createClass(Tooltip, [{
-        key: "enable",
-        value: function enable() {
-          this._isEnabled = true;
-        }
-      }, {
-        key: "disable",
-        value: function disable() {
-          this._isEnabled = false;
-        }
-      }, {
-        key: "toggleEnabled",
-        value: function toggleEnabled() {
-          this._isEnabled = !this._isEnabled;
-        }
-      }, {
-        key: "toggle",
-        value: function toggle(event) {
-          if (!this._isEnabled) {
             return;
           }
 
-          if (event) {
-            var dataKey = this.constructor.DATA_KEY;
-            var context = $(event.currentTarget).data(dataKey);
+          this._enter(null, this);
+        }
+      }
+    }, {
+      key: "dispose",
+      value: function dispose() {
+        clearTimeout(this._timeout);
 
-            if (!context) {
-              context = new this.constructor(event.currentTarget, this._getDelegateConfig());
-              $(event.currentTarget).data(dataKey, context);
-            }
+        _jquery2.default.removeData(this.element, this.constructor.DATA_KEY);
 
-            context._activeTrigger.click = !context._activeTrigger.click;
+        (0, _jquery2.default)(this.element).off(this.constructor.EVENT_KEY);
+        (0, _jquery2.default)(this.element).closest('.modal').off('hide.bs.modal');
 
-            if (context._isWithActiveTrigger()) {
-              context._enter(null, context);
-            } else {
-              context._leave(null, context);
-            }
-          } else {
-            if ($(this.getTipElement()).hasClass(ClassName.SHOW)) {
-              this._leave(null, this);
+        if (this.tip) {
+          (0, _jquery2.default)(this.tip).remove();
+        }
 
-              return;
-            }
+        this._isEnabled = null;
+        this._timeout = null;
+        this._hoverState = null;
+        this._activeTrigger = null;
 
-            this._enter(null, this);
-          }
+        if (this._popper !== null) {
+          this._popper.destroy();
         }
-      }, {
-        key: "dispose",
-        value: function dispose() {
-          clearTimeout(this._timeout);
-          $.removeData(this.element, this.constructor.DATA_KEY);
-          $(this.element).off(this.constructor.EVENT_KEY);
-          $(this.element).closest('.modal').off('hide.bs.modal');
 
-          if (this.tip) {
-            $(this.tip).remove();
-          }
+        this._popper = null;
+        this.element = null;
+        this.config = null;
+        this.tip = null;
+      }
+    }, {
+      key: "show",
+      value: function show() {
+        var _this = this;
 
-          this._isEnabled = null;
-          this._timeout = null;
-          this._hoverState = null;
-          this._activeTrigger = null;
+        if ((0, _jquery2.default)(this.element).css('display') === 'none') {
+          throw new Error('Please use show on visible elements');
+        }
 
-          if (this._popper !== null) {
-            this._popper.destroy();
-          }
+        var showEvent = _jquery2.default.Event(this.constructor.Event.SHOW);
 
-          this._popper = null;
-          this.element = null;
-          this.config = null;
-          this.tip = null;
-        }
-      }, {
-        key: "show",
-        value: function show() {
-          var _this = this;
+        if (this.isWithContent() && this._isEnabled) {
+          (0, _jquery2.default)(this.element).trigger(showEvent);
 
-          if ($(this.element).css('display') === 'none') {
-            throw new Error('Please use show on visible elements');
-          }
+          var shadowRoot = _util2.default.findShadowRoot(this.element);
+
+          var isInTheDom = _jquery2.default.contains(shadowRoot !== null ? shadowRoot : this.element.ownerDocument.documentElement, this.element);
 
-          var showEvent = $.Event(this.constructor.Event.SHOW);
+          if (showEvent.isDefaultPrevented() || !isInTheDom) {
+            return;
+          }
 
-          if (this.isWithContent() && this._isEnabled) {
-            $(this.element).trigger(showEvent);
-            var isInTheDom = $.contains(this.element.ownerDocument.documentElement, this.element);
+          var tip = this.getTipElement();
 
-            if (showEvent.isDefaultPrevented() || !isInTheDom) {
-              return;
-            }
+          var tipId = _util2.default.getUID(this.constructor.NAME);
 
-            var tip = this.getTipElement();
+          tip.setAttribute('id', tipId);
+          this.element.setAttribute('aria-describedby', tipId);
+          this.setContent();
 
-            var tipId = _util2.default.getUID(this.constructor.NAME);
+          if (this.config.animation) {
+            (0, _jquery2.default)(tip).addClass(ClassName.FADE);
+          }
 
-            tip.setAttribute('id', tipId);
-            this.element.setAttribute('aria-describedby', tipId);
-            this.setContent();
+          var placement = typeof this.config.placement === 'function' ? this.config.placement.call(this, tip, this.element) : this.config.placement;
 
-            if (this.config.animation) {
-              $(tip).addClass(ClassName.FADE);
-            }
+          var attachment = this._getAttachment(placement);
 
-            var placement = typeof this.config.placement === 'function' ? this.config.placement.call(this, tip, this.element) : this.config.placement;
+          this.addAttachmentClass(attachment);
 
-            var attachment = this._getAttachment(placement);
+          var container = this._getContainer();
 
-            this.addAttachmentClass(attachment);
-            var container = this.config.container === false ? document.body : $(this.config.container);
-            $(tip).data(this.constructor.DATA_KEY, this);
+          (0, _jquery2.default)(tip).data(this.constructor.DATA_KEY, this);
 
-            if (!$.contains(this.element.ownerDocument.documentElement, this.tip)) {
-              $(tip).appendTo(container);
-            }
+          if (!_jquery2.default.contains(this.element.ownerDocument.documentElement, this.tip)) {
+            (0, _jquery2.default)(tip).appendTo(container);
+          }
 
-            $(this.element).trigger(this.constructor.Event.INSERTED);
-            this._popper = new _popper2.default(this.element, tip, {
-              placement: attachment,
-              modifiers: {
-                offset: {
-                  offset: this.config.offset
-                },
-                flip: {
-                  behavior: this.config.fallbackPlacement
-                },
-                arrow: {
-                  element: Selector.ARROW
-                },
-                preventOverflow: {
-                  boundariesElement: this.config.boundary
-                }
+          (0, _jquery2.default)(this.element).trigger(this.constructor.Event.INSERTED);
+          this._popper = new _popper2.default(this.element, tip, {
+            placement: attachment,
+            modifiers: {
+              offset: this._getOffset(),
+              flip: {
+                behavior: this.config.fallbackPlacement
               },
-              onCreate: function onCreate(data) {
-                if (data.originalPlacement !== data.placement) {
-                  _this._handlePopperPlacementChange(data);
-                }
+              arrow: {
+                element: Selector.ARROW
               },
-              onUpdate: function onUpdate(data) {
+              preventOverflow: {
+                boundariesElement: this.config.boundary
+              }
+            },
+            onCreate: function onCreate(data) {
+              if (data.originalPlacement !== data.placement) {
                 _this._handlePopperPlacementChange(data);
               }
-            });
-            $(tip).addClass(ClassName.SHOW); // If this is a touch-enabled device we add extra
-            // empty mouseover listeners to the body's immediate children;
-            // only needed because of broken event delegation on iOS
-            // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html
-
-            if ('ontouchstart' in document.documentElement) {
-              $('body').children().on('mouseover', null, $.noop);
+            },
+            onUpdate: function onUpdate(data) {
+              return _this._handlePopperPlacementChange(data);
             }
+          });
+          (0, _jquery2.default)(tip).addClass(ClassName.SHOW); // If this is a touch-enabled device we add extra
+          // empty mouseover listeners to the body's immediate children;
+          // only needed because of broken event delegation on iOS
+          // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html
 
-            var complete = function complete() {
-              if (_this.config.animation) {
-                _this._fixTransition();
-              }
+          if ('ontouchstart' in document.documentElement) {
+            (0, _jquery2.default)(document.body).children().on('mouseover', null, _jquery2.default.noop);
+          }
 
-              var prevHoverState = _this._hoverState;
-              _this._hoverState = null;
-              $(_this.element).trigger(_this.constructor.Event.SHOWN);
+          var complete = function complete() {
+            if (_this.config.animation) {
+              _this._fixTransition();
+            }
 
-              if (prevHoverState === HoverState.OUT) {
-                _this._leave(null, _this);
-              }
-            };
+            var prevHoverState = _this._hoverState;
+            _this._hoverState = null;
+            (0, _jquery2.default)(_this.element).trigger(_this.constructor.Event.SHOWN);
 
-            if (_util2.default.supportsTransitionEnd() && $(this.tip).hasClass(ClassName.FADE)) {
-              $(this.tip).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(Tooltip._TRANSITION_DURATION);
-            } else {
-              complete();
+            if (prevHoverState === HoverState.OUT) {
+              _this._leave(null, _this);
             }
+          };
+
+          if ((0, _jquery2.default)(this.tip).hasClass(ClassName.FADE)) {
+            var transitionDuration = _util2.default.getTransitionDurationFromElement(this.tip);
+
+            (0, _jquery2.default)(this.tip).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
+          } else {
+            complete();
           }
         }
-      }, {
-        key: "hide",
-        value: function hide(callback) {
-          var _this2 = this;
+      }
+    }, {
+      key: "hide",
+      value: function hide(callback) {
+        var _this2 = this;
 
-          var tip = this.getTipElement();
-          var hideEvent = $.Event(this.constructor.Event.HIDE);
+        var tip = this.getTipElement();
 
-          var complete = function complete() {
-            if (_this2._hoverState !== HoverState.SHOW && tip.parentNode) {
-              tip.parentNode.removeChild(tip);
-            }
-
-            _this2._cleanTipClass();
+        var hideEvent = _jquery2.default.Event(this.constructor.Event.HIDE);
 
-            _this2.element.removeAttribute('aria-describedby');
+        var complete = function complete() {
+          if (_this2._hoverState !== HoverState.SHOW && tip.parentNode) {
+            tip.parentNode.removeChild(tip);
+          }
 
-            $(_this2.element).trigger(_this2.constructor.Event.HIDDEN);
+          _this2._cleanTipClass();
 
-            if (_this2._popper !== null) {
-              _this2._popper.destroy();
-            }
+          _this2.element.removeAttribute('aria-describedby');
 
-            if (callback) {
-              callback();
-            }
-          };
+          (0, _jquery2.default)(_this2.element).trigger(_this2.constructor.Event.HIDDEN);
 
-          $(this.element).trigger(hideEvent);
+          if (_this2._popper !== null) {
+            _this2._popper.destroy();
+          }
 
-          if (hideEvent.isDefaultPrevented()) {
-            return;
+          if (callback) {
+            callback();
           }
+        };
 
-          $(tip).removeClass(ClassName.SHOW); // If this is a touch-enabled device we remove the extra
-          // empty mouseover listeners we added for iOS support
+        (0, _jquery2.default)(this.element).trigger(hideEvent);
 
-          if ('ontouchstart' in document.documentElement) {
-            $('body').children().off('mouseover', null, $.noop);
-          }
+        if (hideEvent.isDefaultPrevented()) {
+          return;
+        }
 
-          this._activeTrigger[Trigger.CLICK] = false;
-          this._activeTrigger[Trigger.FOCUS] = false;
-          this._activeTrigger[Trigger.HOVER] = false;
+        (0, _jquery2.default)(tip).removeClass(ClassName.SHOW); // If this is a touch-enabled device we remove the extra
+        // empty mouseover listeners we added for iOS support
 
-          if (_util2.default.supportsTransitionEnd() && $(this.tip).hasClass(ClassName.FADE)) {
-            $(tip).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(TRANSITION_DURATION);
-          } else {
-            complete();
-          }
+        if ('ontouchstart' in document.documentElement) {
+          (0, _jquery2.default)(document.body).children().off('mouseover', null, _jquery2.default.noop);
+        }
+
+        this._activeTrigger[Trigger.CLICK] = false;
+        this._activeTrigger[Trigger.FOCUS] = false;
+        this._activeTrigger[Trigger.HOVER] = false;
+
+        if ((0, _jquery2.default)(this.tip).hasClass(ClassName.FADE)) {
+          var transitionDuration = _util2.default.getTransitionDurationFromElement(tip);
 
-          this._hoverState = '';
+          (0, _jquery2.default)(tip).one(_util2.default.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
+        } else {
+          complete();
         }
-      }, {
-        key: "update",
-        value: function update() {
-          if (this._popper !== null) {
-            this._popper.scheduleUpdate();
-          }
+
+        this._hoverState = '';
+      }
+    }, {
+      key: "update",
+      value: function update() {
+        if (this._popper !== null) {
+          this._popper.scheduleUpdate();
         }
-      }, {
-        key: "isWithContent",
-        value: function isWithContent() {
-          return Boolean(this.getTitle());
-        }
-      }, {
-        key: "addAttachmentClass",
-        value: function addAttachmentClass(attachment) {
-          $(this.getTipElement()).addClass("".concat(CLASS_PREFIX, "-").concat(attachment));
-        }
-      }, {
-        key: "getTipElement",
-        value: function getTipElement() {
-          this.tip = this.tip || $(this.config.template)[0];
-          return this.tip;
-        }
-      }, {
-        key: "setContent",
-        value: function setContent() {
-          var $tip = $(this.getTipElement());
-          this.setElementContent($tip.find(Selector.TOOLTIP_INNER), this.getTitle());
-          $tip.removeClass("".concat(ClassName.FADE, " ").concat(ClassName.SHOW));
-        }
-      }, {
-        key: "setElementContent",
-        value: function setElementContent($element, content) {
-          var html = this.config.html;
-
-          if (_typeof(content) === 'object' && (content.nodeType || content.jquery)) {
-            // Content is a DOM node or a jQuery
-            if (html) {
-              if (!$(content).parent().is($element)) {
-                $element.empty().append(content);
-              }
-            } else {
-              $element.text($(content).text());
+      }
+    }, {
+      key: "isWithContent",
+      value: function isWithContent() {
+        return Boolean(this.getTitle());
+      }
+    }, {
+      key: "addAttachmentClass",
+      value: function addAttachmentClass(attachment) {
+        (0, _jquery2.default)(this.getTipElement()).addClass("".concat(CLASS_PREFIX, "-").concat(attachment));
+      }
+    }, {
+      key: "getTipElement",
+      value: function getTipElement() {
+        this.tip = this.tip || (0, _jquery2.default)(this.config.template)[0];
+        return this.tip;
+      }
+    }, {
+      key: "setContent",
+      value: function setContent() {
+        var tip = this.getTipElement();
+        this.setElementContent((0, _jquery2.default)(tip.querySelectorAll(Selector.TOOLTIP_INNER)), this.getTitle());
+        (0, _jquery2.default)(tip).removeClass("".concat(ClassName.FADE, " ").concat(ClassName.SHOW));
+      }
+    }, {
+      key: "setElementContent",
+      value: function setElementContent($element, content) {
+        if (_typeof(content) === 'object' && (content.nodeType || content.jquery)) {
+          // Content is a DOM node or a jQuery
+          if (this.config.html) {
+            if (!(0, _jquery2.default)(content).parent().is($element)) {
+              $element.empty().append(content);
             }
           } else {
-            $element[html ? 'html' : 'text'](content);
+            $element.text((0, _jquery2.default)(content).text());
           }
+
+          return;
         }
-      }, {
-        key: "getTitle",
-        value: function getTitle() {
-          var title = this.element.getAttribute('data-original-title');
 
-          if (!title) {
-            title = typeof this.config.title === 'function' ? this.config.title.call(this.element) : this.config.title;
+        if (this.config.html) {
+          if (this.config.sanitize) {
+            content = (0, _sanitizer.sanitizeHtml)(content, this.config.whiteList, this.config.sanitizeFn);
           }
 
-          return title;
-        }
-      }, {
-        key: "_getAttachment",
-        value: function _getAttachment(placement) {
-          return AttachmentMap[placement.toUpperCase()];
-        }
-      }, {
-        key: "_setListeners",
-        value: function _setListeners() {
-          var _this3 = this;
-
-          var triggers = this.config.trigger.split(' ');
-          triggers.forEach(function (trigger) {
-            if (trigger === 'click') {
-              $(_this3.element).on(_this3.constructor.Event.CLICK, _this3.config.selector, function (event) {
-                return _this3.toggle(event);
-              });
-            } else if (trigger !== Trigger.MANUAL) {
-              var eventIn = trigger === Trigger.HOVER ? _this3.constructor.Event.MOUSEENTER : _this3.constructor.Event.FOCUSIN;
-              var eventOut = trigger === Trigger.HOVER ? _this3.constructor.Event.MOUSELEAVE : _this3.constructor.Event.FOCUSOUT;
-              $(_this3.element).on(eventIn, _this3.config.selector, function (event) {
-                return _this3._enter(event);
-              }).on(eventOut, _this3.config.selector, function (event) {
-                return _this3._leave(event);
-              });
-            }
+          $element.html(content);
+        } else {
+          $element.text(content);
+        }
+      }
+    }, {
+      key: "getTitle",
+      value: function getTitle() {
+        var title = this.element.getAttribute('data-original-title');
 
-            $(_this3.element).closest('.modal').on('hide.bs.modal', function () {
-              return _this3.hide();
-            });
-          });
+        if (!title) {
+          title = typeof this.config.title === 'function' ? this.config.title.call(this.element) : this.config.title;
+        }
 
-          if (this.config.selector) {
-            this.config = _extends({}, this.config, {
-              trigger: 'manual',
-              selector: ''
-            });
-          } else {
-            this._fixTitle();
-          }
+        return title;
+      }
+    }, {
+      key: "_getOffset",
+      value: function _getOffset() {
+        var _this3 = this;
+
+        var offset = {};
+
+        if (typeof this.config.offset === 'function') {
+          offset.fn = function (data) {
+            data.offsets = _objectSpread({}, data.offsets, _this3.config.offset(data.offsets, _this3.element) || {});
+            return data;
+          };
+        } else {
+          offset.offset = this.config.offset;
         }
-      }, {
-        key: "_fixTitle",
-        value: function _fixTitle() {
-          var titleType = _typeof(this.element.getAttribute('data-original-title'));
 
-          if (this.element.getAttribute('title') || titleType !== 'string') {
-            this.element.setAttribute('data-original-title', this.element.getAttribute('title') || '');
-            this.element.setAttribute('title', '');
-          }
+        return offset;
+      }
+    }, {
+      key: "_getContainer",
+      value: function _getContainer() {
+        if (this.config.container === false) {
+          return document.body;
         }
-      }, {
-        key: "_enter",
-        value: function _enter(event, context) {
-          var dataKey = this.constructor.DATA_KEY;
-          context = context || $(event.currentTarget).data(dataKey);
 
-          if (!context) {
-            context = new this.constructor(event.currentTarget, this._getDelegateConfig());
-            $(event.currentTarget).data(dataKey, context);
-          }
+        if (_util2.default.isElement(this.config.container)) {
+          return (0, _jquery2.default)(this.config.container);
+        }
 
-          if (event) {
-            context._activeTrigger[event.type === 'focusin' ? Trigger.FOCUS : Trigger.HOVER] = true;
+        return (0, _jquery2.default)(document).find(this.config.container);
+      }
+    }, {
+      key: "_getAttachment",
+      value: function _getAttachment(placement) {
+        return AttachmentMap[placement.toUpperCase()];
+      }
+    }, {
+      key: "_setListeners",
+      value: function _setListeners() {
+        var _this4 = this;
+
+        var triggers = this.config.trigger.split(' ');
+        triggers.forEach(function (trigger) {
+          if (trigger === 'click') {
+            (0, _jquery2.default)(_this4.element).on(_this4.constructor.Event.CLICK, _this4.config.selector, function (event) {
+              return _this4.toggle(event);
+            });
+          } else if (trigger !== Trigger.MANUAL) {
+            var eventIn = trigger === Trigger.HOVER ? _this4.constructor.Event.MOUSEENTER : _this4.constructor.Event.FOCUSIN;
+            var eventOut = trigger === Trigger.HOVER ? _this4.constructor.Event.MOUSELEAVE : _this4.constructor.Event.FOCUSOUT;
+            (0, _jquery2.default)(_this4.element).on(eventIn, _this4.config.selector, function (event) {
+              return _this4._enter(event);
+            }).on(eventOut, _this4.config.selector, function (event) {
+              return _this4._leave(event);
+            });
           }
-
-          if ($(context.getTipElement()).hasClass(ClassName.SHOW) || context._hoverState === HoverState.SHOW) {
-            context._hoverState = HoverState.SHOW;
-            return;
+        });
+        (0, _jquery2.default)(this.element).closest('.modal').on('hide.bs.modal', function () {
+          if (_this4.element) {
+            _this4.hide();
           }
+        });
+
+        if (this.config.selector) {
+          this.config = _objectSpread({}, this.config, {
+            trigger: 'manual',
+            selector: ''
+          });
+        } else {
+          this._fixTitle();
+        }
+      }
+    }, {
+      key: "_fixTitle",
+      value: function _fixTitle() {
+        var titleType = _typeof(this.element.getAttribute('data-original-title'));
+
+        if (this.element.getAttribute('title') || titleType !== 'string') {
+          this.element.setAttribute('data-original-title', this.element.getAttribute('title') || '');
+          this.element.setAttribute('title', '');
+        }
+      }
+    }, {
+      key: "_enter",
+      value: function _enter(event, context) {
+        var dataKey = this.constructor.DATA_KEY;
+        context = context || (0, _jquery2.default)(event.currentTarget).data(dataKey);
+
+        if (!context) {
+          context = new this.constructor(event.currentTarget, this._getDelegateConfig());
+          (0, _jquery2.default)(event.currentTarget).data(dataKey, context);
+        }
 
-          clearTimeout(context._timeout);
+        if (event) {
+          context._activeTrigger[event.type === 'focusin' ? Trigger.FOCUS : Trigger.HOVER] = true;
+        }
+
+        if ((0, _jquery2.default)(context.getTipElement()).hasClass(ClassName.SHOW) || context._hoverState === HoverState.SHOW) {
           context._hoverState = HoverState.SHOW;
+          return;
+        }
 
-          if (!context.config.delay || !context.config.delay.show) {
+        clearTimeout(context._timeout);
+        context._hoverState = HoverState.SHOW;
+
+        if (!context.config.delay || !context.config.delay.show) {
+          context.show();
+          return;
+        }
+
+        context._timeout = setTimeout(function () {
+          if (context._hoverState === HoverState.SHOW) {
             context.show();
-            return;
           }
+        }, context.config.delay.show);
+      }
+    }, {
+      key: "_leave",
+      value: function _leave(event, context) {
+        var dataKey = this.constructor.DATA_KEY;
+        context = context || (0, _jquery2.default)(event.currentTarget).data(dataKey);
 
-          context._timeout = setTimeout(function () {
-            if (context._hoverState === HoverState.SHOW) {
-              context.show();
-            }
-          }, context.config.delay.show);
+        if (!context) {
+          context = new this.constructor(event.currentTarget, this._getDelegateConfig());
+          (0, _jquery2.default)(event.currentTarget).data(dataKey, context);
         }
-      }, {
-        key: "_leave",
-        value: function _leave(event, context) {
-          var dataKey = this.constructor.DATA_KEY;
-          context = context || $(event.currentTarget).data(dataKey);
 
-          if (!context) {
-            context = new this.constructor(event.currentTarget, this._getDelegateConfig());
-            $(event.currentTarget).data(dataKey, context);
-          }
+        if (event) {
+          context._activeTrigger[event.type === 'focusout' ? Trigger.FOCUS : Trigger.HOVER] = false;
+        }
 
-          if (event) {
-            context._activeTrigger[event.type === 'focusout' ? Trigger.FOCUS : Trigger.HOVER] = false;
-          }
+        if (context._isWithActiveTrigger()) {
+          return;
+        }
 
-          if (context._isWithActiveTrigger()) {
-            return;
-          }
+        clearTimeout(context._timeout);
+        context._hoverState = HoverState.OUT;
 
-          clearTimeout(context._timeout);
-          context._hoverState = HoverState.OUT;
+        if (!context.config.delay || !context.config.delay.hide) {
+          context.hide();
+          return;
+        }
 
-          if (!context.config.delay || !context.config.delay.hide) {
+        context._timeout = setTimeout(function () {
+          if (context._hoverState === HoverState.OUT) {
             context.hide();
-            return;
           }
-
-          context._timeout = setTimeout(function () {
-            if (context._hoverState === HoverState.OUT) {
-              context.hide();
-            }
-          }, context.config.delay.hide);
-        }
-      }, {
-        key: "_isWithActiveTrigger",
-        value: function _isWithActiveTrigger() {
-          for (var trigger in this._activeTrigger) {
-            if (this._activeTrigger[trigger]) {
-              return true;
-            }
+        }, context.config.delay.hide);
+      }
+    }, {
+      key: "_isWithActiveTrigger",
+      value: function _isWithActiveTrigger() {
+        for (var trigger in this._activeTrigger) {
+          if (this._activeTrigger[trigger]) {
+            return true;
           }
-
-          return false;
         }
-      }, {
-        key: "_getConfig",
-        value: function _getConfig(config) {
-          config = _extends({}, this.constructor.Default, $(this.element).data(), config);
-
-          if (typeof config.delay === 'number') {
-            config.delay = {
-              show: config.delay,
-              hide: config.delay
-            };
-          }
 
-          if (typeof config.title === 'number') {
-            config.title = config.title.toString();
+        return false;
+      }
+    }, {
+      key: "_getConfig",
+      value: function _getConfig(config) {
+        var dataAttributes = (0, _jquery2.default)(this.element).data();
+        Object.keys(dataAttributes).forEach(function (dataAttr) {
+          if (DISALLOWED_ATTRIBUTES.indexOf(dataAttr) !== -1) {
+            delete dataAttributes[dataAttr];
           }
+        });
+        config = _objectSpread({}, this.constructor.Default, dataAttributes, _typeof(config) === 'object' && config ? config : {});
 
-          if (typeof config.content === 'number') {
-            config.content = config.content.toString();
-          }
+        if (typeof config.delay === 'number') {
+          config.delay = {
+            show: config.delay,
+            hide: config.delay
+          };
+        }
 
-          _util2.default.typeCheckConfig(NAME, config, this.constructor.DefaultType);
+        if (typeof config.title === 'number') {
+          config.title = config.title.toString();
+        }
 
-          return config;
+        if (typeof config.content === 'number') {
+          config.content = config.content.toString();
         }
-      }, {
-        key: "_getDelegateConfig",
-        value: function _getDelegateConfig() {
-          var config = {};
 
-          if (this.config) {
-            for (var key in this.config) {
-              if (this.constructor.Default[key] !== this.config[key]) {
-                config[key] = this.config[key];
-              }
-            }
-          }
+        _util2.default.typeCheckConfig(NAME, config, this.constructor.DefaultType);
 
-          return config;
+        if (config.sanitize) {
+          config.template = (0, _sanitizer.sanitizeHtml)(config.template, config.whiteList, config.sanitizeFn);
         }
-      }, {
-        key: "_cleanTipClass",
-        value: function _cleanTipClass() {
-          var $tip = $(this.getTipElement());
-          var tabClass = $tip.attr('class').match(BSCLS_PREFIX_REGEX);
 
-          if (tabClass !== null && tabClass.length > 0) {
-            $tip.removeClass(tabClass.join(''));
+        return config;
+      }
+    }, {
+      key: "_getDelegateConfig",
+      value: function _getDelegateConfig() {
+        var config = {};
+
+        if (this.config) {
+          for (var key in this.config) {
+            if (this.constructor.Default[key] !== this.config[key]) {
+              config[key] = this.config[key];
+            }
           }
         }
-      }, {
-        key: "_handlePopperPlacementChange",
-        value: function _handlePopperPlacementChange(data) {
-          this._cleanTipClass();
 
-          this.addAttachmentClass(this._getAttachment(data.placement));
+        return config;
+      }
+    }, {
+      key: "_cleanTipClass",
+      value: function _cleanTipClass() {
+        var $tip = (0, _jquery2.default)(this.getTipElement());
+        var tabClass = $tip.attr('class').match(BSCLS_PREFIX_REGEX);
+
+        if (tabClass !== null && tabClass.length) {
+          $tip.removeClass(tabClass.join(''));
         }
-      }, {
-        key: "_fixTransition",
-        value: function _fixTransition() {
-          var tip = this.getTipElement();
-          var initConfigAnimation = this.config.animation;
+      }
+    }, {
+      key: "_handlePopperPlacementChange",
+      value: function _handlePopperPlacementChange(popperData) {
+        var popperInstance = popperData.instance;
+        this.tip = popperInstance.popper;
 
-          if (tip.getAttribute('x-placement') !== null) {
-            return;
-          }
+        this._cleanTipClass();
+
+        this.addAttachmentClass(this._getAttachment(popperData.placement));
+      }
+    }, {
+      key: "_fixTransition",
+      value: function _fixTransition() {
+        var tip = this.getTipElement();
+        var initConfigAnimation = this.config.animation;
 
-          $(tip).removeClass(ClassName.FADE);
-          this.config.animation = false;
-          this.hide();
-          this.show();
-          this.config.animation = initConfigAnimation;
+        if (tip.getAttribute('x-placement') !== null) {
+          return;
         }
-      }], [{
-        key: "_jQueryInterface",
-        value: function _jQueryInterface(config) {
-          return this.each(function () {
-            var data = $(this).data(DATA_KEY);
 
-            var _config = _typeof(config) === 'object' && config;
+        (0, _jquery2.default)(tip).removeClass(ClassName.FADE);
+        this.config.animation = false;
+        this.hide();
+        this.show();
+        this.config.animation = initConfigAnimation;
+      }
+    }], [{
+      key: "_jQueryInterface",
+      value: function _jQueryInterface(config) {
+        return this.each(function () {
+          var data = (0, _jquery2.default)(this).data(DATA_KEY);
 
-            if (!data && /dispose|hide/.test(config)) {
-              return;
-            }
+          var _config = _typeof(config) === 'object' && config;
 
-            if (!data) {
-              data = new Tooltip(this, _config);
-              $(this).data(DATA_KEY, data);
-            }
+          if (!data && /dispose|hide/.test(config)) {
+            return;
+          }
 
-            if (typeof config === 'string') {
-              if (typeof data[config] === 'undefined') {
-                throw new TypeError("No method named \"".concat(config, "\""));
-              }
+          if (!data) {
+            data = new Tooltip(this, _config);
+            (0, _jquery2.default)(this).data(DATA_KEY, data);
+          }
 
-              data[config]();
+          if (typeof config === 'string') {
+            if (typeof data[config] === 'undefined') {
+              throw new TypeError("No method named \"".concat(config, "\""));
             }
-          });
-        }
-      }, {
-        key: "VERSION",
-        get: function get() {
-          return VERSION;
-        }
-      }, {
-        key: "Default",
-        get: function get() {
-          return Default;
-        }
-      }, {
-        key: "NAME",
-        get: function get() {
-          return NAME;
-        }
-      }, {
-        key: "DATA_KEY",
-        get: function get() {
-          return DATA_KEY;
-        }
-      }, {
-        key: "Event",
-        get: function get() {
-          return Event;
-        }
-      }, {
-        key: "EVENT_KEY",
-        get: function get() {
-          return EVENT_KEY;
-        }
-      }, {
-        key: "DefaultType",
-        get: function get() {
-          return DefaultType;
-        }
-      }]);
 
-      return Tooltip;
-    }();
+            data[config]();
+          }
+        });
+      }
+    }, {
+      key: "VERSION",
+      get: function get() {
+        return VERSION;
+      }
+    }, {
+      key: "Default",
+      get: function get() {
+        return Default;
+      }
+    }, {
+      key: "NAME",
+      get: function get() {
+        return NAME;
+      }
+    }, {
+      key: "DATA_KEY",
+      get: function get() {
+        return DATA_KEY;
+      }
+    }, {
+      key: "Event",
+      get: function get() {
+        return Event;
+      }
+    }, {
+      key: "EVENT_KEY",
+      get: function get() {
+        return EVENT_KEY;
+      }
+    }, {
+      key: "DefaultType",
+      get: function get() {
+        return DefaultType;
+      }
+    }]);
 
-    /**
-     * ------------------------------------------------------------------------
-     * jQuery
-     * ------------------------------------------------------------------------
-     */
-    $.fn[NAME] = Tooltip._jQueryInterface;
-    $.fn[NAME].Constructor = Tooltip;
+    return Tooltip;
+  }();
 
-    $.fn[NAME].noConflict = function () {
-      $.fn[NAME] = JQUERY_NO_CONFLICT;
-      return Tooltip._jQueryInterface;
-    };
+  /**
+   * ------------------------------------------------------------------------
+   * jQuery
+   * ------------------------------------------------------------------------
+   */
+  _jquery2.default.fn[NAME] = Tooltip._jQueryInterface;
+  _jquery2.default.fn[NAME].Constructor = Tooltip;
 
-    return Tooltip;
-  }(_jquery2.default, _popper2.default);
+  _jquery2.default.fn[NAME].noConflict = function () {
+    _jquery2.default.fn[NAME] = JQUERY_NO_CONFLICT;
+    return Tooltip._jQueryInterface;
+  };
 
   exports.default = Tooltip;
 });
\ No newline at end of file
index 19bab70..00cb6b9 100644 (file)
@@ -1,3 +1,5 @@
+"use strict";
+
 define(["exports", "jquery"], function (exports, _jquery) {
   "use strict";
 
@@ -15,142 +17,156 @@ define(["exports", "jquery"], function (exports, _jquery) {
 
   /**
    * --------------------------------------------------------------------------
-   * Bootstrap (v4.0.0): util.js
+   * Bootstrap (v4.3.1): util.js
    * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
    * --------------------------------------------------------------------------
    */
-  var Util = function ($) {
-    /**
-     * ------------------------------------------------------------------------
-     * Private TransitionEnd Helpers
-     * ------------------------------------------------------------------------
-     */
-    var transition = false;
-    var MAX_UID = 1000000; // Shoutout AngusCroll (https://goo.gl/pxwQGp)
-
-    function toType(obj) {
-      return {}.toString.call(obj).match(/\s([a-zA-Z]+)/)[1].toLowerCase();
-    }
 
-    function getSpecialTransitionEndEvent() {
-      return {
-        bindType: transition.end,
-        delegateType: transition.end,
-        handle: function handle(event) {
-          if ($(event.target).is(this)) {
-            return event.handleObj.handler.apply(this, arguments); // eslint-disable-line prefer-rest-params
-          }
+  /**
+   * ------------------------------------------------------------------------
+   * Private TransitionEnd Helpers
+   * ------------------------------------------------------------------------
+   */
+  var TRANSITION_END = 'transitionend';
+  var MAX_UID = 1000000;
+  var MILLISECONDS_MULTIPLIER = 1000; // Shoutout AngusCroll (https://goo.gl/pxwQGp)
 
-          return undefined; // eslint-disable-line no-undefined
+  function toType(obj) {
+    return {}.toString.call(obj).match(/\s([a-z]+)/i)[1].toLowerCase();
+  }
+
+  function getSpecialTransitionEndEvent() {
+    return {
+      bindType: TRANSITION_END,
+      delegateType: TRANSITION_END,
+      handle: function handle(event) {
+        if ((0, _jquery2.default)(event.target).is(this)) {
+          return event.handleObj.handler.apply(this, arguments); // eslint-disable-line prefer-rest-params
         }
-      };
-    }
 
-    function transitionEndTest() {
-      if (typeof window !== 'undefined' && window.QUnit) {
-        return false;
+        return undefined; // eslint-disable-line no-undefined
       }
+    };
+  }
 
-      return {
-        end: 'transitionend'
-      };
-    }
+  function transitionEndEmulator(duration) {
+    var _this = this;
 
-    function transitionEndEmulator(duration) {
-      var _this = this;
+    var called = false;
+    (0, _jquery2.default)(this).one(Util.TRANSITION_END, function () {
+      called = true;
+    });
+    setTimeout(function () {
+      if (!called) {
+        Util.triggerTransitionEnd(_this);
+      }
+    }, duration);
+    return this;
+  }
 
-      var called = false;
-      $(this).one(Util.TRANSITION_END, function () {
-        called = true;
-      });
-      setTimeout(function () {
-        if (!called) {
-          Util.triggerTransitionEnd(_this);
-        }
-      }, duration);
-      return this;
-    }
+  function setTransitionEndSupport() {
+    _jquery2.default.fn.emulateTransitionEnd = transitionEndEmulator;
+    _jquery2.default.event.special[Util.TRANSITION_END] = getSpecialTransitionEndEvent();
+  }
+  /**
+   * --------------------------------------------------------------------------
+   * Public Util Api
+   * --------------------------------------------------------------------------
+   */
 
-    function setTransitionEndSupport() {
-      transition = transitionEndTest();
-      $.fn.emulateTransitionEnd = transitionEndEmulator;
 
-      if (Util.supportsTransitionEnd()) {
-        $.event.special[Util.TRANSITION_END] = getSpecialTransitionEndEvent();
-      }
-    }
+  var Util = {
+    TRANSITION_END: 'bsTransitionEnd',
+    getUID: function getUID(prefix) {
+      do {
+        // eslint-disable-next-line no-bitwise
+        prefix += ~~(Math.random() * MAX_UID); // "~~" acts like a faster Math.floor() here
+      } while (document.getElementById(prefix));
 
-    function escapeId(selector) {
-      // We escape IDs in case of special selectors (selector = '#myId:something')
-      // $.escapeSelector does not exist in jQuery < 3
-      selector = typeof $.escapeSelector === 'function' ? $.escapeSelector(selector).substr(1) : selector.replace(/(:|\.|\[|\]|,|=|@)/g, '\\$1');
-      return selector;
-    }
-    /**
-     * --------------------------------------------------------------------------
-     * Public Util Api
-     * --------------------------------------------------------------------------
-     */
+      return prefix;
+    },
+    getSelectorFromElement: function getSelectorFromElement(element) {
+      var selector = element.getAttribute('data-target');
 
+      if (!selector || selector === '#') {
+        var hrefAttr = element.getAttribute('href');
+        selector = hrefAttr && hrefAttr !== '#' ? hrefAttr.trim() : '';
+      }
 
-    var Util = {
-      TRANSITION_END: 'bsTransitionEnd',
-      getUID: function getUID(prefix) {
-        do {
-          // eslint-disable-next-line no-bitwise
-          prefix += ~~(Math.random() * MAX_UID); // "~~" acts like a faster Math.floor() here
-        } while (document.getElementById(prefix));
+      try {
+        return document.querySelector(selector) ? selector : null;
+      } catch (err) {
+        return null;
+      }
+    },
+    getTransitionDurationFromElement: function getTransitionDurationFromElement(element) {
+      if (!element) {
+        return 0;
+      } // Get transition-duration of the element
+
+
+      var transitionDuration = (0, _jquery2.default)(element).css('transition-duration');
+      var transitionDelay = (0, _jquery2.default)(element).css('transition-delay');
+      var floatTransitionDuration = parseFloat(transitionDuration);
+      var floatTransitionDelay = parseFloat(transitionDelay); // Return 0 if element or transition duration is not found
+
+      if (!floatTransitionDuration && !floatTransitionDelay) {
+        return 0;
+      } // If multiple durations are defined, take the first
+
+
+      transitionDuration = transitionDuration.split(',')[0];
+      transitionDelay = transitionDelay.split(',')[0];
+      return (parseFloat(transitionDuration) + parseFloat(transitionDelay)) * MILLISECONDS_MULTIPLIER;
+    },
+    reflow: function reflow(element) {
+      return element.offsetHeight;
+    },
+    triggerTransitionEnd: function triggerTransitionEnd(element) {
+      (0, _jquery2.default)(element).trigger(TRANSITION_END);
+    },
+    supportsTransitionEnd: function supportsTransitionEnd() {
+      return Boolean(TRANSITION_END);
+    },
+    isElement: function isElement(obj) {
+      return (obj[0] || obj).nodeType;
+    },
+    typeCheckConfig: function typeCheckConfig(componentName, config, configTypes) {
+      for (var property in configTypes) {
+        if (Object.prototype.hasOwnProperty.call(configTypes, property)) {
+          var expectedTypes = configTypes[property];
+          var value = config[property];
+          var valueType = value && Util.isElement(value) ? 'element' : toType(value);
+
+          if (!new RegExp(expectedTypes).test(valueType)) {
+            throw new Error("".concat(componentName.toUpperCase(), ": ") + "Option \"".concat(property, "\" provided type \"").concat(valueType, "\" ") + "but expected type \"".concat(expectedTypes, "\"."));
+          }
+        }
+      }
+    },
+    findShadowRoot: function findShadowRoot(element) {
+      if (!document.documentElement.attachShadow) {
+        return null;
+      } // Can find the shadow root otherwise it'll return the document
 
-        return prefix;
-      },
-      getSelectorFromElement: function getSelectorFromElement(element) {
-        var selector = element.getAttribute('data-target');
 
-        if (!selector || selector === '#') {
-          selector = element.getAttribute('href') || '';
-        } // If it's an ID
+      if (typeof element.getRootNode === 'function') {
+        var root = element.getRootNode();
+        return root instanceof ShadowRoot ? root : null;</