vendor: 5,337 bytes, lines 1-191
1/*! 2 * Generated using the Bootstrap Customizer (https://getbootstrap.com/docs/3.4/customize/) 3 */ 4 5/*! 6 * Bootstrap v3.4.1 (https://getbootstrap.com/) 7 * Copyright 2011-2020 Twitter, Inc. 8 * Licensed under the MIT license 9 */ 10 11if (typeof jQuery === 'undefined') { 12 throw new Error('Bootstrap\'s JavaScript requires jQuery') 13} 14+function ($) { 15 'use strict'; 16 var version = $.fn.jquery.split(' ')[0].split('.') 17 if ((version[0] < 2 && version[1] < 9) || (version[0] == 1 && version[1] == 9 && version[2] < 1) || (version[0] > 3)) { 18 throw new Error('Bootstrap\'s JavaScript requires jQuery version 1.9.1 or higher, but lower than version 4') 19 } 20}(jQuery); 21 22/* ======================================================================== 23 * Bootstrap: alert.js v3.4.1 24 * https://getbootstrap.com/docs/3.4/javascript/#alerts 25 * ======================================================================== 26 * Copyright 2011-2019 Twitter, Inc. 27 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 28 * ======================================================================== */ 29 30 31+function ($) { 32 'use strict'; 33 34 // ALERT CLASS DEFINITION 35 // ====================== 36 37 var dismiss = '[data-dismiss="alert"]' 38 var Alert = function (el) { 39 $(el).on('click', dismiss, this.close) 40 } 41 42 Alert.VERSION = '3.4.1' 43 44 Alert.TRANSITION_DURATION = 150 45 46 Alert.prototype.close = function (e) { 47 var $this = $(this) 48 var selector = $this.attr('data-target') 49 50 if (!selector) { 51 selector = $this.attr('href') 52 selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7 53 } 54 55 selector = selector === '#' ? [] : selector 56 var $parent = $(document).find(selector) 57 58 if (e) e.preventDefault() 59 60 if (!$parent.length) { 61 $parent = $this.closest('.alert') 62 } 63 64 $parent.trigger(e = $.Event('close.bs.alert')) 65 66 if (e.isDefaultPrevented()) return 67 68 $parent.removeClass('in') 69 70 function removeElement() { 71 // detach from parent, fire event then clean up data 72 $parent.detach().trigger('closed.bs.alert').remove() 73 } 74 75 $.support.transition && $parent.hasClass('fade') ? 76 $parent 77 .one('bsTransitionEnd', removeElement) 78 .emulateTransitionEnd(Alert.TRANSITION_DURATION) : 79 removeElement() 80 } 81 82 83 // ALERT PLUGIN DEFINITION 84 // ======================= 85 86 function Plugin(option) { 87 return this.each(function () { 88 var $this = $(this) 89 var data = $this.data('bs.alert') 90 91 if (!data) $this.data('bs.alert', (data = new Alert(this))) 92 if (typeof option == 'string') data[option].call($this) 93 }) 94 } 95 96 var old = $.fn.alert 97 98 $.fn.alert = Plugin 99 $.fn.alert.Constructor = Alert 100 101 102 // ALERT NO CONFLICT 103 // ================= 104 105 $.fn.alert.noConflict = function () { 106 $.fn.alert = old 107 return this 108 } 109 110 111 // ALERT DATA-API 112 // ============== 113 114 $(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close) 115 116}(jQuery); 117 118/* ======================================================================== 119 * Bootstrap: button.js v3.4.1 120 * https://getbootstrap.com/docs/3.4/javascript/#buttons 121 * ======================================================================== 122 * Copyright 2011-2019 Twitter, Inc. 123 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 124 * ======================================================================== */ 125 126 127+function ($) { 128 'use strict'; 129 130 // BUTTON PUBLIC CLASS DEFINITION 131 // ============================== 132 133 var Button = function (element, options) { 134 this.$element = $(element) 135 this.options = $.extend({}, Button.DEFAULTS, options) 136 this.isLoading = false 137 } 138 139 Button.VERSION = '3.4.1' 140 141 Button.DEFAULTS = { 142 loadingText: 'loading...' 143 } 144 145 Button.prototype.setState = function (state) { 146 var d = 'disabled' 147 var $el = this.$element 148 var val = $el.is('input') ? 'val' : 'html' 149 var data = $el.data() 150 151 state += 'Text' 152 153 if (data.resetText == null) $el.data('resetText', $el[val]()) 154 155 // push to event loop to allow forms to submit 156 setTimeout($.proxy(function () { 157 $el[val](data[state] == null ? this.options[state] : data[state]) 158 159 if (state == 'loadingText') { 160 this.isLoading = true 161 $el.addClass(d).attr(d, d).prop(d, true) 162 } else if (this.isLoading) { 163 this.isLoading = false 164 $el.removeClass(d).removeAttr(d).prop(d, false) 165 } 166 }, this), 0) 167 } 168 169 Button.prototype.toggle = function () { 170 var changed = true 171 var $parent = this.$element.closest('[data-toggle="buttons"]') 172 173 if ($parent.length) { 174 var $input = this.$element.find('input') 175 if ($input.prop('type') == 'radio') { 176 if ($input.prop('checked')) changed = false 177 $parent.find('.active').removeClass('active') 178 this.$element.addClass('active') 179 } else if ($input.prop('type') == 'checkbox') { 180 if (($input.prop('checked')) !== this.$element.hasClass('active')) changed = false 181 this.$element.toggleClass('active') 182 } 183 $input.prop('checked', this.$element.hasClass('active')) 184 if (changed) $input.trigger('change') 185 } else { 186 this.$element.attr('aria-pressed', !this.$element.hasClass('active')) 187 this.$element.toggleClass('active') 188 } 189 } 190 191
vendor: 8,772 bytes, lines 192-486
192 // BUTTON PLUGIN DEFINITION 193 // ======================== 194 195 function Plugin(option) { 196 return this.each(function () { 197 var $this = $(this) 198 var data = $this.data('bs.button') 199 var options = typeof option == 'object' && option 200 201 if (!data) $this.data('bs.button', (data = new Button(this, options))) 202 203 if (option == 'toggle') data.toggle() 204 else if (option) data.setState(option) 205 }) 206 } 207 208 var old = $.fn.button 209 210 $.fn.button = Plugin 211 $.fn.button.Constructor = Button 212 213 214 // BUTTON NO CONFLICT 215 // ================== 216 217 $.fn.button.noConflict = function () { 218 $.fn.button = old 219 return this 220 } 221 222 223 // BUTTON DATA-API 224 // =============== 225 226 $(document) 227 .on('click.bs.button.data-api', '[data-toggle^="button"]', function (e) { 228 var $btn = $(e.target).closest('.btn') 229 Plugin.call($btn, 'toggle') 230 if (!($(e.target).is('input[type="radio"], input[type="checkbox"]'))) { 231 // Prevent double click on radios, and the double selections (so cancellation) on checkboxes 232 e.preventDefault() 233 // The target component still receive the focus 234 if ($btn.is('input,button')) $btn.trigger('focus') 235 else $btn.find('input:visible,button:visible').first().trigger('focus') 236 } 237 }) 238 .on('focus.bs.button.data-api blur.bs.button.data-api', '[data-toggle^="button"]', function (e) { 239 $(e.target).closest('.btn').toggleClass('focus', /^focus(in)?$/.test(e.type)) 240 }) 241 242}(jQuery); 243 244/* ======================================================================== 245 * Bootstrap: carousel.js v3.4.1 246 * https://getbootstrap.com/docs/3.4/javascript/#carousel 247 * ======================================================================== 248 * Copyright 2011-2019 Twitter, Inc. 249 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 250 * ======================================================================== */ 251 252 253+function ($) { 254 'use strict'; 255 256 // CAROUSEL CLASS DEFINITION 257 // ========================= 258 259 var Carousel = function (element, options) { 260 this.$element = $(element) 261 this.$indicators = this.$element.find('.carousel-indicators') 262 this.options = options 263 this.paused = null 264 this.sliding = null 265 this.interval = null 266 this.$active = null 267 this.$items = null 268 269 this.options.keyboard && this.$element.on('keydown.bs.carousel', $.proxy(this.keydown, this)) 270 271 this.options.pause == 'hover' && !('ontouchstart' in document.documentElement) && this.$element 272 .on('mouseenter.bs.carousel', $.proxy(this.pause, this)) 273 .on('mouseleave.bs.carousel', $.proxy(this.cycle, this)) 274 } 275 276 Carousel.VERSION = '3.4.1' 277 278 Carousel.TRANSITION_DURATION = 600 279 280 Carousel.DEFAULTS = { 281 interval: 5000, 282 pause: 'hover', 283 wrap: true, 284 keyboard: true 285 } 286 287 Carousel.prototype.keydown = function (e) { 288 if (/input|textarea/i.test(e.target.tagName)) return 289 switch (e.which) { 290 case 37: this.prev(); break 291 case 39: this.next(); break 292 default: return 293 } 294 295 e.preventDefault() 296 } 297 298 Carousel.prototype.cycle = function (e) { 299 e || (this.paused = false) 300 301 this.interval && clearInterval(this.interval) 302 303 this.options.interval 304 && !this.paused 305 && (this.interval = setInterval($.proxy(this.next, this), this.options.interval)) 306 307 return this 308 } 309 310 Carousel.prototype.getItemIndex = function (item) { 311 this.$items = item.parent().children('.item') 312 return this.$items.index(item || this.$active) 313 } 314 315 Carousel.prototype.getItemForDirection = function (direction, active) { 316 var activeIndex = this.getItemIndex(active) 317 var willWrap = (direction == 'prev' && activeIndex === 0) 318 || (direction == 'next' && activeIndex == (this.$items.length - 1)) 319 if (willWrap && !this.options.wrap) return active 320 var delta = direction == 'prev' ? -1 : 1 321 var itemIndex = (activeIndex + delta) % this.$items.length 322 return this.$items.eq(itemIndex) 323 } 324 325 Carousel.prototype.to = function (pos) { 326 var that = this 327 var activeIndex = this.getItemIndex(this.$active = this.$element.find('.item.active')) 328 329 if (pos > (this.$items.length - 1) || pos < 0) return 330 331 if (this.sliding) return this.$element.one('slid.bs.carousel', function () { that.to(pos) }) // yes, "slid" 332 if (activeIndex == pos) return this.pause().cycle() 333 334 return this.slide(pos > activeIndex ? 'next' : 'prev', this.$items.eq(pos)) 335 } 336 337 Carousel.prototype.pause = function (e) { 338 e || (this.paused = true) 339 340 if (this.$element.find('.next, .prev').length && $.support.transition) { 341 this.$element.trigger($.support.transition.end) 342 this.cycle(true) 343 } 344 345 this.interval = clearInterval(this.interval) 346 347 return this 348 } 349 350 Carousel.prototype.next = function () { 351 if (this.sliding) return 352 return this.slide('next') 353 } 354 355 Carousel.prototype.prev = function () { 356 if (this.sliding) return 357 return this.slide('prev') 358 } 359 360 Carousel.prototype.slide = function (type, next) { 361 var $active = this.$element.find('.item.active') 362 var $next = next || this.getItemForDirection(type, $active) 363 var isCycling = this.interval 364 var direction = type == 'next' ? 'left' : 'right' 365 var that = this 366 367 if ($next.hasClass('active')) return (this.sliding = false) 368 369 var relatedTarget = $next[0] 370 var slideEvent = $.Event('slide.bs.carousel', { 371 relatedTarget: relatedTarget, 372 direction: direction 373 }) 374 this.$element.trigger(slideEvent) 375 if (slideEvent.isDefaultPrevented()) return 376 377 this.sliding = true 378 379 isCycling && this.pause() 380 381 if (this.$indicators.length) { 382 this.$indicators.find('.active').removeClass('active') 383 var $nextIndicator = $(this.$indicators.children()[this.getItemIndex($next)]) 384 $nextIndicator && $nextIndicator.addClass('active') 385 } 386 387 var slidEvent = $.Event('slid.bs.carousel', { relatedTarget: relatedTarget, direction: direction }) // yes, "slid" 388 if ($.support.transition && this.$element.hasClass('slide')) { 389 $next.addClass(type) 390 if (typeof $next === 'object' && $next.length) { 391 $next[0].offsetWidth // force reflow 392 } 393 $active.addClass(direction) 394 $next.addClass(direction) 395 $active 396 .one('bsTransitionEnd', function () { 397 $next.removeClass([type, direction].join(' ')).addClass('active') 398 $active.removeClass(['active', direction].join(' ')) 399 that.sliding = false 400 setTimeout(function () { 401 that.$element.trigger(slidEvent) 402 }, 0) 403 }) 404 .emulateTransitionEnd(Carousel.TRANSITION_DURATION) 405 } else { 406 $active.removeClass('active') 407 $next.addClass('active') 408 this.sliding = false 409 this.$element.trigger(slidEvent) 410 } 411 412 isCycling && this.cycle() 413 414 return this 415 } 416 417 418 // CAROUSEL PLUGIN DEFINITION 419 // ========================== 420 421 function Plugin(option) { 422 return this.each(function () { 423 var $this = $(this) 424 var data = $this.data('bs.carousel') 425 var options = $.extend({}, Carousel.DEFAULTS, $this.data(), typeof option == 'object' && option) 426 var action = typeof option == 'string' ? option : options.slide 427 428 if (!data) $this.data('bs.carousel', (data = new Carousel(this, options))) 429 if (typeof option == 'number') data.to(option) 430 else if (action) data[action]() 431 else if (options.interval) data.pause().cycle() 432 }) 433 } 434 435 var old = $.fn.carousel 436 437 $.fn.carousel = Plugin 438 $.fn.carousel.Constructor = Carousel 439 440 441 // CAROUSEL NO CONFLICT 442 // ==================== 443 444 $.fn.carousel.noConflict = function () { 445 $.fn.carousel = old 446 return this 447 } 448 449 450 // CAROUSEL DATA-API 451 // ================= 452 453 var clickHandler = function (e) { 454 var $this = $(this) 455 var href = $this.attr('href') 456 if (href) { 457 href = href.replace(/.*(?=#[^\s]+$)/, '') // strip for ie7 458 } 459 460 var target = $this.attr('data-target') || href 461 var $target = $(document).find(target) 462 463 if (!$target.hasClass('carousel')) return 464 465 var options = $.extend({}, $target.data(), $this.data()) 466 var slideIndex = $this.attr('data-slide-to') 467 if (slideIndex) options.interval = false 468 469 Plugin.call($target, options) 470 471 if (slideIndex) { 472 $target.data('bs.carousel').to(slideIndex) 473 } 474 475 e.preventDefault() 476 } 477 478 $(document) 479 .on('click.bs.carousel.data-api', '[data-slide]', clickHandler) 480 .on('click.bs.carousel.data-api', '[data-slide-to]', clickHandler) 481 482 $(window).on('load', function () { 483 $('[data-ride="carousel"]').each(function () { 484 var $carousel = $(this) 485 Plugin.call($carousel, $carousel.data()) 486 }
vendor: 40,092 bytes, lines 486-1819
486) 487 }) 488 489}(jQuery); 490 491/* ======================================================================== 492 * Bootstrap: dropdown.js v3.4.1 493 * https://getbootstrap.com/docs/3.4/javascript/#dropdowns 494 * ======================================================================== 495 * Copyright 2011-2019 Twitter, Inc. 496 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 497 * ======================================================================== */ 498 499 500+function ($) { 501 'use strict'; 502 503 // DROPDOWN CLASS DEFINITION 504 // ========================= 505 506 var backdrop = '.dropdown-backdrop' 507 var toggle = '[data-toggle="dropdown"]' 508 var Dropdown = function (element) { 509 $(element).on('click.bs.dropdown', this.toggle) 510 } 511 512 Dropdown.VERSION = '3.4.1' 513 514 function getParent($this) { 515 var selector = $this.attr('data-target') 516 517 if (!selector) { 518 selector = $this.attr('href') 519 selector = selector && /#[A-Za-z]/.test(selector) && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7 520 } 521 522 var $parent = selector !== '#' ? $(document).find(selector) : null 523 524 return $parent && $parent.length ? $parent : $this.parent() 525 } 526 527 function clearMenus(e) { 528 if (e && e.which === 3) return 529 $(backdrop).remove() 530 $(toggle).each(function () { 531 var $this = $(this) 532 var $parent = getParent($this) 533 var relatedTarget = { relatedTarget: this } 534 535 if (!$parent.hasClass('open')) return 536 537 if (e && e.type == 'click' && /input|textarea/i.test(e.target.tagName) && $.contains($parent[0], e.target)) return 538 539 $parent.trigger(e = $.Event('hide.bs.dropdown', relatedTarget)) 540 541 if (e.isDefaultPrevented()) return 542 543 $this.attr('aria-expanded', 'false') 544 $parent.removeClass('open').trigger($.Event('hidden.bs.dropdown', relatedTarget)) 545 }) 546 } 547 548 Dropdown.prototype.toggle = function (e) { 549 var $this = $(this) 550 551 if ($this.is('.disabled, :disabled')) return 552 553 var $parent = getParent($this) 554 var isActive = $parent.hasClass('open') 555 556 clearMenus() 557 558 if (!isActive) { 559 if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) { 560 // if mobile we use a backdrop because click events don't delegate 561 $(document.createElement('div')) 562 .addClass('dropdown-backdrop') 563 .insertAfter($(this)) 564 .on('click', clearMenus) 565 } 566 567 var relatedTarget = { relatedTarget: this } 568 $parent.trigger(e = $.Event('show.bs.dropdown', relatedTarget)) 569 570 if (e.isDefaultPrevented()) return 571 572 $this 573 .trigger('focus') 574 .attr('aria-expanded', 'true') 575 576 $parent 577 .toggleClass('open') 578 .trigger($.Event('shown.bs.dropdown', relatedTarget)) 579 } 580 581 return false 582 } 583 584 Dropdown.prototype.keydown = function (e) { 585 if (!/(38|40|27|32)/.test(e.which) || /input|textarea/i.test(e.target.tagName)) return 586 587 var $this = $(this) 588 589 e.preventDefault() 590 e.stopPropagation() 591 592 if ($this.is('.disabled, :disabled')) return 593 594 var $parent = getParent($this) 595 var isActive = $parent.hasClass('open') 596 597 if (!isActive && e.which != 27 || isActive && e.which == 27) { 598 if (e.which == 27) $parent.find(toggle).trigger('focus') 599 return $this.trigger('click') 600 } 601 602 var desc = ' li:not(.disabled):visible a' 603 var $items = $parent.find('.dropdown-menu' + desc) 604 605 if (!$items.length) return 606 607 var index = $items.index(e.target) 608 609 if (e.which == 38 && index > 0) index-- // up 610 if (e.which == 40 && index < $items.length - 1) index++ // down 611 if (!~index) index = 0 612 613 $items.eq(index).trigger('focus') 614 } 615 616 617 // DROPDOWN PLUGIN DEFINITION 618 // ========================== 619 620 function Plugin(option) { 621 return this.each(function () { 622 var $this = $(this) 623 var data = $this.data('bs.dropdown') 624 625 if (!data) $this.data('bs.dropdown', (data = new Dropdown(this))) 626 if (typeof option == 'string') data[option].call($this) 627 }) 628 } 629 630 var old = $.fn.dropdown 631 632 $.fn.dropdown = Plugin 633 $.fn.dropdown.Constructor = Dropdown 634 635 636 // DROPDOWN NO CONFLICT 637 // ==================== 638 639 $.fn.dropdown.noConflict = function () { 640 $.fn.dropdown = old 641 return this 642 } 643 644 645 // APPLY TO STANDARD DROPDOWN ELEMENTS 646 // =================================== 647 648 $(document) 649 .on('click.bs.dropdown.data-api', clearMenus) 650 .on('click.bs.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() }) 651 .on('click.bs.dropdown.data-api', toggle, Dropdown.prototype.toggle) 652 .on('keydown.bs.dropdown.data-api', toggle, Dropdown.prototype.keydown) 653 .on('keydown.bs.dropdown.data-api', '.dropdown-menu', Dropdown.prototype.keydown) 654 655}(jQuery); 656 657/* ======================================================================== 658 * Bootstrap: modal.js v3.4.1 659 * https://getbootstrap.com/docs/3.4/javascript/#modals 660 * ======================================================================== 661 * Copyright 2011-2019 Twitter, Inc. 662 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 663 * ======================================================================== */ 664 665 666+function ($) { 667 'use strict'; 668 669 // MODAL CLASS DEFINITION 670 // ====================== 671 672 var Modal = function (element, options) { 673 this.options = options 674 this.$body = $(document.body) 675 this.$element = $(element) 676 this.$dialog = this.$element.find('.modal-dialog') 677 this.$backdrop = null 678 this.isShown = null 679 this.originalBodyPad = null 680 this.scrollbarWidth = 0 681 this.ignoreBackdropClick = false 682 this.fixedContent = '.navbar-fixed-top, .navbar-fixed-bottom' 683 684 if (this.options.remote) { 685 this.$element 686 .find('.modal-content') 687 .load(this.options.remote, $.proxy(function () { 688 this.$element.trigger('loaded.bs.modal') 689 }, this)) 690 } 691 } 692 693 Modal.VERSION = '3.4.1' 694 695 Modal.TRANSITION_DURATION = 300 696 Modal.BACKDROP_TRANSITION_DURATION = 150 697 698 Modal.DEFAULTS = { 699 backdrop: true, 700 keyboard: true, 701 show: true 702 } 703 704 Modal.prototype.toggle = function (_relatedTarget) { 705 return this.isShown ? this.hide() : this.show(_relatedTarget) 706 } 707 708 Modal.prototype.show = function (_relatedTarget) { 709 var that = this 710 var e = $.Event('show.bs.modal', { relatedTarget: _relatedTarget }) 711 712 this.$element.trigger(e) 713 714 if (this.isShown || e.isDefaultPrevented()) return 715 716 this.isShown = true 717 718 this.checkScrollbar() 719 this.setScrollbar() 720 this.$body.addClass('modal-open') 721 722 this.escape() 723 this.resize() 724 725 this.$element.on('click.dismiss.bs.modal', '[data-dismiss="modal"]', $.proxy(this.hide, this)) 726 727 this.$dialog.on('mousedown.dismiss.bs.modal', function () { 728 that.$element.one('mouseup.dismiss.bs.modal', function (e) { 729 if ($(e.target).is(that.$element)) that.ignoreBackdropClick = true 730 }) 731 }) 732 733 this.backdrop(function () { 734 var transition = $.support.transition && that.$element.hasClass('fade') 735 736 if (!that.$element.parent().length) { 737 that.$element.appendTo(that.$body) // don't move modals dom position 738 } 739 740 that.$element 741 .show() 742 .scrollTop(0) 743 744 that.adjustDialog() 745 746 if (transition) { 747 that.$element[0].offsetWidth // force reflow 748 } 749 750 that.$element.addClass('in') 751 752 that.enforceFocus() 753 754 var e = $.Event('shown.bs.modal', { relatedTarget: _relatedTarget }) 755 756 transition ? 757 that.$dialog // wait for modal to slide in 758 .one('bsTransitionEnd', function () { 759 that.$element.trigger('focus').trigger(e) 760 }) 761 .emulateTransitionEnd(Modal.TRANSITION_DURATION) : 762 that.$element.trigger('focus').trigger(e) 763 }) 764 } 765 766 Modal.prototype.hide = function (e) { 767 if (e) e.preventDefault() 768 769 e = $.Event('hide.bs.modal') 770 771 this.$element.trigger(e) 772 773 if (!this.isShown || e.isDefaultPrevented()) return 774 775 this.isShown = false 776 777 this.escape() 778 this.resize() 779 780 $(document).off('focusin.bs.modal') 781 782 this.$element 783 .removeClass('in') 784 .off('click.dismiss.bs.modal') 785 .off('mouseup.dismiss.bs.modal') 786 787 this.$dialog.off('mousedown.dismiss.bs.modal') 788 789 $.support.transition && this.$element.hasClass('fade') ? 790 this.$element 791 .one('bsTransitionEnd', $.proxy(this.hideModal, this)) 792 .emulateTransitionEnd(Modal.TRANSITION_DURATION) : 793 this.hideModal() 794 } 795 796 Modal.prototype.enforceFocus = function () { 797 $(document) 798 .off('focusin.bs.modal') // guard against infinite focus loop 799 .on('focusin.bs.modal', $.proxy(function (e) { 800 if (document !== e.target && 801 this.$element[0] !== e.target && 802 !this.$element.has(e.target).length) { 803 this.$element.trigger('focus') 804 } 805 }, this)) 806 } 807 808 Modal.prototype.escape = function () { 809 if (this.isShown && this.options.keyboard) { 810 this.$element.on('keydown.dismiss.bs.modal', $.proxy(function (e) { 811 e.which == 27 && this.hide() 812 }, this)) 813 } else if (!this.isShown) { 814 this.$element.off('keydown.dismiss.bs.modal') 815 } 816 } 817 818 Modal.prototype.resize = function () { 819 if (this.isShown) { 820 $(window).on('resize.bs.modal', $.proxy(this.handleUpdate, this)) 821 } else { 822 $(window).off('resize.bs.modal') 823 } 824 } 825 826 Modal.prototype.hideModal = function () { 827 var that = this 828 this.$element.hide() 829 this.backdrop(function () { 830 that.$body.removeClass('modal-open') 831 that.resetAdjustments() 832 that.resetScrollbar() 833 that.$element.trigger('hidden.bs.modal') 834 }) 835 } 836 837 Modal.prototype.removeBackdrop = function () { 838 this.$backdrop && this.$backdrop.remove() 839 this.$backdrop = null 840 } 841 842 Modal.prototype.backdrop = function (callback) { 843 var that = this 844 var animate = this.$element.hasClass('fade') ? 'fade' : '' 845 846 if (this.isShown && this.options.backdrop) { 847 var doAnimate = $.support.transition && animate 848 849 this.$backdrop = $(document.createElement('div')) 850 .addClass('modal-backdrop ' + animate) 851 .appendTo(this.$body) 852 853 this.$element.on('click.dismiss.bs.modal', $.proxy(function (e) { 854 if (this.ignoreBackdropClick) { 855 this.ignoreBackdropClick = false 856 return 857 } 858 if (e.target !== e.currentTarget) return 859 this.options.backdrop == 'static' 860 ? this.$element[0].focus() 861 : this.hide() 862 }, this)) 863 864 if (doAnimate) this.$backdrop[0].offsetWidth // force reflow 865 866 this.$backdrop.addClass('in') 867 868 if (!callback) return 869 870 doAnimate ? 871 this.$backdrop 872 .one('bsTransitionEnd', callback) 873 .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) : 874 callback() 875 876 } else if (!this.isShown && this.$backdrop) { 877 this.$backdrop.removeClass('in') 878 879 var callbackRemove = function () { 880 that.removeBackdrop() 881 callback && callback() 882 } 883 $.support.transition && this.$element.hasClass('fade') ? 884 this.$backdrop 885 .one('bsTransitionEnd', callbackRemove) 886 .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) : 887 callbackRemove() 888 889 } else if (callback) { 890 callback() 891 } 892 } 893 894 // these following methods are used to handle overflowing modals 895 896 Modal.prototype.handleUpdate = function () { 897 this.adjustDialog() 898 } 899 900 Modal.prototype.adjustDialog = function () { 901 var modalIsOverflowing = this.$element[0].scrollHeight > document.documentElement.clientHeight 902 903 this.$element.css({ 904 paddingLeft: !this.bodyIsOverflowing && modalIsOverflowing ? this.scrollbarWidth : '', 905 paddingRight: this.bodyIsOverflowing && !modalIsOverflowing ? this.scrollbarWidth : '' 906 }) 907 } 908 909 Modal.prototype.resetAdjustments = function () { 910 this.$element.css({ 911 paddingLeft: '', 912 paddingRight: '' 913 }) 914 } 915 916 Modal.prototype.checkScrollbar = function () { 917 var fullWindowWidth = window.innerWidth 918 if (!fullWindowWidth) { // workaround for missing window.innerWidth in IE8 919 var documentElementRect = document.documentElement.getBoundingClientRect() 920 fullWindowWidth = documentElementRect.right - Math.abs(documentElementRect.left) 921 } 922 this.bodyIsOverflowing = document.body.clientWidth < fullWindowWidth 923 this.scrollbarWidth = this.measureScrollbar() 924 } 925 926 Modal.prototype.setScrollbar = function () { 927 var bodyPad = parseInt((this.$body.css('padding-right') || 0), 10) 928 this.originalBodyPad = document.body.style.paddingRight || '' 929 var scrollbarWidth = this.scrollbarWidth 930 if (this.bodyIsOverflowing) { 931 this.$body.css('padding-right', bodyPad + scrollbarWidth) 932 $(this.fixedContent).each(function (index, element) { 933 var actualPadding = element.style.paddingRight 934 var calculatedPadding = $(element).css('padding-right') 935 $(element) 936 .data('padding-right', actualPadding) 937 .css('padding-right', parseFloat(calculatedPadding) + scrollbarWidth + 'px') 938 }) 939 } 940 } 941 942 Modal.prototype.resetScrollbar = function () { 943 this.$body.css('padding-right', this.originalBodyPad) 944 $(this.fixedContent).each(function (index, element) { 945 var padding = $(element).data('padding-right') 946 $(element).removeData('padding-right') 947 element.style.paddingRight = padding ? padding : '' 948 }) 949 } 950 951 Modal.prototype.measureScrollbar = function () { // thx walsh 952 var scrollDiv = document.createElement('div') 953 scrollDiv.className = 'modal-scrollbar-measure' 954 this.$body.append(scrollDiv) 955 var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth 956 this.$body[0].removeChild(scrollDiv) 957 return scrollbarWidth 958 } 959 960 961 // MODAL PLUGIN DEFINITION 962 // ======================= 963 964 function Plugin(option, _relatedTarget) { 965 return this.each(function () { 966 var $this = $(this) 967 var data = $this.data('bs.modal') 968 var options = $.extend({}, Modal.DEFAULTS, $this.data(), typeof option == 'object' && option) 969 970 if (!data) $this.data('bs.modal', (data = new Modal(this, options))) 971 if (typeof option == 'string') data[option](_relatedTarget) 972 else if (options.show) data.show(_relatedTarget) 973 }) 974 } 975 976 var old = $.fn.modal 977 978 $.fn.modal = Plugin 979 $.fn.modal.Constructor = Modal 980 981 982 // MODAL NO CONFLICT 983 // ================= 984 985 $.fn.modal.noConflict = function () { 986 $.fn.modal = old 987 return this 988 } 989 990 991 // MODAL DATA-API 992 // ============== 993 994 $(document).on('click.bs.modal.data-api', '[data-toggle="modal"]', function (e) { 995 var $this = $(this) 996 var href = $this.attr('href') 997 var target = $this.attr('data-target') || 998 (href && href.replace(/.*(?=#[^\s]+$)/, '')) // strip for ie7 999 1000 var $target = $(document).find(target) 1001 var option = $target.data('bs.modal') ? 'toggle' : $.extend({ remote: !/#/.test(href) && href }, $target.data(), $this.data()) 1002 1003 if ($this.is('a')) e.preventDefault() 1004 1005 $target.one('show.bs.modal', function (showEvent) { 1006 if (showEvent.isDefaultPrevented()) return // only register focus restorer if modal will actually get shown 1007 $target.one('hidden.bs.modal', function () { 1008 $this.is(':visible') && $this.trigger('focus') 1009 }) 1010 }) 1011 Plugin.call($target, option, this) 1012 }) 1013 1014}(jQuery); 1015 1016/* ======================================================================== 1017 * Bootstrap: tooltip.js v3.4.1 1018 * https://getbootstrap.com/docs/3.4/javascript/#tooltip 1019 * Inspired by the original jQuery.tipsy by Jason Frame 1020 * ======================================================================== 1021 * Copyright 2011-2019 Twitter, Inc. 1022 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 1023 * ======================================================================== */ 1024 1025+function ($) { 1026 'use strict'; 1027 1028 var DISALLOWED_ATTRIBUTES = ['sanitize', 'whiteList', 'sanitizeFn'] 1029 1030 var uriAttrs = [ 1031 'background', 1032 'cite', 1033 'href', 1034 'itemtype', 1035 'longdesc', 1036 'poster', 1037 'src', 1038 'xlink:href' 1039 ] 1040 1041 var ARIA_ATTRIBUTE_PATTERN = /^aria-[\w-]*$/i 1042 1043 var DefaultWhitelist = { 1044 // Global attributes allowed on any supplied element below. 1045 '*': ['class', 'dir', 'id', 'lang', 'role', ARIA_ATTRIBUTE_PATTERN], 1046 a: ['target', 'href', 'title', 'rel'], 1047 area: [], 1048 b: [], 1049 br: [], 1050 col: [], 1051 code: [], 1052 div: [], 1053 em: [], 1054 hr: [], 1055 h1: [], 1056 h2: [], 1057 h3: [], 1058 h4: [], 1059 h5: [], 1060 h6: [], 1061 i: [], 1062 img: ['src', 'alt', 'title', 'width', 'height'], 1063 li: [], 1064 ol: [], 1065 p: [], 1066 pre: [], 1067 s: [], 1068 small: [], 1069 span: [], 1070 sub: [], 1071 sup: [], 1072 strong: [], 1073 u: [], 1074 ul: [] 1075 } 1076 1077 /** 1078 * A pattern that recognizes a commonly useful subset of URLs that are safe. 1079 * 1080 * Shoutout to Angular 7 https://github.com/angular/angular/blob/7.2.4/packages/core/src/sanitization/url_sanitizer.ts 1081 */ 1082 var SAFE_URL_PATTERN = /^(?:(?:https?|mailto|ftp|tel|file):|[^&:/?#]*(?:[/?#]|$))/gi 1083 1084 /** 1085 * A pattern that matches safe data URLs. Only matches image, video and audio types. 1086 * 1087 * Shoutout to Angular 7 https://github.com/angular/angular/blob/7.2.4/packages/core/src/sanitization/url_sanitizer.ts 1088 */ 1089 var DATA_URL_PATTERN = /^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+/]+=*$/i 1090 1091 function allowedAttribute(attr, allowedAttributeList) { 1092 var attrName = attr.nodeName.toLowerCase() 1093 1094 if ($.inArray(attrName, allowedAttributeList) !== -1) { 1095 if ($.inArray(attrName, uriAttrs) !== -1) { 1096 return Boolean(attr.nodeValue.match(SAFE_URL_PATTERN) || attr.nodeValue.match(DATA_URL_PATTERN)) 1097 } 1098 1099 return true 1100 } 1101 1102 var regExp = $(allowedAttributeList).filter(function (index, value) { 1103 return value instanceof RegExp 1104 }) 1105 1106 // Check if a regular expression validates the attribute. 1107 for (var i = 0, l = regExp.length; i < l; i++) { 1108 if (attrName.match(regExp[i])) { 1109 return true 1110 } 1111 } 1112 1113 return false 1114 } 1115 1116 function sanitizeHtml(unsafeHtml, whiteList, sanitizeFn) { 1117 if (unsafeHtml.length === 0) { 1118 return unsafeHtml 1119 } 1120 1121 if (sanitizeFn && typeof sanitizeFn === 'function') { 1122 return sanitizeFn(unsafeHtml) 1123 } 1124 1125 // IE 8 and below don't support createHTMLDocument 1126 if (!document.implementation || !document.implementation.createHTMLDocument) { 1127 return unsafeHtml 1128 } 1129 1130 var createdDocument = document.implementation.createHTMLDocument('sanitization') 1131 createdDocument.body.innerHTML = unsafeHtml 1132 1133 var whitelistKeys = $.map(whiteList, function (el, i) { return i }) 1134 var elements = $(createdDocument.body).find('*') 1135 1136 for (var i = 0, len = elements.length; i < len; i++) { 1137 var el = elements[i] 1138 var elName = el.nodeName.toLowerCase() 1139 1140 if ($.inArray(elName, whitelistKeys) === -1) { 1141 el.parentNode.removeChild(el) 1142 1143 continue 1144 } 1145 1146 var attributeList = $.map(el.attributes, function (el) { return el }) 1147 var whitelistedAttributes = [].concat(whiteList['*'] || [], whiteList[elName] || []) 1148 1149 for (var j = 0, len2 = attributeList.length; j < len2; j++) { 1150 if (!allowedAttribute(attributeList[j], whitelistedAttributes)) { 1151 el.removeAttribute(attributeList[j].nodeName) 1152 } 1153 } 1154 } 1155 1156 return createdDocument.body.innerHTML 1157 } 1158 1159 // TOOLTIP PUBLIC CLASS DEFINITION 1160 // =============================== 1161 1162 var Tooltip = function (element, options) { 1163 this.type = null 1164 this.options = null 1165 this.enabled = null 1166 this.timeout = null 1167 this.hoverState = null 1168 this.$element = null 1169 this.inState = null 1170 1171 this.init('tooltip', element, options) 1172 } 1173 1174 Tooltip.VERSION = '3.4.1' 1175 1176 Tooltip.TRANSITION_DURATION = 150 1177 1178 Tooltip.DEFAULTS = { 1179 animation: true, 1180 placement: 'top', 1181 selector: false, 1182 template: '<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>', 1183 trigger: 'hover focus', 1184 title: '', 1185 delay: 0, 1186 html: false, 1187 container: false, 1188 viewport: { 1189 selector: 'body', 1190 padding: 0 1191 }, 1192 sanitize : true, 1193 sanitizeFn : null, 1194 whiteList : DefaultWhitelist 1195 } 1196 1197 Tooltip.prototype.init = function (type, element, options) { 1198 this.enabled = true 1199 this.type = type 1200 this.$element = $(element) 1201 this.options = this.getOptions(options) 1202 this.$viewport = this.options.viewport && $(document).find($.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : (this.options.viewport.selector || this.options.viewport)) 1203 this.inState = { click: false, hover: false, focus: false } 1204 1205 if (this.$element[0] instanceof document.constructor && !this.options.selector) { 1206 throw new Error('`selector` option must be specified when initializing ' + this.type + ' on the window.document object!') 1207 } 1208 1209 var triggers = this.options.trigger.split(' ') 1210 1211 for (var i = triggers.length; i--;) { 1212 var trigger = triggers[i] 1213 1214 if (trigger == 'click') { 1215 this.$element.on('click.' + this.type, this.options.selector, $.proxy(this.toggle, this)) 1216 } else if (trigger != 'manual') { 1217 var eventIn = trigger == 'hover' ? 'mouseenter' : 'focusin' 1218 var eventOut = trigger == 'hover' ? 'mouseleave' : 'focusout' 1219 1220 this.$element.on(eventIn + '.' + this.type, this.options.selector, $.proxy(this.enter, this)) 1221 this.$element.on(eventOut + '.' + this.type, this.options.selector, $.proxy(this.leave, this)) 1222 } 1223 } 1224 1225 this.options.selector ? 1226 (this._options = $.extend({}, this.options, { trigger: 'manual', selector: '' })) : 1227 this.fixTitle() 1228 } 1229 1230 Tooltip.prototype.getDefaults = function () { 1231 return Tooltip.DEFAULTS 1232 } 1233 1234 Tooltip.prototype.getOptions = function (options) { 1235 var dataAttributes = this.$element.data() 1236 1237 for (var dataAttr in dataAttributes) { 1238 if (dataAttributes.hasOwnProperty(dataAttr) && $.inArray(dataAttr, DISALLOWED_ATTRIBUTES) !== -1) { 1239 delete dataAttributes[dataAttr] 1240 } 1241 } 1242 1243 options = $.extend({}, this.getDefaults(), dataAttributes, options) 1244 1245 if (options.delay && typeof options.delay == 'number') { 1246 options.delay = { 1247 show: options.delay, 1248 hide: options.delay 1249 } 1250 } 1251 1252 if (options.sanitize) { 1253 options.template = sanitizeHtml(options.template, options.whiteList, options.sanitizeFn) 1254 } 1255 1256 return options 1257 } 1258 1259 Tooltip.prototype.getDelegateOptions = function () { 1260 var options = {} 1261 var defaults = this.getDefaults() 1262 1263 this._options && $.each(this._options, function (key, value) { 1264 if (defaults[key] != value) options[key] = value 1265 }) 1266 1267 return options 1268 } 1269 1270 Tooltip.prototype.enter = function (obj) { 1271 var self = obj instanceof this.constructor ? 1272 obj : $(obj.currentTarget).data('bs.' + this.type) 1273 1274 if (!self) { 1275 self = new this.constructor(obj.currentTarget, this.getDelegateOptions()) 1276 $(obj.currentTarget).data('bs.' + this.type, self) 1277 } 1278 1279 if (obj instanceof $.Event) { 1280 self.inState[obj.type == 'focusin' ? 'focus' : 'hover'] = true 1281 } 1282 1283 if (self.tip().hasClass('in') || self.hoverState == 'in') { 1284 self.hoverState = 'in' 1285 return 1286 } 1287 1288 clearTimeout(self.timeout) 1289 1290 self.hoverState = 'in' 1291 1292 if (!self.options.delay || !self.options.delay.show) return self.show() 1293 1294 self.timeout = setTimeout(function () { 1295 if (self.hoverState == 'in') self.show() 1296 }, self.options.delay.show) 1297 } 1298 1299 Tooltip.prototype.isInStateTrue = function () { 1300 for (var key in this.inState) { 1301 if (this.inState[key]) return true 1302 } 1303 1304 return false 1305 } 1306 1307 Tooltip.prototype.leave = function (obj) { 1308 var self = obj instanceof this.constructor ? 1309 obj : $(obj.currentTarget).data('bs.' + this.type) 1310 1311 if (!self) { 1312 self = new this.constructor(obj.currentTarget, this.getDelegateOptions()) 1313 $(obj.currentTarget).data('bs.' + this.type, self) 1314 } 1315 1316 if (obj instanceof $.Event) { 1317 self.inState[obj.type == 'focusout' ? 'focus' : 'hover'] = false 1318 } 1319 1320 if (self.isInStateTrue()) return 1321 1322 clearTimeout(self.timeout) 1323 1324 self.hoverState = 'out' 1325 1326 if (!self.options.delay || !self.options.delay.hide) return self.hide() 1327 1328 self.timeout = setTimeout(function () { 1329 if (self.hoverState == 'out') self.hide() 1330 }, self.options.delay.hide) 1331 } 1332 1333 Tooltip.prototype.show = function () { 1334 var e = $.Event('show.bs.' + this.type) 1335 1336 if (this.hasContent() && this.enabled) { 1337 this.$element.trigger(e) 1338 1339 var inDom = $.contains(this.$element[0].ownerDocument.documentElement, this.$element[0]) 1340 if (e.isDefaultPrevented() || !inDom) return 1341 var that = this 1342 1343 var $tip = this.tip() 1344 1345 var tipId = this.getUID(this.type) 1346 1347 this.setContent() 1348 $tip.attr('id', tipId) 1349 this.$element.attr('aria-describedby', tipId) 1350 1351 if (this.options.animation) $tip.addClass('fade') 1352 1353 var placement = typeof this.options.placement == 'function' ? 1354 this.options.placement.call(this, $tip[0], this.$element[0]) : 1355 this.options.placement 1356 1357 var autoToken = /\s?auto?\s?/i 1358 var autoPlace = autoToken.test(placement) 1359 if (autoPlace) placement = placement.replace(autoToken, '') || 'top' 1360 1361 $tip 1362 .detach() 1363 .css({ top: 0, left: 0, display: 'block' }) 1364 .addClass(placement) 1365 .data('bs.' + this.type, this) 1366 1367 this.options.container ? $tip.appendTo($(document).find(this.options.container)) : $tip.insertAfter(this.$element) 1368 this.$element.trigger('inserted.bs.' + this.type) 1369 1370 var pos = this.getPosition() 1371 var actualWidth = $tip[0].offsetWidth 1372 var actualHeight = $tip[0].offsetHeight 1373 1374 if (autoPlace) { 1375 var orgPlacement = placement 1376 var viewportDim = this.getPosition(this.$viewport) 1377 1378 placement = placement == 'bottom' && pos.bottom + actualHeight > viewportDim.bottom ? 'top' : 1379 placement == 'top' && pos.top - actualHeight < viewportDim.top ? 'bottom' : 1380 placement == 'right' && pos.right + actualWidth > viewportDim.width ? 'left' : 1381 placement == 'left' && pos.left - actualWidth < viewportDim.left ? 'right' : 1382 placement 1383 1384 $tip 1385 .removeClass(orgPlacement) 1386 .addClass(placement) 1387 } 1388 1389 var calculatedOffset = this.getCalculatedOffset(placement, pos, actualWidth, actualHeight) 1390 1391 this.applyPlacement(calculatedOffset, placement) 1392 1393 var complete = function () { 1394 var prevHoverState = that.hoverState 1395 that.$element.trigger('shown.bs.' + that.type) 1396 that.hoverState = null 1397 1398 if (prevHoverState == 'out') that.leave(that) 1399 } 1400 1401 $.support.transition && this.$tip.hasClass('fade') ? 1402 $tip 1403 .one('bsTransitionEnd', complete) 1404 .emulateTransitionEnd(Tooltip.TRANSITION_DURATION) : 1405 complete() 1406 } 1407 } 1408 1409 Tooltip.prototype.applyPlacement = function (offset, placement) { 1410 var $tip = this.tip() 1411 var width = $tip[0].offsetWidth 1412 var height = $tip[0].offsetHeight 1413 1414 // manually read margins because getBoundingClientRect includes difference 1415 var marginTop = parseInt($tip.css('margin-top'), 10) 1416 var marginLeft = parseInt($tip.css('margin-left'), 10) 1417 1418 // we must check for NaN for ie 8/9 1419 if (isNaN(marginTop)) marginTop = 0 1420 if (isNaN(marginLeft)) marginLeft = 0 1421 1422 offset.top += marginTop 1423 offset.left += marginLeft 1424 1425 // $.fn.offset doesn't round pixel values 1426 // so we use setOffset directly with our own function B-0 1427 $.offset.setOffset($tip[0], $.extend({ 1428 using: function (props) { 1429 $tip.css({ 1430 top: Math.round(props.top), 1431 left: Math.round(props.left) 1432 }) 1433 } 1434 }, offset), 0) 1435 1436 $tip.addClass('in') 1437 1438 // check to see if placing tip in new offset caused the tip to resize itself 1439 var actualWidth = $tip[0].offsetWidth 1440 var actualHeight = $tip[0].offsetHeight 1441 1442 if (placement == 'top' && actualHeight != height) { 1443 offset.top = offset.top + height - actualHeight 1444 } 1445 1446 var delta = this.getViewportAdjustedDelta(placement, offset, actualWidth, actualHeight) 1447 1448 if (delta.left) offset.left += delta.left 1449 else offset.top += delta.top 1450 1451 var isVertical = /top|bottom/.test(placement) 1452 var arrowDelta = isVertical ? delta.left * 2 - width + actualWidth : delta.top * 2 - height + actualHeight 1453 var arrowOffsetPosition = isVertical ? 'offsetWidth' : 'offsetHeight' 1454 1455 $tip.offset(offset) 1456 this.replaceArrow(arrowDelta, $tip[0][arrowOffsetPosition], isVertical) 1457 } 1458 1459 Tooltip.prototype.replaceArrow = function (delta, dimension, isVertical) { 1460 this.arrow() 1461 .css(isVertical ? 'left' : 'top', 50 * (1 - delta / dimension) + '%') 1462 .css(isVertical ? 'top' : 'left', '') 1463 } 1464 1465 Tooltip.prototype.setContent = function () { 1466 var $tip = this.tip() 1467 var title = this.getTitle() 1468 1469 if (this.options.html) { 1470 if (this.options.sanitize) { 1471 title = sanitizeHtml(title, this.options.whiteList, this.options.sanitizeFn) 1472 } 1473 1474 $tip.find('.tooltip-inner').html(title) 1475 } else { 1476 $tip.find('.tooltip-inner').text(title) 1477 } 1478 1479 $tip.removeClass('fade in top bottom left right') 1480 } 1481 1482 Tooltip.prototype.hide = function (callback) { 1483 var that = this 1484 var $tip = $(this.$tip) 1485 var e = $.Event('hide.bs.' + this.type) 1486 1487 function complete() { 1488 if (that.hoverState != 'in') $tip.detach() 1489 if (that.$element) { // TODO: Check whether guarding this code with this `if` is really necessary. 1490 that.$element 1491 .removeAttr('aria-describedby') 1492 .trigger('hidden.bs.' + that.type) 1493 } 1494 callback && callback() 1495 } 1496 1497 this.$element.trigger(e) 1498 1499 if (e.isDefaultPrevented()) return 1500 1501 $tip.removeClass('in') 1502 1503 $.support.transition && $tip.hasClass('fade') ? 1504 $tip 1505 .one('bsTransitionEnd', complete) 1506 .emulateTransitionEnd(Tooltip.TRANSITION_DURATION) : 1507 complete() 1508 1509 this.hoverState = null 1510 1511 return this 1512 } 1513 1514 Tooltip.prototype.fixTitle = function () { 1515 var $e = this.$element 1516 if ($e.attr('title') || typeof $e.attr('data-original-title') != 'string') { 1517 $e.attr('data-original-title', $e.attr('title') || '').attr('title', '') 1518 } 1519 } 1520 1521 Tooltip.prototype.hasContent = function () { 1522 return this.getTitle() 1523 } 1524 1525 Tooltip.prototype.getPosition = function ($element) { 1526 $element = $element || this.$element 1527 1528 var el = $element[0] 1529 var isBody = el.tagName == 'BODY' 1530 1531 var elRect = el.getBoundingClientRect() 1532 if (elRect.width == null) { 1533 // width and height are missing in IE8, so compute them manually; see https://github.com/twbs/bootstrap/issues/14093 1534 elRect = $.extend({}, elRect, { width: elRect.right - elRect.left, height: elRect.bottom - elRect.top }) 1535 } 1536 var isSvg = window.SVGElement && el instanceof window.SVGElement 1537 // Avoid using $.offset() on SVGs since it gives incorrect results in jQuery 3. 1538 // See https://github.com/twbs/bootstrap/issues/20280 1539 var elOffset = isBody ? { top: 0, left: 0 } : (isSvg ? null : $element.offset()) 1540 var scroll = { scroll: isBody ? document.documentElement.scrollTop || document.body.scrollTop : $element.scrollTop() } 1541 var outerDims = isBody ? { width: $(window).width(), height: $(window).height() } : null 1542 1543 return $.extend({}, elRect, scroll, outerDims, elOffset) 1544 } 1545 1546 Tooltip.prototype.getCalculatedOffset = function (placement, pos, actualWidth, actualHeight) { 1547 return placement == 'bottom' ? { top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2 } : 1548 placement == 'top' ? { top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2 } : 1549 placement == 'left' ? { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth } : 1550 /* placement == 'right' */ { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width } 1551 1552 } 1553 1554 Tooltip.prototype.getViewportAdjustedDelta = function (placement, pos, actualWidth, actualHeight) { 1555 var delta = { top: 0, left: 0 } 1556 if (!this.$viewport) return delta 1557 1558 var viewportPadding = this.options.viewport && this.options.viewport.padding || 0 1559 var viewportDimensions = this.getPosition(this.$viewport) 1560 1561 if (/right|left/.test(placement)) { 1562 var topEdgeOffset = pos.top - viewportPadding - viewportDimensions.scroll 1563 var bottomEdgeOffset = pos.top + viewportPadding - viewportDimensions.scroll + actualHeight 1564 if (topEdgeOffset < viewportDimensions.top) { // top overflow 1565 delta.top = viewportDimensions.top - topEdgeOffset 1566 } else if (bottomEdgeOffset > viewportDimensions.top + viewportDimensions.height) { // bottom overflow 1567 delta.top = viewportDimensions.top + viewportDimensions.height - bottomEdgeOffset 1568 } 1569 } else { 1570 var leftEdgeOffset = pos.left - viewportPadding 1571 var rightEdgeOffset = pos.left + viewportPadding + actualWidth 1572 if (leftEdgeOffset < viewportDimensions.left) { // left overflow 1573 delta.left = viewportDimensions.left - leftEdgeOffset 1574 } else if (rightEdgeOffset > viewportDimensions.right) { // right overflow 1575 delta.left = viewportDimensions.left + viewportDimensions.width - rightEdgeOffset 1576 } 1577 } 1578 1579 return delta 1580 } 1581 1582 Tooltip.prototype.getTitle = function () { 1583 var title 1584 var $e = this.$element 1585 var o = this.options 1586 1587 title = $e.attr('data-original-title') 1588 || (typeof o.title == 'function' ? o.title.call($e[0]) : o.title) 1589 1590 return title 1591 } 1592 1593 Tooltip.prototype.getUID = function (prefix) { 1594 do prefix += ~~(Math.random() * 1000000) 1595 while (document.getElementById(prefix)) 1596 return prefix 1597 } 1598 1599 Tooltip.prototype.tip = function () { 1600 if (!this.$tip) { 1601 this.$tip = $(this.options.template) 1602 if (this.$tip.length != 1) { 1603 throw new Error(this.type + ' `template` option must consist of exactly 1 top-level element!') 1604 } 1605 } 1606 return this.$tip 1607 } 1608 1609 Tooltip.prototype.arrow = function () { 1610 return (this.$arrow = this.$arrow || this.tip().find('.tooltip-arrow')) 1611 } 1612 1613 Tooltip.prototype.enable = function () { 1614 this.enabled = true 1615 } 1616 1617 Tooltip.prototype.disable = function () { 1618 this.enabled = false 1619 } 1620 1621 Tooltip.prototype.toggleEnabled = function () { 1622 this.enabled = !this.enabled 1623 } 1624 1625 Tooltip.prototype.toggle = function (e) { 1626 var self = this 1627 if (e) { 1628 self = $(e.currentTarget).data('bs.' + this.type) 1629 if (!self) { 1630 self = new this.constructor(e.currentTarget, this.getDelegateOptions()) 1631 $(e.currentTarget).data('bs.' + this.type, self) 1632 } 1633 } 1634 1635 if (e) { 1636 self.inState.click = !self.inState.click 1637 if (self.isInStateTrue()) self.enter(self) 1638 else self.leave(self) 1639 } else { 1640 self.tip().hasClass('in') ? self.leave(self) : self.enter(self) 1641 } 1642 } 1643 1644 Tooltip.prototype.destroy = function () { 1645 var that = this 1646 clearTimeout(this.timeout) 1647 this.hide(function () { 1648 that.$element.off('.' + that.type).removeData('bs.' + that.type) 1649 if (that.$tip) { 1650 that.$tip.detach() 1651 } 1652 that.$tip = null 1653 that.$arrow = null 1654 that.$viewport = null 1655 that.$element = null 1656 }) 1657 } 1658 1659 Tooltip.prototype.sanitizeHtml = function (unsafeHtml) { 1660 return sanitizeHtml(unsafeHtml, this.options.whiteList, this.options.sanitizeFn) 1661 } 1662 1663 // TOOLTIP PLUGIN DEFINITION 1664 // ========================= 1665 1666 function Plugin(option) { 1667 return this.each(function () { 1668 var $this = $(this) 1669 var data = $this.data('bs.tooltip') 1670 var options = typeof option == 'object' && option 1671 1672 if (!data && /destroy|hide/.test(option)) return 1673 if (!data) $this.data('bs.tooltip', (data = new Tooltip(this, options))) 1674 if (typeof option == 'string') data[option]() 1675 }) 1676 } 1677 1678 var old = $.fn.tooltip 1679 1680 $.fn.tooltip = Plugin 1681 $.fn.tooltip.Constructor = Tooltip 1682 1683 1684 // TOOLTIP NO CONFLICT 1685 // =================== 1686 1687 $.fn.tooltip.noConflict = function () { 1688 $.fn.tooltip = old 1689 return this 1690 } 1691 1692}(jQuery); 1693 1694/* ======================================================================== 1695 * Bootstrap: popover.js v3.4.1 1696 * https://getbootstrap.com/docs/3.4/javascript/#popovers 1697 * ======================================================================== 1698 * Copyright 2011-2019 Twitter, Inc. 1699 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 1700 * ======================================================================== */ 1701 1702 1703+function ($) { 1704 'use strict'; 1705 1706 // POPOVER PUBLIC CLASS DEFINITION 1707 // =============================== 1708 1709 var Popover = function (element, options) { 1710 this.init('popover', element, options) 1711 } 1712 1713 if (!$.fn.tooltip) throw new Error('Popover requires tooltip.js') 1714 1715 Popover.VERSION = '3.4.1' 1716 1717 Popover.DEFAULTS = $.extend({}, $.fn.tooltip.Constructor.DEFAULTS, { 1718 placement: 'right', 1719 trigger: 'click', 1720 content: '', 1721 template: '<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>' 1722 }) 1723 1724 1725 // NOTE: POPOVER EXTENDS tooltip.js 1726 // ================================ 1727 1728 Popover.prototype = $.extend({}, $.fn.tooltip.Constructor.prototype) 1729 1730 Popover.prototype.constructor = Popover 1731 1732 Popover.prototype.getDefaults = function () { 1733 return Popover.DEFAULTS 1734 } 1735 1736 Popover.prototype.setContent = function () { 1737 var $tip = this.tip() 1738 var title = this.getTitle() 1739 var content = this.getContent() 1740 1741 if (this.options.html) { 1742 var typeContent = typeof content 1743 1744 if (this.options.sanitize) { 1745 title = this.sanitizeHtml(title) 1746 1747 if (typeContent === 'string') { 1748 content = this.sanitizeHtml(content) 1749 } 1750 } 1751 1752 $tip.find('.popover-title').html(title) 1753 $tip.find('.popover-content').children().detach().end()[ 1754 typeContent === 'string' ? 'html' : 'append' 1755 ](content) 1756 } else { 1757 $tip.find('.popover-title').text(title) 1758 $tip.find('.popover-content').children().detach().end().text(content) 1759 } 1760 1761 $tip.removeClass('fade top bottom left right in') 1762 1763 // IE8 doesn't accept hiding via the `:empty` pseudo selector, we have to do 1764 // this manually by checking the contents. 1765 if (!$tip.find('.popover-title').html()) $tip.find('.popover-title').hide() 1766 } 1767 1768 Popover.prototype.hasContent = function () { 1769 return this.getTitle() || this.getContent() 1770 } 1771 1772 Popover.prototype.getContent = function () { 1773 var $e = this.$element 1774 var o = this.options 1775 1776 return $e.attr('data-content') 1777 || (typeof o.content == 'function' ? 1778 o.content.call($e[0]) : 1779 o.content) 1780 } 1781 1782 Popover.prototype.arrow = function () { 1783 return (this.$arrow = this.$arrow || this.tip().find('.arrow')) 1784 } 1785 1786 1787 // POPOVER PLUGIN DEFINITION 1788 // ========================= 1789 1790 function Plugin(option) { 1791 return this.each(function () { 1792 var $this = $(this) 1793 var data = $this.data('bs.popover') 1794 var options = typeof option == 'object' && option 1795 1796 if (!data && /destroy|hide/.test(option)) return 1797 if (!data) $this.data('bs.popover', (data = new Popover(this, options))) 1798 if (typeof option == 'string') data[option]() 1799 }) 1800 } 1801 1802 var old = $.fn.popover 1803 1804 $.fn.popover = Plugin 1805 $.fn.popover.Constructor = Popover 1806 1807 1808 // POPOVER NO CONFLICT 1809 // =================== 1810 1811 $.fn.popover.noConflict = function () { 1812 $.fn.popover = old 1813 return this 1814 } 1815 1816}(jQuery); 1817 1818/* ======================================================================== 1819 * Bootstrap:
vendor: 7,011 bytes, lines 1819-2061
1819tab.js v3.4.1 1820 * https://getbootstrap.com/docs/3.4/javascript/#tabs 1821 * ======================================================================== 1822 * Copyright 2011-2019 Twitter, Inc. 1823 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 1824 * ======================================================================== */ 1825 1826 1827+function ($) { 1828 'use strict'; 1829 1830 // TAB CLASS DEFINITION 1831 // ==================== 1832 1833 var Tab = function (element) { 1834 // jscs:disable requireDollarBeforejQueryAssignment 1835 this.element = $(element) 1836 // jscs:enable requireDollarBeforejQueryAssignment 1837 } 1838 1839 Tab.VERSION = '3.4.1' 1840 1841 Tab.TRANSITION_DURATION = 150 1842 1843 Tab.prototype.show = function () { 1844 var $this = this.element 1845 var $ul = $this.closest('ul:not(.dropdown-menu)') 1846 var selector = $this.data('target') 1847 1848 if (!selector) { 1849 selector = $this.attr('href') 1850 selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7 1851 } 1852 1853 if ($this.parent('li').hasClass('active')) return 1854 1855 var $previous = $ul.find('.active:last a') 1856 var hideEvent = $.Event('hide.bs.tab', { 1857 relatedTarget: $this[0] 1858 }) 1859 var showEvent = $.Event('show.bs.tab', { 1860 relatedTarget: $previous[0] 1861 }) 1862 1863 $previous.trigger(hideEvent) 1864 $this.trigger(showEvent) 1865 1866 if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) return 1867 1868 var $target = $(document).find(selector) 1869 1870 this.activate($this.closest('li'), $ul) 1871 this.activate($target, $target.parent(), function () { 1872 $previous.trigger({ 1873 type: 'hidden.bs.tab', 1874 relatedTarget: $this[0] 1875 }) 1876 $this.trigger({ 1877 type: 'shown.bs.tab', 1878 relatedTarget: $previous[0] 1879 }) 1880 }) 1881 } 1882 1883 Tab.prototype.activate = function (element, container, callback) { 1884 var $active = container.find('> .active') 1885 var transition = callback 1886 && $.support.transition 1887 && ($active.length && $active.hasClass('fade') || !!container.find('> .fade').length) 1888 1889 function next() { 1890 $active 1891 .removeClass('active') 1892 .find('> .dropdown-menu > .active') 1893 .removeClass('active') 1894 .end() 1895 .find('[data-toggle="tab"]') 1896 .attr('aria-expanded', false) 1897 1898 element 1899 .addClass('active') 1900 .find('[data-toggle="tab"]') 1901 .attr('aria-expanded', true) 1902 1903 if (transition) { 1904 element[0].offsetWidth // reflow for transition 1905 element.addClass('in') 1906 } else { 1907 element.removeClass('fade') 1908 } 1909 1910 if (element.parent('.dropdown-menu').length) { 1911 element 1912 .closest('li.dropdown') 1913 .addClass('active') 1914 .end() 1915 .find('[data-toggle="tab"]') 1916 .attr('aria-expanded', true) 1917 } 1918 1919 callback && callback() 1920 } 1921 1922 $active.length && transition ? 1923 $active 1924 .one('bsTransitionEnd', next) 1925 .emulateTransitionEnd(Tab.TRANSITION_DURATION) : 1926 next() 1927 1928 $active.removeClass('in') 1929 } 1930 1931 1932 // TAB PLUGIN DEFINITION 1933 // ===================== 1934 1935 function Plugin(option) { 1936 return this.each(function () { 1937 var $this = $(this) 1938 var data = $this.data('bs.tab') 1939 1940 if (!data) $this.data('bs.tab', (data = new Tab(this))) 1941 if (typeof option == 'string') data[option]() 1942 }) 1943 } 1944 1945 var old = $.fn.tab 1946 1947 $.fn.tab = Plugin 1948 $.fn.tab.Constructor = Tab 1949 1950 1951 // TAB NO CONFLICT 1952 // =============== 1953 1954 $.fn.tab.noConflict = function () { 1955 $.fn.tab = old 1956 return this 1957 } 1958 1959 1960 // TAB DATA-API 1961 // ============ 1962 1963 var clickHandler = function (e) { 1964 e.preventDefault() 1965 Plugin.call($(this), 'show') 1966 } 1967 1968 $(document) 1969 .on('click.bs.tab.data-api', '[data-toggle="tab"]', clickHandler) 1970 .on('click.bs.tab.data-api', '[data-toggle="pill"]', clickHandler) 1971 1972}(jQuery); 1973 1974/* ======================================================================== 1975 * Bootstrap: affix.js v3.4.1 1976 * https://getbootstrap.com/docs/3.4/javascript/#affix 1977 * ======================================================================== 1978 * Copyright 2011-2019 Twitter, Inc. 1979 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 1980 * ======================================================================== */ 1981 1982 1983+function ($) { 1984 'use strict'; 1985 1986 // AFFIX CLASS DEFINITION 1987 // ====================== 1988 1989 var Affix = function (element, options) { 1990 this.options = $.extend({}, Affix.DEFAULTS, options) 1991 1992 var target = this.options.target === Affix.DEFAULTS.target ? $(this.options.target) : $(document).find(this.options.target) 1993 1994 this.$target = target 1995 .on('scroll.bs.affix.data-api', $.proxy(this.checkPosition, this)) 1996 .on('click.bs.affix.data-api', $.proxy(this.checkPositionWithEventLoop, this)) 1997 1998 this.$element = $(element) 1999 this.affixed = null 2000 this.unpin = null 2001 this.pinnedOffset = null 2002 2003 this.checkPosition() 2004 } 2005 2006 Affix.VERSION = '3.4.1' 2007 2008 Affix.RESET = 'affix affix-top affix-bottom' 2009 2010 Affix.DEFAULTS = { 2011 offset: 0, 2012 target: window 2013 } 2014 2015 Affix.prototype.getState = function (scrollHeight, height, offsetTop, offsetBottom) { 2016 var scrollTop = this.$target.scrollTop() 2017 var position = this.$element.offset() 2018 var targetHeight = this.$target.height() 2019 2020 if (offsetTop != null && this.affixed == 'top') return scrollTop < offsetTop ? 'top' : false 2021 2022 if (this.affixed == 'bottom') { 2023 if (offsetTop != null) return (scrollTop + this.unpin <= position.top) ? false : 'bottom' 2024 return (scrollTop + targetHeight <= scrollHeight - offsetBottom) ? false : 'bottom' 2025 } 2026 2027 var initializing = this.affixed == null 2028 var colliderTop = initializing ? scrollTop : position.top 2029 var colliderHeight = initializing ? targetHeight : height 2030 2031 if (offsetTop != null && scrollTop <= offsetTop) return 'top' 2032 if (offsetBottom != null && (colliderTop + colliderHeight >= scrollHeight - offsetBottom)) return 'bottom' 2033 2034 return false 2035 } 2036 2037 Affix.prototype.getPinnedOffset = function () { 2038 if (this.pinnedOffset) return this.pinnedOffset 2039 this.$element.removeClass(Affix.RESET).addClass('affix') 2040 var scrollTop = this.$target.scrollTop() 2041 var position = this.$element.offset() 2042 return (this.pinnedOffset = position.top - scrollTop) 2043 } 2044 2045 Affix.prototype.checkPositionWithEventLoop = function () { 2046 setTimeout($.proxy(this.checkPosition, this), 1) 2047 } 2048 2049 Affix.prototype.checkPosition = function () { 2050 if (!this.$element.is(':visible')) return 2051 2052 var height = this.$element.height() 2053 var offset = this.options.offset 2054 var offsetTop = offset.top 2055 var offsetBottom = offset.bottom 2056 var scrollHeight = Math.max($(document).height(), $(document.body).height()) 2057 2058 if (typeof offset != 'object') offsetBottom = offsetTop = offset 2059 if (typeof offsetTop == 'function') offsetTop = offset.top(this.$element) 2060 if (typeof offsetBottom == 'function') offsetBottom = offset.bottom(this.$element) 2061
vendor: 9,347 bytes, lines 2062-2398
2062 var affix = this.getState(scrollHeight, height, offsetTop, offsetBottom) 2063 2064 if (this.affixed != affix) { 2065 if (this.unpin != null) this.$element.css('top', '') 2066 2067 var affixType = 'affix' + (affix ? '-' + affix : '') 2068 var e = $.Event(affixType + '.bs.affix') 2069 2070 this.$element.trigger(e) 2071 2072 if (e.isDefaultPrevented()) return 2073 2074 this.affixed = affix 2075 this.unpin = affix == 'bottom' ? this.getPinnedOffset() : null 2076 2077 this.$element 2078 .removeClass(Affix.RESET) 2079 .addClass(affixType) 2080 .trigger(affixType.replace('affix', 'affixed') + '.bs.affix') 2081 } 2082 2083 if (affix == 'bottom') { 2084 this.$element.offset({ 2085 top: scrollHeight - height - offsetBottom 2086 }) 2087 } 2088 } 2089 2090 2091 // AFFIX PLUGIN DEFINITION 2092 // ======================= 2093 2094 function Plugin(option) { 2095 return this.each(function () { 2096 var $this = $(this) 2097 var data = $this.data('bs.affix') 2098 var options = typeof option == 'object' && option 2099 2100 if (!data) $this.data('bs.affix', (data = new Affix(this, options))) 2101 if (typeof option == 'string') data[option]() 2102 }) 2103 } 2104 2105 var old = $.fn.affix 2106 2107 $.fn.affix = Plugin 2108 $.fn.affix.Constructor = Affix 2109 2110 2111 // AFFIX NO CONFLICT 2112 // ================= 2113 2114 $.fn.affix.noConflict = function () { 2115 $.fn.affix = old 2116 return this 2117 } 2118 2119 2120 // AFFIX DATA-API 2121 // ============== 2122 2123 $(window).on('load', function () { 2124 $('[data-spy="affix"]').each(function () { 2125 var $spy = $(this) 2126 var data = $spy.data() 2127 2128 data.offset = data.offset || {} 2129 2130 if (data.offsetBottom != null) data.offset.bottom = data.offsetBottom 2131 if (data.offsetTop != null) data.offset.top = data.offsetTop 2132 2133 Plugin.call($spy, data) 2134 }) 2135 }) 2136 2137}(jQuery); 2138 2139/* ======================================================================== 2140 * Bootstrap: collapse.js v3.4.1 2141 * https://getbootstrap.com/docs/3.4/javascript/#collapse 2142 * ======================================================================== 2143 * Copyright 2011-2019 Twitter, Inc. 2144 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 2145 * ======================================================================== */ 2146 2147/* jshint latedef: false */ 2148 2149+function ($) { 2150 'use strict'; 2151 2152 // COLLAPSE PUBLIC CLASS DEFINITION 2153 // ================================ 2154 2155 var Collapse = function (element, options) { 2156 this.$element = $(element) 2157 this.options = $.extend({}, Collapse.DEFAULTS, options) 2158 this.$trigger = $('[data-toggle="collapse"][href="#' + element.id + '"],' + 2159 '[data-toggle="collapse"][data-target="#' + element.id + '"]') 2160 this.transitioning = null 2161 2162 if (this.options.parent) { 2163 this.$parent = this.getParent() 2164 } else { 2165 this.addAriaAndCollapsedClass(this.$element, this.$trigger) 2166 } 2167 2168 if (this.options.toggle) this.toggle() 2169 } 2170 2171 Collapse.VERSION = '3.4.1' 2172 2173 Collapse.TRANSITION_DURATION = 350 2174 2175 Collapse.DEFAULTS = { 2176 toggle: true 2177 } 2178 2179 Collapse.prototype.dimension = function () { 2180 var hasWidth = this.$element.hasClass('width') 2181 return hasWidth ? 'width' : 'height' 2182 } 2183 2184 Collapse.prototype.show = function () { 2185 if (this.transitioning || this.$element.hasClass('in')) return 2186 2187 var activesData 2188 var actives = this.$parent && this.$parent.children('.panel').children('.in, .collapsing') 2189 2190 if (actives && actives.length) { 2191 activesData = actives.data('bs.collapse') 2192 if (activesData && activesData.transitioning) return 2193 } 2194 2195 var startEvent = $.Event('show.bs.collapse') 2196 this.$element.trigger(startEvent) 2197 if (startEvent.isDefaultPrevented()) return 2198 2199 if (actives && actives.length) { 2200 Plugin.call(actives, 'hide') 2201 activesData || actives.data('bs.collapse', null) 2202 } 2203 2204 var dimension = this.dimension() 2205 2206 this.$element 2207 .removeClass('collapse') 2208 .addClass('collapsing')[dimension](0) 2209 .attr('aria-expanded', true) 2210 2211 this.$trigger 2212 .removeClass('collapsed') 2213 .attr('aria-expanded', true) 2214 2215 this.transitioning = 1 2216 2217 var complete = function () { 2218 this.$element 2219 .removeClass('collapsing') 2220 .addClass('collapse in')[dimension]('') 2221 this.transitioning = 0 2222 this.$element 2223 .trigger('shown.bs.collapse') 2224 } 2225 2226 if (!$.support.transition) return complete.call(this) 2227 2228 var scrollSize = $.camelCase(['scroll', dimension].join('-')) 2229 2230 this.$element 2231 .one('bsTransitionEnd', $.proxy(complete, this)) 2232 .emulateTransitionEnd(Collapse.TRANSITION_DURATION)[dimension](this.$element[0][scrollSize]) 2233 } 2234 2235 Collapse.prototype.hide = function () { 2236 if (this.transitioning || !this.$element.hasClass('in')) return 2237 2238 var startEvent = $.Event('hide.bs.collapse') 2239 this.$element.trigger(startEvent) 2240 if (startEvent.isDefaultPrevented()) return 2241 2242 var dimension = this.dimension() 2243 2244 this.$element[dimension](this.$element[dimension]())[0].offsetHeight 2245 2246 this.$element 2247 .addClass('collapsing') 2248 .removeClass('collapse in') 2249 .attr('aria-expanded', false) 2250 2251 this.$trigger 2252 .addClass('collapsed') 2253 .attr('aria-expanded', false) 2254 2255 this.transitioning = 1 2256 2257 var complete = function () { 2258 this.transitioning = 0 2259 this.$element 2260 .removeClass('collapsing') 2261 .addClass('collapse') 2262 .trigger('hidden.bs.collapse') 2263 } 2264 2265 if (!$.support.transition) return complete.call(this) 2266 2267 this.$element 2268 [dimension](0) 2269 .one('bsTransitionEnd', $.proxy(complete, this)) 2270 .emulateTransitionEnd(Collapse.TRANSITION_DURATION) 2271 } 2272 2273 Collapse.prototype.toggle = function () { 2274 this[this.$element.hasClass('in') ? 'hide' : 'show']() 2275 } 2276 2277 Collapse.prototype.getParent = function () { 2278 return $(document).find(this.options.parent) 2279 .find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]') 2280 .each($.proxy(function (i, element) { 2281 var $element = $(element) 2282 this.addAriaAndCollapsedClass(getTargetFromTrigger($element), $element) 2283 }, this)) 2284 .end() 2285 } 2286 2287 Collapse.prototype.addAriaAndCollapsedClass = function ($element, $trigger) { 2288 var isOpen = $element.hasClass('in') 2289 2290 $element.attr('aria-expanded', isOpen) 2291 $trigger 2292 .toggleClass('collapsed', !isOpen) 2293 .attr('aria-expanded', isOpen) 2294 } 2295 2296 function getTargetFromTrigger($trigger) { 2297 var href 2298 var target = $trigger.attr('data-target') 2299 || (href = $trigger.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') // strip for ie7 2300 2301 return $(document).find(target) 2302 } 2303 2304 2305 // COLLAPSE PLUGIN DEFINITION 2306 // ========================== 2307 2308 function Plugin(option) { 2309 return this.each(function () { 2310 var $this = $(this) 2311 var data = $this.data('bs.collapse') 2312 var options = $.extend({}, Collapse.DEFAULTS, $this.data(), typeof option == 'object' && option) 2313 2314 if (!data && options.toggle && /show|hide/.test(option)) options.toggle = false 2315 if (!data) $this.data('bs.collapse', (data = new Collapse(this, options))) 2316 if (typeof option == 'string') data[option]() 2317 }) 2318 } 2319 2320 var old = $.fn.collapse 2321 2322 $.fn.collapse = Plugin 2323 $.fn.collapse.Constructor = Collapse 2324 2325 2326 // COLLAPSE NO CONFLICT 2327 // ==================== 2328 2329 $.fn.collapse.noConflict = function () { 2330 $.fn.collapse = old 2331 return this 2332 } 2333 2334 2335 // COLLAPSE DATA-API 2336 // ================= 2337 2338 $(document).on('click.bs.collapse.data-api', '[data-toggle="collapse"]', function (e) { 2339 var $this = $(this) 2340 2341 if (!$this.attr('data-target')) e.preventDefault() 2342 2343 var $target = getTargetFromTrigger($this) 2344 var data = $target.data('bs.collapse') 2345 var option = data ? 'toggle' : $this.data() 2346 2347 Plugin.call($target, option) 2348 }) 2349 2350}(jQuery); 2351 2352/* ======================================================================== 2353 * Bootstrap: scrollspy.js v3.4.1 2354 * https://getbootstrap.com/docs/3.4/javascript/#scrollspy 2355 * ======================================================================== 2356 * Copyright 2011-2019 Twitter, Inc. 2357 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 2358 * ======================================================================== */ 2359 2360 2361+function ($) { 2362 'use strict'; 2363 2364 // SCROLLSPY CLASS DEFINITION 2365 // ========================== 2366 2367 function ScrollSpy(element, options) { 2368 this.$body = $(document.body) 2369 this.$scrollElement = $(element).is(document.body) ? $(window) : $(element) 2370 this.options = $.extend({}, ScrollSpy.DEFAULTS, options) 2371 this.selector = (this.options.target || '') + ' .nav li > a' 2372 this.offsets = [] 2373 this.targets = [] 2374 this.activeTarget = null 2375 this.scrollHeight = 0 2376 2377 this.$scrollElement.on('scroll.bs.scrollspy', $.proxy(this.process, this)) 2378 this.refresh() 2379 this.process() 2380 } 2381 2382 ScrollSpy.VERSION = '3.4.1' 2383 2384 ScrollSpy.DEFAULTS = { 2385 offset: 10 2386 } 2387 2388 ScrollSpy.prototype.getScrollHeight = function () { 2389 return this.$scrollElement[0].scrollHeight || Math.max(this.$body[0].scrollHeight, document.documentElement.scrollHeight) 2390 } 2391 2392 ScrollSpy.prototype.refresh = function () { 2393 var that = this 2394 var offsetMethod = 'offset' 2395 var offsetBase = 0 2396 2397 this.offsets = [] 2398 this.targets = []
vendor: 5,024 bytes, lines 2399-2583
2399 this.scrollHeight = this.getScrollHeight() 2400 2401 if (!$.isWindow(this.$scrollElement[0])) { 2402 offsetMethod = 'position' 2403 offsetBase = this.$scrollElement.scrollTop() 2404 } 2405 2406 this.$body 2407 .find(this.selector) 2408 .map(function () { 2409 var $el = $(this) 2410 var href = $el.data('target') || $el.attr('href') 2411 var $href = /^#./.test(href) && $(href) 2412 2413 return ($href 2414 && $href.length 2415 && $href.is(':visible') 2416 && [[$href[offsetMethod]().top + offsetBase, href]]) || null 2417 }) 2418 .sort(function (a, b) { return a[0] - b[0] }) 2419 .each(function () { 2420 that.offsets.push(this[0]) 2421 that.targets.push(this[1]) 2422 }) 2423 } 2424 2425 ScrollSpy.prototype.process = function () { 2426 var scrollTop = this.$scrollElement.scrollTop() + this.options.offset 2427 var scrollHeight = this.getScrollHeight() 2428 var maxScroll = this.options.offset + scrollHeight - this.$scrollElement.height() 2429 var offsets = this.offsets 2430 var targets = this.targets 2431 var activeTarget = this.activeTarget 2432 var i 2433 2434 if (this.scrollHeight != scrollHeight) { 2435 this.refresh() 2436 } 2437 2438 if (scrollTop >= maxScroll) { 2439 return activeTarget != (i = targets[targets.length - 1]) && this.activate(i) 2440 } 2441 2442 if (activeTarget && scrollTop < offsets[0]) { 2443 this.activeTarget = null 2444 return this.clear() 2445 } 2446 2447 for (i = offsets.length; i--;) { 2448 activeTarget != targets[i] 2449 && scrollTop >= offsets[i] 2450 && (offsets[i + 1] === undefined || scrollTop < offsets[i + 1]) 2451 && this.activate(targets[i]) 2452 } 2453 } 2454 2455 ScrollSpy.prototype.activate = function (target) { 2456 this.activeTarget = target 2457 2458 this.clear() 2459 2460 var selector = this.selector + 2461 '[data-target="' + target + '"],' + 2462 this.selector + '[href="' + target + '"]' 2463 2464 var active = $(selector) 2465 .parents('li') 2466 .addClass('active') 2467 2468 if (active.parent('.dropdown-menu').length) { 2469 active = active 2470 .closest('li.dropdown') 2471 .addClass('active') 2472 } 2473 2474 active.trigger('activate.bs.scrollspy') 2475 } 2476 2477 ScrollSpy.prototype.clear = function () { 2478 $(this.selector) 2479 .parentsUntil(this.options.target, '.active') 2480 .removeClass('active') 2481 } 2482 2483 2484 // SCROLLSPY PLUGIN DEFINITION 2485 // =========================== 2486 2487 function Plugin(option) { 2488 return this.each(function () { 2489 var $this = $(this) 2490 var data = $this.data('bs.scrollspy') 2491 var options = typeof option == 'object' && option 2492 2493 if (!data) $this.data('bs.scrollspy', (data = new ScrollSpy(this, options))) 2494 if (typeof option == 'string') data[option]() 2495 }) 2496 } 2497 2498 var old = $.fn.scrollspy 2499 2500 $.fn.scrollspy = Plugin 2501 $.fn.scrollspy.Constructor = ScrollSpy 2502 2503 2504 // SCROLLSPY NO CONFLICT 2505 // ===================== 2506 2507 $.fn.scrollspy.noConflict = function () { 2508 $.fn.scrollspy = old 2509 return this 2510 } 2511 2512 2513 // SCROLLSPY DATA-API 2514 // ================== 2515 2516 $(window).on('load.bs.scrollspy.data-api', function () { 2517 $('[data-spy="scroll"]').each(function () { 2518 var $spy = $(this) 2519 Plugin.call($spy, $spy.data()) 2520 }) 2521 }) 2522 2523}(jQuery); 2524 2525/* ======================================================================== 2526 * Bootstrap: transition.js v3.4.1 2527 * https://getbootstrap.com/docs/3.4/javascript/#transitions 2528 * ======================================================================== 2529 * Copyright 2011-2019 Twitter, Inc. 2530 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 2531 * ======================================================================== */ 2532 2533 2534+function ($) { 2535 'use strict'; 2536 2537 // CSS TRANSITION SUPPORT (Shoutout: https://modernizr.com/) 2538 // ============================================================ 2539 2540 function transitionEnd() { 2541 var el = document.createElement('bootstrap') 2542 2543 var transEndEventNames = { 2544 WebkitTransition : 'webkitTransitionEnd', 2545 MozTransition : 'transitionend', 2546 OTransition : 'oTransitionEnd otransitionend', 2547 transition : 'transitionend' 2548 } 2549 2550 for (var name in transEndEventNames) { 2551 if (el.style[name] !== undefined) { 2552 return { end: transEndEventNames[name] } 2553 } 2554 } 2555 2556 return false // explicit for ie8 ( ._.) 2557 } 2558 2559 // https://blog.alexmaccaw.com/css-transitions 2560 $.fn.emulateTransitionEnd = function (duration) { 2561 var called = false 2562 var $el = this 2563 $(this).one('bsTransitionEnd', function () { called = true }) 2564 var callback = function () { if (!called) $($el).trigger($.support.transition.end) } 2565 setTimeout(callback, duration) 2566 return this 2567 } 2568 2569 $(function () { 2570 $.support.transition = transitionEnd() 2571 2572 if (!$.support.transition) return 2573 2574 $.event.special.bsTransitionEnd = { 2575 bindType: $.support.transition.end, 2576 delegateType: $.support.transition.end, 2577 handle: function (e) { 2578 if ($(e.target).is(this)) return e.handleObj.handler.apply(this, arguments) 2579 } 2580 } 2581 }) 2582 2583}(jQuery);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.