File indexing completed on 2024-11-16 09:01:58
0001
0002
0003
0004
0005
0006 (function (global, factory) {
0007 typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('jquery'), require('popper.js')) :
0008 typeof define === 'function' && define.amd ? define(['exports', 'jquery', 'popper.js'], factory) :
0009 (factory((global.bootstrap = {}),global.jQuery,global.Popper));
0010 }(this, (function (exports,$,Popper) { 'use strict';
0011
0012 $ = $ && $.hasOwnProperty('default') ? $['default'] : $;
0013 Popper = Popper && Popper.hasOwnProperty('default') ? Popper['default'] : Popper;
0014
0015 function _defineProperties(target, props) {
0016 for (var i = 0; i < props.length; i++) {
0017 var descriptor = props[i];
0018 descriptor.enumerable = descriptor.enumerable || false;
0019 descriptor.configurable = true;
0020 if ("value" in descriptor) descriptor.writable = true;
0021 Object.defineProperty(target, descriptor.key, descriptor);
0022 }
0023 }
0024
0025 function _createClass(Constructor, protoProps, staticProps) {
0026 if (protoProps) _defineProperties(Constructor.prototype, protoProps);
0027 if (staticProps) _defineProperties(Constructor, staticProps);
0028 return Constructor;
0029 }
0030
0031 function _extends() {
0032 _extends = Object.assign || function (target) {
0033 for (var i = 1; i < arguments.length; i++) {
0034 var source = arguments[i];
0035
0036 for (var key in source) {
0037 if (Object.prototype.hasOwnProperty.call(source, key)) {
0038 target[key] = source[key];
0039 }
0040 }
0041 }
0042
0043 return target;
0044 };
0045
0046 return _extends.apply(this, arguments);
0047 }
0048
0049 function _inheritsLoose(subClass, superClass) {
0050 subClass.prototype = Object.create(superClass.prototype);
0051 subClass.prototype.constructor = subClass;
0052 subClass.__proto__ = superClass;
0053 }
0054
0055
0056
0057
0058
0059
0060
0061
0062 var Util = function ($$$1) {
0063
0064
0065
0066
0067
0068 var transition = false;
0069 var MAX_UID = 1000000;
0070
0071 function toType(obj) {
0072 return {}.toString.call(obj).match(/\s([a-zA-Z]+)/)[1].toLowerCase();
0073 }
0074
0075 function getSpecialTransitionEndEvent() {
0076 return {
0077 bindType: transition.end,
0078 delegateType: transition.end,
0079 handle: function handle(event) {
0080 if ($$$1(event.target).is(this)) {
0081 return event.handleObj.handler.apply(this, arguments);
0082 }
0083
0084 return undefined;
0085 }
0086 };
0087 }
0088
0089 function transitionEndTest() {
0090 if (typeof window !== 'undefined' && window.QUnit) {
0091 return false;
0092 }
0093
0094 return {
0095 end: 'transitionend'
0096 };
0097 }
0098
0099 function transitionEndEmulator(duration) {
0100 var _this = this;
0101
0102 var called = false;
0103 $$$1(this).one(Util.TRANSITION_END, function () {
0104 called = true;
0105 });
0106 setTimeout(function () {
0107 if (!called) {
0108 Util.triggerTransitionEnd(_this);
0109 }
0110 }, duration);
0111 return this;
0112 }
0113
0114 function setTransitionEndSupport() {
0115 transition = transitionEndTest();
0116 $$$1.fn.emulateTransitionEnd = transitionEndEmulator;
0117
0118 if (Util.supportsTransitionEnd()) {
0119 $$$1.event.special[Util.TRANSITION_END] = getSpecialTransitionEndEvent();
0120 }
0121 }
0122
0123 function escapeId(selector) {
0124
0125
0126 selector = typeof $$$1.escapeSelector === 'function' ? $$$1.escapeSelector(selector).substr(1) : selector.replace(/(:|\.|\[|\]|,|=|@)/g, '\\$1');
0127 return selector;
0128 }
0129
0130
0131
0132
0133
0134
0135
0136 var Util = {
0137 TRANSITION_END: 'bsTransitionEnd',
0138 getUID: function getUID(prefix) {
0139 do {
0140
0141 prefix += ~~(Math.random() * MAX_UID);
0142 } while (document.getElementById(prefix));
0143
0144 return prefix;
0145 },
0146 getSelectorFromElement: function getSelectorFromElement(element) {
0147 var selector = element.getAttribute('data-target');
0148
0149 if (!selector || selector === '#') {
0150 selector = element.getAttribute('href') || '';
0151 }
0152
0153
0154 if (selector.charAt(0) === '#') {
0155 selector = escapeId(selector);
0156 }
0157
0158 try {
0159 var $selector = $$$1(document).find(selector);
0160 return $selector.length > 0 ? selector : null;
0161 } catch (err) {
0162 return null;
0163 }
0164 },
0165 reflow: function reflow(element) {
0166 return element.offsetHeight;
0167 },
0168 triggerTransitionEnd: function triggerTransitionEnd(element) {
0169 $$$1(element).trigger(transition.end);
0170 },
0171 supportsTransitionEnd: function supportsTransitionEnd() {
0172 return Boolean(transition);
0173 },
0174 isElement: function isElement(obj) {
0175 return (obj[0] || obj).nodeType;
0176 },
0177 typeCheckConfig: function typeCheckConfig(componentName, config, configTypes) {
0178 for (var property in configTypes) {
0179 if (Object.prototype.hasOwnProperty.call(configTypes, property)) {
0180 var expectedTypes = configTypes[property];
0181 var value = config[property];
0182 var valueType = value && Util.isElement(value) ? 'element' : toType(value);
0183
0184 if (!new RegExp(expectedTypes).test(valueType)) {
0185 throw new Error(componentName.toUpperCase() + ": " + ("Option \"" + property + "\" provided type \"" + valueType + "\" ") + ("but expected type \"" + expectedTypes + "\"."));
0186 }
0187 }
0188 }
0189 }
0190 };
0191 setTransitionEndSupport();
0192 return Util;
0193 }($);
0194
0195
0196
0197
0198
0199
0200
0201
0202 var Alert = function ($$$1) {
0203
0204
0205
0206
0207
0208 var NAME = 'alert';
0209 var VERSION = '4.0.0';
0210 var DATA_KEY = 'bs.alert';
0211 var EVENT_KEY = "." + DATA_KEY;
0212 var DATA_API_KEY = '.data-api';
0213 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
0214 var TRANSITION_DURATION = 150;
0215 var Selector = {
0216 DISMISS: '[data-dismiss="alert"]'
0217 };
0218 var Event = {
0219 CLOSE: "close" + EVENT_KEY,
0220 CLOSED: "closed" + EVENT_KEY,
0221 CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY
0222 };
0223 var ClassName = {
0224 ALERT: 'alert',
0225 FADE: 'fade',
0226 SHOW: 'show'
0227
0228
0229
0230
0231
0232
0233 };
0234
0235 var Alert =
0236
0237 function () {
0238 function Alert(element) {
0239 this._element = element;
0240 }
0241
0242
0243 var _proto = Alert.prototype;
0244
0245
0246 _proto.close = function close(element) {
0247 element = element || this._element;
0248
0249 var rootElement = this._getRootElement(element);
0250
0251 var customEvent = this._triggerCloseEvent(rootElement);
0252
0253 if (customEvent.isDefaultPrevented()) {
0254 return;
0255 }
0256
0257 this._removeElement(rootElement);
0258 };
0259
0260 _proto.dispose = function dispose() {
0261 $$$1.removeData(this._element, DATA_KEY);
0262 this._element = null;
0263 };
0264
0265
0266 _proto._getRootElement = function _getRootElement(element) {
0267 var selector = Util.getSelectorFromElement(element);
0268 var parent = false;
0269
0270 if (selector) {
0271 parent = $$$1(selector)[0];
0272 }
0273
0274 if (!parent) {
0275 parent = $$$1(element).closest("." + ClassName.ALERT)[0];
0276 }
0277
0278 return parent;
0279 };
0280
0281 _proto._triggerCloseEvent = function _triggerCloseEvent(element) {
0282 var closeEvent = $$$1.Event(Event.CLOSE);
0283 $$$1(element).trigger(closeEvent);
0284 return closeEvent;
0285 };
0286
0287 _proto._removeElement = function _removeElement(element) {
0288 var _this = this;
0289
0290 $$$1(element).removeClass(ClassName.SHOW);
0291
0292 if (!Util.supportsTransitionEnd() || !$$$1(element).hasClass(ClassName.FADE)) {
0293 this._destroyElement(element);
0294
0295 return;
0296 }
0297
0298 $$$1(element).one(Util.TRANSITION_END, function (event) {
0299 return _this._destroyElement(element, event);
0300 }).emulateTransitionEnd(TRANSITION_DURATION);
0301 };
0302
0303 _proto._destroyElement = function _destroyElement(element) {
0304 $$$1(element).detach().trigger(Event.CLOSED).remove();
0305 };
0306
0307
0308 Alert._jQueryInterface = function _jQueryInterface(config) {
0309 return this.each(function () {
0310 var $element = $$$1(this);
0311 var data = $element.data(DATA_KEY);
0312
0313 if (!data) {
0314 data = new Alert(this);
0315 $element.data(DATA_KEY, data);
0316 }
0317
0318 if (config === 'close') {
0319 data[config](this);
0320 }
0321 });
0322 };
0323
0324 Alert._handleDismiss = function _handleDismiss(alertInstance) {
0325 return function (event) {
0326 if (event) {
0327 event.preventDefault();
0328 }
0329
0330 alertInstance.close(this);
0331 };
0332 };
0333
0334 _createClass(Alert, null, [{
0335 key: "VERSION",
0336 get: function get() {
0337 return VERSION;
0338 }
0339 }]);
0340 return Alert;
0341 }();
0342
0343
0344
0345
0346
0347
0348
0349 $$$1(document).on(Event.CLICK_DATA_API, Selector.DISMISS, Alert._handleDismiss(new Alert()));
0350
0351
0352
0353
0354
0355
0356 $$$1.fn[NAME] = Alert._jQueryInterface;
0357 $$$1.fn[NAME].Constructor = Alert;
0358
0359 $$$1.fn[NAME].noConflict = function () {
0360 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
0361 return Alert._jQueryInterface;
0362 };
0363
0364 return Alert;
0365 }($);
0366
0367
0368
0369
0370
0371
0372
0373
0374 var Button = function ($$$1) {
0375
0376
0377
0378
0379
0380 var NAME = 'button';
0381 var VERSION = '4.0.0';
0382 var DATA_KEY = 'bs.button';
0383 var EVENT_KEY = "." + DATA_KEY;
0384 var DATA_API_KEY = '.data-api';
0385 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
0386 var ClassName = {
0387 ACTIVE: 'active',
0388 BUTTON: 'btn',
0389 FOCUS: 'focus'
0390 };
0391 var Selector = {
0392 DATA_TOGGLE_CARROT: '[data-toggle^="button"]',
0393 DATA_TOGGLE: '[data-toggle="buttons"]',
0394 INPUT: 'input',
0395 ACTIVE: '.active',
0396 BUTTON: '.btn'
0397 };
0398 var Event = {
0399 CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY,
0400 FOCUS_BLUR_DATA_API: "focus" + EVENT_KEY + DATA_API_KEY + " " + ("blur" + EVENT_KEY + DATA_API_KEY)
0401
0402
0403
0404
0405
0406
0407 };
0408
0409 var Button =
0410
0411 function () {
0412 function Button(element) {
0413 this._element = element;
0414 }
0415
0416
0417 var _proto = Button.prototype;
0418
0419
0420 _proto.toggle = function toggle() {
0421 var triggerChangeEvent = true;
0422 var addAriaPressed = true;
0423 var rootElement = $$$1(this._element).closest(Selector.DATA_TOGGLE)[0];
0424
0425 if (rootElement) {
0426 var input = $$$1(this._element).find(Selector.INPUT)[0];
0427
0428 if (input) {
0429 if (input.type === 'radio') {
0430 if (input.checked && $$$1(this._element).hasClass(ClassName.ACTIVE)) {
0431 triggerChangeEvent = false;
0432 } else {
0433 var activeElement = $$$1(rootElement).find(Selector.ACTIVE)[0];
0434
0435 if (activeElement) {
0436 $$$1(activeElement).removeClass(ClassName.ACTIVE);
0437 }
0438 }
0439 }
0440
0441 if (triggerChangeEvent) {
0442 if (input.hasAttribute('disabled') || rootElement.hasAttribute('disabled') || input.classList.contains('disabled') || rootElement.classList.contains('disabled')) {
0443 return;
0444 }
0445
0446 input.checked = !$$$1(this._element).hasClass(ClassName.ACTIVE);
0447 $$$1(input).trigger('change');
0448 }
0449
0450 input.focus();
0451 addAriaPressed = false;
0452 }
0453 }
0454
0455 if (addAriaPressed) {
0456 this._element.setAttribute('aria-pressed', !$$$1(this._element).hasClass(ClassName.ACTIVE));
0457 }
0458
0459 if (triggerChangeEvent) {
0460 $$$1(this._element).toggleClass(ClassName.ACTIVE);
0461 }
0462 };
0463
0464 _proto.dispose = function dispose() {
0465 $$$1.removeData(this._element, DATA_KEY);
0466 this._element = null;
0467 };
0468
0469
0470 Button._jQueryInterface = function _jQueryInterface(config) {
0471 return this.each(function () {
0472 var data = $$$1(this).data(DATA_KEY);
0473
0474 if (!data) {
0475 data = new Button(this);
0476 $$$1(this).data(DATA_KEY, data);
0477 }
0478
0479 if (config === 'toggle') {
0480 data[config]();
0481 }
0482 });
0483 };
0484
0485 _createClass(Button, null, [{
0486 key: "VERSION",
0487 get: function get() {
0488 return VERSION;
0489 }
0490 }]);
0491 return Button;
0492 }();
0493
0494
0495
0496
0497
0498
0499
0500 $$$1(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE_CARROT, function (event) {
0501 event.preventDefault();
0502 var button = event.target;
0503
0504 if (!$$$1(button).hasClass(ClassName.BUTTON)) {
0505 button = $$$1(button).closest(Selector.BUTTON);
0506 }
0507
0508 Button._jQueryInterface.call($$$1(button), 'toggle');
0509 }).on(Event.FOCUS_BLUR_DATA_API, Selector.DATA_TOGGLE_CARROT, function (event) {
0510 var button = $$$1(event.target).closest(Selector.BUTTON)[0];
0511 $$$1(button).toggleClass(ClassName.FOCUS, /^focus(in)?$/.test(event.type));
0512 });
0513
0514
0515
0516
0517
0518
0519 $$$1.fn[NAME] = Button._jQueryInterface;
0520 $$$1.fn[NAME].Constructor = Button;
0521
0522 $$$1.fn[NAME].noConflict = function () {
0523 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
0524 return Button._jQueryInterface;
0525 };
0526
0527 return Button;
0528 }($);
0529
0530
0531
0532
0533
0534
0535
0536
0537 var Carousel = function ($$$1) {
0538
0539
0540
0541
0542
0543 var NAME = 'carousel';
0544 var VERSION = '4.0.0';
0545 var DATA_KEY = 'bs.carousel';
0546 var EVENT_KEY = "." + DATA_KEY;
0547 var DATA_API_KEY = '.data-api';
0548 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
0549 var TRANSITION_DURATION = 600;
0550 var ARROW_LEFT_KEYCODE = 37;
0551
0552 var ARROW_RIGHT_KEYCODE = 39;
0553
0554 var TOUCHEVENT_COMPAT_WAIT = 500;
0555
0556 var Default = {
0557 interval: 5000,
0558 keyboard: true,
0559 slide: false,
0560 pause: 'hover',
0561 wrap: true
0562 };
0563 var DefaultType = {
0564 interval: '(number|boolean)',
0565 keyboard: 'boolean',
0566 slide: '(boolean|string)',
0567 pause: '(string|boolean)',
0568 wrap: 'boolean'
0569 };
0570 var Direction = {
0571 NEXT: 'next',
0572 PREV: 'prev',
0573 LEFT: 'left',
0574 RIGHT: 'right'
0575 };
0576 var Event = {
0577 SLIDE: "slide" + EVENT_KEY,
0578 SLID: "slid" + EVENT_KEY,
0579 KEYDOWN: "keydown" + EVENT_KEY,
0580 MOUSEENTER: "mouseenter" + EVENT_KEY,
0581 MOUSELEAVE: "mouseleave" + EVENT_KEY,
0582 TOUCHEND: "touchend" + EVENT_KEY,
0583 LOAD_DATA_API: "load" + EVENT_KEY + DATA_API_KEY,
0584 CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY
0585 };
0586 var ClassName = {
0587 CAROUSEL: 'carousel',
0588 ACTIVE: 'active',
0589 SLIDE: 'slide',
0590 RIGHT: 'carousel-item-right',
0591 LEFT: 'carousel-item-left',
0592 NEXT: 'carousel-item-next',
0593 PREV: 'carousel-item-prev',
0594 ITEM: 'carousel-item'
0595 };
0596 var Selector = {
0597 ACTIVE: '.active',
0598 ACTIVE_ITEM: '.active.carousel-item',
0599 ITEM: '.carousel-item',
0600 NEXT_PREV: '.carousel-item-next, .carousel-item-prev',
0601 INDICATORS: '.carousel-indicators',
0602 DATA_SLIDE: '[data-slide], [data-slide-to]',
0603 DATA_RIDE: '[data-ride="carousel"]'
0604
0605
0606
0607
0608
0609
0610 };
0611
0612 var Carousel =
0613
0614 function () {
0615 function Carousel(element, config) {
0616 this._items = null;
0617 this._interval = null;
0618 this._activeElement = null;
0619 this._isPaused = false;
0620 this._isSliding = false;
0621 this.touchTimeout = null;
0622 this._config = this._getConfig(config);
0623 this._element = $$$1(element)[0];
0624 this._indicatorsElement = $$$1(this._element).find(Selector.INDICATORS)[0];
0625
0626 this._addEventListeners();
0627 }
0628
0629
0630 var _proto = Carousel.prototype;
0631
0632
0633 _proto.next = function next() {
0634 if (!this._isSliding) {
0635 this._slide(Direction.NEXT);
0636 }
0637 };
0638
0639 _proto.nextWhenVisible = function nextWhenVisible() {
0640
0641
0642 if (!document.hidden && $$$1(this._element).is(':visible') && $$$1(this._element).css('visibility') !== 'hidden') {
0643 this.next();
0644 }
0645 };
0646
0647 _proto.prev = function prev() {
0648 if (!this._isSliding) {
0649 this._slide(Direction.PREV);
0650 }
0651 };
0652
0653 _proto.pause = function pause(event) {
0654 if (!event) {
0655 this._isPaused = true;
0656 }
0657
0658 if ($$$1(this._element).find(Selector.NEXT_PREV)[0] && Util.supportsTransitionEnd()) {
0659 Util.triggerTransitionEnd(this._element);
0660 this.cycle(true);
0661 }
0662
0663 clearInterval(this._interval);
0664 this._interval = null;
0665 };
0666
0667 _proto.cycle = function cycle(event) {
0668 if (!event) {
0669 this._isPaused = false;
0670 }
0671
0672 if (this._interval) {
0673 clearInterval(this._interval);
0674 this._interval = null;
0675 }
0676
0677 if (this._config.interval && !this._isPaused) {
0678 this._interval = setInterval((document.visibilityState ? this.nextWhenVisible : this.next).bind(this), this._config.interval);
0679 }
0680 };
0681
0682 _proto.to = function to(index) {
0683 var _this = this;
0684
0685 this._activeElement = $$$1(this._element).find(Selector.ACTIVE_ITEM)[0];
0686
0687 var activeIndex = this._getItemIndex(this._activeElement);
0688
0689 if (index > this._items.length - 1 || index < 0) {
0690 return;
0691 }
0692
0693 if (this._isSliding) {
0694 $$$1(this._element).one(Event.SLID, function () {
0695 return _this.to(index);
0696 });
0697 return;
0698 }
0699
0700 if (activeIndex === index) {
0701 this.pause();
0702 this.cycle();
0703 return;
0704 }
0705
0706 var direction = index > activeIndex ? Direction.NEXT : Direction.PREV;
0707
0708 this._slide(direction, this._items[index]);
0709 };
0710
0711 _proto.dispose = function dispose() {
0712 $$$1(this._element).off(EVENT_KEY);
0713 $$$1.removeData(this._element, DATA_KEY);
0714 this._items = null;
0715 this._config = null;
0716 this._element = null;
0717 this._interval = null;
0718 this._isPaused = null;
0719 this._isSliding = null;
0720 this._activeElement = null;
0721 this._indicatorsElement = null;
0722 };
0723
0724
0725 _proto._getConfig = function _getConfig(config) {
0726 config = _extends({}, Default, config);
0727 Util.typeCheckConfig(NAME, config, DefaultType);
0728 return config;
0729 };
0730
0731 _proto._addEventListeners = function _addEventListeners() {
0732 var _this2 = this;
0733
0734 if (this._config.keyboard) {
0735 $$$1(this._element).on(Event.KEYDOWN, function (event) {
0736 return _this2._keydown(event);
0737 });
0738 }
0739
0740 if (this._config.pause === 'hover') {
0741 $$$1(this._element).on(Event.MOUSEENTER, function (event) {
0742 return _this2.pause(event);
0743 }).on(Event.MOUSELEAVE, function (event) {
0744 return _this2.cycle(event);
0745 });
0746
0747 if ('ontouchstart' in document.documentElement) {
0748
0749
0750
0751
0752
0753
0754
0755 $$$1(this._element).on(Event.TOUCHEND, function () {
0756 _this2.pause();
0757
0758 if (_this2.touchTimeout) {
0759 clearTimeout(_this2.touchTimeout);
0760 }
0761
0762 _this2.touchTimeout = setTimeout(function (event) {
0763 return _this2.cycle(event);
0764 }, TOUCHEVENT_COMPAT_WAIT + _this2._config.interval);
0765 });
0766 }
0767 }
0768 };
0769
0770 _proto._keydown = function _keydown(event) {
0771 if (/input|textarea/i.test(event.target.tagName)) {
0772 return;
0773 }
0774
0775 switch (event.which) {
0776 case ARROW_LEFT_KEYCODE:
0777 event.preventDefault();
0778 this.prev();
0779 break;
0780
0781 case ARROW_RIGHT_KEYCODE:
0782 event.preventDefault();
0783 this.next();
0784 break;
0785
0786 default:
0787 }
0788 };
0789
0790 _proto._getItemIndex = function _getItemIndex(element) {
0791 this._items = $$$1.makeArray($$$1(element).parent().find(Selector.ITEM));
0792 return this._items.indexOf(element);
0793 };
0794
0795 _proto._getItemByDirection = function _getItemByDirection(direction, activeElement) {
0796 var isNextDirection = direction === Direction.NEXT;
0797 var isPrevDirection = direction === Direction.PREV;
0798
0799 var activeIndex = this._getItemIndex(activeElement);
0800
0801 var lastItemIndex = this._items.length - 1;
0802 var isGoingToWrap = isPrevDirection && activeIndex === 0 || isNextDirection && activeIndex === lastItemIndex;
0803
0804 if (isGoingToWrap && !this._config.wrap) {
0805 return activeElement;
0806 }
0807
0808 var delta = direction === Direction.PREV ? -1 : 1;
0809 var itemIndex = (activeIndex + delta) % this._items.length;
0810 return itemIndex === -1 ? this._items[this._items.length - 1] : this._items[itemIndex];
0811 };
0812
0813 _proto._triggerSlideEvent = function _triggerSlideEvent(relatedTarget, eventDirectionName) {
0814 var targetIndex = this._getItemIndex(relatedTarget);
0815
0816 var fromIndex = this._getItemIndex($$$1(this._element).find(Selector.ACTIVE_ITEM)[0]);
0817
0818 var slideEvent = $$$1.Event(Event.SLIDE, {
0819 relatedTarget: relatedTarget,
0820 direction: eventDirectionName,
0821 from: fromIndex,
0822 to: targetIndex
0823 });
0824 $$$1(this._element).trigger(slideEvent);
0825 return slideEvent;
0826 };
0827
0828 _proto._setActiveIndicatorElement = function _setActiveIndicatorElement(element) {
0829 if (this._indicatorsElement) {
0830 $$$1(this._indicatorsElement).find(Selector.ACTIVE).removeClass(ClassName.ACTIVE);
0831
0832 var nextIndicator = this._indicatorsElement.children[this._getItemIndex(element)];
0833
0834 if (nextIndicator) {
0835 $$$1(nextIndicator).addClass(ClassName.ACTIVE);
0836 }
0837 }
0838 };
0839
0840 _proto._slide = function _slide(direction, element) {
0841 var _this3 = this;
0842
0843 var activeElement = $$$1(this._element).find(Selector.ACTIVE_ITEM)[0];
0844
0845 var activeElementIndex = this._getItemIndex(activeElement);
0846
0847 var nextElement = element || activeElement && this._getItemByDirection(direction, activeElement);
0848
0849 var nextElementIndex = this._getItemIndex(nextElement);
0850
0851 var isCycling = Boolean(this._interval);
0852 var directionalClassName;
0853 var orderClassName;
0854 var eventDirectionName;
0855
0856 if (direction === Direction.NEXT) {
0857 directionalClassName = ClassName.LEFT;
0858 orderClassName = ClassName.NEXT;
0859 eventDirectionName = Direction.LEFT;
0860 } else {
0861 directionalClassName = ClassName.RIGHT;
0862 orderClassName = ClassName.PREV;
0863 eventDirectionName = Direction.RIGHT;
0864 }
0865
0866 if (nextElement && $$$1(nextElement).hasClass(ClassName.ACTIVE)) {
0867 this._isSliding = false;
0868 return;
0869 }
0870
0871 var slideEvent = this._triggerSlideEvent(nextElement, eventDirectionName);
0872
0873 if (slideEvent.isDefaultPrevented()) {
0874 return;
0875 }
0876
0877 if (!activeElement || !nextElement) {
0878
0879 return;
0880 }
0881
0882 this._isSliding = true;
0883
0884 if (isCycling) {
0885 this.pause();
0886 }
0887
0888 this._setActiveIndicatorElement(nextElement);
0889
0890 var slidEvent = $$$1.Event(Event.SLID, {
0891 relatedTarget: nextElement,
0892 direction: eventDirectionName,
0893 from: activeElementIndex,
0894 to: nextElementIndex
0895 });
0896
0897 if (Util.supportsTransitionEnd() && $$$1(this._element).hasClass(ClassName.SLIDE)) {
0898 $$$1(nextElement).addClass(orderClassName);
0899 Util.reflow(nextElement);
0900 $$$1(activeElement).addClass(directionalClassName);
0901 $$$1(nextElement).addClass(directionalClassName);
0902 $$$1(activeElement).one(Util.TRANSITION_END, function () {
0903 $$$1(nextElement).removeClass(directionalClassName + " " + orderClassName).addClass(ClassName.ACTIVE);
0904 $$$1(activeElement).removeClass(ClassName.ACTIVE + " " + orderClassName + " " + directionalClassName);
0905 _this3._isSliding = false;
0906 setTimeout(function () {
0907 return $$$1(_this3._element).trigger(slidEvent);
0908 }, 0);
0909 }).emulateTransitionEnd(TRANSITION_DURATION);
0910 } else {
0911 $$$1(activeElement).removeClass(ClassName.ACTIVE);
0912 $$$1(nextElement).addClass(ClassName.ACTIVE);
0913 this._isSliding = false;
0914 $$$1(this._element).trigger(slidEvent);
0915 }
0916
0917 if (isCycling) {
0918 this.cycle();
0919 }
0920 };
0921
0922
0923 Carousel._jQueryInterface = function _jQueryInterface(config) {
0924 return this.each(function () {
0925 var data = $$$1(this).data(DATA_KEY);
0926
0927 var _config = _extends({}, Default, $$$1(this).data());
0928
0929 if (typeof config === 'object') {
0930 _config = _extends({}, _config, config);
0931 }
0932
0933 var action = typeof config === 'string' ? config : _config.slide;
0934
0935 if (!data) {
0936 data = new Carousel(this, _config);
0937 $$$1(this).data(DATA_KEY, data);
0938 }
0939
0940 if (typeof config === 'number') {
0941 data.to(config);
0942 } else if (typeof action === 'string') {
0943 if (typeof data[action] === 'undefined') {
0944 throw new TypeError("No method named \"" + action + "\"");
0945 }
0946
0947 data[action]();
0948 } else if (_config.interval) {
0949 data.pause();
0950 data.cycle();
0951 }
0952 });
0953 };
0954
0955 Carousel._dataApiClickHandler = function _dataApiClickHandler(event) {
0956 var selector = Util.getSelectorFromElement(this);
0957
0958 if (!selector) {
0959 return;
0960 }
0961
0962 var target = $$$1(selector)[0];
0963
0964 if (!target || !$$$1(target).hasClass(ClassName.CAROUSEL)) {
0965 return;
0966 }
0967
0968 var config = _extends({}, $$$1(target).data(), $$$1(this).data());
0969 var slideIndex = this.getAttribute('data-slide-to');
0970
0971 if (slideIndex) {
0972 config.interval = false;
0973 }
0974
0975 Carousel._jQueryInterface.call($$$1(target), config);
0976
0977 if (slideIndex) {
0978 $$$1(target).data(DATA_KEY).to(slideIndex);
0979 }
0980
0981 event.preventDefault();
0982 };
0983
0984 _createClass(Carousel, null, [{
0985 key: "VERSION",
0986 get: function get() {
0987 return VERSION;
0988 }
0989 }, {
0990 key: "Default",
0991 get: function get() {
0992 return Default;
0993 }
0994 }]);
0995 return Carousel;
0996 }();
0997
0998
0999
1000
1001
1002
1003
1004 $$$1(document).on(Event.CLICK_DATA_API, Selector.DATA_SLIDE, Carousel._dataApiClickHandler);
1005 $$$1(window).on(Event.LOAD_DATA_API, function () {
1006 $$$1(Selector.DATA_RIDE).each(function () {
1007 var $carousel = $$$1(this);
1008
1009 Carousel._jQueryInterface.call($carousel, $carousel.data());
1010 });
1011 });
1012
1013
1014
1015
1016
1017
1018 $$$1.fn[NAME] = Carousel._jQueryInterface;
1019 $$$1.fn[NAME].Constructor = Carousel;
1020
1021 $$$1.fn[NAME].noConflict = function () {
1022 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
1023 return Carousel._jQueryInterface;
1024 };
1025
1026 return Carousel;
1027 }($);
1028
1029
1030
1031
1032
1033
1034
1035
1036 var Collapse = function ($$$1) {
1037
1038
1039
1040
1041
1042 var NAME = 'collapse';
1043 var VERSION = '4.0.0';
1044 var DATA_KEY = 'bs.collapse';
1045 var EVENT_KEY = "." + DATA_KEY;
1046 var DATA_API_KEY = '.data-api';
1047 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
1048 var TRANSITION_DURATION = 600;
1049 var Default = {
1050 toggle: true,
1051 parent: ''
1052 };
1053 var DefaultType = {
1054 toggle: 'boolean',
1055 parent: '(string|element)'
1056 };
1057 var Event = {
1058 SHOW: "show" + EVENT_KEY,
1059 SHOWN: "shown" + EVENT_KEY,
1060 HIDE: "hide" + EVENT_KEY,
1061 HIDDEN: "hidden" + EVENT_KEY,
1062 CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY
1063 };
1064 var ClassName = {
1065 SHOW: 'show',
1066 COLLAPSE: 'collapse',
1067 COLLAPSING: 'collapsing',
1068 COLLAPSED: 'collapsed'
1069 };
1070 var Dimension = {
1071 WIDTH: 'width',
1072 HEIGHT: 'height'
1073 };
1074 var Selector = {
1075 ACTIVES: '.show, .collapsing',
1076 DATA_TOGGLE: '[data-toggle="collapse"]'
1077
1078
1079
1080
1081
1082
1083 };
1084
1085 var Collapse =
1086
1087 function () {
1088 function Collapse(element, config) {
1089 this._isTransitioning = false;
1090 this._element = element;
1091 this._config = this._getConfig(config);
1092 this._triggerArray = $$$1.makeArray($$$1("[data-toggle=\"collapse\"][href=\"#" + element.id + "\"]," + ("[data-toggle=\"collapse\"][data-target=\"#" + element.id + "\"]")));
1093 var tabToggles = $$$1(Selector.DATA_TOGGLE);
1094
1095 for (var i = 0; i < tabToggles.length; i++) {
1096 var elem = tabToggles[i];
1097 var selector = Util.getSelectorFromElement(elem);
1098
1099 if (selector !== null && $$$1(selector).filter(element).length > 0) {
1100 this._selector = selector;
1101
1102 this._triggerArray.push(elem);
1103 }
1104 }
1105
1106 this._parent = this._config.parent ? this._getParent() : null;
1107
1108 if (!this._config.parent) {
1109 this._addAriaAndCollapsedClass(this._element, this._triggerArray);
1110 }
1111
1112 if (this._config.toggle) {
1113 this.toggle();
1114 }
1115 }
1116
1117
1118 var _proto = Collapse.prototype;
1119
1120
1121 _proto.toggle = function toggle() {
1122 if ($$$1(this._element).hasClass(ClassName.SHOW)) {
1123 this.hide();
1124 } else {
1125 this.show();
1126 }
1127 };
1128
1129 _proto.show = function show() {
1130 var _this = this;
1131
1132 if (this._isTransitioning || $$$1(this._element).hasClass(ClassName.SHOW)) {
1133 return;
1134 }
1135
1136 var actives;
1137 var activesData;
1138
1139 if (this._parent) {
1140 actives = $$$1.makeArray($$$1(this._parent).find(Selector.ACTIVES).filter("[data-parent=\"" + this._config.parent + "\"]"));
1141
1142 if (actives.length === 0) {
1143 actives = null;
1144 }
1145 }
1146
1147 if (actives) {
1148 activesData = $$$1(actives).not(this._selector).data(DATA_KEY);
1149
1150 if (activesData && activesData._isTransitioning) {
1151 return;
1152 }
1153 }
1154
1155 var startEvent = $$$1.Event(Event.SHOW);
1156 $$$1(this._element).trigger(startEvent);
1157
1158 if (startEvent.isDefaultPrevented()) {
1159 return;
1160 }
1161
1162 if (actives) {
1163 Collapse._jQueryInterface.call($$$1(actives).not(this._selector), 'hide');
1164
1165 if (!activesData) {
1166 $$$1(actives).data(DATA_KEY, null);
1167 }
1168 }
1169
1170 var dimension = this._getDimension();
1171
1172 $$$1(this._element).removeClass(ClassName.COLLAPSE).addClass(ClassName.COLLAPSING);
1173 this._element.style[dimension] = 0;
1174
1175 if (this._triggerArray.length > 0) {
1176 $$$1(this._triggerArray).removeClass(ClassName.COLLAPSED).attr('aria-expanded', true);
1177 }
1178
1179 this.setTransitioning(true);
1180
1181 var complete = function complete() {
1182 $$$1(_this._element).removeClass(ClassName.COLLAPSING).addClass(ClassName.COLLAPSE).addClass(ClassName.SHOW);
1183 _this._element.style[dimension] = '';
1184
1185 _this.setTransitioning(false);
1186
1187 $$$1(_this._element).trigger(Event.SHOWN);
1188 };
1189
1190 if (!Util.supportsTransitionEnd()) {
1191 complete();
1192 return;
1193 }
1194
1195 var capitalizedDimension = dimension[0].toUpperCase() + dimension.slice(1);
1196 var scrollSize = "scroll" + capitalizedDimension;
1197 $$$1(this._element).one(Util.TRANSITION_END, complete).emulateTransitionEnd(TRANSITION_DURATION);
1198 this._element.style[dimension] = this._element[scrollSize] + "px";
1199 };
1200
1201 _proto.hide = function hide() {
1202 var _this2 = this;
1203
1204 if (this._isTransitioning || !$$$1(this._element).hasClass(ClassName.SHOW)) {
1205 return;
1206 }
1207
1208 var startEvent = $$$1.Event(Event.HIDE);
1209 $$$1(this._element).trigger(startEvent);
1210
1211 if (startEvent.isDefaultPrevented()) {
1212 return;
1213 }
1214
1215 var dimension = this._getDimension();
1216
1217 this._element.style[dimension] = this._element.getBoundingClientRect()[dimension] + "px";
1218 Util.reflow(this._element);
1219 $$$1(this._element).addClass(ClassName.COLLAPSING).removeClass(ClassName.COLLAPSE).removeClass(ClassName.SHOW);
1220
1221 if (this._triggerArray.length > 0) {
1222 for (var i = 0; i < this._triggerArray.length; i++) {
1223 var trigger = this._triggerArray[i];
1224 var selector = Util.getSelectorFromElement(trigger);
1225
1226 if (selector !== null) {
1227 var $elem = $$$1(selector);
1228
1229 if (!$elem.hasClass(ClassName.SHOW)) {
1230 $$$1(trigger).addClass(ClassName.COLLAPSED).attr('aria-expanded', false);
1231 }
1232 }
1233 }
1234 }
1235
1236 this.setTransitioning(true);
1237
1238 var complete = function complete() {
1239 _this2.setTransitioning(false);
1240
1241 $$$1(_this2._element).removeClass(ClassName.COLLAPSING).addClass(ClassName.COLLAPSE).trigger(Event.HIDDEN);
1242 };
1243
1244 this._element.style[dimension] = '';
1245
1246 if (!Util.supportsTransitionEnd()) {
1247 complete();
1248 return;
1249 }
1250
1251 $$$1(this._element).one(Util.TRANSITION_END, complete).emulateTransitionEnd(TRANSITION_DURATION);
1252 };
1253
1254 _proto.setTransitioning = function setTransitioning(isTransitioning) {
1255 this._isTransitioning = isTransitioning;
1256 };
1257
1258 _proto.dispose = function dispose() {
1259 $$$1.removeData(this._element, DATA_KEY);
1260 this._config = null;
1261 this._parent = null;
1262 this._element = null;
1263 this._triggerArray = null;
1264 this._isTransitioning = null;
1265 };
1266
1267
1268 _proto._getConfig = function _getConfig(config) {
1269 config = _extends({}, Default, config);
1270 config.toggle = Boolean(config.toggle);
1271
1272 Util.typeCheckConfig(NAME, config, DefaultType);
1273 return config;
1274 };
1275
1276 _proto._getDimension = function _getDimension() {
1277 var hasWidth = $$$1(this._element).hasClass(Dimension.WIDTH);
1278 return hasWidth ? Dimension.WIDTH : Dimension.HEIGHT;
1279 };
1280
1281 _proto._getParent = function _getParent() {
1282 var _this3 = this;
1283
1284 var parent = null;
1285
1286 if (Util.isElement(this._config.parent)) {
1287 parent = this._config.parent;
1288
1289 if (typeof this._config.parent.jquery !== 'undefined') {
1290 parent = this._config.parent[0];
1291 }
1292 } else {
1293 parent = $$$1(this._config.parent)[0];
1294 }
1295
1296 var selector = "[data-toggle=\"collapse\"][data-parent=\"" + this._config.parent + "\"]";
1297 $$$1(parent).find(selector).each(function (i, element) {
1298 _this3._addAriaAndCollapsedClass(Collapse._getTargetFromElement(element), [element]);
1299 });
1300 return parent;
1301 };
1302
1303 _proto._addAriaAndCollapsedClass = function _addAriaAndCollapsedClass(element, triggerArray) {
1304 if (element) {
1305 var isOpen = $$$1(element).hasClass(ClassName.SHOW);
1306
1307 if (triggerArray.length > 0) {
1308 $$$1(triggerArray).toggleClass(ClassName.COLLAPSED, !isOpen).attr('aria-expanded', isOpen);
1309 }
1310 }
1311 };
1312
1313
1314 Collapse._getTargetFromElement = function _getTargetFromElement(element) {
1315 var selector = Util.getSelectorFromElement(element);
1316 return selector ? $$$1(selector)[0] : null;
1317 };
1318
1319 Collapse._jQueryInterface = function _jQueryInterface(config) {
1320 return this.each(function () {
1321 var $this = $$$1(this);
1322 var data = $this.data(DATA_KEY);
1323
1324 var _config = _extends({}, Default, $this.data(), typeof config === 'object' && config);
1325
1326 if (!data && _config.toggle && /show|hide/.test(config)) {
1327 _config.toggle = false;
1328 }
1329
1330 if (!data) {
1331 data = new Collapse(this, _config);
1332 $this.data(DATA_KEY, data);
1333 }
1334
1335 if (typeof config === 'string') {
1336 if (typeof data[config] === 'undefined') {
1337 throw new TypeError("No method named \"" + config + "\"");
1338 }
1339
1340 data[config]();
1341 }
1342 });
1343 };
1344
1345 _createClass(Collapse, null, [{
1346 key: "VERSION",
1347 get: function get() {
1348 return VERSION;
1349 }
1350 }, {
1351 key: "Default",
1352 get: function get() {
1353 return Default;
1354 }
1355 }]);
1356 return Collapse;
1357 }();
1358
1359
1360
1361
1362
1363
1364
1365 $$$1(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
1366
1367 if (event.currentTarget.tagName === 'A') {
1368 event.preventDefault();
1369 }
1370
1371 var $trigger = $$$1(this);
1372 var selector = Util.getSelectorFromElement(this);
1373 $$$1(selector).each(function () {
1374 var $target = $$$1(this);
1375 var data = $target.data(DATA_KEY);
1376 var config = data ? 'toggle' : $trigger.data();
1377
1378 Collapse._jQueryInterface.call($target, config);
1379 });
1380 });
1381
1382
1383
1384
1385
1386
1387 $$$1.fn[NAME] = Collapse._jQueryInterface;
1388 $$$1.fn[NAME].Constructor = Collapse;
1389
1390 $$$1.fn[NAME].noConflict = function () {
1391 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
1392 return Collapse._jQueryInterface;
1393 };
1394
1395 return Collapse;
1396 }($);
1397
1398
1399
1400
1401
1402
1403
1404
1405 var Dropdown = function ($$$1) {
1406
1407
1408
1409
1410
1411 var NAME = 'dropdown';
1412 var VERSION = '4.0.0';
1413 var DATA_KEY = 'bs.dropdown';
1414 var EVENT_KEY = "." + DATA_KEY;
1415 var DATA_API_KEY = '.data-api';
1416 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
1417 var ESCAPE_KEYCODE = 27;
1418
1419 var SPACE_KEYCODE = 32;
1420
1421 var TAB_KEYCODE = 9;
1422
1423 var ARROW_UP_KEYCODE = 38;
1424
1425 var ARROW_DOWN_KEYCODE = 40;
1426
1427 var RIGHT_MOUSE_BUTTON_WHICH = 3;
1428
1429 var REGEXP_KEYDOWN = new RegExp(ARROW_UP_KEYCODE + "|" + ARROW_DOWN_KEYCODE + "|" + ESCAPE_KEYCODE);
1430 var Event = {
1431 HIDE: "hide" + EVENT_KEY,
1432 HIDDEN: "hidden" + EVENT_KEY,
1433 SHOW: "show" + EVENT_KEY,
1434 SHOWN: "shown" + EVENT_KEY,
1435 CLICK: "click" + EVENT_KEY,
1436 CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY,
1437 KEYDOWN_DATA_API: "keydown" + EVENT_KEY + DATA_API_KEY,
1438 KEYUP_DATA_API: "keyup" + EVENT_KEY + DATA_API_KEY
1439 };
1440 var ClassName = {
1441 DISABLED: 'disabled',
1442 SHOW: 'show',
1443 DROPUP: 'dropup',
1444 DROPRIGHT: 'dropright',
1445 DROPLEFT: 'dropleft',
1446 MENURIGHT: 'dropdown-menu-right',
1447 MENULEFT: 'dropdown-menu-left',
1448 POSITION_STATIC: 'position-static'
1449 };
1450 var Selector = {
1451 DATA_TOGGLE: '[data-toggle="dropdown"]',
1452 FORM_CHILD: '.dropdown form',
1453 MENU: '.dropdown-menu',
1454 NAVBAR_NAV: '.navbar-nav',
1455 VISIBLE_ITEMS: '.dropdown-menu .dropdown-item:not(.disabled)'
1456 };
1457 var AttachmentMap = {
1458 TOP: 'top-start',
1459 TOPEND: 'top-end',
1460 BOTTOM: 'bottom-start',
1461 BOTTOMEND: 'bottom-end',
1462 RIGHT: 'right-start',
1463 RIGHTEND: 'right-end',
1464 LEFT: 'left-start',
1465 LEFTEND: 'left-end'
1466 };
1467 var Default = {
1468 offset: 0,
1469 flip: true,
1470 boundary: 'scrollParent'
1471 };
1472 var DefaultType = {
1473 offset: '(number|string|function)',
1474 flip: 'boolean',
1475 boundary: '(string|element)'
1476
1477
1478
1479
1480
1481
1482 };
1483
1484 var Dropdown =
1485
1486 function () {
1487 function Dropdown(element, config) {
1488 this._element = element;
1489 this._popper = null;
1490 this._config = this._getConfig(config);
1491 this._menu = this._getMenuElement();
1492 this._inNavbar = this._detectNavbar();
1493
1494 this._addEventListeners();
1495 }
1496
1497
1498 var _proto = Dropdown.prototype;
1499
1500
1501 _proto.toggle = function toggle() {
1502 if (this._element.disabled || $$$1(this._element).hasClass(ClassName.DISABLED)) {
1503 return;
1504 }
1505
1506 var parent = Dropdown._getParentFromElement(this._element);
1507
1508 var isActive = $$$1(this._menu).hasClass(ClassName.SHOW);
1509
1510 Dropdown._clearMenus();
1511
1512 if (isActive) {
1513 return;
1514 }
1515
1516 var relatedTarget = {
1517 relatedTarget: this._element
1518 };
1519 var showEvent = $$$1.Event(Event.SHOW, relatedTarget);
1520 $$$1(parent).trigger(showEvent);
1521
1522 if (showEvent.isDefaultPrevented()) {
1523 return;
1524 }
1525
1526
1527 if (!this._inNavbar) {
1528
1529
1530
1531
1532 if (typeof Popper === 'undefined') {
1533 throw new TypeError('Bootstrap dropdown require Popper.js (https://popper.js.org)');
1534 }
1535
1536 var element = this._element;
1537
1538 if ($$$1(parent).hasClass(ClassName.DROPUP)) {
1539 if ($$$1(this._menu).hasClass(ClassName.MENULEFT) || $$$1(this._menu).hasClass(ClassName.MENURIGHT)) {
1540 element = parent;
1541 }
1542 }
1543
1544
1545
1546
1547 if (this._config.boundary !== 'scrollParent') {
1548 $$$1(parent).addClass(ClassName.POSITION_STATIC);
1549 }
1550
1551 this._popper = new Popper(element, this._menu, this._getPopperConfig());
1552 }
1553
1554
1555
1556
1557
1558 if ('ontouchstart' in document.documentElement && $$$1(parent).closest(Selector.NAVBAR_NAV).length === 0) {
1559 $$$1('body').children().on('mouseover', null, $$$1.noop);
1560 }
1561
1562 this._element.focus();
1563
1564 this._element.setAttribute('aria-expanded', true);
1565
1566 $$$1(this._menu).toggleClass(ClassName.SHOW);
1567 $$$1(parent).toggleClass(ClassName.SHOW).trigger($$$1.Event(Event.SHOWN, relatedTarget));
1568 };
1569
1570 _proto.dispose = function dispose() {
1571 $$$1.removeData(this._element, DATA_KEY);
1572 $$$1(this._element).off(EVENT_KEY);
1573 this._element = null;
1574 this._menu = null;
1575
1576 if (this._popper !== null) {
1577 this._popper.destroy();
1578
1579 this._popper = null;
1580 }
1581 };
1582
1583 _proto.update = function update() {
1584 this._inNavbar = this._detectNavbar();
1585
1586 if (this._popper !== null) {
1587 this._popper.scheduleUpdate();
1588 }
1589 };
1590
1591
1592 _proto._addEventListeners = function _addEventListeners() {
1593 var _this = this;
1594
1595 $$$1(this._element).on(Event.CLICK, function (event) {
1596 event.preventDefault();
1597 event.stopPropagation();
1598
1599 _this.toggle();
1600 });
1601 };
1602
1603 _proto._getConfig = function _getConfig(config) {
1604 config = _extends({}, this.constructor.Default, $$$1(this._element).data(), config);
1605 Util.typeCheckConfig(NAME, config, this.constructor.DefaultType);
1606 return config;
1607 };
1608
1609 _proto._getMenuElement = function _getMenuElement() {
1610 if (!this._menu) {
1611 var parent = Dropdown._getParentFromElement(this._element);
1612
1613 this._menu = $$$1(parent).find(Selector.MENU)[0];
1614 }
1615
1616 return this._menu;
1617 };
1618
1619 _proto._getPlacement = function _getPlacement() {
1620 var $parentDropdown = $$$1(this._element).parent();
1621 var placement = AttachmentMap.BOTTOM;
1622
1623 if ($parentDropdown.hasClass(ClassName.DROPUP)) {
1624 placement = AttachmentMap.TOP;
1625
1626 if ($$$1(this._menu).hasClass(ClassName.MENURIGHT)) {
1627 placement = AttachmentMap.TOPEND;
1628 }
1629 } else if ($parentDropdown.hasClass(ClassName.DROPRIGHT)) {
1630 placement = AttachmentMap.RIGHT;
1631 } else if ($parentDropdown.hasClass(ClassName.DROPLEFT)) {
1632 placement = AttachmentMap.LEFT;
1633 } else if ($$$1(this._menu).hasClass(ClassName.MENURIGHT)) {
1634 placement = AttachmentMap.BOTTOMEND;
1635 }
1636
1637 return placement;
1638 };
1639
1640 _proto._detectNavbar = function _detectNavbar() {
1641 return $$$1(this._element).closest('.navbar').length > 0;
1642 };
1643
1644 _proto._getPopperConfig = function _getPopperConfig() {
1645 var _this2 = this;
1646
1647 var offsetConf = {};
1648
1649 if (typeof this._config.offset === 'function') {
1650 offsetConf.fn = function (data) {
1651 data.offsets = _extends({}, data.offsets, _this2._config.offset(data.offsets) || {});
1652 return data;
1653 };
1654 } else {
1655 offsetConf.offset = this._config.offset;
1656 }
1657
1658 var popperConfig = {
1659 placement: this._getPlacement(),
1660 modifiers: {
1661 offset: offsetConf,
1662 flip: {
1663 enabled: this._config.flip
1664 },
1665 preventOverflow: {
1666 boundariesElement: this._config.boundary
1667 }
1668 }
1669 };
1670 return popperConfig;
1671 };
1672
1673
1674 Dropdown._jQueryInterface = function _jQueryInterface(config) {
1675 return this.each(function () {
1676 var data = $$$1(this).data(DATA_KEY);
1677
1678 var _config = typeof config === 'object' ? config : null;
1679
1680 if (!data) {
1681 data = new Dropdown(this, _config);
1682 $$$1(this).data(DATA_KEY, data);
1683 }
1684
1685 if (typeof config === 'string') {
1686 if (typeof data[config] === 'undefined') {
1687 throw new TypeError("No method named \"" + config + "\"");
1688 }
1689
1690 data[config]();
1691 }
1692 });
1693 };
1694
1695 Dropdown._clearMenus = function _clearMenus(event) {
1696 if (event && (event.which === RIGHT_MOUSE_BUTTON_WHICH || event.type === 'keyup' && event.which !== TAB_KEYCODE)) {
1697 return;
1698 }
1699
1700 var toggles = $$$1.makeArray($$$1(Selector.DATA_TOGGLE));
1701
1702 for (var i = 0; i < toggles.length; i++) {
1703 var parent = Dropdown._getParentFromElement(toggles[i]);
1704
1705 var context = $$$1(toggles[i]).data(DATA_KEY);
1706 var relatedTarget = {
1707 relatedTarget: toggles[i]
1708 };
1709
1710 if (!context) {
1711 continue;
1712 }
1713
1714 var dropdownMenu = context._menu;
1715
1716 if (!$$$1(parent).hasClass(ClassName.SHOW)) {
1717 continue;
1718 }
1719
1720 if (event && (event.type === 'click' && /input|textarea/i.test(event.target.tagName) || event.type === 'keyup' && event.which === TAB_KEYCODE) && $$$1.contains(parent, event.target)) {
1721 continue;
1722 }
1723
1724 var hideEvent = $$$1.Event(Event.HIDE, relatedTarget);
1725 $$$1(parent).trigger(hideEvent);
1726
1727 if (hideEvent.isDefaultPrevented()) {
1728 continue;
1729 }
1730
1731
1732
1733 if ('ontouchstart' in document.documentElement) {
1734 $$$1('body').children().off('mouseover', null, $$$1.noop);
1735 }
1736
1737 toggles[i].setAttribute('aria-expanded', 'false');
1738 $$$1(dropdownMenu).removeClass(ClassName.SHOW);
1739 $$$1(parent).removeClass(ClassName.SHOW).trigger($$$1.Event(Event.HIDDEN, relatedTarget));
1740 }
1741 };
1742
1743 Dropdown._getParentFromElement = function _getParentFromElement(element) {
1744 var parent;
1745 var selector = Util.getSelectorFromElement(element);
1746
1747 if (selector) {
1748 parent = $$$1(selector)[0];
1749 }
1750
1751 return parent || element.parentNode;
1752 };
1753
1754
1755 Dropdown._dataApiKeydownHandler = function _dataApiKeydownHandler(event) {
1756
1757
1758
1759
1760
1761
1762
1763 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 || $$$1(event.target).closest(Selector.MENU).length) : !REGEXP_KEYDOWN.test(event.which)) {
1764 return;
1765 }
1766
1767 event.preventDefault();
1768 event.stopPropagation();
1769
1770 if (this.disabled || $$$1(this).hasClass(ClassName.DISABLED)) {
1771 return;
1772 }
1773
1774 var parent = Dropdown._getParentFromElement(this);
1775
1776 var isActive = $$$1(parent).hasClass(ClassName.SHOW);
1777
1778 if (!isActive && (event.which !== ESCAPE_KEYCODE || event.which !== SPACE_KEYCODE) || isActive && (event.which === ESCAPE_KEYCODE || event.which === SPACE_KEYCODE)) {
1779 if (event.which === ESCAPE_KEYCODE) {
1780 var toggle = $$$1(parent).find(Selector.DATA_TOGGLE)[0];
1781 $$$1(toggle).trigger('focus');
1782 }
1783
1784 $$$1(this).trigger('click');
1785 return;
1786 }
1787
1788 var items = $$$1(parent).find(Selector.VISIBLE_ITEMS).get();
1789
1790 if (items.length === 0) {
1791 return;
1792 }
1793
1794 var index = items.indexOf(event.target);
1795
1796 if (event.which === ARROW_UP_KEYCODE && index > 0) {
1797
1798 index--;
1799 }
1800
1801 if (event.which === ARROW_DOWN_KEYCODE && index < items.length - 1) {
1802
1803 index++;
1804 }
1805
1806 if (index < 0) {
1807 index = 0;
1808 }
1809
1810 items[index].focus();
1811 };
1812
1813 _createClass(Dropdown, null, [{
1814 key: "VERSION",
1815 get: function get() {
1816 return VERSION;
1817 }
1818 }, {
1819 key: "Default",
1820 get: function get() {
1821 return Default;
1822 }
1823 }, {
1824 key: "DefaultType",
1825 get: function get() {
1826 return DefaultType;
1827 }
1828 }]);
1829 return Dropdown;
1830 }();
1831
1832
1833
1834
1835
1836
1837
1838 $$$1(document).on(Event.KEYDOWN_DATA_API, Selector.DATA_TOGGLE, Dropdown._dataApiKeydownHandler).on(Event.KEYDOWN_DATA_API, Selector.MENU, Dropdown._dataApiKeydownHandler).on(Event.CLICK_DATA_API + " " + Event.KEYUP_DATA_API, Dropdown._clearMenus).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
1839 event.preventDefault();
1840 event.stopPropagation();
1841
1842 Dropdown._jQueryInterface.call($$$1(this), 'toggle');
1843 }).on(Event.CLICK_DATA_API, Selector.FORM_CHILD, function (e) {
1844 e.stopPropagation();
1845 });
1846
1847
1848
1849
1850
1851
1852 $$$1.fn[NAME] = Dropdown._jQueryInterface;
1853 $$$1.fn[NAME].Constructor = Dropdown;
1854
1855 $$$1.fn[NAME].noConflict = function () {
1856 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
1857 return Dropdown._jQueryInterface;
1858 };
1859
1860 return Dropdown;
1861 }($, Popper);
1862
1863
1864
1865
1866
1867
1868
1869
1870 var Modal = function ($$$1) {
1871
1872
1873
1874
1875
1876 var NAME = 'modal';
1877 var VERSION = '4.0.0';
1878 var DATA_KEY = 'bs.modal';
1879 var EVENT_KEY = "." + DATA_KEY;
1880 var DATA_API_KEY = '.data-api';
1881 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
1882 var TRANSITION_DURATION = 300;
1883 var BACKDROP_TRANSITION_DURATION = 150;
1884 var ESCAPE_KEYCODE = 27;
1885
1886 var Default = {
1887 backdrop: true,
1888 keyboard: true,
1889 focus: true,
1890 show: true
1891 };
1892 var DefaultType = {
1893 backdrop: '(boolean|string)',
1894 keyboard: 'boolean',
1895 focus: 'boolean',
1896 show: 'boolean'
1897 };
1898 var Event = {
1899 HIDE: "hide" + EVENT_KEY,
1900 HIDDEN: "hidden" + EVENT_KEY,
1901 SHOW: "show" + EVENT_KEY,
1902 SHOWN: "shown" + EVENT_KEY,
1903 FOCUSIN: "focusin" + EVENT_KEY,
1904 RESIZE: "resize" + EVENT_KEY,
1905 CLICK_DISMISS: "click.dismiss" + EVENT_KEY,
1906 KEYDOWN_DISMISS: "keydown.dismiss" + EVENT_KEY,
1907 MOUSEUP_DISMISS: "mouseup.dismiss" + EVENT_KEY,
1908 MOUSEDOWN_DISMISS: "mousedown.dismiss" + EVENT_KEY,
1909 CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY
1910 };
1911 var ClassName = {
1912 SCROLLBAR_MEASURER: 'modal-scrollbar-measure',
1913 BACKDROP: 'modal-backdrop',
1914 OPEN: 'modal-open',
1915 FADE: 'fade',
1916 SHOW: 'show'
1917 };
1918 var Selector = {
1919 DIALOG: '.modal-dialog',
1920 DATA_TOGGLE: '[data-toggle="modal"]',
1921 DATA_DISMISS: '[data-dismiss="modal"]',
1922 FIXED_CONTENT: '.fixed-top, .fixed-bottom, .is-fixed, .sticky-top',
1923 STICKY_CONTENT: '.sticky-top',
1924 NAVBAR_TOGGLER: '.navbar-toggler'
1925
1926
1927
1928
1929
1930
1931 };
1932
1933 var Modal =
1934
1935 function () {
1936 function Modal(element, config) {
1937 this._config = this._getConfig(config);
1938 this._element = element;
1939 this._dialog = $$$1(element).find(Selector.DIALOG)[0];
1940 this._backdrop = null;
1941 this._isShown = false;
1942 this._isBodyOverflowing = false;
1943 this._ignoreBackdropClick = false;
1944 this._originalBodyPadding = 0;
1945 this._scrollbarWidth = 0;
1946 }
1947
1948
1949 var _proto = Modal.prototype;
1950
1951
1952 _proto.toggle = function toggle(relatedTarget) {
1953 return this._isShown ? this.hide() : this.show(relatedTarget);
1954 };
1955
1956 _proto.show = function show(relatedTarget) {
1957 var _this = this;
1958
1959 if (this._isTransitioning || this._isShown) {
1960 return;
1961 }
1962
1963 if (Util.supportsTransitionEnd() && $$$1(this._element).hasClass(ClassName.FADE)) {
1964 this._isTransitioning = true;
1965 }
1966
1967 var showEvent = $$$1.Event(Event.SHOW, {
1968 relatedTarget: relatedTarget
1969 });
1970 $$$1(this._element).trigger(showEvent);
1971
1972 if (this._isShown || showEvent.isDefaultPrevented()) {
1973 return;
1974 }
1975
1976 this._isShown = true;
1977
1978 this._checkScrollbar();
1979
1980 this._setScrollbar();
1981
1982 this._adjustDialog();
1983
1984 $$$1(document.body).addClass(ClassName.OPEN);
1985
1986 this._setEscapeEvent();
1987
1988 this._setResizeEvent();
1989
1990 $$$1(this._element).on(Event.CLICK_DISMISS, Selector.DATA_DISMISS, function (event) {
1991 return _this.hide(event);
1992 });
1993 $$$1(this._dialog).on(Event.MOUSEDOWN_DISMISS, function () {
1994 $$$1(_this._element).one(Event.MOUSEUP_DISMISS, function (event) {
1995 if ($$$1(event.target).is(_this._element)) {
1996 _this._ignoreBackdropClick = true;
1997 }
1998 });
1999 });
2000
2001 this._showBackdrop(function () {
2002 return _this._showElement(relatedTarget);
2003 });
2004 };
2005
2006 _proto.hide = function hide(event) {
2007 var _this2 = this;
2008
2009 if (event) {
2010 event.preventDefault();
2011 }
2012
2013 if (this._isTransitioning || !this._isShown) {
2014 return;
2015 }
2016
2017 var hideEvent = $$$1.Event(Event.HIDE);
2018 $$$1(this._element).trigger(hideEvent);
2019
2020 if (!this._isShown || hideEvent.isDefaultPrevented()) {
2021 return;
2022 }
2023
2024 this._isShown = false;
2025 var transition = Util.supportsTransitionEnd() && $$$1(this._element).hasClass(ClassName.FADE);
2026
2027 if (transition) {
2028 this._isTransitioning = true;
2029 }
2030
2031 this._setEscapeEvent();
2032
2033 this._setResizeEvent();
2034
2035 $$$1(document).off(Event.FOCUSIN);
2036 $$$1(this._element).removeClass(ClassName.SHOW);
2037 $$$1(this._element).off(Event.CLICK_DISMISS);
2038 $$$1(this._dialog).off(Event.MOUSEDOWN_DISMISS);
2039
2040 if (transition) {
2041 $$$1(this._element).one(Util.TRANSITION_END, function (event) {
2042 return _this2._hideModal(event);
2043 }).emulateTransitionEnd(TRANSITION_DURATION);
2044 } else {
2045 this._hideModal();
2046 }
2047 };
2048
2049 _proto.dispose = function dispose() {
2050 $$$1.removeData(this._element, DATA_KEY);
2051 $$$1(window, document, this._element, this._backdrop).off(EVENT_KEY);
2052 this._config = null;
2053 this._element = null;
2054 this._dialog = null;
2055 this._backdrop = null;
2056 this._isShown = null;
2057 this._isBodyOverflowing = null;
2058 this._ignoreBackdropClick = null;
2059 this._scrollbarWidth = null;
2060 };
2061
2062 _proto.handleUpdate = function handleUpdate() {
2063 this._adjustDialog();
2064 };
2065
2066
2067 _proto._getConfig = function _getConfig(config) {
2068 config = _extends({}, Default, config);
2069 Util.typeCheckConfig(NAME, config, DefaultType);
2070 return config;
2071 };
2072
2073 _proto._showElement = function _showElement(relatedTarget) {
2074 var _this3 = this;
2075
2076 var transition = Util.supportsTransitionEnd() && $$$1(this._element).hasClass(ClassName.FADE);
2077
2078 if (!this._element.parentNode || this._element.parentNode.nodeType !== Node.ELEMENT_NODE) {
2079
2080 document.body.appendChild(this._element);
2081 }
2082
2083 this._element.style.display = 'block';
2084
2085 this._element.removeAttribute('aria-hidden');
2086
2087 this._element.scrollTop = 0;
2088
2089 if (transition) {
2090 Util.reflow(this._element);
2091 }
2092
2093 $$$1(this._element).addClass(ClassName.SHOW);
2094
2095 if (this._config.focus) {
2096 this._enforceFocus();
2097 }
2098
2099 var shownEvent = $$$1.Event(Event.SHOWN, {
2100 relatedTarget: relatedTarget
2101 });
2102
2103 var transitionComplete = function transitionComplete() {
2104 if (_this3._config.focus) {
2105 _this3._element.focus();
2106 }
2107
2108 _this3._isTransitioning = false;
2109 $$$1(_this3._element).trigger(shownEvent);
2110 };
2111
2112 if (transition) {
2113 $$$1(this._dialog).one(Util.TRANSITION_END, transitionComplete).emulateTransitionEnd(TRANSITION_DURATION);
2114 } else {
2115 transitionComplete();
2116 }
2117 };
2118
2119 _proto._enforceFocus = function _enforceFocus() {
2120 var _this4 = this;
2121
2122 $$$1(document).off(Event.FOCUSIN)
2123 .on(Event.FOCUSIN, function (event) {
2124 if (document !== event.target && _this4._element !== event.target && $$$1(_this4._element).has(event.target).length === 0) {
2125 _this4._element.focus();
2126 }
2127 });
2128 };
2129
2130 _proto._setEscapeEvent = function _setEscapeEvent() {
2131 var _this5 = this;
2132
2133 if (this._isShown && this._config.keyboard) {
2134 $$$1(this._element).on(Event.KEYDOWN_DISMISS, function (event) {
2135 if (event.which === ESCAPE_KEYCODE) {
2136 event.preventDefault();
2137
2138 _this5.hide();
2139 }
2140 });
2141 } else if (!this._isShown) {
2142 $$$1(this._element).off(Event.KEYDOWN_DISMISS);
2143 }
2144 };
2145
2146 _proto._setResizeEvent = function _setResizeEvent() {
2147 var _this6 = this;
2148
2149 if (this._isShown) {
2150 $$$1(window).on(Event.RESIZE, function (event) {
2151 return _this6.handleUpdate(event);
2152 });
2153 } else {
2154 $$$1(window).off(Event.RESIZE);
2155 }
2156 };
2157
2158 _proto._hideModal = function _hideModal() {
2159 var _this7 = this;
2160
2161 this._element.style.display = 'none';
2162
2163 this._element.setAttribute('aria-hidden', true);
2164
2165 this._isTransitioning = false;
2166
2167 this._showBackdrop(function () {
2168 $$$1(document.body).removeClass(ClassName.OPEN);
2169
2170 _this7._resetAdjustments();
2171
2172 _this7._resetScrollbar();
2173
2174 $$$1(_this7._element).trigger(Event.HIDDEN);
2175 });
2176 };
2177
2178 _proto._removeBackdrop = function _removeBackdrop() {
2179 if (this._backdrop) {
2180 $$$1(this._backdrop).remove();
2181 this._backdrop = null;
2182 }
2183 };
2184
2185 _proto._showBackdrop = function _showBackdrop(callback) {
2186 var _this8 = this;
2187
2188 var animate = $$$1(this._element).hasClass(ClassName.FADE) ? ClassName.FADE : '';
2189
2190 if (this._isShown && this._config.backdrop) {
2191 var doAnimate = Util.supportsTransitionEnd() && animate;
2192 this._backdrop = document.createElement('div');
2193 this._backdrop.className = ClassName.BACKDROP;
2194
2195 if (animate) {
2196 $$$1(this._backdrop).addClass(animate);
2197 }
2198
2199 $$$1(this._backdrop).appendTo(document.body);
2200 $$$1(this._element).on(Event.CLICK_DISMISS, function (event) {
2201 if (_this8._ignoreBackdropClick) {
2202 _this8._ignoreBackdropClick = false;
2203 return;
2204 }
2205
2206 if (event.target !== event.currentTarget) {
2207 return;
2208 }
2209
2210 if (_this8._config.backdrop === 'static') {
2211 _this8._element.focus();
2212 } else {
2213 _this8.hide();
2214 }
2215 });
2216
2217 if (doAnimate) {
2218 Util.reflow(this._backdrop);
2219 }
2220
2221 $$$1(this._backdrop).addClass(ClassName.SHOW);
2222
2223 if (!callback) {
2224 return;
2225 }
2226
2227 if (!doAnimate) {
2228 callback();
2229 return;
2230 }
2231
2232 $$$1(this._backdrop).one(Util.TRANSITION_END, callback).emulateTransitionEnd(BACKDROP_TRANSITION_DURATION);
2233 } else if (!this._isShown && this._backdrop) {
2234 $$$1(this._backdrop).removeClass(ClassName.SHOW);
2235
2236 var callbackRemove = function callbackRemove() {
2237 _this8._removeBackdrop();
2238
2239 if (callback) {
2240 callback();
2241 }
2242 };
2243
2244 if (Util.supportsTransitionEnd() && $$$1(this._element).hasClass(ClassName.FADE)) {
2245 $$$1(this._backdrop).one(Util.TRANSITION_END, callbackRemove).emulateTransitionEnd(BACKDROP_TRANSITION_DURATION);
2246 } else {
2247 callbackRemove();
2248 }
2249 } else if (callback) {
2250 callback();
2251 }
2252 };
2253
2254
2255
2256
2257
2258 _proto._adjustDialog = function _adjustDialog() {
2259 var isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight;
2260
2261 if (!this._isBodyOverflowing && isModalOverflowing) {
2262 this._element.style.paddingLeft = this._scrollbarWidth + "px";
2263 }
2264
2265 if (this._isBodyOverflowing && !isModalOverflowing) {
2266 this._element.style.paddingRight = this._scrollbarWidth + "px";
2267 }
2268 };
2269
2270 _proto._resetAdjustments = function _resetAdjustments() {
2271 this._element.style.paddingLeft = '';
2272 this._element.style.paddingRight = '';
2273 };
2274
2275 _proto._checkScrollbar = function _checkScrollbar() {
2276 var rect = document.body.getBoundingClientRect();
2277 this._isBodyOverflowing = rect.left + rect.right < window.innerWidth;
2278 this._scrollbarWidth = this._getScrollbarWidth();
2279 };
2280
2281 _proto._setScrollbar = function _setScrollbar() {
2282 var _this9 = this;
2283
2284 if (this._isBodyOverflowing) {
2285
2286
2287
2288 $$$1(Selector.FIXED_CONTENT).each(function (index, element) {
2289 var actualPadding = $$$1(element)[0].style.paddingRight;
2290 var calculatedPadding = $$$1(element).css('padding-right');
2291 $$$1(element).data('padding-right', actualPadding).css('padding-right', parseFloat(calculatedPadding) + _this9._scrollbarWidth + "px");
2292 });
2293
2294 $$$1(Selector.STICKY_CONTENT).each(function (index, element) {
2295 var actualMargin = $$$1(element)[0].style.marginRight;
2296 var calculatedMargin = $$$1(element).css('margin-right');
2297 $$$1(element).data('margin-right', actualMargin).css('margin-right', parseFloat(calculatedMargin) - _this9._scrollbarWidth + "px");
2298 });
2299
2300 $$$1(Selector.NAVBAR_TOGGLER).each(function (index, element) {
2301 var actualMargin = $$$1(element)[0].style.marginRight;
2302 var calculatedMargin = $$$1(element).css('margin-right');
2303 $$$1(element).data('margin-right', actualMargin).css('margin-right', parseFloat(calculatedMargin) + _this9._scrollbarWidth + "px");
2304 });
2305
2306 var actualPadding = document.body.style.paddingRight;
2307 var calculatedPadding = $$$1('body').css('padding-right');
2308 $$$1('body').data('padding-right', actualPadding).css('padding-right', parseFloat(calculatedPadding) + this._scrollbarWidth + "px");
2309 }
2310 };
2311
2312 _proto._resetScrollbar = function _resetScrollbar() {
2313
2314 $$$1(Selector.FIXED_CONTENT).each(function (index, element) {
2315 var padding = $$$1(element).data('padding-right');
2316
2317 if (typeof padding !== 'undefined') {
2318 $$$1(element).css('padding-right', padding).removeData('padding-right');
2319 }
2320 });
2321
2322 $$$1(Selector.STICKY_CONTENT + ", " + Selector.NAVBAR_TOGGLER).each(function (index, element) {
2323 var margin = $$$1(element).data('margin-right');
2324
2325 if (typeof margin !== 'undefined') {
2326 $$$1(element).css('margin-right', margin).removeData('margin-right');
2327 }
2328 });
2329
2330 var padding = $$$1('body').data('padding-right');
2331
2332 if (typeof padding !== 'undefined') {
2333 $$$1('body').css('padding-right', padding).removeData('padding-right');
2334 }
2335 };
2336
2337 _proto._getScrollbarWidth = function _getScrollbarWidth() {
2338
2339 var scrollDiv = document.createElement('div');
2340 scrollDiv.className = ClassName.SCROLLBAR_MEASURER;
2341 document.body.appendChild(scrollDiv);
2342 var scrollbarWidth = scrollDiv.getBoundingClientRect().width - scrollDiv.clientWidth;
2343 document.body.removeChild(scrollDiv);
2344 return scrollbarWidth;
2345 };
2346
2347
2348 Modal._jQueryInterface = function _jQueryInterface(config, relatedTarget) {
2349 return this.each(function () {
2350 var data = $$$1(this).data(DATA_KEY);
2351
2352 var _config = _extends({}, Modal.Default, $$$1(this).data(), typeof config === 'object' && config);
2353
2354 if (!data) {
2355 data = new Modal(this, _config);
2356 $$$1(this).data(DATA_KEY, data);
2357 }
2358
2359 if (typeof config === 'string') {
2360 if (typeof data[config] === 'undefined') {
2361 throw new TypeError("No method named \"" + config + "\"");
2362 }
2363
2364 data[config](relatedTarget);
2365 } else if (_config.show) {
2366 data.show(relatedTarget);
2367 }
2368 });
2369 };
2370
2371 _createClass(Modal, null, [{
2372 key: "VERSION",
2373 get: function get() {
2374 return VERSION;
2375 }
2376 }, {
2377 key: "Default",
2378 get: function get() {
2379 return Default;
2380 }
2381 }]);
2382 return Modal;
2383 }();
2384
2385
2386
2387
2388
2389
2390
2391 $$$1(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
2392 var _this10 = this;
2393
2394 var target;
2395 var selector = Util.getSelectorFromElement(this);
2396
2397 if (selector) {
2398 target = $$$1(selector)[0];
2399 }
2400
2401 var config = $$$1(target).data(DATA_KEY) ? 'toggle' : _extends({}, $$$1(target).data(), $$$1(this).data());
2402
2403 if (this.tagName === 'A' || this.tagName === 'AREA') {
2404 event.preventDefault();
2405 }
2406
2407 var $target = $$$1(target).one(Event.SHOW, function (showEvent) {
2408 if (showEvent.isDefaultPrevented()) {
2409
2410 return;
2411 }
2412
2413 $target.one(Event.HIDDEN, function () {
2414 if ($$$1(_this10).is(':visible')) {
2415 _this10.focus();
2416 }
2417 });
2418 });
2419
2420 Modal._jQueryInterface.call($$$1(target), config, this);
2421 });
2422
2423
2424
2425
2426
2427
2428 $$$1.fn[NAME] = Modal._jQueryInterface;
2429 $$$1.fn[NAME].Constructor = Modal;
2430
2431 $$$1.fn[NAME].noConflict = function () {
2432 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
2433 return Modal._jQueryInterface;
2434 };
2435
2436 return Modal;
2437 }($);
2438
2439
2440
2441
2442
2443
2444
2445
2446 var Tooltip = function ($$$1) {
2447
2448
2449
2450
2451
2452 var NAME = 'tooltip';
2453 var VERSION = '4.0.0';
2454 var DATA_KEY = 'bs.tooltip';
2455 var EVENT_KEY = "." + DATA_KEY;
2456 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
2457 var TRANSITION_DURATION = 150;
2458 var CLASS_PREFIX = 'bs-tooltip';
2459 var BSCLS_PREFIX_REGEX = new RegExp("(^|\\s)" + CLASS_PREFIX + "\\S+", 'g');
2460 var DefaultType = {
2461 animation: 'boolean',
2462 template: 'string',
2463 title: '(string|element|function)',
2464 trigger: 'string',
2465 delay: '(number|object)',
2466 html: 'boolean',
2467 selector: '(string|boolean)',
2468 placement: '(string|function)',
2469 offset: '(number|string)',
2470 container: '(string|element|boolean)',
2471 fallbackPlacement: '(string|array)',
2472 boundary: '(string|element)'
2473 };
2474 var AttachmentMap = {
2475 AUTO: 'auto',
2476 TOP: 'top',
2477 RIGHT: 'right',
2478 BOTTOM: 'bottom',
2479 LEFT: 'left'
2480 };
2481 var Default = {
2482 animation: true,
2483 template: '<div class="tooltip" role="tooltip">' + '<div class="arrow"></div>' + '<div class="tooltip-inner"></div></div>',
2484 trigger: 'hover focus',
2485 title: '',
2486 delay: 0,
2487 html: false,
2488 selector: false,
2489 placement: 'top',
2490 offset: 0,
2491 container: false,
2492 fallbackPlacement: 'flip',
2493 boundary: 'scrollParent'
2494 };
2495 var HoverState = {
2496 SHOW: 'show',
2497 OUT: 'out'
2498 };
2499 var Event = {
2500 HIDE: "hide" + EVENT_KEY,
2501 HIDDEN: "hidden" + EVENT_KEY,
2502 SHOW: "show" + EVENT_KEY,
2503 SHOWN: "shown" + EVENT_KEY,
2504 INSERTED: "inserted" + EVENT_KEY,
2505 CLICK: "click" + EVENT_KEY,
2506 FOCUSIN: "focusin" + EVENT_KEY,
2507 FOCUSOUT: "focusout" + EVENT_KEY,
2508 MOUSEENTER: "mouseenter" + EVENT_KEY,
2509 MOUSELEAVE: "mouseleave" + EVENT_KEY
2510 };
2511 var ClassName = {
2512 FADE: 'fade',
2513 SHOW: 'show'
2514 };
2515 var Selector = {
2516 TOOLTIP: '.tooltip',
2517 TOOLTIP_INNER: '.tooltip-inner',
2518 ARROW: '.arrow'
2519 };
2520 var Trigger = {
2521 HOVER: 'hover',
2522 FOCUS: 'focus',
2523 CLICK: 'click',
2524 MANUAL: 'manual'
2525
2526
2527
2528
2529
2530
2531 };
2532
2533 var Tooltip =
2534
2535 function () {
2536 function Tooltip(element, config) {
2537
2538
2539
2540
2541 if (typeof Popper === 'undefined') {
2542 throw new TypeError('Bootstrap tooltips require Popper.js (https://popper.js.org)');
2543 }
2544
2545
2546 this._isEnabled = true;
2547 this._timeout = 0;
2548 this._hoverState = '';
2549 this._activeTrigger = {};
2550 this._popper = null;
2551
2552 this.element = element;
2553 this.config = this._getConfig(config);
2554 this.tip = null;
2555
2556 this._setListeners();
2557 }
2558
2559
2560 var _proto = Tooltip.prototype;
2561
2562
2563 _proto.enable = function enable() {
2564 this._isEnabled = true;
2565 };
2566
2567 _proto.disable = function disable() {
2568 this._isEnabled = false;
2569 };
2570
2571 _proto.toggleEnabled = function toggleEnabled() {
2572 this._isEnabled = !this._isEnabled;
2573 };
2574
2575 _proto.toggle = function toggle(event) {
2576 if (!this._isEnabled) {
2577 return;
2578 }
2579
2580 if (event) {
2581 var dataKey = this.constructor.DATA_KEY;
2582 var context = $$$1(event.currentTarget).data(dataKey);
2583
2584 if (!context) {
2585 context = new this.constructor(event.currentTarget, this._getDelegateConfig());
2586 $$$1(event.currentTarget).data(dataKey, context);
2587 }
2588
2589 context._activeTrigger.click = !context._activeTrigger.click;
2590
2591 if (context._isWithActiveTrigger()) {
2592 context._enter(null, context);
2593 } else {
2594 context._leave(null, context);
2595 }
2596 } else {
2597 if ($$$1(this.getTipElement()).hasClass(ClassName.SHOW)) {
2598 this._leave(null, this);
2599
2600 return;
2601 }
2602
2603 this._enter(null, this);
2604 }
2605 };
2606
2607 _proto.dispose = function dispose() {
2608 clearTimeout(this._timeout);
2609 $$$1.removeData(this.element, this.constructor.DATA_KEY);
2610 $$$1(this.element).off(this.constructor.EVENT_KEY);
2611 $$$1(this.element).closest('.modal').off('hide.bs.modal');
2612
2613 if (this.tip) {
2614 $$$1(this.tip).remove();
2615 }
2616
2617 this._isEnabled = null;
2618 this._timeout = null;
2619 this._hoverState = null;
2620 this._activeTrigger = null;
2621
2622 if (this._popper !== null) {
2623 this._popper.destroy();
2624 }
2625
2626 this._popper = null;
2627 this.element = null;
2628 this.config = null;
2629 this.tip = null;
2630 };
2631
2632 _proto.show = function show() {
2633 var _this = this;
2634
2635 if ($$$1(this.element).css('display') === 'none') {
2636 throw new Error('Please use show on visible elements');
2637 }
2638
2639 var showEvent = $$$1.Event(this.constructor.Event.SHOW);
2640
2641 if (this.isWithContent() && this._isEnabled) {
2642 $$$1(this.element).trigger(showEvent);
2643 var isInTheDom = $$$1.contains(this.element.ownerDocument.documentElement, this.element);
2644
2645 if (showEvent.isDefaultPrevented() || !isInTheDom) {
2646 return;
2647 }
2648
2649 var tip = this.getTipElement();
2650 var tipId = Util.getUID(this.constructor.NAME);
2651 tip.setAttribute('id', tipId);
2652 this.element.setAttribute('aria-describedby', tipId);
2653 this.setContent();
2654
2655 if (this.config.animation) {
2656 $$$1(tip).addClass(ClassName.FADE);
2657 }
2658
2659 var placement = typeof this.config.placement === 'function' ? this.config.placement.call(this, tip, this.element) : this.config.placement;
2660
2661 var attachment = this._getAttachment(placement);
2662
2663 this.addAttachmentClass(attachment);
2664 var container = this.config.container === false ? document.body : $$$1(this.config.container);
2665 $$$1(tip).data(this.constructor.DATA_KEY, this);
2666
2667 if (!$$$1.contains(this.element.ownerDocument.documentElement, this.tip)) {
2668 $$$1(tip).appendTo(container);
2669 }
2670
2671 $$$1(this.element).trigger(this.constructor.Event.INSERTED);
2672 this._popper = new Popper(this.element, tip, {
2673 placement: attachment,
2674 modifiers: {
2675 offset: {
2676 offset: this.config.offset
2677 },
2678 flip: {
2679 behavior: this.config.fallbackPlacement
2680 },
2681 arrow: {
2682 element: Selector.ARROW
2683 },
2684 preventOverflow: {
2685 boundariesElement: this.config.boundary
2686 }
2687 },
2688 onCreate: function onCreate(data) {
2689 if (data.originalPlacement !== data.placement) {
2690 _this._handlePopperPlacementChange(data);
2691 }
2692 },
2693 onUpdate: function onUpdate(data) {
2694 _this._handlePopperPlacementChange(data);
2695 }
2696 });
2697 $$$1(tip).addClass(ClassName.SHOW);
2698
2699
2700
2701
2702 if ('ontouchstart' in document.documentElement) {
2703 $$$1('body').children().on('mouseover', null, $$$1.noop);
2704 }
2705
2706 var complete = function complete() {
2707 if (_this.config.animation) {
2708 _this._fixTransition();
2709 }
2710
2711 var prevHoverState = _this._hoverState;
2712 _this._hoverState = null;
2713 $$$1(_this.element).trigger(_this.constructor.Event.SHOWN);
2714
2715 if (prevHoverState === HoverState.OUT) {
2716 _this._leave(null, _this);
2717 }
2718 };
2719
2720 if (Util.supportsTransitionEnd() && $$$1(this.tip).hasClass(ClassName.FADE)) {
2721 $$$1(this.tip).one(Util.TRANSITION_END, complete).emulateTransitionEnd(Tooltip._TRANSITION_DURATION);
2722 } else {
2723 complete();
2724 }
2725 }
2726 };
2727
2728 _proto.hide = function hide(callback) {
2729 var _this2 = this;
2730
2731 var tip = this.getTipElement();
2732 var hideEvent = $$$1.Event(this.constructor.Event.HIDE);
2733
2734 var complete = function complete() {
2735 if (_this2._hoverState !== HoverState.SHOW && tip.parentNode) {
2736 tip.parentNode.removeChild(tip);
2737 }
2738
2739 _this2._cleanTipClass();
2740
2741 _this2.element.removeAttribute('aria-describedby');
2742
2743 $$$1(_this2.element).trigger(_this2.constructor.Event.HIDDEN);
2744
2745 if (_this2._popper !== null) {
2746 _this2._popper.destroy();
2747 }
2748
2749 if (callback) {
2750 callback();
2751 }
2752 };
2753
2754 $$$1(this.element).trigger(hideEvent);
2755
2756 if (hideEvent.isDefaultPrevented()) {
2757 return;
2758 }
2759
2760 $$$1(tip).removeClass(ClassName.SHOW);
2761
2762
2763 if ('ontouchstart' in document.documentElement) {
2764 $$$1('body').children().off('mouseover', null, $$$1.noop);
2765 }
2766
2767 this._activeTrigger[Trigger.CLICK] = false;
2768 this._activeTrigger[Trigger.FOCUS] = false;
2769 this._activeTrigger[Trigger.HOVER] = false;
2770
2771 if (Util.supportsTransitionEnd() && $$$1(this.tip).hasClass(ClassName.FADE)) {
2772 $$$1(tip).one(Util.TRANSITION_END, complete).emulateTransitionEnd(TRANSITION_DURATION);
2773 } else {
2774 complete();
2775 }
2776
2777 this._hoverState = '';
2778 };
2779
2780 _proto.update = function update() {
2781 if (this._popper !== null) {
2782 this._popper.scheduleUpdate();
2783 }
2784 };
2785
2786
2787 _proto.isWithContent = function isWithContent() {
2788 return Boolean(this.getTitle());
2789 };
2790
2791 _proto.addAttachmentClass = function addAttachmentClass(attachment) {
2792 $$$1(this.getTipElement()).addClass(CLASS_PREFIX + "-" + attachment);
2793 };
2794
2795 _proto.getTipElement = function getTipElement() {
2796 this.tip = this.tip || $$$1(this.config.template)[0];
2797 return this.tip;
2798 };
2799
2800 _proto.setContent = function setContent() {
2801 var $tip = $$$1(this.getTipElement());
2802 this.setElementContent($tip.find(Selector.TOOLTIP_INNER), this.getTitle());
2803 $tip.removeClass(ClassName.FADE + " " + ClassName.SHOW);
2804 };
2805
2806 _proto.setElementContent = function setElementContent($element, content) {
2807 var html = this.config.html;
2808
2809 if (typeof content === 'object' && (content.nodeType || content.jquery)) {
2810
2811 if (html) {
2812 if (!$$$1(content).parent().is($element)) {
2813 $element.empty().append(content);
2814 }
2815 } else {
2816 $element.text($$$1(content).text());
2817 }
2818 } else {
2819 $element[html ? 'html' : 'text'](content);
2820 }
2821 };
2822
2823 _proto.getTitle = function getTitle() {
2824 var title = this.element.getAttribute('data-original-title');
2825
2826 if (!title) {
2827 title = typeof this.config.title === 'function' ? this.config.title.call(this.element) : this.config.title;
2828 }
2829
2830 return title;
2831 };
2832
2833
2834 _proto._getAttachment = function _getAttachment(placement) {
2835 return AttachmentMap[placement.toUpperCase()];
2836 };
2837
2838 _proto._setListeners = function _setListeners() {
2839 var _this3 = this;
2840
2841 var triggers = this.config.trigger.split(' ');
2842 triggers.forEach(function (trigger) {
2843 if (trigger === 'click') {
2844 $$$1(_this3.element).on(_this3.constructor.Event.CLICK, _this3.config.selector, function (event) {
2845 return _this3.toggle(event);
2846 });
2847 } else if (trigger !== Trigger.MANUAL) {
2848 var eventIn = trigger === Trigger.HOVER ? _this3.constructor.Event.MOUSEENTER : _this3.constructor.Event.FOCUSIN;
2849 var eventOut = trigger === Trigger.HOVER ? _this3.constructor.Event.MOUSELEAVE : _this3.constructor.Event.FOCUSOUT;
2850 $$$1(_this3.element).on(eventIn, _this3.config.selector, function (event) {
2851 return _this3._enter(event);
2852 }).on(eventOut, _this3.config.selector, function (event) {
2853 return _this3._leave(event);
2854 });
2855 }
2856
2857 $$$1(_this3.element).closest('.modal').on('hide.bs.modal', function () {
2858 return _this3.hide();
2859 });
2860 });
2861
2862 if (this.config.selector) {
2863 this.config = _extends({}, this.config, {
2864 trigger: 'manual',
2865 selector: ''
2866 });
2867 } else {
2868 this._fixTitle();
2869 }
2870 };
2871
2872 _proto._fixTitle = function _fixTitle() {
2873 var titleType = typeof this.element.getAttribute('data-original-title');
2874
2875 if (this.element.getAttribute('title') || titleType !== 'string') {
2876 this.element.setAttribute('data-original-title', this.element.getAttribute('title') || '');
2877 this.element.setAttribute('title', '');
2878 }
2879 };
2880
2881 _proto._enter = function _enter(event, context) {
2882 var dataKey = this.constructor.DATA_KEY;
2883 context = context || $$$1(event.currentTarget).data(dataKey);
2884
2885 if (!context) {
2886 context = new this.constructor(event.currentTarget, this._getDelegateConfig());
2887 $$$1(event.currentTarget).data(dataKey, context);
2888 }
2889
2890 if (event) {
2891 context._activeTrigger[event.type === 'focusin' ? Trigger.FOCUS : Trigger.HOVER] = true;
2892 }
2893
2894 if ($$$1(context.getTipElement()).hasClass(ClassName.SHOW) || context._hoverState === HoverState.SHOW) {
2895 context._hoverState = HoverState.SHOW;
2896 return;
2897 }
2898
2899 clearTimeout(context._timeout);
2900 context._hoverState = HoverState.SHOW;
2901
2902 if (!context.config.delay || !context.config.delay.show) {
2903 context.show();
2904 return;
2905 }
2906
2907 context._timeout = setTimeout(function () {
2908 if (context._hoverState === HoverState.SHOW) {
2909 context.show();
2910 }
2911 }, context.config.delay.show);
2912 };
2913
2914 _proto._leave = function _leave(event, context) {
2915 var dataKey = this.constructor.DATA_KEY;
2916 context = context || $$$1(event.currentTarget).data(dataKey);
2917
2918 if (!context) {
2919 context = new this.constructor(event.currentTarget, this._getDelegateConfig());
2920 $$$1(event.currentTarget).data(dataKey, context);
2921 }
2922
2923 if (event) {
2924 context._activeTrigger[event.type === 'focusout' ? Trigger.FOCUS : Trigger.HOVER] = false;
2925 }
2926
2927 if (context._isWithActiveTrigger()) {
2928 return;
2929 }
2930
2931 clearTimeout(context._timeout);
2932 context._hoverState = HoverState.OUT;
2933
2934 if (!context.config.delay || !context.config.delay.hide) {
2935 context.hide();
2936 return;
2937 }
2938
2939 context._timeout = setTimeout(function () {
2940 if (context._hoverState === HoverState.OUT) {
2941 context.hide();
2942 }
2943 }, context.config.delay.hide);
2944 };
2945
2946 _proto._isWithActiveTrigger = function _isWithActiveTrigger() {
2947 for (var trigger in this._activeTrigger) {
2948 if (this._activeTrigger[trigger]) {
2949 return true;
2950 }
2951 }
2952
2953 return false;
2954 };
2955
2956 _proto._getConfig = function _getConfig(config) {
2957 config = _extends({}, this.constructor.Default, $$$1(this.element).data(), config);
2958
2959 if (typeof config.delay === 'number') {
2960 config.delay = {
2961 show: config.delay,
2962 hide: config.delay
2963 };
2964 }
2965
2966 if (typeof config.title === 'number') {
2967 config.title = config.title.toString();
2968 }
2969
2970 if (typeof config.content === 'number') {
2971 config.content = config.content.toString();
2972 }
2973
2974 Util.typeCheckConfig(NAME, config, this.constructor.DefaultType);
2975 return config;
2976 };
2977
2978 _proto._getDelegateConfig = function _getDelegateConfig() {
2979 var config = {};
2980
2981 if (this.config) {
2982 for (var key in this.config) {
2983 if (this.constructor.Default[key] !== this.config[key]) {
2984 config[key] = this.config[key];
2985 }
2986 }
2987 }
2988
2989 return config;
2990 };
2991
2992 _proto._cleanTipClass = function _cleanTipClass() {
2993 var $tip = $$$1(this.getTipElement());
2994 var tabClass = $tip.attr('class').match(BSCLS_PREFIX_REGEX);
2995
2996 if (tabClass !== null && tabClass.length > 0) {
2997 $tip.removeClass(tabClass.join(''));
2998 }
2999 };
3000
3001 _proto._handlePopperPlacementChange = function _handlePopperPlacementChange(data) {
3002 this._cleanTipClass();
3003
3004 this.addAttachmentClass(this._getAttachment(data.placement));
3005 };
3006
3007 _proto._fixTransition = function _fixTransition() {
3008 var tip = this.getTipElement();
3009 var initConfigAnimation = this.config.animation;
3010
3011 if (tip.getAttribute('x-placement') !== null) {
3012 return;
3013 }
3014
3015 $$$1(tip).removeClass(ClassName.FADE);
3016 this.config.animation = false;
3017 this.hide();
3018 this.show();
3019 this.config.animation = initConfigAnimation;
3020 };
3021
3022
3023 Tooltip._jQueryInterface = function _jQueryInterface(config) {
3024 return this.each(function () {
3025 var data = $$$1(this).data(DATA_KEY);
3026
3027 var _config = typeof config === 'object' && config;
3028
3029 if (!data && /dispose|hide/.test(config)) {
3030 return;
3031 }
3032
3033 if (!data) {
3034 data = new Tooltip(this, _config);
3035 $$$1(this).data(DATA_KEY, data);
3036 }
3037
3038 if (typeof config === 'string') {
3039 if (typeof data[config] === 'undefined') {
3040 throw new TypeError("No method named \"" + config + "\"");
3041 }
3042
3043 data[config]();
3044 }
3045 });
3046 };
3047
3048 _createClass(Tooltip, null, [{
3049 key: "VERSION",
3050 get: function get() {
3051 return VERSION;
3052 }
3053 }, {
3054 key: "Default",
3055 get: function get() {
3056 return Default;
3057 }
3058 }, {
3059 key: "NAME",
3060 get: function get() {
3061 return NAME;
3062 }
3063 }, {
3064 key: "DATA_KEY",
3065 get: function get() {
3066 return DATA_KEY;
3067 }
3068 }, {
3069 key: "Event",
3070 get: function get() {
3071 return Event;
3072 }
3073 }, {
3074 key: "EVENT_KEY",
3075 get: function get() {
3076 return EVENT_KEY;
3077 }
3078 }, {
3079 key: "DefaultType",
3080 get: function get() {
3081 return DefaultType;
3082 }
3083 }]);
3084 return Tooltip;
3085 }();
3086
3087
3088
3089
3090
3091
3092
3093 $$$1.fn[NAME] = Tooltip._jQueryInterface;
3094 $$$1.fn[NAME].Constructor = Tooltip;
3095
3096 $$$1.fn[NAME].noConflict = function () {
3097 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
3098 return Tooltip._jQueryInterface;
3099 };
3100
3101 return Tooltip;
3102 }($, Popper);
3103
3104
3105
3106
3107
3108
3109
3110
3111 var Popover = function ($$$1) {
3112
3113
3114
3115
3116
3117 var NAME = 'popover';
3118 var VERSION = '4.0.0';
3119 var DATA_KEY = 'bs.popover';
3120 var EVENT_KEY = "." + DATA_KEY;
3121 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
3122 var CLASS_PREFIX = 'bs-popover';
3123 var BSCLS_PREFIX_REGEX = new RegExp("(^|\\s)" + CLASS_PREFIX + "\\S+", 'g');
3124 var Default = _extends({}, Tooltip.Default, {
3125 placement: 'right',
3126 trigger: 'click',
3127 content: '',
3128 template: '<div class="popover" role="tooltip">' + '<div class="arrow"></div>' + '<h3 class="popover-header"></h3>' + '<div class="popover-body"></div></div>'
3129 });
3130 var DefaultType = _extends({}, Tooltip.DefaultType, {
3131 content: '(string|element|function)'
3132 });
3133 var ClassName = {
3134 FADE: 'fade',
3135 SHOW: 'show'
3136 };
3137 var Selector = {
3138 TITLE: '.popover-header',
3139 CONTENT: '.popover-body'
3140 };
3141 var Event = {
3142 HIDE: "hide" + EVENT_KEY,
3143 HIDDEN: "hidden" + EVENT_KEY,
3144 SHOW: "show" + EVENT_KEY,
3145 SHOWN: "shown" + EVENT_KEY,
3146 INSERTED: "inserted" + EVENT_KEY,
3147 CLICK: "click" + EVENT_KEY,
3148 FOCUSIN: "focusin" + EVENT_KEY,
3149 FOCUSOUT: "focusout" + EVENT_KEY,
3150 MOUSEENTER: "mouseenter" + EVENT_KEY,
3151 MOUSELEAVE: "mouseleave" + EVENT_KEY
3152
3153
3154
3155
3156
3157
3158 };
3159
3160 var Popover =
3161
3162 function (_Tooltip) {
3163 _inheritsLoose(Popover, _Tooltip);
3164
3165 function Popover() {
3166 return _Tooltip.apply(this, arguments) || this;
3167 }
3168
3169 var _proto = Popover.prototype;
3170
3171
3172 _proto.isWithContent = function isWithContent() {
3173 return this.getTitle() || this._getContent();
3174 };
3175
3176 _proto.addAttachmentClass = function addAttachmentClass(attachment) {
3177 $$$1(this.getTipElement()).addClass(CLASS_PREFIX + "-" + attachment);
3178 };
3179
3180 _proto.getTipElement = function getTipElement() {
3181 this.tip = this.tip || $$$1(this.config.template)[0];
3182 return this.tip;
3183 };
3184
3185 _proto.setContent = function setContent() {
3186 var $tip = $$$1(this.getTipElement());
3187
3188 this.setElementContent($tip.find(Selector.TITLE), this.getTitle());
3189
3190 var content = this._getContent();
3191
3192 if (typeof content === 'function') {
3193 content = content.call(this.element);
3194 }
3195
3196 this.setElementContent($tip.find(Selector.CONTENT), content);
3197 $tip.removeClass(ClassName.FADE + " " + ClassName.SHOW);
3198 };
3199
3200
3201 _proto._getContent = function _getContent() {
3202 return this.element.getAttribute('data-content') || this.config.content;
3203 };
3204
3205 _proto._cleanTipClass = function _cleanTipClass() {
3206 var $tip = $$$1(this.getTipElement());
3207 var tabClass = $tip.attr('class').match(BSCLS_PREFIX_REGEX);
3208
3209 if (tabClass !== null && tabClass.length > 0) {
3210 $tip.removeClass(tabClass.join(''));
3211 }
3212 };
3213
3214
3215 Popover._jQueryInterface = function _jQueryInterface(config) {
3216 return this.each(function () {
3217 var data = $$$1(this).data(DATA_KEY);
3218
3219 var _config = typeof config === 'object' ? config : null;
3220
3221 if (!data && /destroy|hide/.test(config)) {
3222 return;
3223 }
3224
3225 if (!data) {
3226 data = new Popover(this, _config);
3227 $$$1(this).data(DATA_KEY, data);
3228 }
3229
3230 if (typeof config === 'string') {
3231 if (typeof data[config] === 'undefined') {
3232 throw new TypeError("No method named \"" + config + "\"");
3233 }
3234
3235 data[config]();
3236 }
3237 });
3238 };
3239
3240 _createClass(Popover, null, [{
3241 key: "VERSION",
3242
3243 get: function get() {
3244 return VERSION;
3245 }
3246 }, {
3247 key: "Default",
3248 get: function get() {
3249 return Default;
3250 }
3251 }, {
3252 key: "NAME",
3253 get: function get() {
3254 return NAME;
3255 }
3256 }, {
3257 key: "DATA_KEY",
3258 get: function get() {
3259 return DATA_KEY;
3260 }
3261 }, {
3262 key: "Event",
3263 get: function get() {
3264 return Event;
3265 }
3266 }, {
3267 key: "EVENT_KEY",
3268 get: function get() {
3269 return EVENT_KEY;
3270 }
3271 }, {
3272 key: "DefaultType",
3273 get: function get() {
3274 return DefaultType;
3275 }
3276 }]);
3277 return Popover;
3278 }(Tooltip);
3279
3280
3281
3282
3283
3284
3285
3286 $$$1.fn[NAME] = Popover._jQueryInterface;
3287 $$$1.fn[NAME].Constructor = Popover;
3288
3289 $$$1.fn[NAME].noConflict = function () {
3290 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
3291 return Popover._jQueryInterface;
3292 };
3293
3294 return Popover;
3295 }($);
3296
3297
3298
3299
3300
3301
3302
3303
3304 var ScrollSpy = function ($$$1) {
3305
3306
3307
3308
3309
3310 var NAME = 'scrollspy';
3311 var VERSION = '4.0.0';
3312 var DATA_KEY = 'bs.scrollspy';
3313 var EVENT_KEY = "." + DATA_KEY;
3314 var DATA_API_KEY = '.data-api';
3315 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
3316 var Default = {
3317 offset: 10,
3318 method: 'auto',
3319 target: ''
3320 };
3321 var DefaultType = {
3322 offset: 'number',
3323 method: 'string',
3324 target: '(string|element)'
3325 };
3326 var Event = {
3327 ACTIVATE: "activate" + EVENT_KEY,
3328 SCROLL: "scroll" + EVENT_KEY,
3329 LOAD_DATA_API: "load" + EVENT_KEY + DATA_API_KEY
3330 };
3331 var ClassName = {
3332 DROPDOWN_ITEM: 'dropdown-item',
3333 DROPDOWN_MENU: 'dropdown-menu',
3334 ACTIVE: 'active'
3335 };
3336 var Selector = {
3337 DATA_SPY: '[data-spy="scroll"]',
3338 ACTIVE: '.active',
3339 NAV_LIST_GROUP: '.nav, .list-group',
3340 NAV_LINKS: '.nav-link',
3341 NAV_ITEMS: '.nav-item',
3342 LIST_ITEMS: '.list-group-item',
3343 DROPDOWN: '.dropdown',
3344 DROPDOWN_ITEMS: '.dropdown-item',
3345 DROPDOWN_TOGGLE: '.dropdown-toggle'
3346 };
3347 var OffsetMethod = {
3348 OFFSET: 'offset',
3349 POSITION: 'position'
3350
3351
3352
3353
3354
3355
3356 };
3357
3358 var ScrollSpy =
3359
3360 function () {
3361 function ScrollSpy(element, config) {
3362 var _this = this;
3363
3364 this._element = element;
3365 this._scrollElement = element.tagName === 'BODY' ? window : element;
3366 this._config = this._getConfig(config);
3367 this._selector = this._config.target + " " + Selector.NAV_LINKS + "," + (this._config.target + " " + Selector.LIST_ITEMS + ",") + (this._config.target + " " + Selector.DROPDOWN_ITEMS);
3368 this._offsets = [];
3369 this._targets = [];
3370 this._activeTarget = null;
3371 this._scrollHeight = 0;
3372 $$$1(this._scrollElement).on(Event.SCROLL, function (event) {
3373 return _this._process(event);
3374 });
3375 this.refresh();
3376
3377 this._process();
3378 }
3379
3380
3381 var _proto = ScrollSpy.prototype;
3382
3383
3384 _proto.refresh = function refresh() {
3385 var _this2 = this;
3386
3387 var autoMethod = this._scrollElement === this._scrollElement.window ? OffsetMethod.OFFSET : OffsetMethod.POSITION;
3388 var offsetMethod = this._config.method === 'auto' ? autoMethod : this._config.method;
3389 var offsetBase = offsetMethod === OffsetMethod.POSITION ? this._getScrollTop() : 0;
3390 this._offsets = [];
3391 this._targets = [];
3392 this._scrollHeight = this._getScrollHeight();
3393 var targets = $$$1.makeArray($$$1(this._selector));
3394 targets.map(function (element) {
3395 var target;
3396 var targetSelector = Util.getSelectorFromElement(element);
3397
3398 if (targetSelector) {
3399 target = $$$1(targetSelector)[0];
3400 }
3401
3402 if (target) {
3403 var targetBCR = target.getBoundingClientRect();
3404
3405 if (targetBCR.width || targetBCR.height) {
3406
3407 return [$$$1(target)[offsetMethod]().top + offsetBase, targetSelector];
3408 }
3409 }
3410
3411 return null;
3412 }).filter(function (item) {
3413 return item;
3414 }).sort(function (a, b) {
3415 return a[0] - b[0];
3416 }).forEach(function (item) {
3417 _this2._offsets.push(item[0]);
3418
3419 _this2._targets.push(item[1]);
3420 });
3421 };
3422
3423 _proto.dispose = function dispose() {
3424 $$$1.removeData(this._element, DATA_KEY);
3425 $$$1(this._scrollElement).off(EVENT_KEY);
3426 this._element = null;
3427 this._scrollElement = null;
3428 this._config = null;
3429 this._selector = null;
3430 this._offsets = null;
3431 this._targets = null;
3432 this._activeTarget = null;
3433 this._scrollHeight = null;
3434 };
3435
3436
3437 _proto._getConfig = function _getConfig(config) {
3438 config = _extends({}, Default, config);
3439
3440 if (typeof config.target !== 'string') {
3441 var id = $$$1(config.target).attr('id');
3442
3443 if (!id) {
3444 id = Util.getUID(NAME);
3445 $$$1(config.target).attr('id', id);
3446 }
3447
3448 config.target = "#" + id;
3449 }
3450
3451 Util.typeCheckConfig(NAME, config, DefaultType);
3452 return config;
3453 };
3454
3455 _proto._getScrollTop = function _getScrollTop() {
3456 return this._scrollElement === window ? this._scrollElement.pageYOffset : this._scrollElement.scrollTop;
3457 };
3458
3459 _proto._getScrollHeight = function _getScrollHeight() {
3460 return this._scrollElement.scrollHeight || Math.max(document.body.scrollHeight, document.documentElement.scrollHeight);
3461 };
3462
3463 _proto._getOffsetHeight = function _getOffsetHeight() {
3464 return this._scrollElement === window ? window.innerHeight : this._scrollElement.getBoundingClientRect().height;
3465 };
3466
3467 _proto._process = function _process() {
3468 var scrollTop = this._getScrollTop() + this._config.offset;
3469
3470 var scrollHeight = this._getScrollHeight();
3471
3472 var maxScroll = this._config.offset + scrollHeight - this._getOffsetHeight();
3473
3474 if (this._scrollHeight !== scrollHeight) {
3475 this.refresh();
3476 }
3477
3478 if (scrollTop >= maxScroll) {
3479 var target = this._targets[this._targets.length - 1];
3480
3481 if (this._activeTarget !== target) {
3482 this._activate(target);
3483 }
3484
3485 return;
3486 }
3487
3488 if (this._activeTarget && scrollTop < this._offsets[0] && this._offsets[0] > 0) {
3489 this._activeTarget = null;
3490
3491 this._clear();
3492
3493 return;
3494 }
3495
3496 for (var i = this._offsets.length; i--;) {
3497 var isActiveTarget = this._activeTarget !== this._targets[i] && scrollTop >= this._offsets[i] && (typeof this._offsets[i + 1] === 'undefined' || scrollTop < this._offsets[i + 1]);
3498
3499 if (isActiveTarget) {
3500 this._activate(this._targets[i]);
3501 }
3502 }
3503 };
3504
3505 _proto._activate = function _activate(target) {
3506 this._activeTarget = target;
3507
3508 this._clear();
3509
3510 var queries = this._selector.split(',');
3511
3512
3513 queries = queries.map(function (selector) {
3514 return selector + "[data-target=\"" + target + "\"]," + (selector + "[href=\"" + target + "\"]");
3515 });
3516 var $link = $$$1(queries.join(','));
3517
3518 if ($link.hasClass(ClassName.DROPDOWN_ITEM)) {
3519 $link.closest(Selector.DROPDOWN).find(Selector.DROPDOWN_TOGGLE).addClass(ClassName.ACTIVE);
3520 $link.addClass(ClassName.ACTIVE);
3521 } else {
3522
3523 $link.addClass(ClassName.ACTIVE);
3524
3525
3526 $link.parents(Selector.NAV_LIST_GROUP).prev(Selector.NAV_LINKS + ", " + Selector.LIST_ITEMS).addClass(ClassName.ACTIVE);
3527
3528 $link.parents(Selector.NAV_LIST_GROUP).prev(Selector.NAV_ITEMS).children(Selector.NAV_LINKS).addClass(ClassName.ACTIVE);
3529 }
3530
3531 $$$1(this._scrollElement).trigger(Event.ACTIVATE, {
3532 relatedTarget: target
3533 });
3534 };
3535
3536 _proto._clear = function _clear() {
3537 $$$1(this._selector).filter(Selector.ACTIVE).removeClass(ClassName.ACTIVE);
3538 };
3539
3540
3541 ScrollSpy._jQueryInterface = function _jQueryInterface(config) {
3542 return this.each(function () {
3543 var data = $$$1(this).data(DATA_KEY);
3544
3545 var _config = typeof config === 'object' && config;
3546
3547 if (!data) {
3548 data = new ScrollSpy(this, _config);
3549 $$$1(this).data(DATA_KEY, data);
3550 }
3551
3552 if (typeof config === 'string') {
3553 if (typeof data[config] === 'undefined') {
3554 throw new TypeError("No method named \"" + config + "\"");
3555 }
3556
3557 data[config]();
3558 }
3559 });
3560 };
3561
3562 _createClass(ScrollSpy, null, [{
3563 key: "VERSION",
3564 get: function get() {
3565 return VERSION;
3566 }
3567 }, {
3568 key: "Default",
3569 get: function get() {
3570 return Default;
3571 }
3572 }]);
3573 return ScrollSpy;
3574 }();
3575
3576
3577
3578
3579
3580
3581
3582 $$$1(window).on(Event.LOAD_DATA_API, function () {
3583 var scrollSpys = $$$1.makeArray($$$1(Selector.DATA_SPY));
3584
3585 for (var i = scrollSpys.length; i--;) {
3586 var $spy = $$$1(scrollSpys[i]);
3587
3588 ScrollSpy._jQueryInterface.call($spy, $spy.data());
3589 }
3590 });
3591
3592
3593
3594
3595
3596
3597 $$$1.fn[NAME] = ScrollSpy._jQueryInterface;
3598 $$$1.fn[NAME].Constructor = ScrollSpy;
3599
3600 $$$1.fn[NAME].noConflict = function () {
3601 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
3602 return ScrollSpy._jQueryInterface;
3603 };
3604
3605 return ScrollSpy;
3606 }($);
3607
3608
3609
3610
3611
3612
3613
3614
3615 var Tab = function ($$$1) {
3616
3617
3618
3619
3620
3621 var NAME = 'tab';
3622 var VERSION = '4.0.0';
3623 var DATA_KEY = 'bs.tab';
3624 var EVENT_KEY = "." + DATA_KEY;
3625 var DATA_API_KEY = '.data-api';
3626 var JQUERY_NO_CONFLICT = $$$1.fn[NAME];
3627 var TRANSITION_DURATION = 150;
3628 var Event = {
3629 HIDE: "hide" + EVENT_KEY,
3630 HIDDEN: "hidden" + EVENT_KEY,
3631 SHOW: "show" + EVENT_KEY,
3632 SHOWN: "shown" + EVENT_KEY,
3633 CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY
3634 };
3635 var ClassName = {
3636 DROPDOWN_MENU: 'dropdown-menu',
3637 ACTIVE: 'active',
3638 DISABLED: 'disabled',
3639 FADE: 'fade',
3640 SHOW: 'show'
3641 };
3642 var Selector = {
3643 DROPDOWN: '.dropdown',
3644 NAV_LIST_GROUP: '.nav, .list-group',
3645 ACTIVE: '.active',
3646 ACTIVE_UL: '> li > .active',
3647 DATA_TOGGLE: '[data-toggle="tab"], [data-toggle="pill"], [data-toggle="list"]',
3648 DROPDOWN_TOGGLE: '.dropdown-toggle',
3649 DROPDOWN_ACTIVE_CHILD: '> .dropdown-menu .active'
3650
3651
3652
3653
3654
3655
3656 };
3657
3658 var Tab =
3659
3660 function () {
3661 function Tab(element) {
3662 this._element = element;
3663 }
3664
3665
3666 var _proto = Tab.prototype;
3667
3668
3669 _proto.show = function show() {
3670 var _this = this;
3671
3672 if (this._element.parentNode && this._element.parentNode.nodeType === Node.ELEMENT_NODE && $$$1(this._element).hasClass(ClassName.ACTIVE) || $$$1(this._element).hasClass(ClassName.DISABLED)) {
3673 return;
3674 }
3675
3676 var target;
3677 var previous;
3678 var listElement = $$$1(this._element).closest(Selector.NAV_LIST_GROUP)[0];
3679 var selector = Util.getSelectorFromElement(this._element);
3680
3681 if (listElement) {
3682 var itemSelector = listElement.nodeName === 'UL' ? Selector.ACTIVE_UL : Selector.ACTIVE;
3683 previous = $$$1.makeArray($$$1(listElement).find(itemSelector));
3684 previous = previous[previous.length - 1];
3685 }
3686
3687 var hideEvent = $$$1.Event(Event.HIDE, {
3688 relatedTarget: this._element
3689 });
3690 var showEvent = $$$1.Event(Event.SHOW, {
3691 relatedTarget: previous
3692 });
3693
3694 if (previous) {
3695 $$$1(previous).trigger(hideEvent);
3696 }
3697
3698 $$$1(this._element).trigger(showEvent);
3699
3700 if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) {
3701 return;
3702 }
3703
3704 if (selector) {
3705 target = $$$1(selector)[0];
3706 }
3707
3708 this._activate(this._element, listElement);
3709
3710 var complete = function complete() {
3711 var hiddenEvent = $$$1.Event(Event.HIDDEN, {
3712 relatedTarget: _this._element
3713 });
3714 var shownEvent = $$$1.Event(Event.SHOWN, {
3715 relatedTarget: previous
3716 });
3717 $$$1(previous).trigger(hiddenEvent);
3718 $$$1(_this._element).trigger(shownEvent);
3719 };
3720
3721 if (target) {
3722 this._activate(target, target.parentNode, complete);
3723 } else {
3724 complete();
3725 }
3726 };
3727
3728 _proto.dispose = function dispose() {
3729 $$$1.removeData(this._element, DATA_KEY);
3730 this._element = null;
3731 };
3732
3733
3734 _proto._activate = function _activate(element, container, callback) {
3735 var _this2 = this;
3736
3737 var activeElements;
3738
3739 if (container.nodeName === 'UL') {
3740 activeElements = $$$1(container).find(Selector.ACTIVE_UL);
3741 } else {
3742 activeElements = $$$1(container).children(Selector.ACTIVE);
3743 }
3744
3745 var active = activeElements[0];
3746 var isTransitioning = callback && Util.supportsTransitionEnd() && active && $$$1(active).hasClass(ClassName.FADE);
3747
3748 var complete = function complete() {
3749 return _this2._transitionComplete(element, active, callback);
3750 };
3751
3752 if (active && isTransitioning) {
3753 $$$1(active).one(Util.TRANSITION_END, complete).emulateTransitionEnd(TRANSITION_DURATION);
3754 } else {
3755 complete();
3756 }
3757 };
3758
3759 _proto._transitionComplete = function _transitionComplete(element, active, callback) {
3760 if (active) {
3761 $$$1(active).removeClass(ClassName.SHOW + " " + ClassName.ACTIVE);
3762 var dropdownChild = $$$1(active.parentNode).find(Selector.DROPDOWN_ACTIVE_CHILD)[0];
3763
3764 if (dropdownChild) {
3765 $$$1(dropdownChild).removeClass(ClassName.ACTIVE);
3766 }
3767
3768 if (active.getAttribute('role') === 'tab') {
3769 active.setAttribute('aria-selected', false);
3770 }
3771 }
3772
3773 $$$1(element).addClass(ClassName.ACTIVE);
3774
3775 if (element.getAttribute('role') === 'tab') {
3776 element.setAttribute('aria-selected', true);
3777 }
3778
3779 Util.reflow(element);
3780 $$$1(element).addClass(ClassName.SHOW);
3781
3782 if (element.parentNode && $$$1(element.parentNode).hasClass(ClassName.DROPDOWN_MENU)) {
3783 var dropdownElement = $$$1(element).closest(Selector.DROPDOWN)[0];
3784
3785 if (dropdownElement) {
3786 $$$1(dropdownElement).find(Selector.DROPDOWN_TOGGLE).addClass(ClassName.ACTIVE);
3787 }
3788
3789 element.setAttribute('aria-expanded', true);
3790 }
3791
3792 if (callback) {
3793 callback();
3794 }
3795 };
3796
3797
3798 Tab._jQueryInterface = function _jQueryInterface(config) {
3799 return this.each(function () {
3800 var $this = $$$1(this);
3801 var data = $this.data(DATA_KEY);
3802
3803 if (!data) {
3804 data = new Tab(this);
3805 $this.data(DATA_KEY, data);
3806 }
3807
3808 if (typeof config === 'string') {
3809 if (typeof data[config] === 'undefined') {
3810 throw new TypeError("No method named \"" + config + "\"");
3811 }
3812
3813 data[config]();
3814 }
3815 });
3816 };
3817
3818 _createClass(Tab, null, [{
3819 key: "VERSION",
3820 get: function get() {
3821 return VERSION;
3822 }
3823 }]);
3824 return Tab;
3825 }();
3826
3827
3828
3829
3830
3831
3832
3833 $$$1(document).on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, function (event) {
3834 event.preventDefault();
3835
3836 Tab._jQueryInterface.call($$$1(this), 'show');
3837 });
3838
3839
3840
3841
3842
3843
3844 $$$1.fn[NAME] = Tab._jQueryInterface;
3845 $$$1.fn[NAME].Constructor = Tab;
3846
3847 $$$1.fn[NAME].noConflict = function () {
3848 $$$1.fn[NAME] = JQUERY_NO_CONFLICT;
3849 return Tab._jQueryInterface;
3850 };
3851
3852 return Tab;
3853 }($);
3854
3855
3856
3857
3858
3859
3860
3861
3862 (function ($$$1) {
3863 if (typeof $$$1 === 'undefined') {
3864 throw new TypeError('Bootstrap\'s JavaScript requires jQuery. jQuery must be included before Bootstrap\'s JavaScript.');
3865 }
3866
3867 var version = $$$1.fn.jquery.split(' ')[0].split('.');
3868 var minMajor = 1;
3869 var ltMajor = 2;
3870 var minMinor = 9;
3871 var minPatch = 1;
3872 var maxMajor = 4;
3873
3874 if (version[0] < ltMajor && version[1] < minMinor || version[0] === minMajor && version[1] === minMinor && version[2] < minPatch || version[0] >= maxMajor) {
3875 throw new Error('Bootstrap\'s JavaScript requires at least jQuery v1.9.1 but less than v4.0.0');
3876 }
3877 })($);
3878
3879 exports.Util = Util;
3880 exports.Alert = Alert;
3881 exports.Button = Button;
3882 exports.Carousel = Carousel;
3883 exports.Collapse = Collapse;
3884 exports.Dropdown = Dropdown;
3885 exports.Modal = Modal;
3886 exports.Popover = Popover;
3887 exports.Scrollspy = ScrollSpy;
3888 exports.Tab = Tab;
3889 exports.Tooltip = Tooltip;
3890
3891 Object.defineProperty(exports, '__esModule', { value: true });
3892
3893 })));
3894