烩面="Game Box Responsive web template, Bootstrap Web Templates, Flat Web Templates, Andriod Compatible web template, MY HOMETOWN郑州简介历史沿革名胜古迹郑州美景郑州美食() { () { }); 43 }); 烩面,中国十大面条之一,有着1300多年的历史。是一种荤、素、汤、菜、饭兼而有之的河南传统美食,以味道鲜美,经济实惠,享誉中原,遍及全国。烩面是以优质高筋面粉为原料,辅以高汤及多种配菜,一种类似宽面条的面食。汤好面筋,营养高。有羊肉烩面、三鲜烩面、五鲜烩面等多种类型。 烩面的精华全在于汤,汤用上等嫩羊肉、羊骨(劈开,露出中间的骨髓)一起煮五个小时以上,先用大火猛滚再用小火煲,其中下七八味中药,骨头油都熬出来了,煲出来的汤白白亮亮,犹如牛乳一样,所以又有人叫白汤。下面时,锅内放原汁肉汤,将面拉成薄条入锅,辅料以海带丝、豆腐丝、粉条、香菜、鹌鹑蛋、海参、鱿鱼等,上桌时外带香菜、辣椒油、糖蒜等小碟。 烩面是河南三大小吃之一。1300年历史河南人荤素搭配1300讲讲烩面的故事李世民相传唐太宗李世民在登基前的一个隆冬雪天,患寒病落难于一个回民农院。回民母子心地善良,将家里养的角似鹿非鹿、头似马非马、身似羊非羊、蹄似牛非牛的四不像(亦称麋鹿)屠宰炖汤,又和进面条为李世民解饿。李世民吃后浑身冒汗、暖流涌身,不觉精神大振,寒疾痊愈。慈禧太后八国联军进军北京时,慈禧太后逃到山西避难,仍然牢记用烩面补身驱寒,多次差总管李莲英诏贡山羊做烩面食用,及时解除了寒疾病险。直到清末满汉全席宗师御厨庞恩福因不甘宫庭御膳房苛律束缚,逃出皇宫隐居黄河河南段后,正宗的原阳烩面才传艺民间。赵荣光抗战时期,日军飞机经常空袭郑州,当时有一位名厨,叫做赵荣光,特别喜欢吃面食。空袭来了,赵师傅就去躲飞机,回来后,就把剩下的面条加点羊肉汤烩烩再吃。久而久之,赵师傅发现重新烩过得面也很好吃,就潜心研究,在里面放些盐和碱,使之更筋。这样做出的面别有一番风味,后来就成了风靡一时的风味美食。知名种类合记羊肉烩面萧记三鲜烩面裕丰源滋补烩面白记烩面76人老烩面煜丰羊肉烩面米河烩面尉氏烩面推荐餐厅萧记三鲜烩面美食城郑州市管城区郑汴路27号(近货栈北街)非常有名气的河南烩面馆子,在市区有好多分店,但这家算是最有人气的,面量大,手工擀的很有嚼劲,三鲜味道是传统菜式,配料好足,羊肉烩面没有膻味,一碗足够饱了。详细了解聚奎苑烩面(纬五路店)金水区 纬五路与经六路交叉口向西50米(经七路口)这家餐厅的一大优势在于环境敞亮明媚。烩面也是很赞,羊腱子肉烩面让人眼前一亮,口味浓郁,肉块也,若是来一份鸿运羊腿,烤得外脆里嫩还流油,真叫人心叫满足。详细了解声明:本网页所使用到的所有图片、链接、资料等均为网上公共资料,如有他人使用,本人不承担任何法律责任。 网页标签郑州天地之中中原经济区古都中原鸣谢百度百科百度图片腾讯QQ爱奇艺视频郑州网联系方式QQ:877922989邮箱:877922989@qq.com微博:鱼骨Eaco-@sina.com作者:景怡柯(点击上方白色字体返回顶部)
烩面源代码
还有一些网页所用到的JavaScript和CSS代码:
JavaScript:
1 if (typeof jQuery === 'undefined') { Error('Bootstrap\'s JavaScript requires jQuery') 3 } 4 5 +function ($) { 6 'use strict'; 7 var version = $.fn.jquery.split(' ')[0].split('.') 8 if ((version[0] < 2 && version[1] < 9) || (version[0] == 1 && version[1] == 9 && version[2] < 1)) { Error('Bootstrap\'s JavaScript requires jQuery version 1.9.1 or higher') 10 } 11 }(jQuery); +function ($) { 15 'use strict'; transitionEnd() { 18 var el = document.createElement('bootstrap') transEndEventNames = { 21 WebkitTransition : 'webkitTransitionEnd', 22 MozTransition : 'transitionend', 23 OTransition : 'oTransitionEnd otransitionend', 24 transition : 'transitionend' 25 } (var name in transEndEventNames) { 28 if (el.style[name] !== undefined) { 29 return { end: transEndEventNames[name] } 30 } 31 } } 35 36 $.fn.emulateTransitionEnd = function (duration) { $el = this 39 $(this).one('bsTransitionEnd', function () { called = true }) 40 var callback = function () { if (!called) $($el).trigger($.support.transition.end) } 41 setTimeout(callback, duration) } 44 45 $(function () { 46 $.support.transition = transitionEnd() (!$.support.transition) $.event.special.bsTransitionEnd = { 51 bindType: $.support.transition.end, 52 delegateType: $.support.transition.end, 53 handle: function (e) { 54 if ($(e.target).is(this)) return e.handleObj.handler.apply(this, arguments) 55 } 56 } 57 }) 58 59 }(jQuery); +function ($) { 65 'use strict'; dismiss = '[data-dismiss="alert"]' 70 var Alert = function (el) { 71 $(el).on('click', dismiss, this.close) 72 } 73 74 Alert.VERSION = '3.3.5' 75 76 Alert.TRANSITION_DURATION = 150 77 78 Alert.prototype.close = function (e) { 79 var $this = $(this) 80 var selector = $this.attr('data-target') (!selector) { 83 selector = $this.attr('href') } $parent = $(selector) (e) e.preventDefault() (!$parent.length) { 92 $parent = $this.closest('.alert') 93 } 94 95 $parent.trigger(e = $.Event('close.bs.alert')) (e.isDefaultPrevented()) $parent.removeClass('in') removeElement() { $parent.detach().trigger('closed.bs.alert').remove() 104 } 105 106 $.support.transition && $parent.hasClass('fade') ? 107 $parent 108 .one('bsTransitionEnd', removeElement) 109 .emulateTransitionEnd(Alert.TRANSITION_DURATION) : 110 removeElement() 111 } Plugin(option) { .each(function () { 119 var $this = $(this) 120 var data = $this.data('bs.alert') (!data) $this.data('bs.alert', (data = new Alert(this))) 123 if (typeof option == 'string') data[option].call($this) 124 }) 125 } old = $.fn.alert 128 129 $.fn.alert = Plugin 130 $.fn.alert.Constructor = Alert $.fn.alert.noConflict = function () { 137 $.fn.alert = old } $(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close) 146 147 }(jQuery); ======================================================================== 150 * Bootstrap: button.js v3.3.5 151 * #buttons 152 * ======================================================================== 153 * Copyright 2011-2015 Twitter, Inc. 154 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 159 'use strict'; Button = function (element, options) { 165 this.$element = $(element) 166 this.options = $.extend({}, Button.DEFAULTS, options) } 169 170 Button.VERSION = '3.3.5' 171 172 Button.DEFAULTS = { 173 loadingText: 'loading...' 174 } 175 176 Button.prototype.setState = function (state) { 177 var d = 'disabled' 178 var $el = this.$element 179 var val = $el.is('input') ? 'val' : 'html' 180 var data = $el.data() 181 182 state += 'Text' (data.resetText == null) $el.data('resetText', $el[val]()) setTimeout($.proxy(function () { 188 $el[val](data[state] == null ? this.options[state] : data[state]) (state == 'loadingText') { $el.addClass(d).attr(d, d) 193 } else if (this.isLoading) { $el.removeClass(d).removeAttr(d) 196 } 197 }, this), 0) 198 } 199 200 Button.prototype.toggle = function () { $parent = this.$element.closest('[data-toggle="buttons"]') ($parent.length) { 205 var $input = this.$element.find('input') 206 if ($input.prop('type') == 'radio') { $parent.find('.active').removeClass('active') 209 this.$element.addClass('active') 210 } else if ($input.prop('type') == 'checkbox') { .$element.toggleClass('active') 213 } 214 $input.prop('checked', this.$element.hasClass('active')) 215 if (changed) $input.trigger('change') 216 } else { 217 this.$element.attr('aria-pressed', !this.$element.hasClass('active')) 218 this.$element.toggleClass('active') 219 } 220 } Plugin(option) { .each(function () { 228 var $this = $(this) 229 var data = $this.data('bs.button') 230 var options = typeof option == 'object' && option (!data) $this.data('bs.button', (data = new Button(this, options))) (option == 'toggle') data.toggle() (option) data.setState(option) 236 }) 237 } old = $.fn.button 240 241 $.fn.button = Plugin 242 $.fn.button.Constructor = Button $.fn.button.noConflict = function () { 249 $.fn.button = old } $(document) 258 .on('click.bs.button.data-api', '[data-toggle^="button"]', function (e) { 259 var $btn = $(e.target) 260 if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn') 261 Plugin.call($btn, 'toggle') 262 if (!($(e.target).is('input[type="radio"]') || $(e.target).is('input[type="checkbox"]'))) e.preventDefault() 263 }) 264 .on('focus.bs.button.data-api blur.bs.button.data-api', '[data-toggle^="button"]', function (e) { 265 $(e.target).closest('.btn').toggleClass('focus', /^focus(in)?$/.test(e.type)) 266 }) 267 268 }(jQuery); ======================================================================== 271 * Bootstrap: carousel.js v3.3.5 272 * #carousel 273 * ======================================================================== 274 * Copyright 2011-2015 Twitter, Inc. 275 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 280 'use strict'; Carousel = function (element, options) { 286 this.$element = $(element) 287 this.$indicators = this.$element.find('.carousel-indicators') 288 this.options = options .sliding = .interval = .$active = .$items = .options.keyboard && this.$element.on('keydown.bs.carousel', $.proxy(this.keydown, this)) .options.pause == 'hover' && !('ontouchstart' in document.documentElement) && this.$element 298 .on('mouseenter.bs.carousel', $.proxy(this.pause, this)) 299 .on('mouseleave.bs.carousel', $.proxy(this.cycle, this)) 300 } 301 302 Carousel.VERSION = '3.3.5' 303 304 Carousel.TRANSITION_DURATION = 600 305 306 Carousel.DEFAULTS = { 307 interval: 5000, 308 pause: 'hover', 309 wrap: true, 310 keyboard: true 311 } 312 313 Carousel.prototype.keydown = function (e) { (e.which) { 39: : return 319 } 320 321 e.preventDefault() 322 } 323 324 Carousel.prototype.cycle = function (e) { 325 e || (this.paused = false) .interval && clearInterval(this.interval) .options.interval 330 && !this.paused 331 && (this.interval = setInterval($.proxy(this.next, this), this.options.interval)) } 335 336 Carousel.prototype.getItemIndex = function (item) { 337 this.$items = item.parent().children('.item') .$items.index(item || this.$active) 339 } 340 341 Carousel.prototype.getItemForDirection = function (direction, active) { 342 var activeIndex = this.getItemIndex(active) 343 var willWrap = (direction == 'prev' && activeIndex === 0) 344 || (direction == 'next' && activeIndex == (this.$items.length - 1)) 345 if (willWrap && !this.options.wrap) return active 346 var delta = direction == 'prev' ? -1 : 1 347 var itemIndex = (activeIndex + delta) % this.$items.length .$items.eq(itemIndex) 349 } 350 351 Carousel.prototype.to = function (pos) { activeIndex = this.getItemIndex(this.$active = this.$element.find('.item.active')) (pos > (((activeIndex == pos) return this.pause().cycle() .slide(pos > activeIndex ? 'next' : 'prev', this.$items.eq(pos)) 361 } 362 363 Carousel.prototype.pause = function (e) { 364 e || (this.paused = true) (this.$element.find('.next, .prev').length && $.support.transition) { 367 this.$element.trigger($.support.transition.end) 368 this.cycle(true) 369 } .interval = clearInterval(this.interval) } 375 376 Carousel.prototype.next = function () { .slide('next') 379 } 380 381 Carousel.prototype.prev = function () { .slide('prev') 384 } 385 386 Carousel.prototype.slide = function (type, next) { 387 var $active = this.$element.find('.item.active') 388 var $next = next || this.getItemForDirection(type, $active) 389 var isCycling = this.interval 390 var direction = type == 'next' ? 'left' : 'right' ($next.hasClass('active')) return (this.sliding = false) relatedTarget = $next[0] 396 var slideEvent = $.Event('slide.bs.carousel', { 397 relatedTarget: relatedTarget, 398 direction: direction 399 }) 400 this.$element.trigger(slideEvent) .sliding = isCycling && this.pause() (this.$indicators.length) { 408 this.$indicators.find('.active').removeClass('active') 409 var $nextIndicator = $(this.$indicators.children()[this.getItemIndex($next)]) 410 $nextIndicator && $nextIndicator.addClass('active') 411 } slidEvent = $.Event('slid.bs.carousel', { relatedTarget: relatedTarget, direction: direction }) ($.support.transition && this.$element.hasClass('slide')) { 415 $next.addClass(type) $active.addClass(direction) 418 $next.addClass(direction) 419 $active 420 .one('bsTransitionEnd', function () { 421 $next.removeClass([type, direction].join(' ')).addClass('active') 422 $active.removeClass(['active', direction].join(' ')) 423 that.sliding = false 424 setTimeout(function () { 425 that.$element.trigger(slidEvent) 426 }, 0) 427 }) 428 .emulateTransitionEnd(Carousel.TRANSITION_DURATION) 429 } else { 430 $active.removeClass('active') 431 $next.addClass('active') .$element.trigger(slidEvent) 434 } 435 436 isCycling && this.cycle() } Plugin(option) { .each(function () { 447 var $this = $(this) 448 var data = $this.data('bs.carousel') 449 var options = $.extend({}, Carousel.DEFAULTS, $this.data(), typeof option == 'object' && option) 450 var action = typeof option == 'string' ? option : options.slide (!data) $this.data('bs.carousel', (data = new Carousel(this, options))) 453 if (typeof option == 'number') data.to(option) (action) data[action]() (options.interval) data.pause().cycle() 456 }) 457 } old = $.fn.carousel 460 461 $.fn.carousel = Plugin 462 $.fn.carousel.Constructor = Carousel $.fn.carousel.noConflict = function () { 469 $.fn.carousel = old } clickHandler = function (e) { 478 var href 479 var $this = $(this) (!$target.hasClass('carousel')) options = $.extend({}, $target.data(), $this.data()) 483 var slideIndex = $this.attr('data-slide-to') Plugin.call($target, options) (slideIndex) { 489 $target.data('bs.carousel').to(slideIndex) 490 } 491 492 e.preventDefault() 493 } 494 495 $(document) 496 .on('click.bs.carousel.data-api', '[data-slide]', clickHandler) 497 .on('click.bs.carousel.data-api', '[data-slide-to]', clickHandler) 498 499 $(window).on('load', function () { 500 $('[data-ride="carousel"]').each(function () { 501 var $carousel = $(this) 502 Plugin.call($carousel, $carousel.data()) 503 }) 504 }) 505 506 }(jQuery); ======================================================================== 509 * Bootstrap: collapse.js v3.3.5 510 * #collapse 511 * ======================================================================== 512 * Copyright 2011-2015 Twitter, Inc. 513 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 518 'use strict'; Collapse = function (element, options) { 524 this.$element = $(element) 525 this.options = $.extend({}, Collapse.DEFAULTS, options) 526 this.$trigger = $('[data-toggle="collapse"][href="#' + element.id + '"],' + 527 '[data-toggle="collapse"][data-target="#' + element.id + '"]') (this.options.parent) { 531 this.$parent = this.getParent() 532 } else { 533 this.addAriaAndCollapsedClass(this.$element, this.$trigger) 534 } (this.options.toggle) this.toggle() 537 } 538 539 Collapse.VERSION = '3.3.5' 540 541 Collapse.TRANSITION_DURATION = 350 542 543 Collapse.DEFAULTS = { 544 toggle: true 545 } 546 547 Collapse.prototype.dimension = function () { 548 var hasWidth = this.$element.hasClass('width') 549 return hasWidth ? 'width' : 'height' 550 } 551 552 Collapse.prototype.show = function () { activesData 556 var actives = this.$parent && this.$parent.children('.panel').children('.in, .collapsing') (actives && actives.length) { 559 activesData = actives.data('bs.collapse') } startEvent = $.Event('show.bs.collapse') 564 this.$element.trigger(startEvent) (actives && actives.length) { 568 Plugin.call(actives, 'hide') 569 activesData || actives.data('bs.collapse', null) 570 } dimension = this.dimension() .$element 575 .removeClass('collapse') 576 .addClass('collapsing')[dimension](0) 577 .attr('aria-expanded', true) .$trigger 580 .removeClass('collapsed') 581 .attr('aria-expanded', true) .transitioning = 1 complete = function () { 586 this.$element 587 .removeClass('collapsing') 588 .addClass('collapse in')[dimension]('') 589 this.transitioning = 0 590 this.$element 591 .trigger('shown.bs.collapse') 592 } (!$.support.transition) return complete.call(this) scrollSize = $.camelCase(['scroll', dimension].join('-')) .$element 599 .one('bsTransitionEnd', $.proxy(complete, this)) 600 .emulateTransitionEnd(Collapse.TRANSITION_DURATION)[dimension](this.$element[0][scrollSize]) 601 } 602 603 Collapse.prototype.hide = function () { startEvent = $.Event('hide.bs.collapse') 607 this.$element.trigger(startEvent) dimension = this.dimension() .$element[dimension](this.$element[dimension]())[0].offsetHeight .$element 615 .addClass('collapsing') 616 .removeClass('collapse in') 617 .attr('aria-expanded', false) .$trigger 620 .addClass('collapsed') 621 .attr('aria-expanded', false) .transitioning = 1 complete = function () { 626 this.transitioning = 0 627 this.$element 628 .removeClass('collapsing') 629 .addClass('collapse') 630 .trigger('hidden.bs.collapse') 631 } (!$.support.transition) return complete.call(this) .$element 636 [dimension](0) 637 .one('bsTransitionEnd', $.proxy(complete, this)) 638 .emulateTransitionEnd(Collapse.TRANSITION_DURATION) 639 } 640 641 Collapse.prototype.toggle = function () { 642 this[this.$element.hasClass('in') ? 'hide' : 'show']() 643 } 644 645 Collapse.prototype.getParent = function () { 646 return $(this.options.parent) 647 .find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]') 648 .each($.proxy(function (i, element) { 649 var $element = $(element) 650 this.addAriaAndCollapsedClass(getTargetFromTrigger($element), $element) 651 }, this)) 652 .end() 653 } 654 655 Collapse.prototype.addAriaAndCollapsedClass = function ($element, $trigger) { 656 var isOpen = $element.hasClass('in') 657 658 $element.attr('aria-expanded', isOpen) 659 $trigger 660 .toggleClass('collapsed', !isOpen) 661 .attr('aria-expanded', isOpen) 662 } getTargetFromTrigger($trigger) { 665 var href 666 var target = $trigger.attr('data-target') $(target) 670 } Plugin(option) { .each(function () { 678 var $this = $(this) 679 var data = $this.data('bs.collapse') 680 var options = $.extend({}, Collapse.DEFAULTS, $this.data(), typeof option == 'object' && option) (!data && options.toggle && /show|hide/.test(option)) options.toggle = (!data) $this.data('bs.collapse', (data = new Collapse(this, options))) 684 if (typeof option == 'string') data[option]() 685 }) 686 } old = $.fn.collapse 689 690 $.fn.collapse = Plugin 691 $.fn.collapse.Constructor = Collapse $.fn.collapse.noConflict = function () { 698 $.fn.collapse = old } $(document).on('click.bs.collapse.data-api', '[data-toggle="collapse"]', function (e) { 707 var $this = $(this) (!$this.attr('data-target')) e.preventDefault() $target = getTargetFromTrigger($this) 712 var data = $target.data('bs.collapse') 713 var option = data ? 'toggle' : $this.data() 714 715 Plugin.call($target, option) 716 }) 717 718 }(jQuery); ======================================================================== 721 * Bootstrap: dropdown.js v3.3.5 722 * #dropdowns 723 * ======================================================================== 724 * Copyright 2011-2015 Twitter, Inc. 725 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 730 'use strict'; backdrop = '.dropdown-backdrop' 736 var toggle = '[data-toggle="dropdown"]' 737 var Dropdown = function (element) { 738 $(element).on('click.bs.dropdown', this.toggle) 739 } 740 741 Dropdown.VERSION = '3.3.5' getParent($this) { 744 var selector = $this.attr('data-target') (!selector) { 747 selector = $this.attr('href') } $parent = selector && $(selector) $parent && $parent.length ? $parent : $this.parent() 754 } clearMenus(e) { $(backdrop).remove() 759 $(toggle).each(function () { 760 var $this = $(this) 761 var $parent = getParent($this) 762 var relatedTarget = { relatedTarget: this } (!$parent.hasClass('open')) (e && e.type == 'click' && /input|textarea/i.test(e.target.tagName) && $.contains($parent[0], e.target)) $parent.trigger(e = $.Event('hide.bs.dropdown', relatedTarget)) (e.isDefaultPrevented()) $this.attr('aria-expanded', 'false') 773 $parent.removeClass('open').trigger('hidden.bs.dropdown', relatedTarget) 774 }) 775 } 776 777 Dropdown.prototype.toggle = function (e) { 778 var $this = $(this) ($$parent = getParent($this) 783 var isActive = $parent.hasClass('open') 784 785 clearMenus() (!isActive) { 788 if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) { $(document.createElement('div')) 791 .addClass('dropdown-backdrop') 792 .insertAfter($(this)) 793 .on('click', clearMenus) 794 } relatedTarget = { relatedTarget: this } 797 $parent.trigger(e = $.Event('show.bs.dropdown', relatedTarget)) (e.isDefaultPrevented()) $this 802 .trigger('focus') 803 .attr('aria-expanded', 'true') 804 805 $parent 806 .toggleClass('open') 807 .trigger('shown.bs.dropdown', relatedTarget) 808 } } 812 813 Dropdown.prototype.keydown = function (e) { $this = $(this) 817 818 e.preventDefault() 819 e.stopPropagation() ($$parent = getParent($this) 824 var isActive = $parent.hasClass('open') (!isActive && e.which != 27 || isActive && e.which == 27) { 827 if (e.which == 27) $parent.find(toggle).trigger('focus') 828 return $this.trigger('click') 829 } desc = ' li:not(.disabled):visible a' 832 var $items = $parent.find('.dropdown-menu' + desc) (!$items.length) index = $items.index(e.target) (e.which == 38 && index > 0) index-- (e.which == 40 && index < $items.length - 1) index++ (!~index) index = 0 841 842 $items.eq(index).trigger('focus') 843 } Plugin(option) { .each(function () { 851 var $this = $(this) 852 var data = $this.data('bs.dropdown') (!data) $this.data('bs.dropdown', (data = new Dropdown(this))) 855 if (typeof option == 'string') data[option].call($this) 856 }) 857 } old = $.fn.dropdown 860 861 $.fn.dropdown = Plugin 862 $.fn.dropdown.Constructor = Dropdown $.fn.dropdown.noConflict = function () { 869 $.fn.dropdown = old } $(document) 878 .on('click.bs.dropdown.data-api', clearMenus) 879 .on('click.bs.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() }) 880 .on('click.bs.dropdown.data-api', toggle, Dropdown.prototype.toggle) 881 .on('keydown.bs.dropdown.data-api', toggle, Dropdown.prototype.keydown) 882 .on('keydown.bs.dropdown.data-api', '.dropdown-menu', Dropdown.prototype.keydown) 883 884 }(jQuery); ======================================================================== 887 * Bootstrap: modal.js v3.3.5 888 * #modals 889 * ======================================================================== 890 * Copyright 2011-2015 Twitter, Inc. 891 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 896 'use strict'; Modal = function (element, options) { 902 this.options = options 903 this.$body = $(document.body) 904 this.$element = $(element) 905 this.$dialog = this.$element.find('.modal-dialog') .isShown = .originalBodyPad = .scrollbarWidth = 0 (this.options.remote) { 913 this.$element 914 .find('.modal-content') 915 .load(this.options.remote, $.proxy(function () { 916 this.$element.trigger('loaded.bs.modal') 917 }, this)) 918 } 919 } 920 921 Modal.VERSION = '3.3.5' 922 923 Modal.TRANSITION_DURATION = 300 924 Modal.BACKDROP_TRANSITION_DURATION = 150 925 926 Modal.DEFAULTS = { 927 backdrop: true, 928 keyboard: true, 929 show: true 930 } 931 932 Modal.prototype.toggle = function (_relatedTarget) { .isShown ? this.hide() : this.show(_relatedTarget) 934 } 935 936 Modal.prototype.show = function (_relatedTarget) { e = $.Event('show.bs.modal', { relatedTarget: _relatedTarget }) .$element.trigger(e) (.isShown = .checkScrollbar() 947 this.setScrollbar() 948 this.$body.addClass('modal-open') .escape() 951 this.resize() .$element.on('click.dismiss.bs.modal', '[data-dismiss="modal"]', $.proxy(this.hide, this)) .$dialog.on('mousedown.dismiss.bs.modal', function () { 956 that.$element.one('mouseup.dismiss.bs.modal', function (e) { }) 959 }) .backdrop(function () { 962 var transition = $.support.transition && that.$element.hasClass('fade') (!that.$element.parent().length) { } 967 968 that.$element 969 .show() 970 .scrollTop(0) 971 972 that.adjustDialog() (transition) { } 977 978 that.$element.addClass('in') 979 980 that.enforceFocus() e = $.Event('shown.bs.modal', { relatedTarget: _relatedTarget }) 983 984 transition ? .one('bsTransitionEnd', function () { 987 that.$element.trigger('focus').trigger(e) 988 }) 989 .emulateTransitionEnd(Modal.TRANSITION_DURATION) : 990 that.$element.trigger('focus').trigger(e) 991 }) 992 } 993 994 Modal.prototype.hide = function (e) { 995 if (e) e.preventDefault() 996 997 e = $.Event('hide.bs.modal') .$element.trigger(e) (!.isShown = .escape() 1006 this.resize() 1007 1008 $(document).off('focusin.bs.modal') .$element 1011 .removeClass('in') 1012 .off('click.dismiss.bs.modal') 1013 .off('mouseup.dismiss.bs.modal') .$dialog.off('mousedown.dismiss.bs.modal') 1016 1017 $.support.transition && this.$element.hasClass('fade') ? 1018 this.$element 1019 .one('bsTransitionEnd', $.proxy(this.hideModal, this)) 1020 .emulateTransitionEnd(Modal.TRANSITION_DURATION) : 1021 this.hideModal() 1022 } 1023 1024 Modal.prototype.enforceFocus = function () { 1025 $(document) .on('focusin.bs.modal', $.proxy(function (e) { 1028 if (this.$element[0] !== e.target && !this.$element.has(e.target).length) { 1029 this.$element.trigger('focus') 1030 } 1031 }, this)) 1032 } 1033 1034 Modal.prototype.escape = function () { 1035 if (this.isShown && this.options.keyboard) { 1036 this.$element.on('keydown.dismiss.bs.modal', $.proxy(function (e) { 1037 e.which == 27 && this.hide() 1038 }, this)) 1039 } else if (!this.isShown) { 1040 this.$element.off('keydown.dismiss.bs.modal') 1041 } 1042 } 1043 1044 Modal.prototype.resize = function () { 1045 if (this.isShown) { 1046 $(window).on('resize.bs.modal', $.proxy(this.handleUpdate, this)) 1047 } else { 1048 $(window).off('resize.bs.modal') 1049 } 1050 } 1051 1052 Modal.prototype.hideModal = function () { .$element.hide() 1055 this.backdrop(function () { 1056 that.$body.removeClass('modal-open') 1057 that.resetAdjustments() 1058 that.resetScrollbar() 1059 that.$element.trigger('hidden.bs.modal') 1060 }) 1061 } 1062 1063 Modal.prototype.removeBackdrop = function () { 1064 this.$backdrop && this.$backdrop.remove() } 1067 1068 Modal.prototype.backdrop = function (callback) { animate = this.$element.hasClass('fade') ? 'fade' : '' (this.isShown && this.options.backdrop) { 1073 var doAnimate = $.support.transition && animate .$backdrop = $(document.createElement('div')) 1076 .addClass('modal-backdrop ' + animate) 1077 .appendTo(this.$body) .$element.on('click.dismiss.bs.modal', $.proxy(function (e) { 1080 if (this.ignoreBackdropClick) { } .options.backdrop == 'static' 1086 ? this.$element[0].focus() 1087 : this.hide() 1088 }, this)) (doAnimate) .$backdrop.addClass('in') (!callback) doAnimate ? 1097 this.$backdrop 1098 .one('bsTransitionEnd', callback) 1099 .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) : 1100 callback() (!this.isShown && this.$backdrop) { 1103 this.$backdrop.removeClass('in') callbackRemove = function () { 1106 that.removeBackdrop() 1107 callback && callback() 1108 } 1109 $.support.transition && this.$element.hasClass('fade') ? 1110 this.$backdrop 1111 .one('bsTransitionEnd', callbackRemove) 1112 .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) : 1113 callbackRemove() (callback) { 1116 callback() 1117 } 1118 } Modal.prototype.handleUpdate = function () { 1123 this.adjustDialog() 1124 } 1125 1126 Modal.prototype.adjustDialog = function () { 1127 var modalIsOverflowing = this.$element[0].scrollHeight > document.documentElement.clientHeight .$element.css({ 1130 paddingLeft: !this.bodyIsOverflowing && modalIsOverflowing ? this.scrollbarWidth : '', 1131 paddingRight: this.bodyIsOverflowing && !modalIsOverflowing ? this.scrollbarWidth : '' 1132 }) 1133 } 1134 1135 Modal.prototype.resetAdjustments = function () { 1136 this.$element.css({ 1137 paddingLeft: '', 1138 paddingRight: '' 1139 }) 1140 } 1141 1142 Modal.prototype.checkScrollbar = function () { 1143 var fullWindowWidth = window.innerWidth documentElementRect = document.documentElement.getBoundingClientRect() 1146 fullWindowWidth = documentElementRect.right - Math.abs(documentElementRect.left) 1147 } 1148 this.bodyIsOverflowing = document.body.clientWidth < fullWindowWidth 1149 this.scrollbarWidth = this.measureScrollbar() 1150 } 1151 1152 Modal.prototype.setScrollbar = function () { 1153 var bodyPad = parseInt((this.$body.css('padding-right') || 0), 10) 1154 this.originalBodyPad = document.body.style.paddingRight || '' 1155 if (this.bodyIsOverflowing) this.$body.css('padding-right', bodyPad + this.scrollbarWidth) 1156 } 1157 1158 Modal.prototype.resetScrollbar = function () { 1159 this.$body.css('padding-right', this.originalBodyPad) 1160 } scrollDiv = document.createElement('div') 1164 scrollDiv.className = 'modal-scrollbar-measure' 1165 this.$body.append(scrollDiv) 1166 var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth 1167 this.$body[0].removeChild(scrollDiv) 1168 return scrollbarWidth 1169 } Plugin(option, _relatedTarget) { .each(function () { 1177 var $this = $(this) 1178 var data = $this.data('bs.modal') 1179 var options = $.extend({}, Modal.DEFAULTS, $this.data(), typeof option == 'object' && option) (!data) $this.data('bs.modal', (data = new Modal(this, options))) 1182 if (typeof option == 'string') data[option](_relatedTarget) (options.show) data.show(_relatedTarget) 1184 }) 1185 } old = $.fn.modal 1188 1189 $.fn.modal = Plugin 1190 $.fn.modal.Constructor = Modal $.fn.modal.noConflict = function () { 1197 $.fn.modal = old } $(document).on('click.bs.modal.data-api', '[data-toggle="modal"]', function (e) { 1206 var $this = $(this) 1207 var href = $this.attr('href') option = $target.data('bs.modal') ? 'toggle' : $.extend({ remote: !/#/.test(href) && href }, $target.data(), $this.data()) ($this.is('a')) e.preventDefault() 1212 1213 $target.one('show.bs.modal', function (showEvent) { $target.one('hidden.bs.modal', function () { 1216 $this.is(':visible') && $this.trigger('focus') 1217 }) 1218 }) 1219 Plugin.call($target, option, this) 1220 }) 1221 1222 }(jQuery); ======================================================================== 1225 * Bootstrap: tooltip.js v3.3.5 1226 * #tooltip 1227 * Inspired by the original jQuery.tipsy by Jason Frame 1228 * ======================================================================== 1229 * Copyright 2011-2015 Twitter, Inc. 1230 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 1235 'use strict'; Tooltip = function (element, options) { .options = .enabled = .timeout = .hoverState = .$element = .inState = .init('tooltip', element, options) 1250 } 1251 1252 Tooltip.VERSION = '3.3.5' 1253 1254 Tooltip.TRANSITION_DURATION = 150 1255 1256 Tooltip.DEFAULTS = { 1257 animation: true, 1258 placement: 'top', 1259 selector: false, 1260 template: '<div role="tooltip"><div></div><div></div></div>', 1261 trigger: 'hover focus', 1262 title: '', 1263 delay: 0, 1264 html: false, 1265 container: false, 1266 viewport: { 1267 selector: 'body', 1268 padding: 0 1269 } 1270 } 1271 1272 Tooltip.prototype.init = function (type, element, options) { .type = type 1275 this.$element = $(element) 1276 this.options = this.getOptions(options) 1277 this.$viewport = this.options.viewport && $($.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : (this.options.viewport.selector || this.options.viewport)) 1278 this.inState = { click: false, hover: false, focus: false } (this.$element[0] instanceof document.constructor && !this.options.selector) { Error('`selector` option must be specified when initializing ' + this.type + ' on the window.document object!') 1282 } triggers = this.options.trigger.split(' ') (var i = triggers.length; i--;) { 1287 var trigger = triggers[i] (trigger == 'click') { 1290 this.$element.on('click.' + this.type, this.options.selector, $.proxy(this.toggle, this)) 1291 } else if (trigger != 'manual') { 1292 var eventIn = trigger == 'hover' ? 'mouseenter' : 'focusin' 1293 var eventOut = trigger == 'hover' ? 'mouseleave' : 'focusout' .$element.on(eventIn + '.' + this.type, this.options.selector, $.proxy(this.enter, this)) 1296 this.$element.on(eventOut + '.' + this.type, this.options.selector, $.proxy(this.leave, this)) 1297 } 1298 } .options.selector ? 1301 (this._options = $.extend({}, this.options, { trigger: 'manual', selector: '' })) : 1302 this.fixTitle() 1303 } 1304 1305 Tooltip.prototype.getDefaults = function () { 1306 return Tooltip.DEFAULTS 1307 } 1308 1309 Tooltip.prototype.getOptions = function (options) { 1310 options = $.extend({}, this.getDefaults(), this.$element.data(), options) (options.delay && typeof options.delay == 'number') { 1313 options.delay = { 1314 show: options.delay, 1315 hide: options.delay 1316 } 1317 } options 1320 } 1321 1322 Tooltip.prototype.getDelegateOptions = function () { 1323 var options = {} 1324 var defaults = this.getDefaults() ._options && $.each(this._options, function (key, value) { 1327 if (defaults[key] != value) options[key] = value 1328 }) options 1331 } 1332 1333 Tooltip.prototype.enter = function (obj) { .constructor ? 1335 obj : $(obj.currentTarget).data('bs.' + this.type) (!self) { 1338 self = new this.constructor(obj.currentTarget, this.getDelegateOptions()) 1339 $(obj.currentTarget).data('bs.' + this.type, self) 1340 } (obj instanceof $.Event) { 1343 self.inState[obj.type == 'focusin' ? 'focus' : 'hover'] = true 1344 } (self.tip().hasClass('in') || self.hoverState == 'in') { 1347 self.hoverState = 'in' } 1350 1351 clearTimeout(self.timeout) 1352 1353 self.hoverState = 'in' (!self.options.delay || !self.options.delay.show) return self.show() 1356 1357 self.timeout = setTimeout(function () { 1358 if (self.hoverState == 'in') self.show() 1359 }, self.options.delay.show) 1360 } 1361 1362 Tooltip.prototype.isInStateTrue = function () { .inState) { } } 1369 1370 Tooltip.prototype.leave = function (obj) { .constructor ? 1372 obj : $(obj.currentTarget).data('bs.' + this.type) (!self) { 1375 self = new this.constructor(obj.currentTarget, this.getDelegateOptions()) 1376 $(obj.currentTarget).data('bs.' + this.type, self) 1377 } (obj instanceof $.Event) { 1380 self.inState[obj.type == 'focusout' ? 'focus' : 'hover'] = false 1381 } (self.isInStateTrue()) clearTimeout(self.timeout) 1386 1387 self.hoverState = 'out' (!self.options.delay || !self.options.delay.hide) return self.hide() 1390 1391 self.timeout = setTimeout(function () { 1392 if (self.hoverState == 'out') self.hide() 1393 }, self.options.delay.hide) 1394 } 1395 1396 Tooltip.prototype.show = function () { 1397 var e = $.Event('show.bs.' + this.type) (this.hasContent() && this.enabled) { 1400 this.$element.trigger(e) inDom = $.contains(this.$element[0].ownerDocument.documentElement, this.$element[0]) that = $tip = this.tip() tipId = this.getUID(this.type) .setContent() 1411 $tip.attr('id', tipId) 1412 this.$element.attr('aria-describedby', tipId) (this.options.animation) $tip.addClass('fade') placement = typeof this.options.placement == 'function' ? 1417 this.options.placement.call(this, $tip[0], this.$element[0]) : 1418 this.options.placement autoToken = /\s?auto?\s?/i 1421 var autoPlace = autoToken.test(placement) 1422 if (autoPlace) placement = placement.replace(autoToken, '') || 'top' 1423 1424 $tip 1425 .detach() 1426 .css({ top: 0, left: 0, display: 'block' }) 1427 .addClass(placement) 1428 .data('bs.' + this.type, this) .options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element) 1431 this.$element.trigger('inserted.bs.' + this.type) pos = this.getPosition() 1434 var actualWidth = $tip[0].offsetWidth 1435 var actualHeight = $tip[0].offsetHeight (autoPlace) { 1438 var orgPlacement = placement 1439 var viewportDim = this.getPosition(this.$viewport) 1440 1441 placement = placement == 'bottom' && pos.bottom + actualHeight > viewportDim.bottom ? 'top' : 1442 placement == 'top' && pos.top - actualHeight < viewportDim.top ? 'bottom' : 1443 placement == 'right' && pos.right + actualWidth > viewportDim.width ? 'left' : 1444 placement == 'left' && pos.left - actualWidth < viewportDim.left ? 'right' : 1445 placement 1446 1447 $tip 1448 .removeClass(orgPlacement) 1449 .addClass(placement) 1450 } calculatedOffset = this.getCalculatedOffset(placement, pos, actualWidth, actualHeight) .applyPlacement(calculatedOffset, placement) complete = function () { 1457 var prevHoverState = that.hoverState 1458 that.$element.trigger('shown.bs.' + that.type) (prevHoverState == 'out') that.leave(that) 1462 } 1463 1464 $.support.transition && this.$tip.hasClass('fade') ? 1465 $tip 1466 .one('bsTransitionEnd', complete) 1467 .emulateTransitionEnd(Tooltip.TRANSITION_DURATION) : 1468 complete() 1469 } 1470 } 1471 1472 Tooltip.prototype.applyPlacement = function (offset, placement) { 1473 var $tip = this.tip() 1474 var width = $tip[0].offsetWidth 1475 var height = $tip[0].offsetHeight marginTop = parseInt($tip.css('margin-top'), 10) 1479 var marginLeft = parseInt($tip.css('margin-left'), 10) (isNaN(marginTop)) marginTop = 0 1483 if (isNaN(marginLeft)) marginLeft = 0 1484 1485 offset.top += marginTop 1486 offset.left += marginLeft $.offset.setOffset($tip[0], $.extend({ 1491 using: function (props) { 1492 $tip.css({ 1493 top: Math.round(props.top), 1494 left: Math.round(props.left) 1495 }) 1496 } 1497 }, offset), 0) 1498 1499 $tip.addClass('in') actualWidth = $tip[0].offsetWidth 1503 var actualHeight = $tip[0].offsetHeight (placement == 'top' && actualHeight != height) { 1506 offset.top = offset.top + height - actualHeight 1507 } delta = this.getViewportAdjustedDelta(placement, offset, actualWidth, actualHeight) (delta.left) offset.left += delta.left 1512 else offset.top += delta.top isVertical = /top|bottom/.test(placement) 1515 var arrowDelta = isVertical ? delta.left * 2 - width + actualWidth : delta.top * 2 - height + actualHeight 1516 var arrowOffsetPosition = isVertical ? 'offsetWidth' : 'offsetHeight' 1517 1518 $tip.offset(offset) 1519 this.replaceArrow(arrowDelta, $tip[0][arrowOffsetPosition], isVertical) 1520 } 1521 1522 Tooltip.prototype.replaceArrow = function (delta, dimension, isVertical) { 1523 this.arrow() 1524 .css(isVertical ? 'left' : 'top', 50 * (1 - delta / dimension) + '%') 1525 .css(isVertical ? 'top' : 'left', '') 1526 } 1527 1528 Tooltip.prototype.setContent = function () { 1529 var $tip = this.tip() 1530 var title = this.getTitle() 1531 1532 $tip.find('.tooltip-inner')[this.options.html ? 'html' : 'text'](title) 1533 $tip.removeClass('fade in top bottom left right') 1534 } 1535 1536 Tooltip.prototype.hide = function (callback) { $tip = $(this.$tip) 1539 var e = $.Event('hide.bs.' + this.type) complete() { 1542 if (that.hoverState != 'in') $tip.detach() 1543 that.$element 1544 .removeAttr('aria-describedby') 1545 .trigger('hidden.bs.' + that.type) 1546 callback && callback() 1547 } .$element.trigger(e) (e.isDefaultPrevented()) $tip.removeClass('in') 1554 1555 $.support.transition && $tip.hasClass('fade') ? 1556 $tip 1557 .one('bsTransitionEnd', complete) 1558 .emulateTransitionEnd(Tooltip.TRANSITION_DURATION) : 1559 complete() .hoverState = } 1565 1566 Tooltip.prototype.fixTitle = function () { 1567 var $e = this.$element 1568 if ($e.attr('title') || typeof $e.attr('data-original-title') != 'string') { 1569 $e.attr('data-original-title', $e.attr('title') || '').attr('title', '') 1570 } 1571 } 1572 1573 Tooltip.prototype.hasContent = function () { .getTitle() 1575 } 1576 1577 Tooltip.prototype.getPosition = function ($element) { 1578 $element = $element || this.$element el = $element[0] 1581 var isBody = el.tagName == 'BODY' elRect = el.getBoundingClientRect() 1584 if (elRect.width == null) { elRect = $.extend({}, elRect, { width: elRect.right - elRect.left, height: elRect.bottom - elRect.top }) 1587 } 1588 var elOffset = isBody ? { top: 0, left: 0 } : $element.offset() 1589 var scroll = { scroll: isBody ? document.documentElement.scrollTop || document.body.scrollTop : $element.scrollTop() } $.extend({}, elRect, scroll, outerDims, elOffset) 1593 } 1594 1595 Tooltip.prototype.getCalculatedOffset = function (placement, pos, actualWidth, actualHeight) { 1596 return placement == 'bottom' ? { top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2 } : 1597 placement == 'top' ? { top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2 } : 1598 placement == 'left' ? { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth } : { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width } 1600 1601 } 1602 1603 Tooltip.prototype.getViewportAdjustedDelta = function (placement, pos, actualWidth, actualHeight) { 1604 var delta = { top: 0, left: 0 } 1605 if (!this.$viewport) return delta viewportPadding = this.options.viewport && this.options.viewport.padding || 0 1608 var viewportDimensions = this.getPosition(this.$viewport) (/right|left/.test(placement)) { 1611 var topEdgeOffset = pos.top - viewportPadding - viewportDimensions.scroll 1612 var bottomEdgeOffset = pos.top + viewportPadding - viewportDimensions.scroll + actualHeight delta.top = viewportDimensions.top - topEdgeOffset delta.top = viewportDimensions.top + viewportDimensions.height - bottomEdgeOffset 1617 } 1618 } else { 1619 var leftEdgeOffset = pos.left - viewportPadding 1620 var rightEdgeOffset = pos.left + viewportPadding + actualWidth delta.left = viewportDimensions.left - leftEdgeOffset delta.left = viewportDimensions.left + viewportDimensions.width - rightEdgeOffset 1625 } 1626 } delta 1629 } 1630 1631 Tooltip.prototype.getTitle = function () { 1632 var title 1633 var $e = this.$element 1634 var o = this.options 1635 1636 title = $e.attr('data-original-title') 1637 || (typeof o.title == 'function' ? o.title.call($e[0]) : o.title) title 1640 } 1641 1642 Tooltip.prototype.getUID = function (prefix) { 1643 do prefix += ~~(Math.random() * 1000000) 1644 while (document.getElementById(prefix)) 1645 return prefix 1646 } 1647 1648 Tooltip.prototype.tip = function () { 1649 if (!this.$tip) { 1650 this.$tip = $(this.options.template) 1651 if (this.$tip.length != 1) { Error(this.type + ' `template` option must consist of exactly 1 top-level element!') 1653 } 1654 } .$tip 1656 } 1657 1658 Tooltip.prototype.arrow = function () { 1659 return (this.$arrow = this.$arrow || this.tip().find('.tooltip-arrow')) 1660 } 1661 1662 Tooltip.prototype.enable = function () { } 1665 1666 Tooltip.prototype.disable = function () { } 1669 1670 Tooltip.prototype.toggleEnabled = function () { 1671 this.enabled = !this.enabled 1672 } 1673 1674 Tooltip.prototype.toggle = function (e) { (e) { 1677 self = $(e.currentTarget).data('bs.' + this.type) 1678 if (!self) { 1679 self = new this.constructor(e.currentTarget, this.getDelegateOptions()) 1680 $(e.currentTarget).data('bs.' + this.type, self) 1681 } 1682 } (e) { 1685 self.inState.click = !self.inState.click 1686 if (self.isInStateTrue()) self.enter(self) 1687 else self.leave(self) 1688 } else { 1689 self.tip().hasClass('in') ? self.leave(self) : self.enter(self) 1690 } 1691 } 1692 1693 Tooltip.prototype.destroy = function () { clearTimeout(this.timeout) 1696 this.hide(function () { 1697 that.$element.off('.' + that.type).removeData('bs.' + that.type) 1698 if (that.$tip) { 1699 that.$tip.detach() 1700 } that.$viewport = null 1704 }) 1705 } Plugin(option) { .each(function () { 1713 var $this = $(this) 1714 var data = $this.data('bs.tooltip') 1715 var options = typeof option == 'object' && option (!data && /destroy|hide/.test(option)) (!data) $this.data('bs.tooltip', (data = new Tooltip(this, options))) 1719 if (typeof option == 'string') data[option]() 1720 }) 1721 } old = $.fn.tooltip 1724 1725 $.fn.tooltip = Plugin 1726 $.fn.tooltip.Constructor = Tooltip $.fn.tooltip.noConflict = function () { 1733 $.fn.tooltip = old } 1736 1737 }(jQuery); ======================================================================== 1740 * Bootstrap: popover.js v3.3.5 1741 * #popovers 1742 * ======================================================================== 1743 * Copyright 2011-2015 Twitter, Inc. 1744 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 1749 'use strict'; Popover = function (element, options) { 1755 this.init('popover', element, options) 1756 } (!$.fn.tooltip) throw new Error('Popover requires tooltip.js') 1759 1760 Popover.VERSION = '3.3.5' 1761 1762 Popover.DEFAULTS = $.extend({}, $.fn.tooltip.Constructor.DEFAULTS, { 1763 placement: 'right', 1764 trigger: 'click', 1765 content: '', 1766 template: '<div role="tooltip"><div></div><h3></h3><div></div></div>' 1767 }) Popover.prototype = $.extend({}, $.fn.tooltip.Constructor.prototype) 1774 1775 Popover.prototype.constructor = Popover 1776 1777 Popover.prototype.getDefaults = function () { 1778 return Popover.DEFAULTS 1779 } 1780 1781 Popover.prototype.setContent = function () { 1782 var $tip = this.tip() 1783 var title = this.getTitle() 1784 var content = this.getContent() 1785 1786 $tip.find('.popover-title')[this.options.html ? 'html' : 'text'](title) .options.html ? (typeof content == 'string' ? 'html' : 'append') : 'text' 1789 ](content) 1790 1791 $tip.removeClass('fade top bottom left right in') (!$tip.find('.popover-title').html()) $tip.find('.popover-title').hide() 1796 } 1797 1798 Popover.prototype.hasContent = function () { .getTitle() || this.getContent() 1800 } 1801 1802 Popover.prototype.getContent = function () { 1803 var $e = this.$element 1804 var o = this.options $e.attr('data-content') 1807 || (typeof o.content == 'function' ? 1808 o.content.call($e[0]) : 1809 o.content) 1810 } 1811 1812 Popover.prototype.arrow = function () { 1813 return (this.$arrow = this.$arrow || this.tip().find('.arrow')) 1814 } Plugin(option) { .each(function () { 1822 var $this = $(this) 1823 var data = $this.data('bs.popover') 1824 var options = typeof option == 'object' && option (!data && /destroy|hide/.test(option)) (!data) $this.data('bs.popover', (data = new Popover(this, options))) 1828 if (typeof option == 'string') data[option]() 1829 }) 1830 } old = $.fn.popover 1833 1834 $.fn.popover = Plugin 1835 $.fn.popover.Constructor = Popover $.fn.popover.noConflict = function () { 1842 $.fn.popover = old } 1845 1846 }(jQuery); ======================================================================== 1849 * Bootstrap: scrollspy.js v3.3.5 1850 * #scrollspy 1851 * ======================================================================== 1852 * Copyright 2011-2015 Twitter, Inc. 1853 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 1858 'use strict'; ScrollSpy(element, options) { 1864 this.$body = $(document.body) 1865 this.$scrollElement = $(element).is(document.body) ? $(window) : $(element) 1866 this.options = $.extend({}, ScrollSpy.DEFAULTS, options) 1867 this.selector = (this.options.target || '') + ' .nav li > a' 1868 this.offsets = [] 1869 this.targets = [] .scrollHeight = 0 .$scrollElement.on('scroll.bs.scrollspy', $.proxy(this.process, this)) 1874 this.refresh() 1875 this.process() 1876 } 1877 1878 ScrollSpy.VERSION = '3.3.5' 1879 1880 ScrollSpy.DEFAULTS = { 1881 offset: 10 1882 } 1883 1884 ScrollSpy.prototype.getScrollHeight = function () { .$scrollElement[0].scrollHeight || Math.max(this.$body[0].scrollHeight, document.documentElement.scrollHeight) 1886 } 1887 1888 ScrollSpy.prototype.refresh = function () { offsetMethod = 'offset' 1891 var offsetBase = 0 .offsets = [] 1894 this.targets = [] 1895 this.scrollHeight = this.getScrollHeight() (!$.isWindow(this.$scrollElement[0])) { 1898 offsetMethod = 'position' 1899 offsetBase = this.$scrollElement.scrollTop() 1900 } .$body 1903 .find(this.selector) 1904 .map(function () { 1905 var $el = $(this) 1906 var href = $el.data('target') || $el.attr('href') 1907 var $href = /^#./.test(href) && $(href) ($href 1910 && $href.length 1911 && $href.is(':visible') 1912 && [[$href[offsetMethod]().top + offsetBase, href]]) || null 1913 }) 1914 .sort(function (a, b) { return a[0] - b[0] }) 1915 .each(function () { 1916 that.offsets.push(this[0]) 1917 that.targets.push(this[1]) 1918 }) 1919 } 1920 1921 ScrollSpy.prototype.process = function () { 1922 var scrollTop = this.$scrollElement.scrollTop() + this.options.offset 1923 var scrollHeight = this.getScrollHeight() 1924 var maxScroll = this.options.offset + scrollHeight - this.$scrollElement.height() 1925 var offsets = this.offsets 1926 var targets = this.targets 1927 var activeTarget = this.activeTarget 1928 var i (this.scrollHeight != scrollHeight) { 1931 this.refresh() 1932 } (scrollTop >= maxScroll) { 1935 return activeTarget != (i = targets[targets.length - 1]) && this.activate(i) 1936 } (activeTarget && scrollTop < offsets[0]) { .clear() 1941 } (i = offsets.length; i--;) { 1944 activeTarget != targets[i] 1945 && scrollTop >= offsets[i] 1946 && (offsets[i + 1] === undefined || scrollTop < offsets[i + 1]) 1947 && this.activate(targets[i]) 1948 } 1949 } 1950 1951 ScrollSpy.prototype.activate = function (target) { 1952 this.activeTarget = target .clear() selector = this.selector + 1957 '[data-target="' + target + '"],' + 1958 this.selector + '[href="' + target + '"]' active = $(selector) 1961 .parents('li') 1962 .addClass('active') (active.parent('.dropdown-menu').length) { 1965 active = active 1966 .closest('li.dropdown') 1967 .addClass('active') 1968 } 1969 1970 active.trigger('activate.bs.scrollspy') 1971 } 1972 1973 ScrollSpy.prototype.clear = function () { 1974 $(this.selector) 1975 .parentsUntil(this.options.target, '.active') 1976 .removeClass('active') 1977 } Plugin(option) { .each(function () { 1985 var $this = $(this) 1986 var data = $this.data('bs.scrollspy') 1987 var options = typeof option == 'object' && option (!data) $this.data('bs.scrollspy', (data = new ScrollSpy(this, options))) 1990 if (typeof option == 'string') data[option]() 1991 }) 1992 } old = $.fn.scrollspy 1995 1996 $.fn.scrollspy = Plugin 1997 $.fn.scrollspy.Constructor = ScrollSpy $.fn.scrollspy.noConflict = function () { 2004 $.fn.scrollspy = old } $(window).on('load.bs.scrollspy.data-api', function () { 2013 $('[data-spy="scroll"]').each(function () { 2014 var $spy = $(this) 2015 Plugin.call($spy, $spy.data()) 2016 }) 2017 }) 2018 2019 }(jQuery); ======================================================================== 2022 * Bootstrap: tab.js v3.3.5 2023 * #tabs 2024 * ======================================================================== 2025 * Copyright 2011-2015 Twitter, Inc. 2026 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 2031 'use strict'; Tab = function (element) { .element = $(element) } 2041 2042 Tab.VERSION = '3.3.5' 2043 2044 Tab.TRANSITION_DURATION = 150 2045 2046 Tab.prototype.show = function () { 2047 var $this = this.element 2048 var $ul = $this.closest('ul:not(.dropdown-menu)') 2049 var selector = $this.data('target') (!selector) { 2052 selector = $this.attr('href') } ($$previous = $ul.find('.active:last a') 2059 var hideEvent = $.Event('hide.bs.tab', { 2060 relatedTarget: $this[0] 2061 }) 2062 var showEvent = $.Event('show.bs.tab', { 2063 relatedTarget: $previous[0] 2064 }) 2065 2066 $previous.trigger(hideEvent) 2067 $this.trigger(showEvent) (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) $target = $(selector) .activate($this.closest('li'), $ul) 2074 this.activate($target, $target.parent(), function () { 2075 $previous.trigger({ 2076 type: 'hidden.bs.tab', 2077 relatedTarget: $this[0] 2078 }) 2079 $this.trigger({ 2080 type: 'shown.bs.tab', 2081 relatedTarget: $previous[0] 2082 }) 2083 }) 2084 } 2085 2086 Tab.prototype.activate = function (element, container, callback) { 2087 var $active = container.find('> .active') 2088 var transition = callback 2089 && $.support.transition 2090 && ($active.length && $active.hasClass('fade') || !!container.find('> .fade').length) next() { 2093 $active 2094 .removeClass('active') 2095 .find('> .dropdown-menu > .active') 2096 .removeClass('active') 2097 .end() 2098 .find('[data-toggle="tab"]') 2099 .attr('aria-expanded', false) 2100 2101 element 2102 .addClass('active') 2103 .find('[data-toggle="tab"]') 2104 .attr('aria-expanded', true) (transition) { element.addClass('in') 2109 } else { 2110 element.removeClass('fade') 2111 } (element.parent('.dropdown-menu').length) { 2114 element 2115 .closest('li.dropdown') 2116 .addClass('active') 2117 .end() 2118 .find('[data-toggle="tab"]') 2119 .attr('aria-expanded', true) 2120 } 2121 2122 callback && callback() 2123 } 2124 2125 $active.length && transition ? 2126 $active 2127 .one('bsTransitionEnd', next) 2128 .emulateTransitionEnd(Tab.TRANSITION_DURATION) : 2129 next() 2130 2131 $active.removeClass('in') 2132 } Plugin(option) { .each(function () { 2140 var $this = $(this) 2141 var data = $this.data('bs.tab') (!data) $this.data('bs.tab', (data = new Tab(this))) 2144 if (typeof option == 'string') data[option]() 2145 }) 2146 } old = $.fn.tab 2149 2150 $.fn.tab = Plugin 2151 $.fn.tab.Constructor = Tab $.fn.tab.noConflict = function () { 2158 $.fn.tab = old } clickHandler = function (e) { 2167 e.preventDefault() 2168 Plugin.call($(this), 'show') 2169 } 2170 2171 $(document) 2172 .on('click.bs.tab.data-api', '[data-toggle="tab"]', clickHandler) 2173 .on('click.bs.tab.data-api', '[data-toggle="pill"]', clickHandler) 2174 2175 }(jQuery); ======================================================================== 2178 * Bootstrap: affix.js v3.3.5 2179 * #affix 2180 * ======================================================================== 2181 * Copyright 2011-2015 Twitter, Inc. 2182 * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) +function ($) { 2187 'use strict'; Affix = function (element, options) { 2193 this.options = $.extend({}, Affix.DEFAULTS, options) .$target = $(this.options.target) 2196 .on('scroll.bs.affix.data-api', $.proxy(this.checkPosition, this)) 2197 .on('click.bs.affix.data-api', $.proxy(this.checkPositionWithEventLoop, this)) .$element = $(element) .unpin = .pinnedOffset = .checkPosition() 2205 } 2206 2207 Affix.VERSION = '3.3.5' 2208 2209 Affix.RESET = 'affix affix-top affix-bottom' 2210 2211 Affix.DEFAULTS = { 2212 offset: 0, 2213 target: window 2214 } 2215 2216 Affix.prototype.getState = function (scrollHeight, height, offsetTop, offsetBottom) { 2217 var scrollTop = this.$target.scrollTop() 2218 var position = this.$element.offset() 2219 var targetHeight = this.$target.height() (offsetTop != (this.affixed == 'bottom') { 2224 if (offsetTop != null) return (scrollTop + this.unpin <= position.top) ? false : 'bottom' 2225 return (scrollTop + targetHeight <= scrollHeight - offsetBottom) ? false : 'bottom' 2226 } initializing = colliderTop = initializing ? scrollTop : position.top 2230 var colliderHeight = initializing ? targetHeight : height (offsetTop != null && scrollTop <= offsetTop) return 'top' 2233 if (offsetBottom != null && (colliderTop + colliderHeight >= scrollHeight - offsetBottom)) return 'bottom' } 2237 2238 Affix.prototype.getPinnedOffset = function () { .pinnedOffset 2240 this.$element.removeClass(Affix.RESET).addClass('affix') 2241 var scrollTop = this.$target.scrollTop() 2242 var position = this.$element.offset() 2243 return (this.pinnedOffset = position.top - scrollTop) 2244 } 2245 2246 Affix.prototype.checkPositionWithEventLoop = function () { 2247 setTimeout($.proxy(this.checkPosition, this), 1) 2248 } 2249 2250 Affix.prototype.checkPosition = function () { height = this.$element.height() 2254 var offset = this.options.offset 2255 var offsetTop = offset.top 2256 var offsetBottom = offset.bottom 2257 var scrollHeight = Math.max($(document).height(), $(document.body).height()) (typeof offset != 'object') offsetBottom = offsetTop = offset 2260 if (typeof offsetTop == 'function') offsetTop = offset.top(this.$element) 2261 if (typeof offsetBottom == 'function') offsetBottom = offset.bottom(this.$element) affix = this.getState(scrollHeight, height, offsetTop, offsetBottom) (this.affixed != affix) { 2266 if (this.unpin != null) this.$element.css('top', '') affixType = 'affix' + (affix ? '-' + affix : '') 2269 var e = $.Event(affixType + '.bs.affix') .$element.trigger(e) (e.isDefaultPrevented()) .affixed = affix .$element 2279 .removeClass(Affix.RESET) 2280 .addClass(affixType) 2281 .trigger(affixType.replace('affix', 'affixed') + '.bs.affix') 2282 } (affix == 'bottom') { 2285 this.$element.offset({ 2286 top: scrollHeight - height - offsetBottom 2287 }) 2288 } 2289 } Plugin(option) { .each(function () { 2297 var $this = $(this) 2298 var data = $this.data('bs.affix') 2299 var options = typeof option == 'object' && option (!data) $this.data('bs.affix', (data = new Affix(this, options))) 2302 if (typeof option == 'string') data[option]() 2303 }) 2304 } old = $.fn.affix 2307 2308 $.fn.affix = Plugin 2309 $.fn.affix.Constructor = Affix $.fn.affix.noConflict = function () { 2316 $.fn.affix = old } $(window).on('load', function () { 2325 $('[data-spy="affix"]').each(function () { 2326 var $spy = $(this) 2327 var data = $spy.data() 2328 2329 data.offset = data.offset || {} (data.offsetBottom != null) data.offset.bottom = data.offsetBottom 2332 if (data.offsetTop != null) data.offset.top = data.offsetTop 2333 2334 Plugin.call($spy, data) 2335 }) 2336 }) 2337 2338 }(jQuery);
bootstrap