LaravelTest

Форк
0
4357 строк · 134.4 Кб
1
/*!
2
  * Bootstrap v4.6.1 (https://getbootstrap.com/)
3
  * Copyright 2011-2021 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
4
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
5
  */
6
(function (global, factory) {
7
  typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('jquery'), require('popper.js')) :
8
  typeof define === 'function' && define.amd ? define(['exports', 'jquery', 'popper.js'], factory) :
9
  (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.bootstrap = {}, global.jQuery, global.Popper));
10
})(this, (function (exports, $, Popper) { 'use strict';
11

12
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
13

14
  var $__default = /*#__PURE__*/_interopDefaultLegacy($);
15
  var Popper__default = /*#__PURE__*/_interopDefaultLegacy(Popper);
16

17
  function _defineProperties(target, props) {
18
    for (var i = 0; i < props.length; i++) {
19
      var descriptor = props[i];
20
      descriptor.enumerable = descriptor.enumerable || false;
21
      descriptor.configurable = true;
22
      if ("value" in descriptor) descriptor.writable = true;
23
      Object.defineProperty(target, descriptor.key, descriptor);
24
    }
25
  }
26

27
  function _createClass(Constructor, protoProps, staticProps) {
28
    if (protoProps) _defineProperties(Constructor.prototype, protoProps);
29
    if (staticProps) _defineProperties(Constructor, staticProps);
30
    return Constructor;
31
  }
32

33
  function _extends() {
34
    _extends = Object.assign || function (target) {
35
      for (var i = 1; i < arguments.length; i++) {
36
        var source = arguments[i];
37

38
        for (var key in source) {
39
          if (Object.prototype.hasOwnProperty.call(source, key)) {
40
            target[key] = source[key];
41
          }
42
        }
43
      }
44

45
      return target;
46
    };
47

48
    return _extends.apply(this, arguments);
49
  }
50

51
  function _inheritsLoose(subClass, superClass) {
52
    subClass.prototype = Object.create(superClass.prototype);
53
    subClass.prototype.constructor = subClass;
54

55
    _setPrototypeOf(subClass, superClass);
56
  }
57

58
  function _setPrototypeOf(o, p) {
59
    _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
60
      o.__proto__ = p;
61
      return o;
62
    };
63

64
    return _setPrototypeOf(o, p);
65
  }
66

67
  /**
68
   * --------------------------------------------------------------------------
69
   * Bootstrap (v4.6.1): util.js
70
   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
71
   * --------------------------------------------------------------------------
72
   */
73
  /**
74
   * Private TransitionEnd Helpers
75
   */
76

77
  var TRANSITION_END = 'transitionend';
78
  var MAX_UID = 1000000;
79
  var MILLISECONDS_MULTIPLIER = 1000; // Shoutout AngusCroll (https://goo.gl/pxwQGp)
80

81
  function toType(obj) {
82
    if (obj === null || typeof obj === 'undefined') {
83
      return "" + obj;
84
    }
85

86
    return {}.toString.call(obj).match(/\s([a-z]+)/i)[1].toLowerCase();
87
  }
88

89
  function getSpecialTransitionEndEvent() {
90
    return {
91
      bindType: TRANSITION_END,
92
      delegateType: TRANSITION_END,
93
      handle: function handle(event) {
94
        if ($__default["default"](event.target).is(this)) {
95
          return event.handleObj.handler.apply(this, arguments); // eslint-disable-line prefer-rest-params
96
        }
97

98
        return undefined;
99
      }
100
    };
101
  }
102

103
  function transitionEndEmulator(duration) {
104
    var _this = this;
105

106
    var called = false;
107
    $__default["default"](this).one(Util.TRANSITION_END, function () {
108
      called = true;
109
    });
110
    setTimeout(function () {
111
      if (!called) {
112
        Util.triggerTransitionEnd(_this);
113
      }
114
    }, duration);
115
    return this;
116
  }
117

118
  function setTransitionEndSupport() {
119
    $__default["default"].fn.emulateTransitionEnd = transitionEndEmulator;
120
    $__default["default"].event.special[Util.TRANSITION_END] = getSpecialTransitionEndEvent();
121
  }
122
  /**
123
   * Public Util API
124
   */
125

126

127
  var Util = {
128
    TRANSITION_END: 'bsTransitionEnd',
129
    getUID: function getUID(prefix) {
130
      do {
131
        // eslint-disable-next-line no-bitwise
132
        prefix += ~~(Math.random() * MAX_UID); // "~~" acts like a faster Math.floor() here
133
      } while (document.getElementById(prefix));
134

135
      return prefix;
136
    },
137
    getSelectorFromElement: function getSelectorFromElement(element) {
138
      var selector = element.getAttribute('data-target');
139

140
      if (!selector || selector === '#') {
141
        var hrefAttr = element.getAttribute('href');
142
        selector = hrefAttr && hrefAttr !== '#' ? hrefAttr.trim() : '';
143
      }
144

145
      try {
146
        return document.querySelector(selector) ? selector : null;
147
      } catch (_) {
148
        return null;
149
      }
150
    },
151
    getTransitionDurationFromElement: function getTransitionDurationFromElement(element) {
152
      if (!element) {
153
        return 0;
154
      } // Get transition-duration of the element
155

156

157
      var transitionDuration = $__default["default"](element).css('transition-duration');
158
      var transitionDelay = $__default["default"](element).css('transition-delay');
159
      var floatTransitionDuration = parseFloat(transitionDuration);
160
      var floatTransitionDelay = parseFloat(transitionDelay); // Return 0 if element or transition duration is not found
161

162
      if (!floatTransitionDuration && !floatTransitionDelay) {
163
        return 0;
164
      } // If multiple durations are defined, take the first
165

166

167
      transitionDuration = transitionDuration.split(',')[0];
168
      transitionDelay = transitionDelay.split(',')[0];
169
      return (parseFloat(transitionDuration) + parseFloat(transitionDelay)) * MILLISECONDS_MULTIPLIER;
170
    },
171
    reflow: function reflow(element) {
172
      return element.offsetHeight;
173
    },
174
    triggerTransitionEnd: function triggerTransitionEnd(element) {
175
      $__default["default"](element).trigger(TRANSITION_END);
176
    },
177
    supportsTransitionEnd: function supportsTransitionEnd() {
178
      return Boolean(TRANSITION_END);
179
    },
180
    isElement: function isElement(obj) {
181
      return (obj[0] || obj).nodeType;
182
    },
183
    typeCheckConfig: function typeCheckConfig(componentName, config, configTypes) {
184
      for (var property in configTypes) {
185
        if (Object.prototype.hasOwnProperty.call(configTypes, property)) {
186
          var expectedTypes = configTypes[property];
187
          var value = config[property];
188
          var valueType = value && Util.isElement(value) ? 'element' : toType(value);
189

190
          if (!new RegExp(expectedTypes).test(valueType)) {
191
            throw new Error(componentName.toUpperCase() + ": " + ("Option \"" + property + "\" provided type \"" + valueType + "\" ") + ("but expected type \"" + expectedTypes + "\"."));
192
          }
193
        }
194
      }
195
    },
196
    findShadowRoot: function findShadowRoot(element) {
197
      if (!document.documentElement.attachShadow) {
198
        return null;
199
      } // Can find the shadow root otherwise it'll return the document
200

201

202
      if (typeof element.getRootNode === 'function') {
203
        var root = element.getRootNode();
204
        return root instanceof ShadowRoot ? root : null;
205
      }
206

207
      if (element instanceof ShadowRoot) {
208
        return element;
209
      } // when we don't find a shadow root
210

211

212
      if (!element.parentNode) {
213
        return null;
214
      }
215

216
      return Util.findShadowRoot(element.parentNode);
217
    },
218
    jQueryDetection: function jQueryDetection() {
219
      if (typeof $__default["default"] === 'undefined') {
220
        throw new TypeError('Bootstrap\'s JavaScript requires jQuery. jQuery must be included before Bootstrap\'s JavaScript.');
221
      }
222

223
      var version = $__default["default"].fn.jquery.split(' ')[0].split('.');
224
      var minMajor = 1;
225
      var ltMajor = 2;
226
      var minMinor = 9;
227
      var minPatch = 1;
228
      var maxMajor = 4;
229

230
      if (version[0] < ltMajor && version[1] < minMinor || version[0] === minMajor && version[1] === minMinor && version[2] < minPatch || version[0] >= maxMajor) {
231
        throw new Error('Bootstrap\'s JavaScript requires at least jQuery v1.9.1 but less than v4.0.0');
232
      }
233
    }
234
  };
235
  Util.jQueryDetection();
236
  setTransitionEndSupport();
237

238
  /**
239
   * Constants
240
   */
241

242
  var NAME$a = 'alert';
243
  var VERSION$a = '4.6.1';
244
  var DATA_KEY$a = 'bs.alert';
245
  var EVENT_KEY$a = "." + DATA_KEY$a;
246
  var DATA_API_KEY$7 = '.data-api';
247
  var JQUERY_NO_CONFLICT$a = $__default["default"].fn[NAME$a];
248
  var CLASS_NAME_ALERT = 'alert';
249
  var CLASS_NAME_FADE$5 = 'fade';
250
  var CLASS_NAME_SHOW$7 = 'show';
251
  var EVENT_CLOSE = "close" + EVENT_KEY$a;
252
  var EVENT_CLOSED = "closed" + EVENT_KEY$a;
253
  var EVENT_CLICK_DATA_API$6 = "click" + EVENT_KEY$a + DATA_API_KEY$7;
254
  var SELECTOR_DISMISS = '[data-dismiss="alert"]';
255
  /**
256
   * Class definition
257
   */
258

259
  var Alert = /*#__PURE__*/function () {
260
    function Alert(element) {
261
      this._element = element;
262
    } // Getters
263

264

265
    var _proto = Alert.prototype;
266

267
    // Public
268
    _proto.close = function close(element) {
269
      var rootElement = this._element;
270

271
      if (element) {
272
        rootElement = this._getRootElement(element);
273
      }
274

275
      var customEvent = this._triggerCloseEvent(rootElement);
276

277
      if (customEvent.isDefaultPrevented()) {
278
        return;
279
      }
280

281
      this._removeElement(rootElement);
282
    };
283

284
    _proto.dispose = function dispose() {
285
      $__default["default"].removeData(this._element, DATA_KEY$a);
286
      this._element = null;
287
    } // Private
288
    ;
289

290
    _proto._getRootElement = function _getRootElement(element) {
291
      var selector = Util.getSelectorFromElement(element);
292
      var parent = false;
293

294
      if (selector) {
295
        parent = document.querySelector(selector);
296
      }
297

298
      if (!parent) {
299
        parent = $__default["default"](element).closest("." + CLASS_NAME_ALERT)[0];
300
      }
301

302
      return parent;
303
    };
304

305
    _proto._triggerCloseEvent = function _triggerCloseEvent(element) {
306
      var closeEvent = $__default["default"].Event(EVENT_CLOSE);
307
      $__default["default"](element).trigger(closeEvent);
308
      return closeEvent;
309
    };
310

311
    _proto._removeElement = function _removeElement(element) {
312
      var _this = this;
313

314
      $__default["default"](element).removeClass(CLASS_NAME_SHOW$7);
315

316
      if (!$__default["default"](element).hasClass(CLASS_NAME_FADE$5)) {
317
        this._destroyElement(element);
318

319
        return;
320
      }
321

322
      var transitionDuration = Util.getTransitionDurationFromElement(element);
323
      $__default["default"](element).one(Util.TRANSITION_END, function (event) {
324
        return _this._destroyElement(element, event);
325
      }).emulateTransitionEnd(transitionDuration);
326
    };
327

328
    _proto._destroyElement = function _destroyElement(element) {
329
      $__default["default"](element).detach().trigger(EVENT_CLOSED).remove();
330
    } // Static
331
    ;
332

333
    Alert._jQueryInterface = function _jQueryInterface(config) {
334
      return this.each(function () {
335
        var $element = $__default["default"](this);
336
        var data = $element.data(DATA_KEY$a);
337

338
        if (!data) {
339
          data = new Alert(this);
340
          $element.data(DATA_KEY$a, data);
341
        }
342

343
        if (config === 'close') {
344
          data[config](this);
345
        }
346
      });
347
    };
348

349
    Alert._handleDismiss = function _handleDismiss(alertInstance) {
350
      return function (event) {
351
        if (event) {
352
          event.preventDefault();
353
        }
354

355
        alertInstance.close(this);
356
      };
357
    };
358

359
    _createClass(Alert, null, [{
360
      key: "VERSION",
361
      get: function get() {
362
        return VERSION$a;
363
      }
364
    }]);
365

366
    return Alert;
367
  }();
368
  /**
369
   * Data API implementation
370
   */
371

372

373
  $__default["default"](document).on(EVENT_CLICK_DATA_API$6, SELECTOR_DISMISS, Alert._handleDismiss(new Alert()));
374
  /**
375
   * jQuery
376
   */
377

378
  $__default["default"].fn[NAME$a] = Alert._jQueryInterface;
379
  $__default["default"].fn[NAME$a].Constructor = Alert;
380

381
  $__default["default"].fn[NAME$a].noConflict = function () {
382
    $__default["default"].fn[NAME$a] = JQUERY_NO_CONFLICT$a;
383
    return Alert._jQueryInterface;
384
  };
385

386
  /**
387
   * Constants
388
   */
389

390
  var NAME$9 = 'button';
391
  var VERSION$9 = '4.6.1';
392
  var DATA_KEY$9 = 'bs.button';
393
  var EVENT_KEY$9 = "." + DATA_KEY$9;
394
  var DATA_API_KEY$6 = '.data-api';
395
  var JQUERY_NO_CONFLICT$9 = $__default["default"].fn[NAME$9];
396
  var CLASS_NAME_ACTIVE$3 = 'active';
397
  var CLASS_NAME_BUTTON = 'btn';
398
  var CLASS_NAME_FOCUS = 'focus';
399
  var EVENT_CLICK_DATA_API$5 = "click" + EVENT_KEY$9 + DATA_API_KEY$6;
400
  var EVENT_FOCUS_BLUR_DATA_API = "focus" + EVENT_KEY$9 + DATA_API_KEY$6 + " " + ("blur" + EVENT_KEY$9 + DATA_API_KEY$6);
401
  var EVENT_LOAD_DATA_API$2 = "load" + EVENT_KEY$9 + DATA_API_KEY$6;
402
  var SELECTOR_DATA_TOGGLE_CARROT = '[data-toggle^="button"]';
403
  var SELECTOR_DATA_TOGGLES = '[data-toggle="buttons"]';
404
  var SELECTOR_DATA_TOGGLE$4 = '[data-toggle="button"]';
405
  var SELECTOR_DATA_TOGGLES_BUTTONS = '[data-toggle="buttons"] .btn';
406
  var SELECTOR_INPUT = 'input:not([type="hidden"])';
407
  var SELECTOR_ACTIVE$2 = '.active';
408
  var SELECTOR_BUTTON = '.btn';
409
  /**
410
   * Class definition
411
   */
412

413
  var Button = /*#__PURE__*/function () {
414
    function Button(element) {
415
      this._element = element;
416
      this.shouldAvoidTriggerChange = false;
417
    } // Getters
418

419

420
    var _proto = Button.prototype;
421

422
    // Public
423
    _proto.toggle = function toggle() {
424
      var triggerChangeEvent = true;
425
      var addAriaPressed = true;
426
      var rootElement = $__default["default"](this._element).closest(SELECTOR_DATA_TOGGLES)[0];
427

428
      if (rootElement) {
429
        var input = this._element.querySelector(SELECTOR_INPUT);
430

431
        if (input) {
432
          if (input.type === 'radio') {
433
            if (input.checked && this._element.classList.contains(CLASS_NAME_ACTIVE$3)) {
434
              triggerChangeEvent = false;
435
            } else {
436
              var activeElement = rootElement.querySelector(SELECTOR_ACTIVE$2);
437

438
              if (activeElement) {
439
                $__default["default"](activeElement).removeClass(CLASS_NAME_ACTIVE$3);
440
              }
441
            }
442
          }
443

444
          if (triggerChangeEvent) {
445
            // if it's not a radio button or checkbox don't add a pointless/invalid checked property to the input
446
            if (input.type === 'checkbox' || input.type === 'radio') {
447
              input.checked = !this._element.classList.contains(CLASS_NAME_ACTIVE$3);
448
            }
449

450
            if (!this.shouldAvoidTriggerChange) {
451
              $__default["default"](input).trigger('change');
452
            }
453
          }
454

455
          input.focus();
456
          addAriaPressed = false;
457
        }
458
      }
459

460
      if (!(this._element.hasAttribute('disabled') || this._element.classList.contains('disabled'))) {
461
        if (addAriaPressed) {
462
          this._element.setAttribute('aria-pressed', !this._element.classList.contains(CLASS_NAME_ACTIVE$3));
463
        }
464

465
        if (triggerChangeEvent) {
466
          $__default["default"](this._element).toggleClass(CLASS_NAME_ACTIVE$3);
467
        }
468
      }
469
    };
470

471
    _proto.dispose = function dispose() {
472
      $__default["default"].removeData(this._element, DATA_KEY$9);
473
      this._element = null;
474
    } // Static
475
    ;
476

477
    Button._jQueryInterface = function _jQueryInterface(config, avoidTriggerChange) {
478
      return this.each(function () {
479
        var $element = $__default["default"](this);
480
        var data = $element.data(DATA_KEY$9);
481

482
        if (!data) {
483
          data = new Button(this);
484
          $element.data(DATA_KEY$9, data);
485
        }
486

487
        data.shouldAvoidTriggerChange = avoidTriggerChange;
488

489
        if (config === 'toggle') {
490
          data[config]();
491
        }
492
      });
493
    };
494

495
    _createClass(Button, null, [{
496
      key: "VERSION",
497
      get: function get() {
498
        return VERSION$9;
499
      }
500
    }]);
501

502
    return Button;
503
  }();
504
  /**
505
   * Data API implementation
506
   */
507

508

509
  $__default["default"](document).on(EVENT_CLICK_DATA_API$5, SELECTOR_DATA_TOGGLE_CARROT, function (event) {
510
    var button = event.target;
511
    var initialButton = button;
512

513
    if (!$__default["default"](button).hasClass(CLASS_NAME_BUTTON)) {
514
      button = $__default["default"](button).closest(SELECTOR_BUTTON)[0];
515
    }
516

517
    if (!button || button.hasAttribute('disabled') || button.classList.contains('disabled')) {
518
      event.preventDefault(); // work around Firefox bug #1540995
519
    } else {
520
      var inputBtn = button.querySelector(SELECTOR_INPUT);
521

522
      if (inputBtn && (inputBtn.hasAttribute('disabled') || inputBtn.classList.contains('disabled'))) {
523
        event.preventDefault(); // work around Firefox bug #1540995
524

525
        return;
526
      }
527

528
      if (initialButton.tagName === 'INPUT' || button.tagName !== 'LABEL') {
529
        Button._jQueryInterface.call($__default["default"](button), 'toggle', initialButton.tagName === 'INPUT');
530
      }
531
    }
532
  }).on(EVENT_FOCUS_BLUR_DATA_API, SELECTOR_DATA_TOGGLE_CARROT, function (event) {
533
    var button = $__default["default"](event.target).closest(SELECTOR_BUTTON)[0];
534
    $__default["default"](button).toggleClass(CLASS_NAME_FOCUS, /^focus(in)?$/.test(event.type));
535
  });
536
  $__default["default"](window).on(EVENT_LOAD_DATA_API$2, function () {
537
    // ensure correct active class is set to match the controls' actual values/states
538
    // find all checkboxes/readio buttons inside data-toggle groups
539
    var buttons = [].slice.call(document.querySelectorAll(SELECTOR_DATA_TOGGLES_BUTTONS));
540

541
    for (var i = 0, len = buttons.length; i < len; i++) {
542
      var button = buttons[i];
543
      var input = button.querySelector(SELECTOR_INPUT);
544

545
      if (input.checked || input.hasAttribute('checked')) {
546
        button.classList.add(CLASS_NAME_ACTIVE$3);
547
      } else {
548
        button.classList.remove(CLASS_NAME_ACTIVE$3);
549
      }
550
    } // find all button toggles
551

552

553
    buttons = [].slice.call(document.querySelectorAll(SELECTOR_DATA_TOGGLE$4));
554

555
    for (var _i = 0, _len = buttons.length; _i < _len; _i++) {
556
      var _button = buttons[_i];
557

558
      if (_button.getAttribute('aria-pressed') === 'true') {
559
        _button.classList.add(CLASS_NAME_ACTIVE$3);
560
      } else {
561
        _button.classList.remove(CLASS_NAME_ACTIVE$3);
562
      }
563
    }
564
  });
565
  /**
566
   * jQuery
567
   */
568

569
  $__default["default"].fn[NAME$9] = Button._jQueryInterface;
570
  $__default["default"].fn[NAME$9].Constructor = Button;
571

572
  $__default["default"].fn[NAME$9].noConflict = function () {
573
    $__default["default"].fn[NAME$9] = JQUERY_NO_CONFLICT$9;
574
    return Button._jQueryInterface;
575
  };
576

577
  /**
578
   * Constants
579
   */
580

581
  var NAME$8 = 'carousel';
582
  var VERSION$8 = '4.6.1';
583
  var DATA_KEY$8 = 'bs.carousel';
584
  var EVENT_KEY$8 = "." + DATA_KEY$8;
585
  var DATA_API_KEY$5 = '.data-api';
586
  var JQUERY_NO_CONFLICT$8 = $__default["default"].fn[NAME$8];
587
  var ARROW_LEFT_KEYCODE = 37; // KeyboardEvent.which value for left arrow key
588

589
  var ARROW_RIGHT_KEYCODE = 39; // KeyboardEvent.which value for right arrow key
590

591
  var TOUCHEVENT_COMPAT_WAIT = 500; // Time for mouse compat events to fire after touch
592

593
  var SWIPE_THRESHOLD = 40;
594
  var CLASS_NAME_CAROUSEL = 'carousel';
595
  var CLASS_NAME_ACTIVE$2 = 'active';
596
  var CLASS_NAME_SLIDE = 'slide';
597
  var CLASS_NAME_RIGHT = 'carousel-item-right';
598
  var CLASS_NAME_LEFT = 'carousel-item-left';
599
  var CLASS_NAME_NEXT = 'carousel-item-next';
600
  var CLASS_NAME_PREV = 'carousel-item-prev';
601
  var CLASS_NAME_POINTER_EVENT = 'pointer-event';
602
  var DIRECTION_NEXT = 'next';
603
  var DIRECTION_PREV = 'prev';
604
  var DIRECTION_LEFT = 'left';
605
  var DIRECTION_RIGHT = 'right';
606
  var EVENT_SLIDE = "slide" + EVENT_KEY$8;
607
  var EVENT_SLID = "slid" + EVENT_KEY$8;
608
  var EVENT_KEYDOWN = "keydown" + EVENT_KEY$8;
609
  var EVENT_MOUSEENTER = "mouseenter" + EVENT_KEY$8;
610
  var EVENT_MOUSELEAVE = "mouseleave" + EVENT_KEY$8;
611
  var EVENT_TOUCHSTART = "touchstart" + EVENT_KEY$8;
612
  var EVENT_TOUCHMOVE = "touchmove" + EVENT_KEY$8;
613
  var EVENT_TOUCHEND = "touchend" + EVENT_KEY$8;
614
  var EVENT_POINTERDOWN = "pointerdown" + EVENT_KEY$8;
615
  var EVENT_POINTERUP = "pointerup" + EVENT_KEY$8;
616
  var EVENT_DRAG_START = "dragstart" + EVENT_KEY$8;
617
  var EVENT_LOAD_DATA_API$1 = "load" + EVENT_KEY$8 + DATA_API_KEY$5;
618
  var EVENT_CLICK_DATA_API$4 = "click" + EVENT_KEY$8 + DATA_API_KEY$5;
619
  var SELECTOR_ACTIVE$1 = '.active';
620
  var SELECTOR_ACTIVE_ITEM = '.active.carousel-item';
621
  var SELECTOR_ITEM = '.carousel-item';
622
  var SELECTOR_ITEM_IMG = '.carousel-item img';
623
  var SELECTOR_NEXT_PREV = '.carousel-item-next, .carousel-item-prev';
624
  var SELECTOR_INDICATORS = '.carousel-indicators';
625
  var SELECTOR_DATA_SLIDE = '[data-slide], [data-slide-to]';
626
  var SELECTOR_DATA_RIDE = '[data-ride="carousel"]';
627
  var Default$7 = {
628
    interval: 5000,
629
    keyboard: true,
630
    slide: false,
631
    pause: 'hover',
632
    wrap: true,
633
    touch: true
634
  };
635
  var DefaultType$7 = {
636
    interval: '(number|boolean)',
637
    keyboard: 'boolean',
638
    slide: '(boolean|string)',
639
    pause: '(string|boolean)',
640
    wrap: 'boolean',
641
    touch: 'boolean'
642
  };
643
  var PointerType = {
644
    TOUCH: 'touch',
645
    PEN: 'pen'
646
  };
647
  /**
648
   * Class definition
649
   */
650

651
  var Carousel = /*#__PURE__*/function () {
652
    function Carousel(element, config) {
653
      this._items = null;
654
      this._interval = null;
655
      this._activeElement = null;
656
      this._isPaused = false;
657
      this._isSliding = false;
658
      this.touchTimeout = null;
659
      this.touchStartX = 0;
660
      this.touchDeltaX = 0;
661
      this._config = this._getConfig(config);
662
      this._element = element;
663
      this._indicatorsElement = this._element.querySelector(SELECTOR_INDICATORS);
664
      this._touchSupported = 'ontouchstart' in document.documentElement || navigator.maxTouchPoints > 0;
665
      this._pointerEvent = Boolean(window.PointerEvent || window.MSPointerEvent);
666

667
      this._addEventListeners();
668
    } // Getters
669

670

671
    var _proto = Carousel.prototype;
672

673
    // Public
674
    _proto.next = function next() {
675
      if (!this._isSliding) {
676
        this._slide(DIRECTION_NEXT);
677
      }
678
    };
679

680
    _proto.nextWhenVisible = function nextWhenVisible() {
681
      var $element = $__default["default"](this._element); // Don't call next when the page isn't visible
682
      // or the carousel or its parent isn't visible
683

684
      if (!document.hidden && $element.is(':visible') && $element.css('visibility') !== 'hidden') {
685
        this.next();
686
      }
687
    };
688

689
    _proto.prev = function prev() {
690
      if (!this._isSliding) {
691
        this._slide(DIRECTION_PREV);
692
      }
693
    };
694

695
    _proto.pause = function pause(event) {
696
      if (!event) {
697
        this._isPaused = true;
698
      }
699

700
      if (this._element.querySelector(SELECTOR_NEXT_PREV)) {
701
        Util.triggerTransitionEnd(this._element);
702
        this.cycle(true);
703
      }
704

705
      clearInterval(this._interval);
706
      this._interval = null;
707
    };
708

709
    _proto.cycle = function cycle(event) {
710
      if (!event) {
711
        this._isPaused = false;
712
      }
713

714
      if (this._interval) {
715
        clearInterval(this._interval);
716
        this._interval = null;
717
      }
718

719
      if (this._config.interval && !this._isPaused) {
720
        this._updateInterval();
721

722
        this._interval = setInterval((document.visibilityState ? this.nextWhenVisible : this.next).bind(this), this._config.interval);
723
      }
724
    };
725

726
    _proto.to = function to(index) {
727
      var _this = this;
728

729
      this._activeElement = this._element.querySelector(SELECTOR_ACTIVE_ITEM);
730

731
      var activeIndex = this._getItemIndex(this._activeElement);
732

733
      if (index > this._items.length - 1 || index < 0) {
734
        return;
735
      }
736

737
      if (this._isSliding) {
738
        $__default["default"](this._element).one(EVENT_SLID, function () {
739
          return _this.to(index);
740
        });
741
        return;
742
      }
743

744
      if (activeIndex === index) {
745
        this.pause();
746
        this.cycle();
747
        return;
748
      }
749

750
      var direction = index > activeIndex ? DIRECTION_NEXT : DIRECTION_PREV;
751

752
      this._slide(direction, this._items[index]);
753
    };
754

755
    _proto.dispose = function dispose() {
756
      $__default["default"](this._element).off(EVENT_KEY$8);
757
      $__default["default"].removeData(this._element, DATA_KEY$8);
758
      this._items = null;
759
      this._config = null;
760
      this._element = null;
761
      this._interval = null;
762
      this._isPaused = null;
763
      this._isSliding = null;
764
      this._activeElement = null;
765
      this._indicatorsElement = null;
766
    } // Private
767
    ;
768

769
    _proto._getConfig = function _getConfig(config) {
770
      config = _extends({}, Default$7, config);
771
      Util.typeCheckConfig(NAME$8, config, DefaultType$7);
772
      return config;
773
    };
774

775
    _proto._handleSwipe = function _handleSwipe() {
776
      var absDeltax = Math.abs(this.touchDeltaX);
777

778
      if (absDeltax <= SWIPE_THRESHOLD) {
779
        return;
780
      }
781

782
      var direction = absDeltax / this.touchDeltaX;
783
      this.touchDeltaX = 0; // swipe left
784

785
      if (direction > 0) {
786
        this.prev();
787
      } // swipe right
788

789

790
      if (direction < 0) {
791
        this.next();
792
      }
793
    };
794

795
    _proto._addEventListeners = function _addEventListeners() {
796
      var _this2 = this;
797

798
      if (this._config.keyboard) {
799
        $__default["default"](this._element).on(EVENT_KEYDOWN, function (event) {
800
          return _this2._keydown(event);
801
        });
802
      }
803

804
      if (this._config.pause === 'hover') {
805
        $__default["default"](this._element).on(EVENT_MOUSEENTER, function (event) {
806
          return _this2.pause(event);
807
        }).on(EVENT_MOUSELEAVE, function (event) {
808
          return _this2.cycle(event);
809
        });
810
      }
811

812
      if (this._config.touch) {
813
        this._addTouchEventListeners();
814
      }
815
    };
816

817
    _proto._addTouchEventListeners = function _addTouchEventListeners() {
818
      var _this3 = this;
819

820
      if (!this._touchSupported) {
821
        return;
822
      }
823

824
      var start = function start(event) {
825
        if (_this3._pointerEvent && PointerType[event.originalEvent.pointerType.toUpperCase()]) {
826
          _this3.touchStartX = event.originalEvent.clientX;
827
        } else if (!_this3._pointerEvent) {
828
          _this3.touchStartX = event.originalEvent.touches[0].clientX;
829
        }
830
      };
831

832
      var move = function move(event) {
833
        // ensure swiping with one touch and not pinching
834
        _this3.touchDeltaX = event.originalEvent.touches && event.originalEvent.touches.length > 1 ? 0 : event.originalEvent.touches[0].clientX - _this3.touchStartX;
835
      };
836

837
      var end = function end(event) {
838
        if (_this3._pointerEvent && PointerType[event.originalEvent.pointerType.toUpperCase()]) {
839
          _this3.touchDeltaX = event.originalEvent.clientX - _this3.touchStartX;
840
        }
841

842
        _this3._handleSwipe();
843

844
        if (_this3._config.pause === 'hover') {
845
          // If it's a touch-enabled device, mouseenter/leave are fired as
846
          // part of the mouse compatibility events on first tap - the carousel
847
          // would stop cycling until user tapped out of it;
848
          // here, we listen for touchend, explicitly pause the carousel
849
          // (as if it's the second time we tap on it, mouseenter compat event
850
          // is NOT fired) and after a timeout (to allow for mouse compatibility
851
          // events to fire) we explicitly restart cycling
852
          _this3.pause();
853

854
          if (_this3.touchTimeout) {
855
            clearTimeout(_this3.touchTimeout);
856
          }
857

858
          _this3.touchTimeout = setTimeout(function (event) {
859
            return _this3.cycle(event);
860
          }, TOUCHEVENT_COMPAT_WAIT + _this3._config.interval);
861
        }
862
      };
863

864
      $__default["default"](this._element.querySelectorAll(SELECTOR_ITEM_IMG)).on(EVENT_DRAG_START, function (e) {
865
        return e.preventDefault();
866
      });
867

868
      if (this._pointerEvent) {
869
        $__default["default"](this._element).on(EVENT_POINTERDOWN, function (event) {
870
          return start(event);
871
        });
872
        $__default["default"](this._element).on(EVENT_POINTERUP, function (event) {
873
          return end(event);
874
        });
875

876
        this._element.classList.add(CLASS_NAME_POINTER_EVENT);
877
      } else {
878
        $__default["default"](this._element).on(EVENT_TOUCHSTART, function (event) {
879
          return start(event);
880
        });
881
        $__default["default"](this._element).on(EVENT_TOUCHMOVE, function (event) {
882
          return move(event);
883
        });
884
        $__default["default"](this._element).on(EVENT_TOUCHEND, function (event) {
885
          return end(event);
886
        });
887
      }
888
    };
889

890
    _proto._keydown = function _keydown(event) {
891
      if (/input|textarea/i.test(event.target.tagName)) {
892
        return;
893
      }
894

895
      switch (event.which) {
896
        case ARROW_LEFT_KEYCODE:
897
          event.preventDefault();
898
          this.prev();
899
          break;
900

901
        case ARROW_RIGHT_KEYCODE:
902
          event.preventDefault();
903
          this.next();
904
          break;
905
      }
906
    };
907

908
    _proto._getItemIndex = function _getItemIndex(element) {
909
      this._items = element && element.parentNode ? [].slice.call(element.parentNode.querySelectorAll(SELECTOR_ITEM)) : [];
910
      return this._items.indexOf(element);
911
    };
912

913
    _proto._getItemByDirection = function _getItemByDirection(direction, activeElement) {
914
      var isNextDirection = direction === DIRECTION_NEXT;
915
      var isPrevDirection = direction === DIRECTION_PREV;
916

917
      var activeIndex = this._getItemIndex(activeElement);
918

919
      var lastItemIndex = this._items.length - 1;
920
      var isGoingToWrap = isPrevDirection && activeIndex === 0 || isNextDirection && activeIndex === lastItemIndex;
921

922
      if (isGoingToWrap && !this._config.wrap) {
923
        return activeElement;
924
      }
925

926
      var delta = direction === DIRECTION_PREV ? -1 : 1;
927
      var itemIndex = (activeIndex + delta) % this._items.length;
928
      return itemIndex === -1 ? this._items[this._items.length - 1] : this._items[itemIndex];
929
    };
930

931
    _proto._triggerSlideEvent = function _triggerSlideEvent(relatedTarget, eventDirectionName) {
932
      var targetIndex = this._getItemIndex(relatedTarget);
933

934
      var fromIndex = this._getItemIndex(this._element.querySelector(SELECTOR_ACTIVE_ITEM));
935

936
      var slideEvent = $__default["default"].Event(EVENT_SLIDE, {
937
        relatedTarget: relatedTarget,
938
        direction: eventDirectionName,
939
        from: fromIndex,
940
        to: targetIndex
941
      });
942
      $__default["default"](this._element).trigger(slideEvent);
943
      return slideEvent;
944
    };
945

946
    _proto._setActiveIndicatorElement = function _setActiveIndicatorElement(element) {
947
      if (this._indicatorsElement) {
948
        var indicators = [].slice.call(this._indicatorsElement.querySelectorAll(SELECTOR_ACTIVE$1));
949
        $__default["default"](indicators).removeClass(CLASS_NAME_ACTIVE$2);
950

951
        var nextIndicator = this._indicatorsElement.children[this._getItemIndex(element)];
952

953
        if (nextIndicator) {
954
          $__default["default"](nextIndicator).addClass(CLASS_NAME_ACTIVE$2);
955
        }
956
      }
957
    };
958

959
    _proto._updateInterval = function _updateInterval() {
960
      var element = this._activeElement || this._element.querySelector(SELECTOR_ACTIVE_ITEM);
961

962
      if (!element) {
963
        return;
964
      }
965

966
      var elementInterval = parseInt(element.getAttribute('data-interval'), 10);
967

968
      if (elementInterval) {
969
        this._config.defaultInterval = this._config.defaultInterval || this._config.interval;
970
        this._config.interval = elementInterval;
971
      } else {
972
        this._config.interval = this._config.defaultInterval || this._config.interval;
973
      }
974
    };
975

976
    _proto._slide = function _slide(direction, element) {
977
      var _this4 = this;
978

979
      var activeElement = this._element.querySelector(SELECTOR_ACTIVE_ITEM);
980

981
      var activeElementIndex = this._getItemIndex(activeElement);
982

983
      var nextElement = element || activeElement && this._getItemByDirection(direction, activeElement);
984

985
      var nextElementIndex = this._getItemIndex(nextElement);
986

987
      var isCycling = Boolean(this._interval);
988
      var directionalClassName;
989
      var orderClassName;
990
      var eventDirectionName;
991

992
      if (direction === DIRECTION_NEXT) {
993
        directionalClassName = CLASS_NAME_LEFT;
994
        orderClassName = CLASS_NAME_NEXT;
995
        eventDirectionName = DIRECTION_LEFT;
996
      } else {
997
        directionalClassName = CLASS_NAME_RIGHT;
998
        orderClassName = CLASS_NAME_PREV;
999
        eventDirectionName = DIRECTION_RIGHT;
1000
      }
1001

1002
      if (nextElement && $__default["default"](nextElement).hasClass(CLASS_NAME_ACTIVE$2)) {
1003
        this._isSliding = false;
1004
        return;
1005
      }
1006

1007
      var slideEvent = this._triggerSlideEvent(nextElement, eventDirectionName);
1008

1009
      if (slideEvent.isDefaultPrevented()) {
1010
        return;
1011
      }
1012

1013
      if (!activeElement || !nextElement) {
1014
        // Some weirdness is happening, so we bail
1015
        return;
1016
      }
1017

1018
      this._isSliding = true;
1019

1020
      if (isCycling) {
1021
        this.pause();
1022
      }
1023

1024
      this._setActiveIndicatorElement(nextElement);
1025

1026
      this._activeElement = nextElement;
1027
      var slidEvent = $__default["default"].Event(EVENT_SLID, {
1028
        relatedTarget: nextElement,
1029
        direction: eventDirectionName,
1030
        from: activeElementIndex,
1031
        to: nextElementIndex
1032
      });
1033

1034
      if ($__default["default"](this._element).hasClass(CLASS_NAME_SLIDE)) {
1035
        $__default["default"](nextElement).addClass(orderClassName);
1036
        Util.reflow(nextElement);
1037
        $__default["default"](activeElement).addClass(directionalClassName);
1038
        $__default["default"](nextElement).addClass(directionalClassName);
1039
        var transitionDuration = Util.getTransitionDurationFromElement(activeElement);
1040
        $__default["default"](activeElement).one(Util.TRANSITION_END, function () {
1041
          $__default["default"](nextElement).removeClass(directionalClassName + " " + orderClassName).addClass(CLASS_NAME_ACTIVE$2);
1042
          $__default["default"](activeElement).removeClass(CLASS_NAME_ACTIVE$2 + " " + orderClassName + " " + directionalClassName);
1043
          _this4._isSliding = false;
1044
          setTimeout(function () {
1045
            return $__default["default"](_this4._element).trigger(slidEvent);
1046
          }, 0);
1047
        }).emulateTransitionEnd(transitionDuration);
1048
      } else {
1049
        $__default["default"](activeElement).removeClass(CLASS_NAME_ACTIVE$2);
1050
        $__default["default"](nextElement).addClass(CLASS_NAME_ACTIVE$2);
1051
        this._isSliding = false;
1052
        $__default["default"](this._element).trigger(slidEvent);
1053
      }
1054

1055
      if (isCycling) {
1056
        this.cycle();
1057
      }
1058
    } // Static
1059
    ;
1060

1061
    Carousel._jQueryInterface = function _jQueryInterface(config) {
1062
      return this.each(function () {
1063
        var data = $__default["default"](this).data(DATA_KEY$8);
1064

1065
        var _config = _extends({}, Default$7, $__default["default"](this).data());
1066

1067
        if (typeof config === 'object') {
1068
          _config = _extends({}, _config, config);
1069
        }
1070

1071
        var action = typeof config === 'string' ? config : _config.slide;
1072

1073
        if (!data) {
1074
          data = new Carousel(this, _config);
1075
          $__default["default"](this).data(DATA_KEY$8, data);
1076
        }
1077

1078
        if (typeof config === 'number') {
1079
          data.to(config);
1080
        } else if (typeof action === 'string') {
1081
          if (typeof data[action] === 'undefined') {
1082
            throw new TypeError("No method named \"" + action + "\"");
1083
          }
1084

1085
          data[action]();
1086
        } else if (_config.interval && _config.ride) {
1087
          data.pause();
1088
          data.cycle();
1089
        }
1090
      });
1091
    };
1092

1093
    Carousel._dataApiClickHandler = function _dataApiClickHandler(event) {
1094
      var selector = Util.getSelectorFromElement(this);
1095

1096
      if (!selector) {
1097
        return;
1098
      }
1099

1100
      var target = $__default["default"](selector)[0];
1101

1102
      if (!target || !$__default["default"](target).hasClass(CLASS_NAME_CAROUSEL)) {
1103
        return;
1104
      }
1105

1106
      var config = _extends({}, $__default["default"](target).data(), $__default["default"](this).data());
1107

1108
      var slideIndex = this.getAttribute('data-slide-to');
1109

1110
      if (slideIndex) {
1111
        config.interval = false;
1112
      }
1113

1114
      Carousel._jQueryInterface.call($__default["default"](target), config);
1115

1116
      if (slideIndex) {
1117
        $__default["default"](target).data(DATA_KEY$8).to(slideIndex);
1118
      }
1119

1120
      event.preventDefault();
1121
    };
1122

1123
    _createClass(Carousel, null, [{
1124
      key: "VERSION",
1125
      get: function get() {
1126
        return VERSION$8;
1127
      }
1128
    }, {
1129
      key: "Default",
1130
      get: function get() {
1131
        return Default$7;
1132
      }
1133
    }]);
1134

1135
    return Carousel;
1136
  }();
1137
  /**
1138
   * Data API implementation
1139
   */
1140

1141

1142
  $__default["default"](document).on(EVENT_CLICK_DATA_API$4, SELECTOR_DATA_SLIDE, Carousel._dataApiClickHandler);
1143
  $__default["default"](window).on(EVENT_LOAD_DATA_API$1, function () {
1144
    var carousels = [].slice.call(document.querySelectorAll(SELECTOR_DATA_RIDE));
1145

1146
    for (var i = 0, len = carousels.length; i < len; i++) {
1147
      var $carousel = $__default["default"](carousels[i]);
1148

1149
      Carousel._jQueryInterface.call($carousel, $carousel.data());
1150
    }
1151
  });
1152
  /**
1153
   * jQuery
1154
   */
1155

1156
  $__default["default"].fn[NAME$8] = Carousel._jQueryInterface;
1157
  $__default["default"].fn[NAME$8].Constructor = Carousel;
1158

1159
  $__default["default"].fn[NAME$8].noConflict = function () {
1160
    $__default["default"].fn[NAME$8] = JQUERY_NO_CONFLICT$8;
1161
    return Carousel._jQueryInterface;
1162
  };
1163

1164
  /**
1165
   * Constants
1166
   */
1167

1168
  var NAME$7 = 'collapse';
1169
  var VERSION$7 = '4.6.1';
1170
  var DATA_KEY$7 = 'bs.collapse';
1171
  var EVENT_KEY$7 = "." + DATA_KEY$7;
1172
  var DATA_API_KEY$4 = '.data-api';
1173
  var JQUERY_NO_CONFLICT$7 = $__default["default"].fn[NAME$7];
1174
  var CLASS_NAME_SHOW$6 = 'show';
1175
  var CLASS_NAME_COLLAPSE = 'collapse';
1176
  var CLASS_NAME_COLLAPSING = 'collapsing';
1177
  var CLASS_NAME_COLLAPSED = 'collapsed';
1178
  var DIMENSION_WIDTH = 'width';
1179
  var DIMENSION_HEIGHT = 'height';
1180
  var EVENT_SHOW$4 = "show" + EVENT_KEY$7;
1181
  var EVENT_SHOWN$4 = "shown" + EVENT_KEY$7;
1182
  var EVENT_HIDE$4 = "hide" + EVENT_KEY$7;
1183
  var EVENT_HIDDEN$4 = "hidden" + EVENT_KEY$7;
1184
  var EVENT_CLICK_DATA_API$3 = "click" + EVENT_KEY$7 + DATA_API_KEY$4;
1185
  var SELECTOR_ACTIVES = '.show, .collapsing';
1186
  var SELECTOR_DATA_TOGGLE$3 = '[data-toggle="collapse"]';
1187
  var Default$6 = {
1188
    toggle: true,
1189
    parent: ''
1190
  };
1191
  var DefaultType$6 = {
1192
    toggle: 'boolean',
1193
    parent: '(string|element)'
1194
  };
1195
  /**
1196
   * Class definition
1197
   */
1198

1199
  var Collapse = /*#__PURE__*/function () {
1200
    function Collapse(element, config) {
1201
      this._isTransitioning = false;
1202
      this._element = element;
1203
      this._config = this._getConfig(config);
1204
      this._triggerArray = [].slice.call(document.querySelectorAll("[data-toggle=\"collapse\"][href=\"#" + element.id + "\"]," + ("[data-toggle=\"collapse\"][data-target=\"#" + element.id + "\"]")));
1205
      var toggleList = [].slice.call(document.querySelectorAll(SELECTOR_DATA_TOGGLE$3));
1206

1207
      for (var i = 0, len = toggleList.length; i < len; i++) {
1208
        var elem = toggleList[i];
1209
        var selector = Util.getSelectorFromElement(elem);
1210
        var filterElement = [].slice.call(document.querySelectorAll(selector)).filter(function (foundElem) {
1211
          return foundElem === element;
1212
        });
1213

1214
        if (selector !== null && filterElement.length > 0) {
1215
          this._selector = selector;
1216

1217
          this._triggerArray.push(elem);
1218
        }
1219
      }
1220

1221
      this._parent = this._config.parent ? this._getParent() : null;
1222

1223
      if (!this._config.parent) {
1224
        this._addAriaAndCollapsedClass(this._element, this._triggerArray);
1225
      }
1226

1227
      if (this._config.toggle) {
1228
        this.toggle();
1229
      }
1230
    } // Getters
1231

1232

1233
    var _proto = Collapse.prototype;
1234

1235
    // Public
1236
    _proto.toggle = function toggle() {
1237
      if ($__default["default"](this._element).hasClass(CLASS_NAME_SHOW$6)) {
1238
        this.hide();
1239
      } else {
1240
        this.show();
1241
      }
1242
    };
1243

1244
    _proto.show = function show() {
1245
      var _this = this;
1246

1247
      if (this._isTransitioning || $__default["default"](this._element).hasClass(CLASS_NAME_SHOW$6)) {
1248
        return;
1249
      }
1250

1251
      var actives;
1252
      var activesData;
1253

1254
      if (this._parent) {
1255
        actives = [].slice.call(this._parent.querySelectorAll(SELECTOR_ACTIVES)).filter(function (elem) {
1256
          if (typeof _this._config.parent === 'string') {
1257
            return elem.getAttribute('data-parent') === _this._config.parent;
1258
          }
1259

1260
          return elem.classList.contains(CLASS_NAME_COLLAPSE);
1261
        });
1262

1263
        if (actives.length === 0) {
1264
          actives = null;
1265
        }
1266
      }
1267

1268
      if (actives) {
1269
        activesData = $__default["default"](actives).not(this._selector).data(DATA_KEY$7);
1270

1271
        if (activesData && activesData._isTransitioning) {
1272
          return;
1273
        }
1274
      }
1275

1276
      var startEvent = $__default["default"].Event(EVENT_SHOW$4);
1277
      $__default["default"](this._element).trigger(startEvent);
1278

1279
      if (startEvent.isDefaultPrevented()) {
1280
        return;
1281
      }
1282

1283
      if (actives) {
1284
        Collapse._jQueryInterface.call($__default["default"](actives).not(this._selector), 'hide');
1285

1286
        if (!activesData) {
1287
          $__default["default"](actives).data(DATA_KEY$7, null);
1288
        }
1289
      }
1290

1291
      var dimension = this._getDimension();
1292

1293
      $__default["default"](this._element).removeClass(CLASS_NAME_COLLAPSE).addClass(CLASS_NAME_COLLAPSING);
1294
      this._element.style[dimension] = 0;
1295

1296
      if (this._triggerArray.length) {
1297
        $__default["default"](this._triggerArray).removeClass(CLASS_NAME_COLLAPSED).attr('aria-expanded', true);
1298
      }
1299

1300
      this.setTransitioning(true);
1301

1302
      var complete = function complete() {
1303
        $__default["default"](_this._element).removeClass(CLASS_NAME_COLLAPSING).addClass(CLASS_NAME_COLLAPSE + " " + CLASS_NAME_SHOW$6);
1304
        _this._element.style[dimension] = '';
1305

1306
        _this.setTransitioning(false);
1307

1308
        $__default["default"](_this._element).trigger(EVENT_SHOWN$4);
1309
      };
1310

1311
      var capitalizedDimension = dimension[0].toUpperCase() + dimension.slice(1);
1312
      var scrollSize = "scroll" + capitalizedDimension;
1313
      var transitionDuration = Util.getTransitionDurationFromElement(this._element);
1314
      $__default["default"](this._element).one(Util.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
1315
      this._element.style[dimension] = this._element[scrollSize] + "px";
1316
    };
1317

1318
    _proto.hide = function hide() {
1319
      var _this2 = this;
1320

1321
      if (this._isTransitioning || !$__default["default"](this._element).hasClass(CLASS_NAME_SHOW$6)) {
1322
        return;
1323
      }
1324

1325
      var startEvent = $__default["default"].Event(EVENT_HIDE$4);
1326
      $__default["default"](this._element).trigger(startEvent);
1327

1328
      if (startEvent.isDefaultPrevented()) {
1329
        return;
1330
      }
1331

1332
      var dimension = this._getDimension();
1333

1334
      this._element.style[dimension] = this._element.getBoundingClientRect()[dimension] + "px";
1335
      Util.reflow(this._element);
1336
      $__default["default"](this._element).addClass(CLASS_NAME_COLLAPSING).removeClass(CLASS_NAME_COLLAPSE + " " + CLASS_NAME_SHOW$6);
1337
      var triggerArrayLength = this._triggerArray.length;
1338

1339
      if (triggerArrayLength > 0) {
1340
        for (var i = 0; i < triggerArrayLength; i++) {
1341
          var trigger = this._triggerArray[i];
1342
          var selector = Util.getSelectorFromElement(trigger);
1343

1344
          if (selector !== null) {
1345
            var $elem = $__default["default"]([].slice.call(document.querySelectorAll(selector)));
1346

1347
            if (!$elem.hasClass(CLASS_NAME_SHOW$6)) {
1348
              $__default["default"](trigger).addClass(CLASS_NAME_COLLAPSED).attr('aria-expanded', false);
1349
            }
1350
          }
1351
        }
1352
      }
1353

1354
      this.setTransitioning(true);
1355

1356
      var complete = function complete() {
1357
        _this2.setTransitioning(false);
1358

1359
        $__default["default"](_this2._element).removeClass(CLASS_NAME_COLLAPSING).addClass(CLASS_NAME_COLLAPSE).trigger(EVENT_HIDDEN$4);
1360
      };
1361

1362
      this._element.style[dimension] = '';
1363
      var transitionDuration = Util.getTransitionDurationFromElement(this._element);
1364
      $__default["default"](this._element).one(Util.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
1365
    };
1366

1367
    _proto.setTransitioning = function setTransitioning(isTransitioning) {
1368
      this._isTransitioning = isTransitioning;
1369
    };
1370

1371
    _proto.dispose = function dispose() {
1372
      $__default["default"].removeData(this._element, DATA_KEY$7);
1373
      this._config = null;
1374
      this._parent = null;
1375
      this._element = null;
1376
      this._triggerArray = null;
1377
      this._isTransitioning = null;
1378
    } // Private
1379
    ;
1380

1381
    _proto._getConfig = function _getConfig(config) {
1382
      config = _extends({}, Default$6, config);
1383
      config.toggle = Boolean(config.toggle); // Coerce string values
1384

1385
      Util.typeCheckConfig(NAME$7, config, DefaultType$6);
1386
      return config;
1387
    };
1388

1389
    _proto._getDimension = function _getDimension() {
1390
      var hasWidth = $__default["default"](this._element).hasClass(DIMENSION_WIDTH);
1391
      return hasWidth ? DIMENSION_WIDTH : DIMENSION_HEIGHT;
1392
    };
1393

1394
    _proto._getParent = function _getParent() {
1395
      var _this3 = this;
1396

1397
      var parent;
1398

1399
      if (Util.isElement(this._config.parent)) {
1400
        parent = this._config.parent; // It's a jQuery object
1401

1402
        if (typeof this._config.parent.jquery !== 'undefined') {
1403
          parent = this._config.parent[0];
1404
        }
1405
      } else {
1406
        parent = document.querySelector(this._config.parent);
1407
      }
1408

1409
      var selector = "[data-toggle=\"collapse\"][data-parent=\"" + this._config.parent + "\"]";
1410
      var children = [].slice.call(parent.querySelectorAll(selector));
1411
      $__default["default"](children).each(function (i, element) {
1412
        _this3._addAriaAndCollapsedClass(Collapse._getTargetFromElement(element), [element]);
1413
      });
1414
      return parent;
1415
    };
1416

1417
    _proto._addAriaAndCollapsedClass = function _addAriaAndCollapsedClass(element, triggerArray) {
1418
      var isOpen = $__default["default"](element).hasClass(CLASS_NAME_SHOW$6);
1419

1420
      if (triggerArray.length) {
1421
        $__default["default"](triggerArray).toggleClass(CLASS_NAME_COLLAPSED, !isOpen).attr('aria-expanded', isOpen);
1422
      }
1423
    } // Static
1424
    ;
1425

1426
    Collapse._getTargetFromElement = function _getTargetFromElement(element) {
1427
      var selector = Util.getSelectorFromElement(element);
1428
      return selector ? document.querySelector(selector) : null;
1429
    };
1430

1431
    Collapse._jQueryInterface = function _jQueryInterface(config) {
1432
      return this.each(function () {
1433
        var $element = $__default["default"](this);
1434
        var data = $element.data(DATA_KEY$7);
1435

1436
        var _config = _extends({}, Default$6, $element.data(), typeof config === 'object' && config ? config : {});
1437

1438
        if (!data && _config.toggle && typeof config === 'string' && /show|hide/.test(config)) {
1439
          _config.toggle = false;
1440
        }
1441

1442
        if (!data) {
1443
          data = new Collapse(this, _config);
1444
          $element.data(DATA_KEY$7, data);
1445
        }
1446

1447
        if (typeof config === 'string') {
1448
          if (typeof data[config] === 'undefined') {
1449
            throw new TypeError("No method named \"" + config + "\"");
1450
          }
1451

1452
          data[config]();
1453
        }
1454
      });
1455
    };
1456

1457
    _createClass(Collapse, null, [{
1458
      key: "VERSION",
1459
      get: function get() {
1460
        return VERSION$7;
1461
      }
1462
    }, {
1463
      key: "Default",
1464
      get: function get() {
1465
        return Default$6;
1466
      }
1467
    }]);
1468

1469
    return Collapse;
1470
  }();
1471
  /**
1472
   * Data API implementation
1473
   */
1474

1475

1476
  $__default["default"](document).on(EVENT_CLICK_DATA_API$3, SELECTOR_DATA_TOGGLE$3, function (event) {
1477
    // preventDefault only for <a> elements (which change the URL) not inside the collapsible element
1478
    if (event.currentTarget.tagName === 'A') {
1479
      event.preventDefault();
1480
    }
1481

1482
    var $trigger = $__default["default"](this);
1483
    var selector = Util.getSelectorFromElement(this);
1484
    var selectors = [].slice.call(document.querySelectorAll(selector));
1485
    $__default["default"](selectors).each(function () {
1486
      var $target = $__default["default"](this);
1487
      var data = $target.data(DATA_KEY$7);
1488
      var config = data ? 'toggle' : $trigger.data();
1489

1490
      Collapse._jQueryInterface.call($target, config);
1491
    });
1492
  });
1493
  /**
1494
   * jQuery
1495
   */
1496

1497
  $__default["default"].fn[NAME$7] = Collapse._jQueryInterface;
1498
  $__default["default"].fn[NAME$7].Constructor = Collapse;
1499

1500
  $__default["default"].fn[NAME$7].noConflict = function () {
1501
    $__default["default"].fn[NAME$7] = JQUERY_NO_CONFLICT$7;
1502
    return Collapse._jQueryInterface;
1503
  };
1504

1505
  /**
1506
   * Constants
1507
   */
1508

1509
  var NAME$6 = 'dropdown';
1510
  var VERSION$6 = '4.6.1';
1511
  var DATA_KEY$6 = 'bs.dropdown';
1512
  var EVENT_KEY$6 = "." + DATA_KEY$6;
1513
  var DATA_API_KEY$3 = '.data-api';
1514
  var JQUERY_NO_CONFLICT$6 = $__default["default"].fn[NAME$6];
1515
  var ESCAPE_KEYCODE$1 = 27; // KeyboardEvent.which value for Escape (Esc) key
1516

1517
  var SPACE_KEYCODE = 32; // KeyboardEvent.which value for space key
1518

1519
  var TAB_KEYCODE = 9; // KeyboardEvent.which value for tab key
1520

1521
  var ARROW_UP_KEYCODE = 38; // KeyboardEvent.which value for up arrow key
1522

1523
  var ARROW_DOWN_KEYCODE = 40; // KeyboardEvent.which value for down arrow key
1524

1525
  var RIGHT_MOUSE_BUTTON_WHICH = 3; // MouseEvent.which value for the right button (assuming a right-handed mouse)
1526

1527
  var REGEXP_KEYDOWN = new RegExp(ARROW_UP_KEYCODE + "|" + ARROW_DOWN_KEYCODE + "|" + ESCAPE_KEYCODE$1);
1528
  var CLASS_NAME_DISABLED$1 = 'disabled';
1529
  var CLASS_NAME_SHOW$5 = 'show';
1530
  var CLASS_NAME_DROPUP = 'dropup';
1531
  var CLASS_NAME_DROPRIGHT = 'dropright';
1532
  var CLASS_NAME_DROPLEFT = 'dropleft';
1533
  var CLASS_NAME_MENURIGHT = 'dropdown-menu-right';
1534
  var CLASS_NAME_POSITION_STATIC = 'position-static';
1535
  var EVENT_HIDE$3 = "hide" + EVENT_KEY$6;
1536
  var EVENT_HIDDEN$3 = "hidden" + EVENT_KEY$6;
1537
  var EVENT_SHOW$3 = "show" + EVENT_KEY$6;
1538
  var EVENT_SHOWN$3 = "shown" + EVENT_KEY$6;
1539
  var EVENT_CLICK = "click" + EVENT_KEY$6;
1540
  var EVENT_CLICK_DATA_API$2 = "click" + EVENT_KEY$6 + DATA_API_KEY$3;
1541
  var EVENT_KEYDOWN_DATA_API = "keydown" + EVENT_KEY$6 + DATA_API_KEY$3;
1542
  var EVENT_KEYUP_DATA_API = "keyup" + EVENT_KEY$6 + DATA_API_KEY$3;
1543
  var SELECTOR_DATA_TOGGLE$2 = '[data-toggle="dropdown"]';
1544
  var SELECTOR_FORM_CHILD = '.dropdown form';
1545
  var SELECTOR_MENU = '.dropdown-menu';
1546
  var SELECTOR_NAVBAR_NAV = '.navbar-nav';
1547
  var SELECTOR_VISIBLE_ITEMS = '.dropdown-menu .dropdown-item:not(.disabled):not(:disabled)';
1548
  var PLACEMENT_TOP = 'top-start';
1549
  var PLACEMENT_TOPEND = 'top-end';
1550
  var PLACEMENT_BOTTOM = 'bottom-start';
1551
  var PLACEMENT_BOTTOMEND = 'bottom-end';
1552
  var PLACEMENT_RIGHT = 'right-start';
1553
  var PLACEMENT_LEFT = 'left-start';
1554
  var Default$5 = {
1555
    offset: 0,
1556
    flip: true,
1557
    boundary: 'scrollParent',
1558
    reference: 'toggle',
1559
    display: 'dynamic',
1560
    popperConfig: null
1561
  };
1562
  var DefaultType$5 = {
1563
    offset: '(number|string|function)',
1564
    flip: 'boolean',
1565
    boundary: '(string|element)',
1566
    reference: '(string|element)',
1567
    display: 'string',
1568
    popperConfig: '(null|object)'
1569
  };
1570
  /**
1571
   * Class definition
1572
   */
1573

1574
  var Dropdown = /*#__PURE__*/function () {
1575
    function Dropdown(element, config) {
1576
      this._element = element;
1577
      this._popper = null;
1578
      this._config = this._getConfig(config);
1579
      this._menu = this._getMenuElement();
1580
      this._inNavbar = this._detectNavbar();
1581

1582
      this._addEventListeners();
1583
    } // Getters
1584

1585

1586
    var _proto = Dropdown.prototype;
1587

1588
    // Public
1589
    _proto.toggle = function toggle() {
1590
      if (this._element.disabled || $__default["default"](this._element).hasClass(CLASS_NAME_DISABLED$1)) {
1591
        return;
1592
      }
1593

1594
      var isActive = $__default["default"](this._menu).hasClass(CLASS_NAME_SHOW$5);
1595

1596
      Dropdown._clearMenus();
1597

1598
      if (isActive) {
1599
        return;
1600
      }
1601

1602
      this.show(true);
1603
    };
1604

1605
    _proto.show = function show(usePopper) {
1606
      if (usePopper === void 0) {
1607
        usePopper = false;
1608
      }
1609

1610
      if (this._element.disabled || $__default["default"](this._element).hasClass(CLASS_NAME_DISABLED$1) || $__default["default"](this._menu).hasClass(CLASS_NAME_SHOW$5)) {
1611
        return;
1612
      }
1613

1614
      var relatedTarget = {
1615
        relatedTarget: this._element
1616
      };
1617
      var showEvent = $__default["default"].Event(EVENT_SHOW$3, relatedTarget);
1618

1619
      var parent = Dropdown._getParentFromElement(this._element);
1620

1621
      $__default["default"](parent).trigger(showEvent);
1622

1623
      if (showEvent.isDefaultPrevented()) {
1624
        return;
1625
      } // Totally disable Popper for Dropdowns in Navbar
1626

1627

1628
      if (!this._inNavbar && usePopper) {
1629
        // Check for Popper dependency
1630
        if (typeof Popper__default["default"] === 'undefined') {
1631
          throw new TypeError('Bootstrap\'s dropdowns require Popper (https://popper.js.org)');
1632
        }
1633

1634
        var referenceElement = this._element;
1635

1636
        if (this._config.reference === 'parent') {
1637
          referenceElement = parent;
1638
        } else if (Util.isElement(this._config.reference)) {
1639
          referenceElement = this._config.reference; // Check if it's jQuery element
1640

1641
          if (typeof this._config.reference.jquery !== 'undefined') {
1642
            referenceElement = this._config.reference[0];
1643
          }
1644
        } // If boundary is not `scrollParent`, then set position to `static`
1645
        // to allow the menu to "escape" the scroll parent's boundaries
1646
        // https://github.com/twbs/bootstrap/issues/24251
1647

1648

1649
        if (this._config.boundary !== 'scrollParent') {
1650
          $__default["default"](parent).addClass(CLASS_NAME_POSITION_STATIC);
1651
        }
1652

1653
        this._popper = new Popper__default["default"](referenceElement, this._menu, this._getPopperConfig());
1654
      } // If this is a touch-enabled device we add extra
1655
      // empty mouseover listeners to the body's immediate children;
1656
      // only needed because of broken event delegation on iOS
1657
      // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html
1658

1659

1660
      if ('ontouchstart' in document.documentElement && $__default["default"](parent).closest(SELECTOR_NAVBAR_NAV).length === 0) {
1661
        $__default["default"](document.body).children().on('mouseover', null, $__default["default"].noop);
1662
      }
1663

1664
      this._element.focus();
1665

1666
      this._element.setAttribute('aria-expanded', true);
1667

1668
      $__default["default"](this._menu).toggleClass(CLASS_NAME_SHOW$5);
1669
      $__default["default"](parent).toggleClass(CLASS_NAME_SHOW$5).trigger($__default["default"].Event(EVENT_SHOWN$3, relatedTarget));
1670
    };
1671

1672
    _proto.hide = function hide() {
1673
      if (this._element.disabled || $__default["default"](this._element).hasClass(CLASS_NAME_DISABLED$1) || !$__default["default"](this._menu).hasClass(CLASS_NAME_SHOW$5)) {
1674
        return;
1675
      }
1676

1677
      var relatedTarget = {
1678
        relatedTarget: this._element
1679
      };
1680
      var hideEvent = $__default["default"].Event(EVENT_HIDE$3, relatedTarget);
1681

1682
      var parent = Dropdown._getParentFromElement(this._element);
1683

1684
      $__default["default"](parent).trigger(hideEvent);
1685

1686
      if (hideEvent.isDefaultPrevented()) {
1687
        return;
1688
      }
1689

1690
      if (this._popper) {
1691
        this._popper.destroy();
1692
      }
1693

1694
      $__default["default"](this._menu).toggleClass(CLASS_NAME_SHOW$5);
1695
      $__default["default"](parent).toggleClass(CLASS_NAME_SHOW$5).trigger($__default["default"].Event(EVENT_HIDDEN$3, relatedTarget));
1696
    };
1697

1698
    _proto.dispose = function dispose() {
1699
      $__default["default"].removeData(this._element, DATA_KEY$6);
1700
      $__default["default"](this._element).off(EVENT_KEY$6);
1701
      this._element = null;
1702
      this._menu = null;
1703

1704
      if (this._popper !== null) {
1705
        this._popper.destroy();
1706

1707
        this._popper = null;
1708
      }
1709
    };
1710

1711
    _proto.update = function update() {
1712
      this._inNavbar = this._detectNavbar();
1713

1714
      if (this._popper !== null) {
1715
        this._popper.scheduleUpdate();
1716
      }
1717
    } // Private
1718
    ;
1719

1720
    _proto._addEventListeners = function _addEventListeners() {
1721
      var _this = this;
1722

1723
      $__default["default"](this._element).on(EVENT_CLICK, function (event) {
1724
        event.preventDefault();
1725
        event.stopPropagation();
1726

1727
        _this.toggle();
1728
      });
1729
    };
1730

1731
    _proto._getConfig = function _getConfig(config) {
1732
      config = _extends({}, this.constructor.Default, $__default["default"](this._element).data(), config);
1733
      Util.typeCheckConfig(NAME$6, config, this.constructor.DefaultType);
1734
      return config;
1735
    };
1736

1737
    _proto._getMenuElement = function _getMenuElement() {
1738
      if (!this._menu) {
1739
        var parent = Dropdown._getParentFromElement(this._element);
1740

1741
        if (parent) {
1742
          this._menu = parent.querySelector(SELECTOR_MENU);
1743
        }
1744
      }
1745

1746
      return this._menu;
1747
    };
1748

1749
    _proto._getPlacement = function _getPlacement() {
1750
      var $parentDropdown = $__default["default"](this._element.parentNode);
1751
      var placement = PLACEMENT_BOTTOM; // Handle dropup
1752

1753
      if ($parentDropdown.hasClass(CLASS_NAME_DROPUP)) {
1754
        placement = $__default["default"](this._menu).hasClass(CLASS_NAME_MENURIGHT) ? PLACEMENT_TOPEND : PLACEMENT_TOP;
1755
      } else if ($parentDropdown.hasClass(CLASS_NAME_DROPRIGHT)) {
1756
        placement = PLACEMENT_RIGHT;
1757
      } else if ($parentDropdown.hasClass(CLASS_NAME_DROPLEFT)) {
1758
        placement = PLACEMENT_LEFT;
1759
      } else if ($__default["default"](this._menu).hasClass(CLASS_NAME_MENURIGHT)) {
1760
        placement = PLACEMENT_BOTTOMEND;
1761
      }
1762

1763
      return placement;
1764
    };
1765

1766
    _proto._detectNavbar = function _detectNavbar() {
1767
      return $__default["default"](this._element).closest('.navbar').length > 0;
1768
    };
1769

1770
    _proto._getOffset = function _getOffset() {
1771
      var _this2 = this;
1772

1773
      var offset = {};
1774

1775
      if (typeof this._config.offset === 'function') {
1776
        offset.fn = function (data) {
1777
          data.offsets = _extends({}, data.offsets, _this2._config.offset(data.offsets, _this2._element));
1778
          return data;
1779
        };
1780
      } else {
1781
        offset.offset = this._config.offset;
1782
      }
1783

1784
      return offset;
1785
    };
1786

1787
    _proto._getPopperConfig = function _getPopperConfig() {
1788
      var popperConfig = {
1789
        placement: this._getPlacement(),
1790
        modifiers: {
1791
          offset: this._getOffset(),
1792
          flip: {
1793
            enabled: this._config.flip
1794
          },
1795
          preventOverflow: {
1796
            boundariesElement: this._config.boundary
1797
          }
1798
        }
1799
      }; // Disable Popper if we have a static display
1800

1801
      if (this._config.display === 'static') {
1802
        popperConfig.modifiers.applyStyle = {
1803
          enabled: false
1804
        };
1805
      }
1806

1807
      return _extends({}, popperConfig, this._config.popperConfig);
1808
    } // Static
1809
    ;
1810

1811
    Dropdown._jQueryInterface = function _jQueryInterface(config) {
1812
      return this.each(function () {
1813
        var data = $__default["default"](this).data(DATA_KEY$6);
1814

1815
        var _config = typeof config === 'object' ? config : null;
1816

1817
        if (!data) {
1818
          data = new Dropdown(this, _config);
1819
          $__default["default"](this).data(DATA_KEY$6, data);
1820
        }
1821

1822
        if (typeof config === 'string') {
1823
          if (typeof data[config] === 'undefined') {
1824
            throw new TypeError("No method named \"" + config + "\"");
1825
          }
1826

1827
          data[config]();
1828
        }
1829
      });
1830
    };
1831

1832
    Dropdown._clearMenus = function _clearMenus(event) {
1833
      if (event && (event.which === RIGHT_MOUSE_BUTTON_WHICH || event.type === 'keyup' && event.which !== TAB_KEYCODE)) {
1834
        return;
1835
      }
1836

1837
      var toggles = [].slice.call(document.querySelectorAll(SELECTOR_DATA_TOGGLE$2));
1838

1839
      for (var i = 0, len = toggles.length; i < len; i++) {
1840
        var parent = Dropdown._getParentFromElement(toggles[i]);
1841

1842
        var context = $__default["default"](toggles[i]).data(DATA_KEY$6);
1843
        var relatedTarget = {
1844
          relatedTarget: toggles[i]
1845
        };
1846

1847
        if (event && event.type === 'click') {
1848
          relatedTarget.clickEvent = event;
1849
        }
1850

1851
        if (!context) {
1852
          continue;
1853
        }
1854

1855
        var dropdownMenu = context._menu;
1856

1857
        if (!$__default["default"](parent).hasClass(CLASS_NAME_SHOW$5)) {
1858
          continue;
1859
        }
1860

1861
        if (event && (event.type === 'click' && /input|textarea/i.test(event.target.tagName) || event.type === 'keyup' && event.which === TAB_KEYCODE) && $__default["default"].contains(parent, event.target)) {
1862
          continue;
1863
        }
1864

1865
        var hideEvent = $__default["default"].Event(EVENT_HIDE$3, relatedTarget);
1866
        $__default["default"](parent).trigger(hideEvent);
1867

1868
        if (hideEvent.isDefaultPrevented()) {
1869
          continue;
1870
        } // If this is a touch-enabled device we remove the extra
1871
        // empty mouseover listeners we added for iOS support
1872

1873

1874
        if ('ontouchstart' in document.documentElement) {
1875
          $__default["default"](document.body).children().off('mouseover', null, $__default["default"].noop);
1876
        }
1877

1878
        toggles[i].setAttribute('aria-expanded', 'false');
1879

1880
        if (context._popper) {
1881
          context._popper.destroy();
1882
        }
1883

1884
        $__default["default"](dropdownMenu).removeClass(CLASS_NAME_SHOW$5);
1885
        $__default["default"](parent).removeClass(CLASS_NAME_SHOW$5).trigger($__default["default"].Event(EVENT_HIDDEN$3, relatedTarget));
1886
      }
1887
    };
1888

1889
    Dropdown._getParentFromElement = function _getParentFromElement(element) {
1890
      var parent;
1891
      var selector = Util.getSelectorFromElement(element);
1892

1893
      if (selector) {
1894
        parent = document.querySelector(selector);
1895
      }
1896

1897
      return parent || element.parentNode;
1898
    } // eslint-disable-next-line complexity
1899
    ;
1900

1901
    Dropdown._dataApiKeydownHandler = function _dataApiKeydownHandler(event) {
1902
      // If not input/textarea:
1903
      //  - And not a key in REGEXP_KEYDOWN => not a dropdown command
1904
      // If input/textarea:
1905
      //  - If space key => not a dropdown command
1906
      //  - If key is other than escape
1907
      //    - If key is not up or down => not a dropdown command
1908
      //    - If trigger inside the menu => not a dropdown command
1909
      if (/input|textarea/i.test(event.target.tagName) ? event.which === SPACE_KEYCODE || event.which !== ESCAPE_KEYCODE$1 && (event.which !== ARROW_DOWN_KEYCODE && event.which !== ARROW_UP_KEYCODE || $__default["default"](event.target).closest(SELECTOR_MENU).length) : !REGEXP_KEYDOWN.test(event.which)) {
1910
        return;
1911
      }
1912

1913
      if (this.disabled || $__default["default"](this).hasClass(CLASS_NAME_DISABLED$1)) {
1914
        return;
1915
      }
1916

1917
      var parent = Dropdown._getParentFromElement(this);
1918

1919
      var isActive = $__default["default"](parent).hasClass(CLASS_NAME_SHOW$5);
1920

1921
      if (!isActive && event.which === ESCAPE_KEYCODE$1) {
1922
        return;
1923
      }
1924

1925
      event.preventDefault();
1926
      event.stopPropagation();
1927

1928
      if (!isActive || event.which === ESCAPE_KEYCODE$1 || event.which === SPACE_KEYCODE) {
1929
        if (event.which === ESCAPE_KEYCODE$1) {
1930
          $__default["default"](parent.querySelector(SELECTOR_DATA_TOGGLE$2)).trigger('focus');
1931
        }
1932

1933
        $__default["default"](this).trigger('click');
1934
        return;
1935
      }
1936

1937
      var items = [].slice.call(parent.querySelectorAll(SELECTOR_VISIBLE_ITEMS)).filter(function (item) {
1938
        return $__default["default"](item).is(':visible');
1939
      });
1940

1941
      if (items.length === 0) {
1942
        return;
1943
      }
1944

1945
      var index = items.indexOf(event.target);
1946

1947
      if (event.which === ARROW_UP_KEYCODE && index > 0) {
1948
        // Up
1949
        index--;
1950
      }
1951

1952
      if (event.which === ARROW_DOWN_KEYCODE && index < items.length - 1) {
1953
        // Down
1954
        index++;
1955
      }
1956

1957
      if (index < 0) {
1958
        index = 0;
1959
      }
1960

1961
      items[index].focus();
1962
    };
1963

1964
    _createClass(Dropdown, null, [{
1965
      key: "VERSION",
1966
      get: function get() {
1967
        return VERSION$6;
1968
      }
1969
    }, {
1970
      key: "Default",
1971
      get: function get() {
1972
        return Default$5;
1973
      }
1974
    }, {
1975
      key: "DefaultType",
1976
      get: function get() {
1977
        return DefaultType$5;
1978
      }
1979
    }]);
1980

1981
    return Dropdown;
1982
  }();
1983
  /**
1984
   * Data API implementation
1985
   */
1986

1987

1988
  $__default["default"](document).on(EVENT_KEYDOWN_DATA_API, SELECTOR_DATA_TOGGLE$2, Dropdown._dataApiKeydownHandler).on(EVENT_KEYDOWN_DATA_API, SELECTOR_MENU, Dropdown._dataApiKeydownHandler).on(EVENT_CLICK_DATA_API$2 + " " + EVENT_KEYUP_DATA_API, Dropdown._clearMenus).on(EVENT_CLICK_DATA_API$2, SELECTOR_DATA_TOGGLE$2, function (event) {
1989
    event.preventDefault();
1990
    event.stopPropagation();
1991

1992
    Dropdown._jQueryInterface.call($__default["default"](this), 'toggle');
1993
  }).on(EVENT_CLICK_DATA_API$2, SELECTOR_FORM_CHILD, function (e) {
1994
    e.stopPropagation();
1995
  });
1996
  /**
1997
   * jQuery
1998
   */
1999

2000
  $__default["default"].fn[NAME$6] = Dropdown._jQueryInterface;
2001
  $__default["default"].fn[NAME$6].Constructor = Dropdown;
2002

2003
  $__default["default"].fn[NAME$6].noConflict = function () {
2004
    $__default["default"].fn[NAME$6] = JQUERY_NO_CONFLICT$6;
2005
    return Dropdown._jQueryInterface;
2006
  };
2007

2008
  /**
2009
   * Constants
2010
   */
2011

2012
  var NAME$5 = 'modal';
2013
  var VERSION$5 = '4.6.1';
2014
  var DATA_KEY$5 = 'bs.modal';
2015
  var EVENT_KEY$5 = "." + DATA_KEY$5;
2016
  var DATA_API_KEY$2 = '.data-api';
2017
  var JQUERY_NO_CONFLICT$5 = $__default["default"].fn[NAME$5];
2018
  var ESCAPE_KEYCODE = 27; // KeyboardEvent.which value for Escape (Esc) key
2019

2020
  var CLASS_NAME_SCROLLABLE = 'modal-dialog-scrollable';
2021
  var CLASS_NAME_SCROLLBAR_MEASURER = 'modal-scrollbar-measure';
2022
  var CLASS_NAME_BACKDROP = 'modal-backdrop';
2023
  var CLASS_NAME_OPEN = 'modal-open';
2024
  var CLASS_NAME_FADE$4 = 'fade';
2025
  var CLASS_NAME_SHOW$4 = 'show';
2026
  var CLASS_NAME_STATIC = 'modal-static';
2027
  var EVENT_HIDE$2 = "hide" + EVENT_KEY$5;
2028
  var EVENT_HIDE_PREVENTED = "hidePrevented" + EVENT_KEY$5;
2029
  var EVENT_HIDDEN$2 = "hidden" + EVENT_KEY$5;
2030
  var EVENT_SHOW$2 = "show" + EVENT_KEY$5;
2031
  var EVENT_SHOWN$2 = "shown" + EVENT_KEY$5;
2032
  var EVENT_FOCUSIN = "focusin" + EVENT_KEY$5;
2033
  var EVENT_RESIZE = "resize" + EVENT_KEY$5;
2034
  var EVENT_CLICK_DISMISS$1 = "click.dismiss" + EVENT_KEY$5;
2035
  var EVENT_KEYDOWN_DISMISS = "keydown.dismiss" + EVENT_KEY$5;
2036
  var EVENT_MOUSEUP_DISMISS = "mouseup.dismiss" + EVENT_KEY$5;
2037
  var EVENT_MOUSEDOWN_DISMISS = "mousedown.dismiss" + EVENT_KEY$5;
2038
  var EVENT_CLICK_DATA_API$1 = "click" + EVENT_KEY$5 + DATA_API_KEY$2;
2039
  var SELECTOR_DIALOG = '.modal-dialog';
2040
  var SELECTOR_MODAL_BODY = '.modal-body';
2041
  var SELECTOR_DATA_TOGGLE$1 = '[data-toggle="modal"]';
2042
  var SELECTOR_DATA_DISMISS$1 = '[data-dismiss="modal"]';
2043
  var SELECTOR_FIXED_CONTENT = '.fixed-top, .fixed-bottom, .is-fixed, .sticky-top';
2044
  var SELECTOR_STICKY_CONTENT = '.sticky-top';
2045
  var Default$4 = {
2046
    backdrop: true,
2047
    keyboard: true,
2048
    focus: true,
2049
    show: true
2050
  };
2051
  var DefaultType$4 = {
2052
    backdrop: '(boolean|string)',
2053
    keyboard: 'boolean',
2054
    focus: 'boolean',
2055
    show: 'boolean'
2056
  };
2057
  /**
2058
   * Class definition
2059
   */
2060

2061
  var Modal = /*#__PURE__*/function () {
2062
    function Modal(element, config) {
2063
      this._config = this._getConfig(config);
2064
      this._element = element;
2065
      this._dialog = element.querySelector(SELECTOR_DIALOG);
2066
      this._backdrop = null;
2067
      this._isShown = false;
2068
      this._isBodyOverflowing = false;
2069
      this._ignoreBackdropClick = false;
2070
      this._isTransitioning = false;
2071
      this._scrollbarWidth = 0;
2072
    } // Getters
2073

2074

2075
    var _proto = Modal.prototype;
2076

2077
    // Public
2078
    _proto.toggle = function toggle(relatedTarget) {
2079
      return this._isShown ? this.hide() : this.show(relatedTarget);
2080
    };
2081

2082
    _proto.show = function show(relatedTarget) {
2083
      var _this = this;
2084

2085
      if (this._isShown || this._isTransitioning) {
2086
        return;
2087
      }
2088

2089
      var showEvent = $__default["default"].Event(EVENT_SHOW$2, {
2090
        relatedTarget: relatedTarget
2091
      });
2092
      $__default["default"](this._element).trigger(showEvent);
2093

2094
      if (showEvent.isDefaultPrevented()) {
2095
        return;
2096
      }
2097

2098
      this._isShown = true;
2099

2100
      if ($__default["default"](this._element).hasClass(CLASS_NAME_FADE$4)) {
2101
        this._isTransitioning = true;
2102
      }
2103

2104
      this._checkScrollbar();
2105

2106
      this._setScrollbar();
2107

2108
      this._adjustDialog();
2109

2110
      this._setEscapeEvent();
2111

2112
      this._setResizeEvent();
2113

2114
      $__default["default"](this._element).on(EVENT_CLICK_DISMISS$1, SELECTOR_DATA_DISMISS$1, function (event) {
2115
        return _this.hide(event);
2116
      });
2117
      $__default["default"](this._dialog).on(EVENT_MOUSEDOWN_DISMISS, function () {
2118
        $__default["default"](_this._element).one(EVENT_MOUSEUP_DISMISS, function (event) {
2119
          if ($__default["default"](event.target).is(_this._element)) {
2120
            _this._ignoreBackdropClick = true;
2121
          }
2122
        });
2123
      });
2124

2125
      this._showBackdrop(function () {
2126
        return _this._showElement(relatedTarget);
2127
      });
2128
    };
2129

2130
    _proto.hide = function hide(event) {
2131
      var _this2 = this;
2132

2133
      if (event) {
2134
        event.preventDefault();
2135
      }
2136

2137
      if (!this._isShown || this._isTransitioning) {
2138
        return;
2139
      }
2140

2141
      var hideEvent = $__default["default"].Event(EVENT_HIDE$2);
2142
      $__default["default"](this._element).trigger(hideEvent);
2143

2144
      if (!this._isShown || hideEvent.isDefaultPrevented()) {
2145
        return;
2146
      }
2147

2148
      this._isShown = false;
2149
      var transition = $__default["default"](this._element).hasClass(CLASS_NAME_FADE$4);
2150

2151
      if (transition) {
2152
        this._isTransitioning = true;
2153
      }
2154

2155
      this._setEscapeEvent();
2156

2157
      this._setResizeEvent();
2158

2159
      $__default["default"](document).off(EVENT_FOCUSIN);
2160
      $__default["default"](this._element).removeClass(CLASS_NAME_SHOW$4);
2161
      $__default["default"](this._element).off(EVENT_CLICK_DISMISS$1);
2162
      $__default["default"](this._dialog).off(EVENT_MOUSEDOWN_DISMISS);
2163

2164
      if (transition) {
2165
        var transitionDuration = Util.getTransitionDurationFromElement(this._element);
2166
        $__default["default"](this._element).one(Util.TRANSITION_END, function (event) {
2167
          return _this2._hideModal(event);
2168
        }).emulateTransitionEnd(transitionDuration);
2169
      } else {
2170
        this._hideModal();
2171
      }
2172
    };
2173

2174
    _proto.dispose = function dispose() {
2175
      [window, this._element, this._dialog].forEach(function (htmlElement) {
2176
        return $__default["default"](htmlElement).off(EVENT_KEY$5);
2177
      });
2178
      /**
2179
       * `document` has 2 events `EVENT_FOCUSIN` and `EVENT_CLICK_DATA_API`
2180
       * Do not move `document` in `htmlElements` array
2181
       * It will remove `EVENT_CLICK_DATA_API` event that should remain
2182
       */
2183

2184
      $__default["default"](document).off(EVENT_FOCUSIN);
2185
      $__default["default"].removeData(this._element, DATA_KEY$5);
2186
      this._config = null;
2187
      this._element = null;
2188
      this._dialog = null;
2189
      this._backdrop = null;
2190
      this._isShown = null;
2191
      this._isBodyOverflowing = null;
2192
      this._ignoreBackdropClick = null;
2193
      this._isTransitioning = null;
2194
      this._scrollbarWidth = null;
2195
    };
2196

2197
    _proto.handleUpdate = function handleUpdate() {
2198
      this._adjustDialog();
2199
    } // Private
2200
    ;
2201

2202
    _proto._getConfig = function _getConfig(config) {
2203
      config = _extends({}, Default$4, config);
2204
      Util.typeCheckConfig(NAME$5, config, DefaultType$4);
2205
      return config;
2206
    };
2207

2208
    _proto._triggerBackdropTransition = function _triggerBackdropTransition() {
2209
      var _this3 = this;
2210

2211
      var hideEventPrevented = $__default["default"].Event(EVENT_HIDE_PREVENTED);
2212
      $__default["default"](this._element).trigger(hideEventPrevented);
2213

2214
      if (hideEventPrevented.isDefaultPrevented()) {
2215
        return;
2216
      }
2217

2218
      var isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight;
2219

2220
      if (!isModalOverflowing) {
2221
        this._element.style.overflowY = 'hidden';
2222
      }
2223

2224
      this._element.classList.add(CLASS_NAME_STATIC);
2225

2226
      var modalTransitionDuration = Util.getTransitionDurationFromElement(this._dialog);
2227
      $__default["default"](this._element).off(Util.TRANSITION_END);
2228
      $__default["default"](this._element).one(Util.TRANSITION_END, function () {
2229
        _this3._element.classList.remove(CLASS_NAME_STATIC);
2230

2231
        if (!isModalOverflowing) {
2232
          $__default["default"](_this3._element).one(Util.TRANSITION_END, function () {
2233
            _this3._element.style.overflowY = '';
2234
          }).emulateTransitionEnd(_this3._element, modalTransitionDuration);
2235
        }
2236
      }).emulateTransitionEnd(modalTransitionDuration);
2237

2238
      this._element.focus();
2239
    };
2240

2241
    _proto._showElement = function _showElement(relatedTarget) {
2242
      var _this4 = this;
2243

2244
      var transition = $__default["default"](this._element).hasClass(CLASS_NAME_FADE$4);
2245
      var modalBody = this._dialog ? this._dialog.querySelector(SELECTOR_MODAL_BODY) : null;
2246

2247
      if (!this._element.parentNode || this._element.parentNode.nodeType !== Node.ELEMENT_NODE) {
2248
        // Don't move modal's DOM position
2249
        document.body.appendChild(this._element);
2250
      }
2251

2252
      this._element.style.display = 'block';
2253

2254
      this._element.removeAttribute('aria-hidden');
2255

2256
      this._element.setAttribute('aria-modal', true);
2257

2258
      this._element.setAttribute('role', 'dialog');
2259

2260
      if ($__default["default"](this._dialog).hasClass(CLASS_NAME_SCROLLABLE) && modalBody) {
2261
        modalBody.scrollTop = 0;
2262
      } else {
2263
        this._element.scrollTop = 0;
2264
      }
2265

2266
      if (transition) {
2267
        Util.reflow(this._element);
2268
      }
2269

2270
      $__default["default"](this._element).addClass(CLASS_NAME_SHOW$4);
2271

2272
      if (this._config.focus) {
2273
        this._enforceFocus();
2274
      }
2275

2276
      var shownEvent = $__default["default"].Event(EVENT_SHOWN$2, {
2277
        relatedTarget: relatedTarget
2278
      });
2279

2280
      var transitionComplete = function transitionComplete() {
2281
        if (_this4._config.focus) {
2282
          _this4._element.focus();
2283
        }
2284

2285
        _this4._isTransitioning = false;
2286
        $__default["default"](_this4._element).trigger(shownEvent);
2287
      };
2288

2289
      if (transition) {
2290
        var transitionDuration = Util.getTransitionDurationFromElement(this._dialog);
2291
        $__default["default"](this._dialog).one(Util.TRANSITION_END, transitionComplete).emulateTransitionEnd(transitionDuration);
2292
      } else {
2293
        transitionComplete();
2294
      }
2295
    };
2296

2297
    _proto._enforceFocus = function _enforceFocus() {
2298
      var _this5 = this;
2299

2300
      $__default["default"](document).off(EVENT_FOCUSIN) // Guard against infinite focus loop
2301
      .on(EVENT_FOCUSIN, function (event) {
2302
        if (document !== event.target && _this5._element !== event.target && $__default["default"](_this5._element).has(event.target).length === 0) {
2303
          _this5._element.focus();
2304
        }
2305
      });
2306
    };
2307

2308
    _proto._setEscapeEvent = function _setEscapeEvent() {
2309
      var _this6 = this;
2310

2311
      if (this._isShown) {
2312
        $__default["default"](this._element).on(EVENT_KEYDOWN_DISMISS, function (event) {
2313
          if (_this6._config.keyboard && event.which === ESCAPE_KEYCODE) {
2314
            event.preventDefault();
2315

2316
            _this6.hide();
2317
          } else if (!_this6._config.keyboard && event.which === ESCAPE_KEYCODE) {
2318
            _this6._triggerBackdropTransition();
2319
          }
2320
        });
2321
      } else if (!this._isShown) {
2322
        $__default["default"](this._element).off(EVENT_KEYDOWN_DISMISS);
2323
      }
2324
    };
2325

2326
    _proto._setResizeEvent = function _setResizeEvent() {
2327
      var _this7 = this;
2328

2329
      if (this._isShown) {
2330
        $__default["default"](window).on(EVENT_RESIZE, function (event) {
2331
          return _this7.handleUpdate(event);
2332
        });
2333
      } else {
2334
        $__default["default"](window).off(EVENT_RESIZE);
2335
      }
2336
    };
2337

2338
    _proto._hideModal = function _hideModal() {
2339
      var _this8 = this;
2340

2341
      this._element.style.display = 'none';
2342

2343
      this._element.setAttribute('aria-hidden', true);
2344

2345
      this._element.removeAttribute('aria-modal');
2346

2347
      this._element.removeAttribute('role');
2348

2349
      this._isTransitioning = false;
2350

2351
      this._showBackdrop(function () {
2352
        $__default["default"](document.body).removeClass(CLASS_NAME_OPEN);
2353

2354
        _this8._resetAdjustments();
2355

2356
        _this8._resetScrollbar();
2357

2358
        $__default["default"](_this8._element).trigger(EVENT_HIDDEN$2);
2359
      });
2360
    };
2361

2362
    _proto._removeBackdrop = function _removeBackdrop() {
2363
      if (this._backdrop) {
2364
        $__default["default"](this._backdrop).remove();
2365
        this._backdrop = null;
2366
      }
2367
    };
2368

2369
    _proto._showBackdrop = function _showBackdrop(callback) {
2370
      var _this9 = this;
2371

2372
      var animate = $__default["default"](this._element).hasClass(CLASS_NAME_FADE$4) ? CLASS_NAME_FADE$4 : '';
2373

2374
      if (this._isShown && this._config.backdrop) {
2375
        this._backdrop = document.createElement('div');
2376
        this._backdrop.className = CLASS_NAME_BACKDROP;
2377

2378
        if (animate) {
2379
          this._backdrop.classList.add(animate);
2380
        }
2381

2382
        $__default["default"](this._backdrop).appendTo(document.body);
2383
        $__default["default"](this._element).on(EVENT_CLICK_DISMISS$1, function (event) {
2384
          if (_this9._ignoreBackdropClick) {
2385
            _this9._ignoreBackdropClick = false;
2386
            return;
2387
          }
2388

2389
          if (event.target !== event.currentTarget) {
2390
            return;
2391
          }
2392

2393
          if (_this9._config.backdrop === 'static') {
2394
            _this9._triggerBackdropTransition();
2395
          } else {
2396
            _this9.hide();
2397
          }
2398
        });
2399

2400
        if (animate) {
2401
          Util.reflow(this._backdrop);
2402
        }
2403

2404
        $__default["default"](this._backdrop).addClass(CLASS_NAME_SHOW$4);
2405

2406
        if (!callback) {
2407
          return;
2408
        }
2409

2410
        if (!animate) {
2411
          callback();
2412
          return;
2413
        }
2414

2415
        var backdropTransitionDuration = Util.getTransitionDurationFromElement(this._backdrop);
2416
        $__default["default"](this._backdrop).one(Util.TRANSITION_END, callback).emulateTransitionEnd(backdropTransitionDuration);
2417
      } else if (!this._isShown && this._backdrop) {
2418
        $__default["default"](this._backdrop).removeClass(CLASS_NAME_SHOW$4);
2419

2420
        var callbackRemove = function callbackRemove() {
2421
          _this9._removeBackdrop();
2422

2423
          if (callback) {
2424
            callback();
2425
          }
2426
        };
2427

2428
        if ($__default["default"](this._element).hasClass(CLASS_NAME_FADE$4)) {
2429
          var _backdropTransitionDuration = Util.getTransitionDurationFromElement(this._backdrop);
2430

2431
          $__default["default"](this._backdrop).one(Util.TRANSITION_END, callbackRemove).emulateTransitionEnd(_backdropTransitionDuration);
2432
        } else {
2433
          callbackRemove();
2434
        }
2435
      } else if (callback) {
2436
        callback();
2437
      }
2438
    } // ----------------------------------------------------------------------
2439
    // the following methods are used to handle overflowing modals
2440
    // todo (fat): these should probably be refactored out of modal.js
2441
    // ----------------------------------------------------------------------
2442
    ;
2443

2444
    _proto._adjustDialog = function _adjustDialog() {
2445
      var isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight;
2446

2447
      if (!this._isBodyOverflowing && isModalOverflowing) {
2448
        this._element.style.paddingLeft = this._scrollbarWidth + "px";
2449
      }
2450

2451
      if (this._isBodyOverflowing && !isModalOverflowing) {
2452
        this._element.style.paddingRight = this._scrollbarWidth + "px";
2453
      }
2454
    };
2455

2456
    _proto._resetAdjustments = function _resetAdjustments() {
2457
      this._element.style.paddingLeft = '';
2458
      this._element.style.paddingRight = '';
2459
    };
2460

2461
    _proto._checkScrollbar = function _checkScrollbar() {
2462
      var rect = document.body.getBoundingClientRect();
2463
      this._isBodyOverflowing = Math.round(rect.left + rect.right) < window.innerWidth;
2464
      this._scrollbarWidth = this._getScrollbarWidth();
2465
    };
2466

2467
    _proto._setScrollbar = function _setScrollbar() {
2468
      var _this10 = this;
2469

2470
      if (this._isBodyOverflowing) {
2471
        // Note: DOMNode.style.paddingRight returns the actual value or '' if not set
2472
        //   while $(DOMNode).css('padding-right') returns the calculated value or 0 if not set
2473
        var fixedContent = [].slice.call(document.querySelectorAll(SELECTOR_FIXED_CONTENT));
2474
        var stickyContent = [].slice.call(document.querySelectorAll(SELECTOR_STICKY_CONTENT)); // Adjust fixed content padding
2475

2476
        $__default["default"](fixedContent).each(function (index, element) {
2477
          var actualPadding = element.style.paddingRight;
2478
          var calculatedPadding = $__default["default"](element).css('padding-right');
2479
          $__default["default"](element).data('padding-right', actualPadding).css('padding-right', parseFloat(calculatedPadding) + _this10._scrollbarWidth + "px");
2480
        }); // Adjust sticky content margin
2481

2482
        $__default["default"](stickyContent).each(function (index, element) {
2483
          var actualMargin = element.style.marginRight;
2484
          var calculatedMargin = $__default["default"](element).css('margin-right');
2485
          $__default["default"](element).data('margin-right', actualMargin).css('margin-right', parseFloat(calculatedMargin) - _this10._scrollbarWidth + "px");
2486
        }); // Adjust body padding
2487

2488
        var actualPadding = document.body.style.paddingRight;
2489
        var calculatedPadding = $__default["default"](document.body).css('padding-right');
2490
        $__default["default"](document.body).data('padding-right', actualPadding).css('padding-right', parseFloat(calculatedPadding) + this._scrollbarWidth + "px");
2491
      }
2492

2493
      $__default["default"](document.body).addClass(CLASS_NAME_OPEN);
2494
    };
2495

2496
    _proto._resetScrollbar = function _resetScrollbar() {
2497
      // Restore fixed content padding
2498
      var fixedContent = [].slice.call(document.querySelectorAll(SELECTOR_FIXED_CONTENT));
2499
      $__default["default"](fixedContent).each(function (index, element) {
2500
        var padding = $__default["default"](element).data('padding-right');
2501
        $__default["default"](element).removeData('padding-right');
2502
        element.style.paddingRight = padding ? padding : '';
2503
      }); // Restore sticky content
2504

2505
      var elements = [].slice.call(document.querySelectorAll("" + SELECTOR_STICKY_CONTENT));
2506
      $__default["default"](elements).each(function (index, element) {
2507
        var margin = $__default["default"](element).data('margin-right');
2508

2509
        if (typeof margin !== 'undefined') {
2510
          $__default["default"](element).css('margin-right', margin).removeData('margin-right');
2511
        }
2512
      }); // Restore body padding
2513

2514
      var padding = $__default["default"](document.body).data('padding-right');
2515
      $__default["default"](document.body).removeData('padding-right');
2516
      document.body.style.paddingRight = padding ? padding : '';
2517
    };
2518

2519
    _proto._getScrollbarWidth = function _getScrollbarWidth() {
2520
      // thx d.walsh
2521
      var scrollDiv = document.createElement('div');
2522
      scrollDiv.className = CLASS_NAME_SCROLLBAR_MEASURER;
2523
      document.body.appendChild(scrollDiv);
2524
      var scrollbarWidth = scrollDiv.getBoundingClientRect().width - scrollDiv.clientWidth;
2525
      document.body.removeChild(scrollDiv);
2526
      return scrollbarWidth;
2527
    } // Static
2528
    ;
2529

2530
    Modal._jQueryInterface = function _jQueryInterface(config, relatedTarget) {
2531
      return this.each(function () {
2532
        var data = $__default["default"](this).data(DATA_KEY$5);
2533

2534
        var _config = _extends({}, Default$4, $__default["default"](this).data(), typeof config === 'object' && config ? config : {});
2535

2536
        if (!data) {
2537
          data = new Modal(this, _config);
2538
          $__default["default"](this).data(DATA_KEY$5, data);
2539
        }
2540

2541
        if (typeof config === 'string') {
2542
          if (typeof data[config] === 'undefined') {
2543
            throw new TypeError("No method named \"" + config + "\"");
2544
          }
2545

2546
          data[config](relatedTarget);
2547
        } else if (_config.show) {
2548
          data.show(relatedTarget);
2549
        }
2550
      });
2551
    };
2552

2553
    _createClass(Modal, null, [{
2554
      key: "VERSION",
2555
      get: function get() {
2556
        return VERSION$5;
2557
      }
2558
    }, {
2559
      key: "Default",
2560
      get: function get() {
2561
        return Default$4;
2562
      }
2563
    }]);
2564

2565
    return Modal;
2566
  }();
2567
  /**
2568
   * Data API implementation
2569
   */
2570

2571

2572
  $__default["default"](document).on(EVENT_CLICK_DATA_API$1, SELECTOR_DATA_TOGGLE$1, function (event) {
2573
    var _this11 = this;
2574

2575
    var target;
2576
    var selector = Util.getSelectorFromElement(this);
2577

2578
    if (selector) {
2579
      target = document.querySelector(selector);
2580
    }
2581

2582
    var config = $__default["default"](target).data(DATA_KEY$5) ? 'toggle' : _extends({}, $__default["default"](target).data(), $__default["default"](this).data());
2583

2584
    if (this.tagName === 'A' || this.tagName === 'AREA') {
2585
      event.preventDefault();
2586
    }
2587

2588
    var $target = $__default["default"](target).one(EVENT_SHOW$2, function (showEvent) {
2589
      if (showEvent.isDefaultPrevented()) {
2590
        // Only register focus restorer if modal will actually get shown
2591
        return;
2592
      }
2593

2594
      $target.one(EVENT_HIDDEN$2, function () {
2595
        if ($__default["default"](_this11).is(':visible')) {
2596
          _this11.focus();
2597
        }
2598
      });
2599
    });
2600

2601
    Modal._jQueryInterface.call($__default["default"](target), config, this);
2602
  });
2603
  /**
2604
   * jQuery
2605
   */
2606

2607
  $__default["default"].fn[NAME$5] = Modal._jQueryInterface;
2608
  $__default["default"].fn[NAME$5].Constructor = Modal;
2609

2610
  $__default["default"].fn[NAME$5].noConflict = function () {
2611
    $__default["default"].fn[NAME$5] = JQUERY_NO_CONFLICT$5;
2612
    return Modal._jQueryInterface;
2613
  };
2614

2615
  /**
2616
   * --------------------------------------------------------------------------
2617
   * Bootstrap (v4.6.1): tools/sanitizer.js
2618
   * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
2619
   * --------------------------------------------------------------------------
2620
   */
2621
  var uriAttrs = ['background', 'cite', 'href', 'itemtype', 'longdesc', 'poster', 'src', 'xlink:href'];
2622
  var ARIA_ATTRIBUTE_PATTERN = /^aria-[\w-]*$/i;
2623
  var DefaultWhitelist = {
2624
    // Global attributes allowed on any supplied element below.
2625
    '*': ['class', 'dir', 'id', 'lang', 'role', ARIA_ATTRIBUTE_PATTERN],
2626
    a: ['target', 'href', 'title', 'rel'],
2627
    area: [],
2628
    b: [],
2629
    br: [],
2630
    col: [],
2631
    code: [],
2632
    div: [],
2633
    em: [],
2634
    hr: [],
2635
    h1: [],
2636
    h2: [],
2637
    h3: [],
2638
    h4: [],
2639
    h5: [],
2640
    h6: [],
2641
    i: [],
2642
    img: ['src', 'srcset', 'alt', 'title', 'width', 'height'],
2643
    li: [],
2644
    ol: [],
2645
    p: [],
2646
    pre: [],
2647
    s: [],
2648
    small: [],
2649
    span: [],
2650
    sub: [],
2651
    sup: [],
2652
    strong: [],
2653
    u: [],
2654
    ul: []
2655
  };
2656
  /**
2657
   * A pattern that recognizes a commonly useful subset of URLs that are safe.
2658
   *
2659
   * Shoutout to Angular https://github.com/angular/angular/blob/12.2.x/packages/core/src/sanitization/url_sanitizer.ts
2660
   */
2661

2662
  var SAFE_URL_PATTERN = /^(?:(?:https?|mailto|ftp|tel|file|sms):|[^#&/:?]*(?:[#/?]|$))/i;
2663
  /**
2664
   * A pattern that matches safe data URLs. Only matches image, video and audio types.
2665
   *
2666
   * Shoutout to Angular https://github.com/angular/angular/blob/12.2.x/packages/core/src/sanitization/url_sanitizer.ts
2667
   */
2668

2669
  var DATA_URL_PATTERN = /^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[\d+/a-z]+=*$/i;
2670

2671
  function allowedAttribute(attr, allowedAttributeList) {
2672
    var attrName = attr.nodeName.toLowerCase();
2673

2674
    if (allowedAttributeList.indexOf(attrName) !== -1) {
2675
      if (uriAttrs.indexOf(attrName) !== -1) {
2676
        return Boolean(SAFE_URL_PATTERN.test(attr.nodeValue) || DATA_URL_PATTERN.test(attr.nodeValue));
2677
      }
2678

2679
      return true;
2680
    }
2681

2682
    var regExp = allowedAttributeList.filter(function (attrRegex) {
2683
      return attrRegex instanceof RegExp;
2684
    }); // Check if a regular expression validates the attribute.
2685

2686
    for (var i = 0, len = regExp.length; i < len; i++) {
2687
      if (regExp[i].test(attrName)) {
2688
        return true;
2689
      }
2690
    }
2691

2692
    return false;
2693
  }
2694

2695
  function sanitizeHtml(unsafeHtml, whiteList, sanitizeFn) {
2696
    if (unsafeHtml.length === 0) {
2697
      return unsafeHtml;
2698
    }
2699

2700
    if (sanitizeFn && typeof sanitizeFn === 'function') {
2701
      return sanitizeFn(unsafeHtml);
2702
    }
2703

2704
    var domParser = new window.DOMParser();
2705
    var createdDocument = domParser.parseFromString(unsafeHtml, 'text/html');
2706
    var whitelistKeys = Object.keys(whiteList);
2707
    var elements = [].slice.call(createdDocument.body.querySelectorAll('*'));
2708

2709
    var _loop = function _loop(i, len) {
2710
      var el = elements[i];
2711
      var elName = el.nodeName.toLowerCase();
2712

2713
      if (whitelistKeys.indexOf(el.nodeName.toLowerCase()) === -1) {
2714
        el.parentNode.removeChild(el);
2715
        return "continue";
2716
      }
2717

2718
      var attributeList = [].slice.call(el.attributes); // eslint-disable-next-line unicorn/prefer-spread
2719

2720
      var whitelistedAttributes = [].concat(whiteList['*'] || [], whiteList[elName] || []);
2721
      attributeList.forEach(function (attr) {
2722
        if (!allowedAttribute(attr, whitelistedAttributes)) {
2723
          el.removeAttribute(attr.nodeName);
2724
        }
2725
      });
2726
    };
2727

2728
    for (var i = 0, len = elements.length; i < len; i++) {
2729
      var _ret = _loop(i);
2730

2731
      if (_ret === "continue") continue;
2732
    }
2733

2734
    return createdDocument.body.innerHTML;
2735
  }
2736

2737
  /**
2738
   * Constants
2739
   */
2740

2741
  var NAME$4 = 'tooltip';
2742
  var VERSION$4 = '4.6.1';
2743
  var DATA_KEY$4 = 'bs.tooltip';
2744
  var EVENT_KEY$4 = "." + DATA_KEY$4;
2745
  var JQUERY_NO_CONFLICT$4 = $__default["default"].fn[NAME$4];
2746
  var CLASS_PREFIX$1 = 'bs-tooltip';
2747
  var BSCLS_PREFIX_REGEX$1 = new RegExp("(^|\\s)" + CLASS_PREFIX$1 + "\\S+", 'g');
2748
  var DISALLOWED_ATTRIBUTES = ['sanitize', 'whiteList', 'sanitizeFn'];
2749
  var CLASS_NAME_FADE$3 = 'fade';
2750
  var CLASS_NAME_SHOW$3 = 'show';
2751
  var HOVER_STATE_SHOW = 'show';
2752
  var HOVER_STATE_OUT = 'out';
2753
  var SELECTOR_TOOLTIP_INNER = '.tooltip-inner';
2754
  var SELECTOR_ARROW = '.arrow';
2755
  var TRIGGER_HOVER = 'hover';
2756
  var TRIGGER_FOCUS = 'focus';
2757
  var TRIGGER_CLICK = 'click';
2758
  var TRIGGER_MANUAL = 'manual';
2759
  var AttachmentMap = {
2760
    AUTO: 'auto',
2761
    TOP: 'top',
2762
    RIGHT: 'right',
2763
    BOTTOM: 'bottom',
2764
    LEFT: 'left'
2765
  };
2766
  var Default$3 = {
2767
    animation: true,
2768
    template: '<div class="tooltip" role="tooltip">' + '<div class="arrow"></div>' + '<div class="tooltip-inner"></div></div>',
2769
    trigger: 'hover focus',
2770
    title: '',
2771
    delay: 0,
2772
    html: false,
2773
    selector: false,
2774
    placement: 'top',
2775
    offset: 0,
2776
    container: false,
2777
    fallbackPlacement: 'flip',
2778
    boundary: 'scrollParent',
2779
    customClass: '',
2780
    sanitize: true,
2781
    sanitizeFn: null,
2782
    whiteList: DefaultWhitelist,
2783
    popperConfig: null
2784
  };
2785
  var DefaultType$3 = {
2786
    animation: 'boolean',
2787
    template: 'string',
2788
    title: '(string|element|function)',
2789
    trigger: 'string',
2790
    delay: '(number|object)',
2791
    html: 'boolean',
2792
    selector: '(string|boolean)',
2793
    placement: '(string|function)',
2794
    offset: '(number|string|function)',
2795
    container: '(string|element|boolean)',
2796
    fallbackPlacement: '(string|array)',
2797
    boundary: '(string|element)',
2798
    customClass: '(string|function)',
2799
    sanitize: 'boolean',
2800
    sanitizeFn: '(null|function)',
2801
    whiteList: 'object',
2802
    popperConfig: '(null|object)'
2803
  };
2804
  var Event$1 = {
2805
    HIDE: "hide" + EVENT_KEY$4,
2806
    HIDDEN: "hidden" + EVENT_KEY$4,
2807
    SHOW: "show" + EVENT_KEY$4,
2808
    SHOWN: "shown" + EVENT_KEY$4,
2809
    INSERTED: "inserted" + EVENT_KEY$4,
2810
    CLICK: "click" + EVENT_KEY$4,
2811
    FOCUSIN: "focusin" + EVENT_KEY$4,
2812
    FOCUSOUT: "focusout" + EVENT_KEY$4,
2813
    MOUSEENTER: "mouseenter" + EVENT_KEY$4,
2814
    MOUSELEAVE: "mouseleave" + EVENT_KEY$4
2815
  };
2816
  /**
2817
   * Class definition
2818
   */
2819

2820
  var Tooltip = /*#__PURE__*/function () {
2821
    function Tooltip(element, config) {
2822
      if (typeof Popper__default["default"] === 'undefined') {
2823
        throw new TypeError('Bootstrap\'s tooltips require Popper (https://popper.js.org)');
2824
      } // Private
2825

2826

2827
      this._isEnabled = true;
2828
      this._timeout = 0;
2829
      this._hoverState = '';
2830
      this._activeTrigger = {};
2831
      this._popper = null; // Protected
2832

2833
      this.element = element;
2834
      this.config = this._getConfig(config);
2835
      this.tip = null;
2836

2837
      this._setListeners();
2838
    } // Getters
2839

2840

2841
    var _proto = Tooltip.prototype;
2842

2843
    // Public
2844
    _proto.enable = function enable() {
2845
      this._isEnabled = true;
2846
    };
2847

2848
    _proto.disable = function disable() {
2849
      this._isEnabled = false;
2850
    };
2851

2852
    _proto.toggleEnabled = function toggleEnabled() {
2853
      this._isEnabled = !this._isEnabled;
2854
    };
2855

2856
    _proto.toggle = function toggle(event) {
2857
      if (!this._isEnabled) {
2858
        return;
2859
      }
2860

2861
      if (event) {
2862
        var dataKey = this.constructor.DATA_KEY;
2863
        var context = $__default["default"](event.currentTarget).data(dataKey);
2864

2865
        if (!context) {
2866
          context = new this.constructor(event.currentTarget, this._getDelegateConfig());
2867
          $__default["default"](event.currentTarget).data(dataKey, context);
2868
        }
2869

2870
        context._activeTrigger.click = !context._activeTrigger.click;
2871

2872
        if (context._isWithActiveTrigger()) {
2873
          context._enter(null, context);
2874
        } else {
2875
          context._leave(null, context);
2876
        }
2877
      } else {
2878
        if ($__default["default"](this.getTipElement()).hasClass(CLASS_NAME_SHOW$3)) {
2879
          this._leave(null, this);
2880

2881
          return;
2882
        }
2883

2884
        this._enter(null, this);
2885
      }
2886
    };
2887

2888
    _proto.dispose = function dispose() {
2889
      clearTimeout(this._timeout);
2890
      $__default["default"].removeData(this.element, this.constructor.DATA_KEY);
2891
      $__default["default"](this.element).off(this.constructor.EVENT_KEY);
2892
      $__default["default"](this.element).closest('.modal').off('hide.bs.modal', this._hideModalHandler);
2893

2894
      if (this.tip) {
2895
        $__default["default"](this.tip).remove();
2896
      }
2897

2898
      this._isEnabled = null;
2899
      this._timeout = null;
2900
      this._hoverState = null;
2901
      this._activeTrigger = null;
2902

2903
      if (this._popper) {
2904
        this._popper.destroy();
2905
      }
2906

2907
      this._popper = null;
2908
      this.element = null;
2909
      this.config = null;
2910
      this.tip = null;
2911
    };
2912

2913
    _proto.show = function show() {
2914
      var _this = this;
2915

2916
      if ($__default["default"](this.element).css('display') === 'none') {
2917
        throw new Error('Please use show on visible elements');
2918
      }
2919

2920
      var showEvent = $__default["default"].Event(this.constructor.Event.SHOW);
2921

2922
      if (this.isWithContent() && this._isEnabled) {
2923
        $__default["default"](this.element).trigger(showEvent);
2924
        var shadowRoot = Util.findShadowRoot(this.element);
2925
        var isInTheDom = $__default["default"].contains(shadowRoot !== null ? shadowRoot : this.element.ownerDocument.documentElement, this.element);
2926

2927
        if (showEvent.isDefaultPrevented() || !isInTheDom) {
2928
          return;
2929
        }
2930

2931
        var tip = this.getTipElement();
2932
        var tipId = Util.getUID(this.constructor.NAME);
2933
        tip.setAttribute('id', tipId);
2934
        this.element.setAttribute('aria-describedby', tipId);
2935
        this.setContent();
2936

2937
        if (this.config.animation) {
2938
          $__default["default"](tip).addClass(CLASS_NAME_FADE$3);
2939
        }
2940

2941
        var placement = typeof this.config.placement === 'function' ? this.config.placement.call(this, tip, this.element) : this.config.placement;
2942

2943
        var attachment = this._getAttachment(placement);
2944

2945
        this.addAttachmentClass(attachment);
2946

2947
        var container = this._getContainer();
2948

2949
        $__default["default"](tip).data(this.constructor.DATA_KEY, this);
2950

2951
        if (!$__default["default"].contains(this.element.ownerDocument.documentElement, this.tip)) {
2952
          $__default["default"](tip).appendTo(container);
2953
        }
2954

2955
        $__default["default"](this.element).trigger(this.constructor.Event.INSERTED);
2956
        this._popper = new Popper__default["default"](this.element, tip, this._getPopperConfig(attachment));
2957
        $__default["default"](tip).addClass(CLASS_NAME_SHOW$3);
2958
        $__default["default"](tip).addClass(this.config.customClass); // If this is a touch-enabled device we add extra
2959
        // empty mouseover listeners to the body's immediate children;
2960
        // only needed because of broken event delegation on iOS
2961
        // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html
2962

2963
        if ('ontouchstart' in document.documentElement) {
2964
          $__default["default"](document.body).children().on('mouseover', null, $__default["default"].noop);
2965
        }
2966

2967
        var complete = function complete() {
2968
          if (_this.config.animation) {
2969
            _this._fixTransition();
2970
          }
2971

2972
          var prevHoverState = _this._hoverState;
2973
          _this._hoverState = null;
2974
          $__default["default"](_this.element).trigger(_this.constructor.Event.SHOWN);
2975

2976
          if (prevHoverState === HOVER_STATE_OUT) {
2977
            _this._leave(null, _this);
2978
          }
2979
        };
2980

2981
        if ($__default["default"](this.tip).hasClass(CLASS_NAME_FADE$3)) {
2982
          var transitionDuration = Util.getTransitionDurationFromElement(this.tip);
2983
          $__default["default"](this.tip).one(Util.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
2984
        } else {
2985
          complete();
2986
        }
2987
      }
2988
    };
2989

2990
    _proto.hide = function hide(callback) {
2991
      var _this2 = this;
2992

2993
      var tip = this.getTipElement();
2994
      var hideEvent = $__default["default"].Event(this.constructor.Event.HIDE);
2995

2996
      var complete = function complete() {
2997
        if (_this2._hoverState !== HOVER_STATE_SHOW && tip.parentNode) {
2998
          tip.parentNode.removeChild(tip);
2999
        }
3000

3001
        _this2._cleanTipClass();
3002

3003
        _this2.element.removeAttribute('aria-describedby');
3004

3005
        $__default["default"](_this2.element).trigger(_this2.constructor.Event.HIDDEN);
3006

3007
        if (_this2._popper !== null) {
3008
          _this2._popper.destroy();
3009
        }
3010

3011
        if (callback) {
3012
          callback();
3013
        }
3014
      };
3015

3016
      $__default["default"](this.element).trigger(hideEvent);
3017

3018
      if (hideEvent.isDefaultPrevented()) {
3019
        return;
3020
      }
3021

3022
      $__default["default"](tip).removeClass(CLASS_NAME_SHOW$3); // If this is a touch-enabled device we remove the extra
3023
      // empty mouseover listeners we added for iOS support
3024

3025
      if ('ontouchstart' in document.documentElement) {
3026
        $__default["default"](document.body).children().off('mouseover', null, $__default["default"].noop);
3027
      }
3028

3029
      this._activeTrigger[TRIGGER_CLICK] = false;
3030
      this._activeTrigger[TRIGGER_FOCUS] = false;
3031
      this._activeTrigger[TRIGGER_HOVER] = false;
3032

3033
      if ($__default["default"](this.tip).hasClass(CLASS_NAME_FADE$3)) {
3034
        var transitionDuration = Util.getTransitionDurationFromElement(tip);
3035
        $__default["default"](tip).one(Util.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
3036
      } else {
3037
        complete();
3038
      }
3039

3040
      this._hoverState = '';
3041
    };
3042

3043
    _proto.update = function update() {
3044
      if (this._popper !== null) {
3045
        this._popper.scheduleUpdate();
3046
      }
3047
    } // Protected
3048
    ;
3049

3050
    _proto.isWithContent = function isWithContent() {
3051
      return Boolean(this.getTitle());
3052
    };
3053

3054
    _proto.addAttachmentClass = function addAttachmentClass(attachment) {
3055
      $__default["default"](this.getTipElement()).addClass(CLASS_PREFIX$1 + "-" + attachment);
3056
    };
3057

3058
    _proto.getTipElement = function getTipElement() {
3059
      this.tip = this.tip || $__default["default"](this.config.template)[0];
3060
      return this.tip;
3061
    };
3062

3063
    _proto.setContent = function setContent() {
3064
      var tip = this.getTipElement();
3065
      this.setElementContent($__default["default"](tip.querySelectorAll(SELECTOR_TOOLTIP_INNER)), this.getTitle());
3066
      $__default["default"](tip).removeClass(CLASS_NAME_FADE$3 + " " + CLASS_NAME_SHOW$3);
3067
    };
3068

3069
    _proto.setElementContent = function setElementContent($element, content) {
3070
      if (typeof content === 'object' && (content.nodeType || content.jquery)) {
3071
        // Content is a DOM node or a jQuery
3072
        if (this.config.html) {
3073
          if (!$__default["default"](content).parent().is($element)) {
3074
            $element.empty().append(content);
3075
          }
3076
        } else {
3077
          $element.text($__default["default"](content).text());
3078
        }
3079

3080
        return;
3081
      }
3082

3083
      if (this.config.html) {
3084
        if (this.config.sanitize) {
3085
          content = sanitizeHtml(content, this.config.whiteList, this.config.sanitizeFn);
3086
        }
3087

3088
        $element.html(content);
3089
      } else {
3090
        $element.text(content);
3091
      }
3092
    };
3093

3094
    _proto.getTitle = function getTitle() {
3095
      var title = this.element.getAttribute('data-original-title');
3096

3097
      if (!title) {
3098
        title = typeof this.config.title === 'function' ? this.config.title.call(this.element) : this.config.title;
3099
      }
3100

3101
      return title;
3102
    } // Private
3103
    ;
3104

3105
    _proto._getPopperConfig = function _getPopperConfig(attachment) {
3106
      var _this3 = this;
3107

3108
      var defaultBsConfig = {
3109
        placement: attachment,
3110
        modifiers: {
3111
          offset: this._getOffset(),
3112
          flip: {
3113
            behavior: this.config.fallbackPlacement
3114
          },
3115
          arrow: {
3116
            element: SELECTOR_ARROW
3117
          },
3118
          preventOverflow: {
3119
            boundariesElement: this.config.boundary
3120
          }
3121
        },
3122
        onCreate: function onCreate(data) {
3123
          if (data.originalPlacement !== data.placement) {
3124
            _this3._handlePopperPlacementChange(data);
3125
          }
3126
        },
3127
        onUpdate: function onUpdate(data) {
3128
          return _this3._handlePopperPlacementChange(data);
3129
        }
3130
      };
3131
      return _extends({}, defaultBsConfig, this.config.popperConfig);
3132
    };
3133

3134
    _proto._getOffset = function _getOffset() {
3135
      var _this4 = this;
3136

3137
      var offset = {};
3138

3139
      if (typeof this.config.offset === 'function') {
3140
        offset.fn = function (data) {
3141
          data.offsets = _extends({}, data.offsets, _this4.config.offset(data.offsets, _this4.element));
3142
          return data;
3143
        };
3144
      } else {
3145
        offset.offset = this.config.offset;
3146
      }
3147

3148
      return offset;
3149
    };
3150

3151
    _proto._getContainer = function _getContainer() {
3152
      if (this.config.container === false) {
3153
        return document.body;
3154
      }
3155

3156
      if (Util.isElement(this.config.container)) {
3157
        return $__default["default"](this.config.container);
3158
      }
3159

3160
      return $__default["default"](document).find(this.config.container);
3161
    };
3162

3163
    _proto._getAttachment = function _getAttachment(placement) {
3164
      return AttachmentMap[placement.toUpperCase()];
3165
    };
3166

3167
    _proto._setListeners = function _setListeners() {
3168
      var _this5 = this;
3169

3170
      var triggers = this.config.trigger.split(' ');
3171
      triggers.forEach(function (trigger) {
3172
        if (trigger === 'click') {
3173
          $__default["default"](_this5.element).on(_this5.constructor.Event.CLICK, _this5.config.selector, function (event) {
3174
            return _this5.toggle(event);
3175
          });
3176
        } else if (trigger !== TRIGGER_MANUAL) {
3177
          var eventIn = trigger === TRIGGER_HOVER ? _this5.constructor.Event.MOUSEENTER : _this5.constructor.Event.FOCUSIN;
3178
          var eventOut = trigger === TRIGGER_HOVER ? _this5.constructor.Event.MOUSELEAVE : _this5.constructor.Event.FOCUSOUT;
3179
          $__default["default"](_this5.element).on(eventIn, _this5.config.selector, function (event) {
3180
            return _this5._enter(event);
3181
          }).on(eventOut, _this5.config.selector, function (event) {
3182
            return _this5._leave(event);
3183
          });
3184
        }
3185
      });
3186

3187
      this._hideModalHandler = function () {
3188
        if (_this5.element) {
3189
          _this5.hide();
3190
        }
3191
      };
3192

3193
      $__default["default"](this.element).closest('.modal').on('hide.bs.modal', this._hideModalHandler);
3194

3195
      if (this.config.selector) {
3196
        this.config = _extends({}, this.config, {
3197
          trigger: 'manual',
3198
          selector: ''
3199
        });
3200
      } else {
3201
        this._fixTitle();
3202
      }
3203
    };
3204

3205
    _proto._fixTitle = function _fixTitle() {
3206
      var titleType = typeof this.element.getAttribute('data-original-title');
3207

3208
      if (this.element.getAttribute('title') || titleType !== 'string') {
3209
        this.element.setAttribute('data-original-title', this.element.getAttribute('title') || '');
3210
        this.element.setAttribute('title', '');
3211
      }
3212
    };
3213

3214
    _proto._enter = function _enter(event, context) {
3215
      var dataKey = this.constructor.DATA_KEY;
3216
      context = context || $__default["default"](event.currentTarget).data(dataKey);
3217

3218
      if (!context) {
3219
        context = new this.constructor(event.currentTarget, this._getDelegateConfig());
3220
        $__default["default"](event.currentTarget).data(dataKey, context);
3221
      }
3222

3223
      if (event) {
3224
        context._activeTrigger[event.type === 'focusin' ? TRIGGER_FOCUS : TRIGGER_HOVER] = true;
3225
      }
3226

3227
      if ($__default["default"](context.getTipElement()).hasClass(CLASS_NAME_SHOW$3) || context._hoverState === HOVER_STATE_SHOW) {
3228
        context._hoverState = HOVER_STATE_SHOW;
3229
        return;
3230
      }
3231

3232
      clearTimeout(context._timeout);
3233
      context._hoverState = HOVER_STATE_SHOW;
3234

3235
      if (!context.config.delay || !context.config.delay.show) {
3236
        context.show();
3237
        return;
3238
      }
3239

3240
      context._timeout = setTimeout(function () {
3241
        if (context._hoverState === HOVER_STATE_SHOW) {
3242
          context.show();
3243
        }
3244
      }, context.config.delay.show);
3245
    };
3246

3247
    _proto._leave = function _leave(event, context) {
3248
      var dataKey = this.constructor.DATA_KEY;
3249
      context = context || $__default["default"](event.currentTarget).data(dataKey);
3250

3251
      if (!context) {
3252
        context = new this.constructor(event.currentTarget, this._getDelegateConfig());
3253
        $__default["default"](event.currentTarget).data(dataKey, context);
3254
      }
3255

3256
      if (event) {
3257
        context._activeTrigger[event.type === 'focusout' ? TRIGGER_FOCUS : TRIGGER_HOVER] = false;
3258
      }
3259

3260
      if (context._isWithActiveTrigger()) {
3261
        return;
3262
      }
3263

3264
      clearTimeout(context._timeout);
3265
      context._hoverState = HOVER_STATE_OUT;
3266

3267
      if (!context.config.delay || !context.config.delay.hide) {
3268
        context.hide();
3269
        return;
3270
      }
3271

3272
      context._timeout = setTimeout(function () {
3273
        if (context._hoverState === HOVER_STATE_OUT) {
3274
          context.hide();
3275
        }
3276
      }, context.config.delay.hide);
3277
    };
3278

3279
    _proto._isWithActiveTrigger = function _isWithActiveTrigger() {
3280
      for (var trigger in this._activeTrigger) {
3281
        if (this._activeTrigger[trigger]) {
3282
          return true;
3283
        }
3284
      }
3285

3286
      return false;
3287
    };
3288

3289
    _proto._getConfig = function _getConfig(config) {
3290
      var dataAttributes = $__default["default"](this.element).data();
3291
      Object.keys(dataAttributes).forEach(function (dataAttr) {
3292
        if (DISALLOWED_ATTRIBUTES.indexOf(dataAttr) !== -1) {
3293
          delete dataAttributes[dataAttr];
3294
        }
3295
      });
3296
      config = _extends({}, this.constructor.Default, dataAttributes, typeof config === 'object' && config ? config : {});
3297

3298
      if (typeof config.delay === 'number') {
3299
        config.delay = {
3300
          show: config.delay,
3301
          hide: config.delay
3302
        };
3303
      }
3304

3305
      if (typeof config.title === 'number') {
3306
        config.title = config.title.toString();
3307
      }
3308

3309
      if (typeof config.content === 'number') {
3310
        config.content = config.content.toString();
3311
      }
3312

3313
      Util.typeCheckConfig(NAME$4, config, this.constructor.DefaultType);
3314

3315
      if (config.sanitize) {
3316
        config.template = sanitizeHtml(config.template, config.whiteList, config.sanitizeFn);
3317
      }
3318

3319
      return config;
3320
    };
3321

3322
    _proto._getDelegateConfig = function _getDelegateConfig() {
3323
      var config = {};
3324

3325
      if (this.config) {
3326
        for (var key in this.config) {
3327
          if (this.constructor.Default[key] !== this.config[key]) {
3328
            config[key] = this.config[key];
3329
          }
3330
        }
3331
      }
3332

3333
      return config;
3334
    };
3335

3336
    _proto._cleanTipClass = function _cleanTipClass() {
3337
      var $tip = $__default["default"](this.getTipElement());
3338
      var tabClass = $tip.attr('class').match(BSCLS_PREFIX_REGEX$1);
3339

3340
      if (tabClass !== null && tabClass.length) {
3341
        $tip.removeClass(tabClass.join(''));
3342
      }
3343
    };
3344

3345
    _proto._handlePopperPlacementChange = function _handlePopperPlacementChange(popperData) {
3346
      this.tip = popperData.instance.popper;
3347

3348
      this._cleanTipClass();
3349

3350
      this.addAttachmentClass(this._getAttachment(popperData.placement));
3351
    };
3352

3353
    _proto._fixTransition = function _fixTransition() {
3354
      var tip = this.getTipElement();
3355
      var initConfigAnimation = this.config.animation;
3356

3357
      if (tip.getAttribute('x-placement') !== null) {
3358
        return;
3359
      }
3360

3361
      $__default["default"](tip).removeClass(CLASS_NAME_FADE$3);
3362
      this.config.animation = false;
3363
      this.hide();
3364
      this.show();
3365
      this.config.animation = initConfigAnimation;
3366
    } // Static
3367
    ;
3368

3369
    Tooltip._jQueryInterface = function _jQueryInterface(config) {
3370
      return this.each(function () {
3371
        var $element = $__default["default"](this);
3372
        var data = $element.data(DATA_KEY$4);
3373

3374
        var _config = typeof config === 'object' && config;
3375

3376
        if (!data && /dispose|hide/.test(config)) {
3377
          return;
3378
        }
3379

3380
        if (!data) {
3381
          data = new Tooltip(this, _config);
3382
          $element.data(DATA_KEY$4, data);
3383
        }
3384

3385
        if (typeof config === 'string') {
3386
          if (typeof data[config] === 'undefined') {
3387
            throw new TypeError("No method named \"" + config + "\"");
3388
          }
3389

3390
          data[config]();
3391
        }
3392
      });
3393
    };
3394

3395
    _createClass(Tooltip, null, [{
3396
      key: "VERSION",
3397
      get: function get() {
3398
        return VERSION$4;
3399
      }
3400
    }, {
3401
      key: "Default",
3402
      get: function get() {
3403
        return Default$3;
3404
      }
3405
    }, {
3406
      key: "NAME",
3407
      get: function get() {
3408
        return NAME$4;
3409
      }
3410
    }, {
3411
      key: "DATA_KEY",
3412
      get: function get() {
3413
        return DATA_KEY$4;
3414
      }
3415
    }, {
3416
      key: "Event",
3417
      get: function get() {
3418
        return Event$1;
3419
      }
3420
    }, {
3421
      key: "EVENT_KEY",
3422
      get: function get() {
3423
        return EVENT_KEY$4;
3424
      }
3425
    }, {
3426
      key: "DefaultType",
3427
      get: function get() {
3428
        return DefaultType$3;
3429
      }
3430
    }]);
3431

3432
    return Tooltip;
3433
  }();
3434
  /**
3435
   * jQuery
3436
   */
3437

3438

3439
  $__default["default"].fn[NAME$4] = Tooltip._jQueryInterface;
3440
  $__default["default"].fn[NAME$4].Constructor = Tooltip;
3441

3442
  $__default["default"].fn[NAME$4].noConflict = function () {
3443
    $__default["default"].fn[NAME$4] = JQUERY_NO_CONFLICT$4;
3444
    return Tooltip._jQueryInterface;
3445
  };
3446

3447
  /**
3448
   * Constants
3449
   */
3450

3451
  var NAME$3 = 'popover';
3452
  var VERSION$3 = '4.6.1';
3453
  var DATA_KEY$3 = 'bs.popover';
3454
  var EVENT_KEY$3 = "." + DATA_KEY$3;
3455
  var JQUERY_NO_CONFLICT$3 = $__default["default"].fn[NAME$3];
3456
  var CLASS_PREFIX = 'bs-popover';
3457
  var BSCLS_PREFIX_REGEX = new RegExp("(^|\\s)" + CLASS_PREFIX + "\\S+", 'g');
3458
  var CLASS_NAME_FADE$2 = 'fade';
3459
  var CLASS_NAME_SHOW$2 = 'show';
3460
  var SELECTOR_TITLE = '.popover-header';
3461
  var SELECTOR_CONTENT = '.popover-body';
3462

3463
  var Default$2 = _extends({}, Tooltip.Default, {
3464
    placement: 'right',
3465
    trigger: 'click',
3466
    content: '',
3467
    template: '<div class="popover" role="tooltip">' + '<div class="arrow"></div>' + '<h3 class="popover-header"></h3>' + '<div class="popover-body"></div></div>'
3468
  });
3469

3470
  var DefaultType$2 = _extends({}, Tooltip.DefaultType, {
3471
    content: '(string|element|function)'
3472
  });
3473

3474
  var Event = {
3475
    HIDE: "hide" + EVENT_KEY$3,
3476
    HIDDEN: "hidden" + EVENT_KEY$3,
3477
    SHOW: "show" + EVENT_KEY$3,
3478
    SHOWN: "shown" + EVENT_KEY$3,
3479
    INSERTED: "inserted" + EVENT_KEY$3,
3480
    CLICK: "click" + EVENT_KEY$3,
3481
    FOCUSIN: "focusin" + EVENT_KEY$3,
3482
    FOCUSOUT: "focusout" + EVENT_KEY$3,
3483
    MOUSEENTER: "mouseenter" + EVENT_KEY$3,
3484
    MOUSELEAVE: "mouseleave" + EVENT_KEY$3
3485
  };
3486
  /**
3487
   * Class definition
3488
   */
3489

3490
  var Popover = /*#__PURE__*/function (_Tooltip) {
3491
    _inheritsLoose(Popover, _Tooltip);
3492

3493
    function Popover() {
3494
      return _Tooltip.apply(this, arguments) || this;
3495
    }
3496

3497
    var _proto = Popover.prototype;
3498

3499
    // Overrides
3500
    _proto.isWithContent = function isWithContent() {
3501
      return this.getTitle() || this._getContent();
3502
    };
3503

3504
    _proto.addAttachmentClass = function addAttachmentClass(attachment) {
3505
      $__default["default"](this.getTipElement()).addClass(CLASS_PREFIX + "-" + attachment);
3506
    };
3507

3508
    _proto.getTipElement = function getTipElement() {
3509
      this.tip = this.tip || $__default["default"](this.config.template)[0];
3510
      return this.tip;
3511
    };
3512

3513
    _proto.setContent = function setContent() {
3514
      var $tip = $__default["default"](this.getTipElement()); // We use append for html objects to maintain js events
3515

3516
      this.setElementContent($tip.find(SELECTOR_TITLE), this.getTitle());
3517

3518
      var content = this._getContent();
3519

3520
      if (typeof content === 'function') {
3521
        content = content.call(this.element);
3522
      }
3523

3524
      this.setElementContent($tip.find(SELECTOR_CONTENT), content);
3525
      $tip.removeClass(CLASS_NAME_FADE$2 + " " + CLASS_NAME_SHOW$2);
3526
    } // Private
3527
    ;
3528

3529
    _proto._getContent = function _getContent() {
3530
      return this.element.getAttribute('data-content') || this.config.content;
3531
    };
3532

3533
    _proto._cleanTipClass = function _cleanTipClass() {
3534
      var $tip = $__default["default"](this.getTipElement());
3535
      var tabClass = $tip.attr('class').match(BSCLS_PREFIX_REGEX);
3536

3537
      if (tabClass !== null && tabClass.length > 0) {
3538
        $tip.removeClass(tabClass.join(''));
3539
      }
3540
    } // Static
3541
    ;
3542

3543
    Popover._jQueryInterface = function _jQueryInterface(config) {
3544
      return this.each(function () {
3545
        var data = $__default["default"](this).data(DATA_KEY$3);
3546

3547
        var _config = typeof config === 'object' ? config : null;
3548

3549
        if (!data && /dispose|hide/.test(config)) {
3550
          return;
3551
        }
3552

3553
        if (!data) {
3554
          data = new Popover(this, _config);
3555
          $__default["default"](this).data(DATA_KEY$3, data);
3556
        }
3557

3558
        if (typeof config === 'string') {
3559
          if (typeof data[config] === 'undefined') {
3560
            throw new TypeError("No method named \"" + config + "\"");
3561
          }
3562

3563
          data[config]();
3564
        }
3565
      });
3566
    };
3567

3568
    _createClass(Popover, null, [{
3569
      key: "VERSION",
3570
      get: // Getters
3571
      function get() {
3572
        return VERSION$3;
3573
      }
3574
    }, {
3575
      key: "Default",
3576
      get: function get() {
3577
        return Default$2;
3578
      }
3579
    }, {
3580
      key: "NAME",
3581
      get: function get() {
3582
        return NAME$3;
3583
      }
3584
    }, {
3585
      key: "DATA_KEY",
3586
      get: function get() {
3587
        return DATA_KEY$3;
3588
      }
3589
    }, {
3590
      key: "Event",
3591
      get: function get() {
3592
        return Event;
3593
      }
3594
    }, {
3595
      key: "EVENT_KEY",
3596
      get: function get() {
3597
        return EVENT_KEY$3;
3598
      }
3599
    }, {
3600
      key: "DefaultType",
3601
      get: function get() {
3602
        return DefaultType$2;
3603
      }
3604
    }]);
3605

3606
    return Popover;
3607
  }(Tooltip);
3608
  /**
3609
   * jQuery
3610
   */
3611

3612

3613
  $__default["default"].fn[NAME$3] = Popover._jQueryInterface;
3614
  $__default["default"].fn[NAME$3].Constructor = Popover;
3615

3616
  $__default["default"].fn[NAME$3].noConflict = function () {
3617
    $__default["default"].fn[NAME$3] = JQUERY_NO_CONFLICT$3;
3618
    return Popover._jQueryInterface;
3619
  };
3620

3621
  /**
3622
   * Constants
3623
   */
3624

3625
  var NAME$2 = 'scrollspy';
3626
  var VERSION$2 = '4.6.1';
3627
  var DATA_KEY$2 = 'bs.scrollspy';
3628
  var EVENT_KEY$2 = "." + DATA_KEY$2;
3629
  var DATA_API_KEY$1 = '.data-api';
3630
  var JQUERY_NO_CONFLICT$2 = $__default["default"].fn[NAME$2];
3631
  var CLASS_NAME_DROPDOWN_ITEM = 'dropdown-item';
3632
  var CLASS_NAME_ACTIVE$1 = 'active';
3633
  var EVENT_ACTIVATE = "activate" + EVENT_KEY$2;
3634
  var EVENT_SCROLL = "scroll" + EVENT_KEY$2;
3635
  var EVENT_LOAD_DATA_API = "load" + EVENT_KEY$2 + DATA_API_KEY$1;
3636
  var METHOD_OFFSET = 'offset';
3637
  var METHOD_POSITION = 'position';
3638
  var SELECTOR_DATA_SPY = '[data-spy="scroll"]';
3639
  var SELECTOR_NAV_LIST_GROUP$1 = '.nav, .list-group';
3640
  var SELECTOR_NAV_LINKS = '.nav-link';
3641
  var SELECTOR_NAV_ITEMS = '.nav-item';
3642
  var SELECTOR_LIST_ITEMS = '.list-group-item';
3643
  var SELECTOR_DROPDOWN$1 = '.dropdown';
3644
  var SELECTOR_DROPDOWN_ITEMS = '.dropdown-item';
3645
  var SELECTOR_DROPDOWN_TOGGLE$1 = '.dropdown-toggle';
3646
  var Default$1 = {
3647
    offset: 10,
3648
    method: 'auto',
3649
    target: ''
3650
  };
3651
  var DefaultType$1 = {
3652
    offset: 'number',
3653
    method: 'string',
3654
    target: '(string|element)'
3655
  };
3656
  /**
3657
   * Class definition
3658
   */
3659

3660
  var ScrollSpy = /*#__PURE__*/function () {
3661
    function ScrollSpy(element, config) {
3662
      var _this = this;
3663

3664
      this._element = element;
3665
      this._scrollElement = element.tagName === 'BODY' ? window : element;
3666
      this._config = this._getConfig(config);
3667
      this._selector = this._config.target + " " + SELECTOR_NAV_LINKS + "," + (this._config.target + " " + SELECTOR_LIST_ITEMS + ",") + (this._config.target + " " + SELECTOR_DROPDOWN_ITEMS);
3668
      this._offsets = [];
3669
      this._targets = [];
3670
      this._activeTarget = null;
3671
      this._scrollHeight = 0;
3672
      $__default["default"](this._scrollElement).on(EVENT_SCROLL, function (event) {
3673
        return _this._process(event);
3674
      });
3675
      this.refresh();
3676

3677
      this._process();
3678
    } // Getters
3679

3680

3681
    var _proto = ScrollSpy.prototype;
3682

3683
    // Public
3684
    _proto.refresh = function refresh() {
3685
      var _this2 = this;
3686

3687
      var autoMethod = this._scrollElement === this._scrollElement.window ? METHOD_OFFSET : METHOD_POSITION;
3688
      var offsetMethod = this._config.method === 'auto' ? autoMethod : this._config.method;
3689
      var offsetBase = offsetMethod === METHOD_POSITION ? this._getScrollTop() : 0;
3690
      this._offsets = [];
3691
      this._targets = [];
3692
      this._scrollHeight = this._getScrollHeight();
3693
      var targets = [].slice.call(document.querySelectorAll(this._selector));
3694
      targets.map(function (element) {
3695
        var target;
3696
        var targetSelector = Util.getSelectorFromElement(element);
3697

3698
        if (targetSelector) {
3699
          target = document.querySelector(targetSelector);
3700
        }
3701

3702
        if (target) {
3703
          var targetBCR = target.getBoundingClientRect();
3704

3705
          if (targetBCR.width || targetBCR.height) {
3706
            // TODO (fat): remove sketch reliance on jQuery position/offset
3707
            return [$__default["default"](target)[offsetMethod]().top + offsetBase, targetSelector];
3708
          }
3709
        }
3710

3711
        return null;
3712
      }).filter(function (item) {
3713
        return item;
3714
      }).sort(function (a, b) {
3715
        return a[0] - b[0];
3716
      }).forEach(function (item) {
3717
        _this2._offsets.push(item[0]);
3718

3719
        _this2._targets.push(item[1]);
3720
      });
3721
    };
3722

3723
    _proto.dispose = function dispose() {
3724
      $__default["default"].removeData(this._element, DATA_KEY$2);
3725
      $__default["default"](this._scrollElement).off(EVENT_KEY$2);
3726
      this._element = null;
3727
      this._scrollElement = null;
3728
      this._config = null;
3729
      this._selector = null;
3730
      this._offsets = null;
3731
      this._targets = null;
3732
      this._activeTarget = null;
3733
      this._scrollHeight = null;
3734
    } // Private
3735
    ;
3736

3737
    _proto._getConfig = function _getConfig(config) {
3738
      config = _extends({}, Default$1, typeof config === 'object' && config ? config : {});
3739

3740
      if (typeof config.target !== 'string' && Util.isElement(config.target)) {
3741
        var id = $__default["default"](config.target).attr('id');
3742

3743
        if (!id) {
3744
          id = Util.getUID(NAME$2);
3745
          $__default["default"](config.target).attr('id', id);
3746
        }
3747

3748
        config.target = "#" + id;
3749
      }
3750

3751
      Util.typeCheckConfig(NAME$2, config, DefaultType$1);
3752
      return config;
3753
    };
3754

3755
    _proto._getScrollTop = function _getScrollTop() {
3756
      return this._scrollElement === window ? this._scrollElement.pageYOffset : this._scrollElement.scrollTop;
3757
    };
3758

3759
    _proto._getScrollHeight = function _getScrollHeight() {
3760
      return this._scrollElement.scrollHeight || Math.max(document.body.scrollHeight, document.documentElement.scrollHeight);
3761
    };
3762

3763
    _proto._getOffsetHeight = function _getOffsetHeight() {
3764
      return this._scrollElement === window ? window.innerHeight : this._scrollElement.getBoundingClientRect().height;
3765
    };
3766

3767
    _proto._process = function _process() {
3768
      var scrollTop = this._getScrollTop() + this._config.offset;
3769

3770
      var scrollHeight = this._getScrollHeight();
3771

3772
      var maxScroll = this._config.offset + scrollHeight - this._getOffsetHeight();
3773

3774
      if (this._scrollHeight !== scrollHeight) {
3775
        this.refresh();
3776
      }
3777

3778
      if (scrollTop >= maxScroll) {
3779
        var target = this._targets[this._targets.length - 1];
3780

3781
        if (this._activeTarget !== target) {
3782
          this._activate(target);
3783
        }
3784

3785
        return;
3786
      }
3787

3788
      if (this._activeTarget && scrollTop < this._offsets[0] && this._offsets[0] > 0) {
3789
        this._activeTarget = null;
3790

3791
        this._clear();
3792

3793
        return;
3794
      }
3795

3796
      for (var i = this._offsets.length; i--;) {
3797
        var isActiveTarget = this._activeTarget !== this._targets[i] && scrollTop >= this._offsets[i] && (typeof this._offsets[i + 1] === 'undefined' || scrollTop < this._offsets[i + 1]);
3798

3799
        if (isActiveTarget) {
3800
          this._activate(this._targets[i]);
3801
        }
3802
      }
3803
    };
3804

3805
    _proto._activate = function _activate(target) {
3806
      this._activeTarget = target;
3807

3808
      this._clear();
3809

3810
      var queries = this._selector.split(',').map(function (selector) {
3811
        return selector + "[data-target=\"" + target + "\"]," + selector + "[href=\"" + target + "\"]";
3812
      });
3813

3814
      var $link = $__default["default"]([].slice.call(document.querySelectorAll(queries.join(','))));
3815

3816
      if ($link.hasClass(CLASS_NAME_DROPDOWN_ITEM)) {
3817
        $link.closest(SELECTOR_DROPDOWN$1).find(SELECTOR_DROPDOWN_TOGGLE$1).addClass(CLASS_NAME_ACTIVE$1);
3818
        $link.addClass(CLASS_NAME_ACTIVE$1);
3819
      } else {
3820
        // Set triggered link as active
3821
        $link.addClass(CLASS_NAME_ACTIVE$1); // Set triggered links parents as active
3822
        // With both <ul> and <nav> markup a parent is the previous sibling of any nav ancestor
3823

3824
        $link.parents(SELECTOR_NAV_LIST_GROUP$1).prev(SELECTOR_NAV_LINKS + ", " + SELECTOR_LIST_ITEMS).addClass(CLASS_NAME_ACTIVE$1); // Handle special case when .nav-link is inside .nav-item
3825

3826
        $link.parents(SELECTOR_NAV_LIST_GROUP$1).prev(SELECTOR_NAV_ITEMS).children(SELECTOR_NAV_LINKS).addClass(CLASS_NAME_ACTIVE$1);
3827
      }
3828

3829
      $__default["default"](this._scrollElement).trigger(EVENT_ACTIVATE, {
3830
        relatedTarget: target
3831
      });
3832
    };
3833

3834
    _proto._clear = function _clear() {
3835
      [].slice.call(document.querySelectorAll(this._selector)).filter(function (node) {
3836
        return node.classList.contains(CLASS_NAME_ACTIVE$1);
3837
      }).forEach(function (node) {
3838
        return node.classList.remove(CLASS_NAME_ACTIVE$1);
3839
      });
3840
    } // Static
3841
    ;
3842

3843
    ScrollSpy._jQueryInterface = function _jQueryInterface(config) {
3844
      return this.each(function () {
3845
        var data = $__default["default"](this).data(DATA_KEY$2);
3846

3847
        var _config = typeof config === 'object' && config;
3848

3849
        if (!data) {
3850
          data = new ScrollSpy(this, _config);
3851
          $__default["default"](this).data(DATA_KEY$2, data);
3852
        }
3853

3854
        if (typeof config === 'string') {
3855
          if (typeof data[config] === 'undefined') {
3856
            throw new TypeError("No method named \"" + config + "\"");
3857
          }
3858

3859
          data[config]();
3860
        }
3861
      });
3862
    };
3863

3864
    _createClass(ScrollSpy, null, [{
3865
      key: "VERSION",
3866
      get: function get() {
3867
        return VERSION$2;
3868
      }
3869
    }, {
3870
      key: "Default",
3871
      get: function get() {
3872
        return Default$1;
3873
      }
3874
    }]);
3875

3876
    return ScrollSpy;
3877
  }();
3878
  /**
3879
   * Data API implementation
3880
   */
3881

3882

3883
  $__default["default"](window).on(EVENT_LOAD_DATA_API, function () {
3884
    var scrollSpys = [].slice.call(document.querySelectorAll(SELECTOR_DATA_SPY));
3885
    var scrollSpysLength = scrollSpys.length;
3886

3887
    for (var i = scrollSpysLength; i--;) {
3888
      var $spy = $__default["default"](scrollSpys[i]);
3889

3890
      ScrollSpy._jQueryInterface.call($spy, $spy.data());
3891
    }
3892
  });
3893
  /**
3894
   * jQuery
3895
   */
3896

3897
  $__default["default"].fn[NAME$2] = ScrollSpy._jQueryInterface;
3898
  $__default["default"].fn[NAME$2].Constructor = ScrollSpy;
3899

3900
  $__default["default"].fn[NAME$2].noConflict = function () {
3901
    $__default["default"].fn[NAME$2] = JQUERY_NO_CONFLICT$2;
3902
    return ScrollSpy._jQueryInterface;
3903
  };
3904

3905
  /**
3906
   * Constants
3907
   */
3908

3909
  var NAME$1 = 'tab';
3910
  var VERSION$1 = '4.6.1';
3911
  var DATA_KEY$1 = 'bs.tab';
3912
  var EVENT_KEY$1 = "." + DATA_KEY$1;
3913
  var DATA_API_KEY = '.data-api';
3914
  var JQUERY_NO_CONFLICT$1 = $__default["default"].fn[NAME$1];
3915
  var CLASS_NAME_DROPDOWN_MENU = 'dropdown-menu';
3916
  var CLASS_NAME_ACTIVE = 'active';
3917
  var CLASS_NAME_DISABLED = 'disabled';
3918
  var CLASS_NAME_FADE$1 = 'fade';
3919
  var CLASS_NAME_SHOW$1 = 'show';
3920
  var EVENT_HIDE$1 = "hide" + EVENT_KEY$1;
3921
  var EVENT_HIDDEN$1 = "hidden" + EVENT_KEY$1;
3922
  var EVENT_SHOW$1 = "show" + EVENT_KEY$1;
3923
  var EVENT_SHOWN$1 = "shown" + EVENT_KEY$1;
3924
  var EVENT_CLICK_DATA_API = "click" + EVENT_KEY$1 + DATA_API_KEY;
3925
  var SELECTOR_DROPDOWN = '.dropdown';
3926
  var SELECTOR_NAV_LIST_GROUP = '.nav, .list-group';
3927
  var SELECTOR_ACTIVE = '.active';
3928
  var SELECTOR_ACTIVE_UL = '> li > .active';
3929
  var SELECTOR_DATA_TOGGLE = '[data-toggle="tab"], [data-toggle="pill"], [data-toggle="list"]';
3930
  var SELECTOR_DROPDOWN_TOGGLE = '.dropdown-toggle';
3931
  var SELECTOR_DROPDOWN_ACTIVE_CHILD = '> .dropdown-menu .active';
3932
  /**
3933
   * Class definition
3934
   */
3935

3936
  var Tab = /*#__PURE__*/function () {
3937
    function Tab(element) {
3938
      this._element = element;
3939
    } // Getters
3940

3941

3942
    var _proto = Tab.prototype;
3943

3944
    // Public
3945
    _proto.show = function show() {
3946
      var _this = this;
3947

3948
      if (this._element.parentNode && this._element.parentNode.nodeType === Node.ELEMENT_NODE && $__default["default"](this._element).hasClass(CLASS_NAME_ACTIVE) || $__default["default"](this._element).hasClass(CLASS_NAME_DISABLED)) {
3949
        return;
3950
      }
3951

3952
      var target;
3953
      var previous;
3954
      var listElement = $__default["default"](this._element).closest(SELECTOR_NAV_LIST_GROUP)[0];
3955
      var selector = Util.getSelectorFromElement(this._element);
3956

3957
      if (listElement) {
3958
        var itemSelector = listElement.nodeName === 'UL' || listElement.nodeName === 'OL' ? SELECTOR_ACTIVE_UL : SELECTOR_ACTIVE;
3959
        previous = $__default["default"].makeArray($__default["default"](listElement).find(itemSelector));
3960
        previous = previous[previous.length - 1];
3961
      }
3962

3963
      var hideEvent = $__default["default"].Event(EVENT_HIDE$1, {
3964
        relatedTarget: this._element
3965
      });
3966
      var showEvent = $__default["default"].Event(EVENT_SHOW$1, {
3967
        relatedTarget: previous
3968
      });
3969

3970
      if (previous) {
3971
        $__default["default"](previous).trigger(hideEvent);
3972
      }
3973

3974
      $__default["default"](this._element).trigger(showEvent);
3975

3976
      if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) {
3977
        return;
3978
      }
3979

3980
      if (selector) {
3981
        target = document.querySelector(selector);
3982
      }
3983

3984
      this._activate(this._element, listElement);
3985

3986
      var complete = function complete() {
3987
        var hiddenEvent = $__default["default"].Event(EVENT_HIDDEN$1, {
3988
          relatedTarget: _this._element
3989
        });
3990
        var shownEvent = $__default["default"].Event(EVENT_SHOWN$1, {
3991
          relatedTarget: previous
3992
        });
3993
        $__default["default"](previous).trigger(hiddenEvent);
3994
        $__default["default"](_this._element).trigger(shownEvent);
3995
      };
3996

3997
      if (target) {
3998
        this._activate(target, target.parentNode, complete);
3999
      } else {
4000
        complete();
4001
      }
4002
    };
4003

4004
    _proto.dispose = function dispose() {
4005
      $__default["default"].removeData(this._element, DATA_KEY$1);
4006
      this._element = null;
4007
    } // Private
4008
    ;
4009

4010
    _proto._activate = function _activate(element, container, callback) {
4011
      var _this2 = this;
4012

4013
      var activeElements = container && (container.nodeName === 'UL' || container.nodeName === 'OL') ? $__default["default"](container).find(SELECTOR_ACTIVE_UL) : $__default["default"](container).children(SELECTOR_ACTIVE);
4014
      var active = activeElements[0];
4015
      var isTransitioning = callback && active && $__default["default"](active).hasClass(CLASS_NAME_FADE$1);
4016

4017
      var complete = function complete() {
4018
        return _this2._transitionComplete(element, active, callback);
4019
      };
4020

4021
      if (active && isTransitioning) {
4022
        var transitionDuration = Util.getTransitionDurationFromElement(active);
4023
        $__default["default"](active).removeClass(CLASS_NAME_SHOW$1).one(Util.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
4024
      } else {
4025
        complete();
4026
      }
4027
    };
4028

4029
    _proto._transitionComplete = function _transitionComplete(element, active, callback) {
4030
      if (active) {
4031
        $__default["default"](active).removeClass(CLASS_NAME_ACTIVE);
4032
        var dropdownChild = $__default["default"](active.parentNode).find(SELECTOR_DROPDOWN_ACTIVE_CHILD)[0];
4033

4034
        if (dropdownChild) {
4035
          $__default["default"](dropdownChild).removeClass(CLASS_NAME_ACTIVE);
4036
        }
4037

4038
        if (active.getAttribute('role') === 'tab') {
4039
          active.setAttribute('aria-selected', false);
4040
        }
4041
      }
4042

4043
      $__default["default"](element).addClass(CLASS_NAME_ACTIVE);
4044

4045
      if (element.getAttribute('role') === 'tab') {
4046
        element.setAttribute('aria-selected', true);
4047
      }
4048

4049
      Util.reflow(element);
4050

4051
      if (element.classList.contains(CLASS_NAME_FADE$1)) {
4052
        element.classList.add(CLASS_NAME_SHOW$1);
4053
      }
4054

4055
      var parent = element.parentNode;
4056

4057
      if (parent && parent.nodeName === 'LI') {
4058
        parent = parent.parentNode;
4059
      }
4060

4061
      if (parent && $__default["default"](parent).hasClass(CLASS_NAME_DROPDOWN_MENU)) {
4062
        var dropdownElement = $__default["default"](element).closest(SELECTOR_DROPDOWN)[0];
4063

4064
        if (dropdownElement) {
4065
          var dropdownToggleList = [].slice.call(dropdownElement.querySelectorAll(SELECTOR_DROPDOWN_TOGGLE));
4066
          $__default["default"](dropdownToggleList).addClass(CLASS_NAME_ACTIVE);
4067
        }
4068

4069
        element.setAttribute('aria-expanded', true);
4070
      }
4071

4072
      if (callback) {
4073
        callback();
4074
      }
4075
    } // Static
4076
    ;
4077

4078
    Tab._jQueryInterface = function _jQueryInterface(config) {
4079
      return this.each(function () {
4080
        var $this = $__default["default"](this);
4081
        var data = $this.data(DATA_KEY$1);
4082

4083
        if (!data) {
4084
          data = new Tab(this);
4085
          $this.data(DATA_KEY$1, data);
4086
        }
4087

4088
        if (typeof config === 'string') {
4089
          if (typeof data[config] === 'undefined') {
4090
            throw new TypeError("No method named \"" + config + "\"");
4091
          }
4092

4093
          data[config]();
4094
        }
4095
      });
4096
    };
4097

4098
    _createClass(Tab, null, [{
4099
      key: "VERSION",
4100
      get: function get() {
4101
        return VERSION$1;
4102
      }
4103
    }]);
4104

4105
    return Tab;
4106
  }();
4107
  /**
4108
   * Data API implementation
4109
   */
4110

4111

4112
  $__default["default"](document).on(EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE, function (event) {
4113
    event.preventDefault();
4114

4115
    Tab._jQueryInterface.call($__default["default"](this), 'show');
4116
  });
4117
  /**
4118
   * jQuery
4119
   */
4120

4121
  $__default["default"].fn[NAME$1] = Tab._jQueryInterface;
4122
  $__default["default"].fn[NAME$1].Constructor = Tab;
4123

4124
  $__default["default"].fn[NAME$1].noConflict = function () {
4125
    $__default["default"].fn[NAME$1] = JQUERY_NO_CONFLICT$1;
4126
    return Tab._jQueryInterface;
4127
  };
4128

4129
  /**
4130
   * Constants
4131
   */
4132

4133
  var NAME = 'toast';
4134
  var VERSION = '4.6.1';
4135
  var DATA_KEY = 'bs.toast';
4136
  var EVENT_KEY = "." + DATA_KEY;
4137
  var JQUERY_NO_CONFLICT = $__default["default"].fn[NAME];
4138
  var CLASS_NAME_FADE = 'fade';
4139
  var CLASS_NAME_HIDE = 'hide';
4140
  var CLASS_NAME_SHOW = 'show';
4141
  var CLASS_NAME_SHOWING = 'showing';
4142
  var EVENT_CLICK_DISMISS = "click.dismiss" + EVENT_KEY;
4143
  var EVENT_HIDE = "hide" + EVENT_KEY;
4144
  var EVENT_HIDDEN = "hidden" + EVENT_KEY;
4145
  var EVENT_SHOW = "show" + EVENT_KEY;
4146
  var EVENT_SHOWN = "shown" + EVENT_KEY;
4147
  var SELECTOR_DATA_DISMISS = '[data-dismiss="toast"]';
4148
  var Default = {
4149
    animation: true,
4150
    autohide: true,
4151
    delay: 500
4152
  };
4153
  var DefaultType = {
4154
    animation: 'boolean',
4155
    autohide: 'boolean',
4156
    delay: 'number'
4157
  };
4158
  /**
4159
   * Class definition
4160
   */
4161

4162
  var Toast = /*#__PURE__*/function () {
4163
    function Toast(element, config) {
4164
      this._element = element;
4165
      this._config = this._getConfig(config);
4166
      this._timeout = null;
4167

4168
      this._setListeners();
4169
    } // Getters
4170

4171

4172
    var _proto = Toast.prototype;
4173

4174
    // Public
4175
    _proto.show = function show() {
4176
      var _this = this;
4177

4178
      var showEvent = $__default["default"].Event(EVENT_SHOW);
4179
      $__default["default"](this._element).trigger(showEvent);
4180

4181
      if (showEvent.isDefaultPrevented()) {
4182
        return;
4183
      }
4184

4185
      this._clearTimeout();
4186

4187
      if (this._config.animation) {
4188
        this._element.classList.add(CLASS_NAME_FADE);
4189
      }
4190

4191
      var complete = function complete() {
4192
        _this._element.classList.remove(CLASS_NAME_SHOWING);
4193

4194
        _this._element.classList.add(CLASS_NAME_SHOW);
4195

4196
        $__default["default"](_this._element).trigger(EVENT_SHOWN);
4197

4198
        if (_this._config.autohide) {
4199
          _this._timeout = setTimeout(function () {
4200
            _this.hide();
4201
          }, _this._config.delay);
4202
        }
4203
      };
4204

4205
      this._element.classList.remove(CLASS_NAME_HIDE);
4206

4207
      Util.reflow(this._element);
4208

4209
      this._element.classList.add(CLASS_NAME_SHOWING);
4210

4211
      if (this._config.animation) {
4212
        var transitionDuration = Util.getTransitionDurationFromElement(this._element);
4213
        $__default["default"](this._element).one(Util.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
4214
      } else {
4215
        complete();
4216
      }
4217
    };
4218

4219
    _proto.hide = function hide() {
4220
      if (!this._element.classList.contains(CLASS_NAME_SHOW)) {
4221
        return;
4222
      }
4223

4224
      var hideEvent = $__default["default"].Event(EVENT_HIDE);
4225
      $__default["default"](this._element).trigger(hideEvent);
4226

4227
      if (hideEvent.isDefaultPrevented()) {
4228
        return;
4229
      }
4230

4231
      this._close();
4232
    };
4233

4234
    _proto.dispose = function dispose() {
4235
      this._clearTimeout();
4236

4237
      if (this._element.classList.contains(CLASS_NAME_SHOW)) {
4238
        this._element.classList.remove(CLASS_NAME_SHOW);
4239
      }
4240

4241
      $__default["default"](this._element).off(EVENT_CLICK_DISMISS);
4242
      $__default["default"].removeData(this._element, DATA_KEY);
4243
      this._element = null;
4244
      this._config = null;
4245
    } // Private
4246
    ;
4247

4248
    _proto._getConfig = function _getConfig(config) {
4249
      config = _extends({}, Default, $__default["default"](this._element).data(), typeof config === 'object' && config ? config : {});
4250
      Util.typeCheckConfig(NAME, config, this.constructor.DefaultType);
4251
      return config;
4252
    };
4253

4254
    _proto._setListeners = function _setListeners() {
4255
      var _this2 = this;
4256

4257
      $__default["default"](this._element).on(EVENT_CLICK_DISMISS, SELECTOR_DATA_DISMISS, function () {
4258
        return _this2.hide();
4259
      });
4260
    };
4261

4262
    _proto._close = function _close() {
4263
      var _this3 = this;
4264

4265
      var complete = function complete() {
4266
        _this3._element.classList.add(CLASS_NAME_HIDE);
4267

4268
        $__default["default"](_this3._element).trigger(EVENT_HIDDEN);
4269
      };
4270

4271
      this._element.classList.remove(CLASS_NAME_SHOW);
4272

4273
      if (this._config.animation) {
4274
        var transitionDuration = Util.getTransitionDurationFromElement(this._element);
4275
        $__default["default"](this._element).one(Util.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
4276
      } else {
4277
        complete();
4278
      }
4279
    };
4280

4281
    _proto._clearTimeout = function _clearTimeout() {
4282
      clearTimeout(this._timeout);
4283
      this._timeout = null;
4284
    } // Static
4285
    ;
4286

4287
    Toast._jQueryInterface = function _jQueryInterface(config) {
4288
      return this.each(function () {
4289
        var $element = $__default["default"](this);
4290
        var data = $element.data(DATA_KEY);
4291

4292
        var _config = typeof config === 'object' && config;
4293

4294
        if (!data) {
4295
          data = new Toast(this, _config);
4296
          $element.data(DATA_KEY, data);
4297
        }
4298

4299
        if (typeof config === 'string') {
4300
          if (typeof data[config] === 'undefined') {
4301
            throw new TypeError("No method named \"" + config + "\"");
4302
          }
4303

4304
          data[config](this);
4305
        }
4306
      });
4307
    };
4308

4309
    _createClass(Toast, null, [{
4310
      key: "VERSION",
4311
      get: function get() {
4312
        return VERSION;
4313
      }
4314
    }, {
4315
      key: "DefaultType",
4316
      get: function get() {
4317
        return DefaultType;
4318
      }
4319
    }, {
4320
      key: "Default",
4321
      get: function get() {
4322
        return Default;
4323
      }
4324
    }]);
4325

4326
    return Toast;
4327
  }();
4328
  /**
4329
   * jQuery
4330
   */
4331

4332

4333
  $__default["default"].fn[NAME] = Toast._jQueryInterface;
4334
  $__default["default"].fn[NAME].Constructor = Toast;
4335

4336
  $__default["default"].fn[NAME].noConflict = function () {
4337
    $__default["default"].fn[NAME] = JQUERY_NO_CONFLICT;
4338
    return Toast._jQueryInterface;
4339
  };
4340

4341
  exports.Alert = Alert;
4342
  exports.Button = Button;
4343
  exports.Carousel = Carousel;
4344
  exports.Collapse = Collapse;
4345
  exports.Dropdown = Dropdown;
4346
  exports.Modal = Modal;
4347
  exports.Popover = Popover;
4348
  exports.Scrollspy = ScrollSpy;
4349
  exports.Tab = Tab;
4350
  exports.Toast = Toast;
4351
  exports.Tooltip = Tooltip;
4352
  exports.Util = Util;
4353

4354
  Object.defineProperty(exports, '__esModule', { value: true });
4355

4356
}));
4357
//# sourceMappingURL=bootstrap.js.map
4358

Использование cookies

Мы используем файлы cookie в соответствии с Политикой конфиденциальности и Политикой использования cookies.

Нажимая кнопку «Принимаю», Вы даете АО «СберТех» согласие на обработку Ваших персональных данных в целях совершенствования нашего веб-сайта и Сервиса GitVerse, а также повышения удобства их использования.

Запретить использование cookies Вы можете самостоятельно в настройках Вашего браузера.