From f140084f2beb17b0a266b42ab9a03d0b935e5f66 Mon Sep 17 00:00:00 2001 From: Josh Dague Date: Thu, 22 Aug 2013 14:50:15 -0400 Subject: Don't explicitly reference global jQuery Removes `window.jQuery` in favor of `jQuery`, fixes #10038 --- js/affix.js | 2 +- js/alert.js | 2 +- js/button.js | 2 +- js/carousel.js | 2 +- js/collapse.js | 2 +- js/dropdown.js | 2 +- js/modal.js | 2 +- js/popover.js | 2 +- js/scrollspy.js | 2 +- js/tab.js | 2 +- js/tooltip.js | 2 +- js/transition.js | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) (limited to 'js') diff --git a/js/affix.js b/js/affix.js index c7be96e1d..7ab1479c3 100644 --- a/js/affix.js +++ b/js/affix.js @@ -123,4 +123,4 @@ }) }) -}(window.jQuery); +}(jQuery); diff --git a/js/alert.js b/js/alert.js index 663029ed8..df04b7e5e 100644 --- a/js/alert.js +++ b/js/alert.js @@ -95,4 +95,4 @@ $(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close) -}(window.jQuery); +}(jQuery); diff --git a/js/button.js b/js/button.js index fc73b555f..68c211b57 100644 --- a/js/button.js +++ b/js/button.js @@ -106,4 +106,4 @@ e.preventDefault() }) -}(window.jQuery); +}(jQuery); diff --git a/js/carousel.js b/js/carousel.js index d8c4c243c..b633cfb9f 100644 --- a/js/carousel.js +++ b/js/carousel.js @@ -214,4 +214,4 @@ }) }) -}(window.jQuery); +}(jQuery); diff --git a/js/collapse.js b/js/collapse.js index 92cc0bc76..2e0d4290c 100644 --- a/js/collapse.js +++ b/js/collapse.js @@ -176,4 +176,4 @@ $target.collapse(option) }) -}(window.jQuery); +}(jQuery); diff --git a/js/dropdown.js b/js/dropdown.js index 6093f11a8..9293b830b 100644 --- a/js/dropdown.js +++ b/js/dropdown.js @@ -151,4 +151,4 @@ .on('click.bs.dropdown.data-api' , toggle, Dropdown.prototype.toggle) .on('keydown.bs.dropdown.data-api', toggle + ', [role=menu]' , Dropdown.prototype.keydown) -}(window.jQuery); +}(jQuery); diff --git a/js/modal.js b/js/modal.js index 65eba481e..0107f22d0 100644 --- a/js/modal.js +++ b/js/modal.js @@ -243,4 +243,4 @@ .on('show.bs.modal', '.modal', function () { $(document.body).addClass('modal-open') }) .on('hidden.bs.modal', '.modal', function () { $(document.body).removeClass('modal-open') }) -}(window.jQuery); +}(jQuery); diff --git a/js/popover.js b/js/popover.js index ecd37ac23..12ad7f993 100644 --- a/js/popover.js +++ b/js/popover.js @@ -114,4 +114,4 @@ return this } -}(window.jQuery); +}(jQuery); diff --git a/js/scrollspy.js b/js/scrollspy.js index 10f95f249..1094481cc 100644 --- a/js/scrollspy.js +++ b/js/scrollspy.js @@ -155,4 +155,4 @@ }) }) -}(window.jQuery); +}(jQuery); diff --git a/js/tab.js b/js/tab.js index e1c155920..9b2de8b44 100644 --- a/js/tab.js +++ b/js/tab.js @@ -132,4 +132,4 @@ $(this).tab('show') }) -}(window.jQuery); +}(jQuery); diff --git a/js/tooltip.js b/js/tooltip.js index 89802287a..67806c56e 100644 --- a/js/tooltip.js +++ b/js/tooltip.js @@ -383,4 +383,4 @@ return this } -}(window.jQuery); +}(jQuery); diff --git a/js/transition.js b/js/transition.js index e8f318beb..36ca6f894 100644 --- a/js/transition.js +++ b/js/transition.js @@ -53,4 +53,4 @@ $.support.transition = transitionEnd() }) -}(window.jQuery); +}(jQuery); -- cgit v1.2.3 From 7ee2b6a976a5041a06514805216673ff6331dc54 Mon Sep 17 00:00:00 2001 From: Alexey Date: Sun, 8 Sep 2013 04:49:27 +0300 Subject: changed attr('data-target') to data('target'); this will extend js interface, to be possible to setup targets for tabs as var content=$('
',{text: 'content'}); var tab=('
  • ',{html: $('',{text: 'Main options'})}).addClass('active').data({target: $main,toggle: 'tab'}).appendTo(tabs); --- js/tab.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'js') diff --git a/js/tab.js b/js/tab.js index e1c155920..10dc7e99b 100644 --- a/js/tab.js +++ b/js/tab.js @@ -30,7 +30,7 @@ Tab.prototype.show = function () { var $this = this.element var $ul = $this.closest('ul:not(.dropdown-menu)') - var selector = $this.attr('data-target') + var selector = $this.data('target') if (!selector) { selector = $this.attr('href') -- cgit v1.2.3 From 62c905f5bc8c2132d434b9bedd5b75c2ea3d85a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zlatan=20Vasovi=C4=87?= Date: Wed, 9 Oct 2013 09:45:05 +0200 Subject: Remove [type] type="text/css" isn't needed --- js/tests/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'js') diff --git a/js/tests/index.html b/js/tests/index.html index 501bf38f2..4e3d487db 100644 --- a/js/tests/index.html +++ b/js/tests/index.html @@ -8,7 +8,7 @@ - + -- cgit v1.2.3 From 63433fbef9e47f04658085e01d637559f4f14392 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zlatan=20Vasovi=C4=87?= Date: Tue, 22 Oct 2013 18:41:33 +0200 Subject: Update license year --- js/affix.js | 2 +- js/carousel.js | 2 +- js/collapse.js | 2 +- js/dropdown.js | 2 +- js/modal.js | 2 +- js/popover.js | 2 +- js/scrollspy.js | 2 +- js/tab.js | 2 +- js/tooltip.js | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) (limited to 'js') diff --git a/js/affix.js b/js/affix.js index c7be96e1d..1ea51d2b5 100644 --- a/js/affix.js +++ b/js/affix.js @@ -2,7 +2,7 @@ * Bootstrap: affix.js v3.0.0 * http://twbs.github.com/bootstrap/javascript.html#affix * ======================================================================== - * Copyright 2012 Twitter, Inc. + * Copyright 2013 Twitter, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/js/carousel.js b/js/carousel.js index d8c4c243c..c0cf13e90 100644 --- a/js/carousel.js +++ b/js/carousel.js @@ -2,7 +2,7 @@ * Bootstrap: carousel.js v3.0.0 * http://twbs.github.com/bootstrap/javascript.html#carousel * ======================================================================== - * Copyright 2012 Twitter, Inc. + * Copyright 2013 Twitter, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/js/collapse.js b/js/collapse.js index 92cc0bc76..414bef442 100644 --- a/js/collapse.js +++ b/js/collapse.js @@ -2,7 +2,7 @@ * Bootstrap: collapse.js v3.0.0 * http://twbs.github.com/bootstrap/javascript.html#collapse * ======================================================================== - * Copyright 2012 Twitter, Inc. + * Copyright 2013 Twitter, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/js/dropdown.js b/js/dropdown.js index 6093f11a8..98c816e4f 100644 --- a/js/dropdown.js +++ b/js/dropdown.js @@ -2,7 +2,7 @@ * Bootstrap: dropdown.js v3.0.0 * http://twbs.github.com/bootstrap/javascript.html#dropdowns * ======================================================================== - * Copyright 2012 Twitter, Inc. + * Copyright 2013 Twitter, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/js/modal.js b/js/modal.js index 65eba481e..fb04eece3 100644 --- a/js/modal.js +++ b/js/modal.js @@ -2,7 +2,7 @@ * Bootstrap: modal.js v3.0.0 * http://twbs.github.com/bootstrap/javascript.html#modals * ======================================================================== - * Copyright 2012 Twitter, Inc. + * Copyright 2013 Twitter, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/js/popover.js b/js/popover.js index ecd37ac23..81ef5538e 100644 --- a/js/popover.js +++ b/js/popover.js @@ -2,7 +2,7 @@ * Bootstrap: popover.js v3.0.0 * http://twbs.github.com/bootstrap/javascript.html#popovers * ======================================================================== - * Copyright 2012 Twitter, Inc. + * Copyright 2013 Twitter, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/js/scrollspy.js b/js/scrollspy.js index 10f95f249..e4010b61d 100644 --- a/js/scrollspy.js +++ b/js/scrollspy.js @@ -2,7 +2,7 @@ * Bootstrap: scrollspy.js v3.0.0 * http://twbs.github.com/bootstrap/javascript.html#scrollspy * ======================================================================== - * Copyright 2012 Twitter, Inc. + * Copyright 2013 Twitter, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/js/tab.js b/js/tab.js index 10dc7e99b..bdf8bbe94 100644 --- a/js/tab.js +++ b/js/tab.js @@ -2,7 +2,7 @@ * Bootstrap: tab.js v3.0.0 * http://twbs.github.com/bootstrap/javascript.html#tabs * ======================================================================== - * Copyright 2012 Twitter, Inc. + * Copyright 2013 Twitter, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/js/tooltip.js b/js/tooltip.js index 89802287a..4edd80fa5 100644 --- a/js/tooltip.js +++ b/js/tooltip.js @@ -3,7 +3,7 @@ * http://twbs.github.com/bootstrap/javascript.html#tooltip * Inspired by the original jQuery.tipsy by Jason Frame * ======================================================================== - * Copyright 2012 Twitter, Inc. + * Copyright 2013 Twitter, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. -- cgit v1.2.3 From 7b24f3c47c195b5519ddc2904840db98858ec015 Mon Sep 17 00:00:00 2001 From: Chris Rebert Date: Fri, 25 Oct 2013 14:14:30 -0700 Subject: QUnit.equals() is deprecated; use QUnit.equal() instead --- js/tests/unit/button.js | 10 +++++----- js/tests/unit/popover.js | 12 ++++++------ js/tests/unit/tab.js | 12 ++++++------ js/tests/unit/tooltip.js | 2 +- 4 files changed, 18 insertions(+), 18 deletions(-) (limited to 'js') diff --git a/js/tests/unit/button.js b/js/tests/unit/button.js index 41ddb5c2f..16284e0ce 100644 --- a/js/tests/unit/button.js +++ b/js/tests/unit/button.js @@ -18,9 +18,9 @@ $(function () { test("should return set state to loading", function () { var btn = $('') - equals(btn.html(), 'mdo', 'btn text equals mdo') + equal(btn.html(), 'mdo', 'btn text equals mdo') btn.button('loading') - equals(btn.html(), 'fat', 'btn text equals fat') + equal(btn.html(), 'fat', 'btn text equals fat') stop() setTimeout(function () { ok(btn.attr('disabled'), 'btn is disabled') @@ -31,9 +31,9 @@ $(function () { test("should return reset state", function () { var btn = $('') - equals(btn.html(), 'mdo', 'btn text equals mdo') + equal(btn.html(), 'mdo', 'btn text equals mdo') btn.button('loading') - equals(btn.html(), 'fat', 'btn text equals fat') + equal(btn.html(), 'fat', 'btn text equals fat') stop() setTimeout(function () { ok(btn.attr('disabled'), 'btn is disabled') @@ -41,7 +41,7 @@ $(function () { start() stop() btn.button('reset') - equals(btn.html(), 'mdo', 'btn text equals mdo') + equal(btn.html(), 'mdo', 'btn text equals mdo') setTimeout(function () { ok(!btn.attr('disabled'), 'btn is not disabled') ok(!btn.hasClass('disabled'), 'btn does not have disabled class') diff --git a/js/tests/unit/popover.js b/js/tests/unit/popover.js index 767d79864..c9f7d63a7 100644 --- a/js/tests/unit/popover.js +++ b/js/tests/unit/popover.js @@ -53,8 +53,8 @@ $(function () { popover.popover('show') ok($('.popover').length, 'popover was inserted') - equals($('.popover .popover-title').text(), '@fat', 'title correctly inserted') - equals($('.popover .popover-content').text(), 'loves writing tests (╯°□°)╯︵ ┻━┻', 'content correctly inserted') + equal($('.popover .popover-title').text(), '@fat', 'title correctly inserted') + equal($('.popover .popover-content').text(), 'loves writing tests (╯°□°)╯︵ ┻━┻', 'content correctly inserted') popover.popover('hide') ok(!$('.popover').length, 'popover was removed') @@ -69,8 +69,8 @@ $(function () { .popover('show') ok($('.popover').length, 'popover was inserted') - equals($('.popover .popover-title').text(), '@mdo', 'title correctly inserted') - equals($('.popover .popover-content').text(), "loves data attributes (づ。◕‿‿◕。)づ ︵ ┻━┻", 'content correctly inserted') + equal($('.popover .popover-title').text(), '@mdo', 'title correctly inserted') + equal($('.popover .popover-content').text(), "loves data attributes (づ。◕‿‿◕。)づ ︵ ┻━┻", 'content correctly inserted') popover.popover('hide') ok(!$('.popover').length, 'popover was removed') @@ -89,8 +89,8 @@ $(function () { .popover('show') ok($('.popover').length, 'popover was inserted') - equals($('.popover .popover-title').text(), '@mdo', 'title correctly inserted') - equals($('.popover .popover-content').text(), "loves data attributes (づ。◕‿‿◕。)づ ︵ ┻━┻", 'content correctly inserted') + equal($('.popover .popover-title').text(), '@mdo', 'title correctly inserted') + equal($('.popover .popover-content').text(), "loves data attributes (づ。◕‿‿◕。)づ ︵ ┻━┻", 'content correctly inserted') popover.popover('hide') ok(!$('.popover').length, 'popover was removed') diff --git a/js/tests/unit/tab.js b/js/tests/unit/tab.js index aede32abb..0db7cdb5b 100644 --- a/js/tests/unit/tab.js +++ b/js/tests/unit/tab.js @@ -26,10 +26,10 @@ $(function () { $('
    ').appendTo("#qunit-fixture") $(tabsHTML).find('li:last a').tab('show') - equals($("#qunit-fixture").find('.active').attr('id'), "profile") + equal($("#qunit-fixture").find('.active').attr('id'), "profile") $(tabsHTML).find('li:first a').tab('show') - equals($("#qunit-fixture").find('.active').attr('id'), "home") + equal($("#qunit-fixture").find('.active').attr('id'), "home") }) test("should activate element by tab id", function () { @@ -42,10 +42,10 @@ $(function () { $('
    ').appendTo("#qunit-fixture") $(pillsHTML).find('li:last a').tab('show') - equals($("#qunit-fixture").find('.active').attr('id'), "profile") + equal($("#qunit-fixture").find('.active').attr('id'), "profile") $(pillsHTML).find('li:first a').tab('show') - equals($("#qunit-fixture").find('.active').attr('id'), "home") + equal($("#qunit-fixture").find('.active').attr('id'), "home") }) @@ -77,9 +77,9 @@ $(function () { $(dropHTML).find('ul>li:first a').tab('show').end() .find('ul>li:last a').on('show', function(event){ - equals(event.relatedTarget.hash, "#1-1") + equal(event.relatedTarget.hash, "#1-1") }).on('shown', function(event){ - equals(event.relatedTarget.hash, "#1-1") + equal(event.relatedTarget.hash, "#1-1") }).tab('show') }) diff --git a/js/tests/unit/tooltip.js b/js/tests/unit/tooltip.js index ed1bf54b3..dc3ddd377 100644 --- a/js/tests/unit/tooltip.js +++ b/js/tests/unit/tooltip.js @@ -29,7 +29,7 @@ $(function () { test("should add data attribute for referencing original title", function () { var tooltip = $('
    ').tooltip() - equals(tooltip.attr('data-original-title'), 'Another tooltip', 'original title preserved in data attribute') + equal(tooltip.attr('data-original-title'), 'Another tooltip', 'original title preserved in data attribute') }) test("should place tooltips relative to placement option", function () { -- cgit v1.2.3 From 583697fec330b7f3aa3ae7dd6074d461ba91029c Mon Sep 17 00:00:00 2001 From: Jared Christensen Date: Tue, 29 Oct 2013 12:10:47 -0500 Subject: JS comments pointed to new documentation --- js/affix.js | 2 +- js/alert.js | 2 +- js/button.js | 2 +- js/carousel.js | 2 +- js/collapse.js | 2 +- js/dropdown.js | 2 +- js/modal.js | 2 +- js/popover.js | 2 +- js/scrollspy.js | 2 +- js/tab.js | 2 +- js/tooltip.js | 2 +- js/transition.js | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) (limited to 'js') diff --git a/js/affix.js b/js/affix.js index 1ea51d2b5..a75a46db0 100644 --- a/js/affix.js +++ b/js/affix.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: affix.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#affix + * http://getbootstrap.com/javascript/#affix * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/alert.js b/js/alert.js index 663029ed8..73372e4f1 100644 --- a/js/alert.js +++ b/js/alert.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: alert.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#alerts + * http://getbootstrap.com/javascript/#alerts * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/button.js b/js/button.js index fc73b555f..44c101a2a 100644 --- a/js/button.js +++ b/js/button.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: button.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#buttons + * http://getbootstrap.com/javascript/#buttons * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/carousel.js b/js/carousel.js index c0cf13e90..cf7baf2a7 100644 --- a/js/carousel.js +++ b/js/carousel.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: carousel.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#carousel + * http://getbootstrap.com/javascript/#carousel * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/collapse.js b/js/collapse.js index 414bef442..beb047725 100644 --- a/js/collapse.js +++ b/js/collapse.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: collapse.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#collapse + * http://getbootstrap.com/javascript/#collapse * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/dropdown.js b/js/dropdown.js index 98c816e4f..e45d51c2d 100644 --- a/js/dropdown.js +++ b/js/dropdown.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: dropdown.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#dropdowns + * http://getbootstrap.com/javascript/#dropdowns * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/modal.js b/js/modal.js index fb04eece3..b5b56016c 100644 --- a/js/modal.js +++ b/js/modal.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: modal.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#modals + * http://getbootstrap.com/javascript/#modals * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/popover.js b/js/popover.js index 81ef5538e..d5cd02e59 100644 --- a/js/popover.js +++ b/js/popover.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: popover.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#popovers + * http://getbootstrap.com/javascript/#popovers * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/scrollspy.js b/js/scrollspy.js index e4010b61d..c88eaad99 100644 --- a/js/scrollspy.js +++ b/js/scrollspy.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: scrollspy.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#scrollspy + * http://getbootstrap.com/javascript/#scrollspy * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/tab.js b/js/tab.js index bdf8bbe94..7aff6130a 100644 --- a/js/tab.js +++ b/js/tab.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: tab.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#tabs + * http://getbootstrap.com/javascript/#tabs * ======================================================================== * Copyright 2013 Twitter, Inc. * diff --git a/js/tooltip.js b/js/tooltip.js index 4edd80fa5..41375c6c9 100644 --- a/js/tooltip.js +++ b/js/tooltip.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: tooltip.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#tooltip + * http://getbootstrap.com/javascript/#tooltip * Inspired by the original jQuery.tipsy by Jason Frame * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/transition.js b/js/transition.js index e8f318beb..d3a7abffb 100644 --- a/js/transition.js +++ b/js/transition.js @@ -1,6 +1,6 @@ /* ======================================================================== * Bootstrap: transition.js v3.0.0 - * http://twbs.github.com/bootstrap/javascript.html#transitions + * http://getbootstrap.com/javascript/#transitions * ======================================================================== * Copyright 2013 Twitter, Inc. * -- cgit v1.2.3 From 4e0d022de5b0d27b063156533dfcc248fc08257e Mon Sep 17 00:00:00 2001 From: Chris Rebert Date: Fri, 1 Nov 2013 17:15:34 -0700 Subject: update version numbers in JS file comment headers to v3.0.1 & regrunt --- js/affix.js | 2 +- js/alert.js | 2 +- js/button.js | 2 +- js/carousel.js | 2 +- js/collapse.js | 2 +- js/dropdown.js | 2 +- js/modal.js | 2 +- js/popover.js | 2 +- js/scrollspy.js | 2 +- js/tab.js | 2 +- js/tooltip.js | 2 +- js/transition.js | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) (limited to 'js') diff --git a/js/affix.js b/js/affix.js index a75a46db0..c79103731 100644 --- a/js/affix.js +++ b/js/affix.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: affix.js v3.0.0 + * Bootstrap: affix.js v3.0.1 * http://getbootstrap.com/javascript/#affix * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/alert.js b/js/alert.js index 73372e4f1..25bc67c29 100644 --- a/js/alert.js +++ b/js/alert.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: alert.js v3.0.0 + * Bootstrap: alert.js v3.0.1 * http://getbootstrap.com/javascript/#alerts * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/button.js b/js/button.js index 44c101a2a..8a518cb0e 100644 --- a/js/button.js +++ b/js/button.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: button.js v3.0.0 + * Bootstrap: button.js v3.0.1 * http://getbootstrap.com/javascript/#buttons * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/carousel.js b/js/carousel.js index cf7baf2a7..8c580b818 100644 --- a/js/carousel.js +++ b/js/carousel.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: carousel.js v3.0.0 + * Bootstrap: carousel.js v3.0.1 * http://getbootstrap.com/javascript/#carousel * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/collapse.js b/js/collapse.js index beb047725..c89de982f 100644 --- a/js/collapse.js +++ b/js/collapse.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: collapse.js v3.0.0 + * Bootstrap: collapse.js v3.0.1 * http://getbootstrap.com/javascript/#collapse * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/dropdown.js b/js/dropdown.js index e45d51c2d..5680791c3 100644 --- a/js/dropdown.js +++ b/js/dropdown.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: dropdown.js v3.0.0 + * Bootstrap: dropdown.js v3.0.1 * http://getbootstrap.com/javascript/#dropdowns * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/modal.js b/js/modal.js index b5b56016c..d5e11296f 100644 --- a/js/modal.js +++ b/js/modal.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: modal.js v3.0.0 + * Bootstrap: modal.js v3.0.1 * http://getbootstrap.com/javascript/#modals * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/popover.js b/js/popover.js index d5cd02e59..f2ba5be00 100644 --- a/js/popover.js +++ b/js/popover.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: popover.js v3.0.0 + * Bootstrap: popover.js v3.0.1 * http://getbootstrap.com/javascript/#popovers * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/scrollspy.js b/js/scrollspy.js index c88eaad99..19ed6fcd5 100644 --- a/js/scrollspy.js +++ b/js/scrollspy.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: scrollspy.js v3.0.0 + * Bootstrap: scrollspy.js v3.0.1 * http://getbootstrap.com/javascript/#scrollspy * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/tab.js b/js/tab.js index 7aff6130a..87dae6452 100644 --- a/js/tab.js +++ b/js/tab.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: tab.js v3.0.0 + * Bootstrap: tab.js v3.0.1 * http://getbootstrap.com/javascript/#tabs * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/tooltip.js b/js/tooltip.js index 41375c6c9..68078d05f 100644 --- a/js/tooltip.js +++ b/js/tooltip.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: tooltip.js v3.0.0 + * Bootstrap: tooltip.js v3.0.1 * http://getbootstrap.com/javascript/#tooltip * Inspired by the original jQuery.tipsy by Jason Frame * ======================================================================== diff --git a/js/transition.js b/js/transition.js index d3a7abffb..bf6c7329c 100644 --- a/js/transition.js +++ b/js/transition.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: transition.js v3.0.0 + * Bootstrap: transition.js v3.0.1 * http://getbootstrap.com/javascript/#transitions * ======================================================================== * Copyright 2013 Twitter, Inc. -- cgit v1.2.3 From 6a4230556532d3d947a84aa0d07f57e40a68a9ff Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Wed, 6 Nov 2013 12:57:28 -0800 Subject: bump versions to v3.0.2 --- js/affix.js | 2 +- js/alert.js | 2 +- js/button.js | 2 +- js/carousel.js | 2 +- js/collapse.js | 2 +- js/dropdown.js | 2 +- js/modal.js | 2 +- js/popover.js | 2 +- js/scrollspy.js | 2 +- js/tab.js | 2 +- js/tooltip.js | 2 +- js/transition.js | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) (limited to 'js') diff --git a/js/affix.js b/js/affix.js index 291e31959..7d111ecc4 100644 --- a/js/affix.js +++ b/js/affix.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: affix.js v3.0.1 + * Bootstrap: affix.js v3.0.2 * http://getbootstrap.com/javascript/#affix * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/alert.js b/js/alert.js index 72dda55a7..031d72aa5 100644 --- a/js/alert.js +++ b/js/alert.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: alert.js v3.0.1 + * Bootstrap: alert.js v3.0.2 * http://getbootstrap.com/javascript/#alerts * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/button.js b/js/button.js index b4f8f3077..0145689dd 100644 --- a/js/button.js +++ b/js/button.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: button.js v3.0.1 + * Bootstrap: button.js v3.0.2 * http://getbootstrap.com/javascript/#buttons * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/carousel.js b/js/carousel.js index d56c21891..902d4d781 100644 --- a/js/carousel.js +++ b/js/carousel.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: carousel.js v3.0.1 + * Bootstrap: carousel.js v3.0.2 * http://getbootstrap.com/javascript/#carousel * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/collapse.js b/js/collapse.js index 83eb41d19..9967b167f 100644 --- a/js/collapse.js +++ b/js/collapse.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: collapse.js v3.0.1 + * Bootstrap: collapse.js v3.0.2 * http://getbootstrap.com/javascript/#collapse * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/dropdown.js b/js/dropdown.js index 192903340..d5da638de 100644 --- a/js/dropdown.js +++ b/js/dropdown.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: dropdown.js v3.0.1 + * Bootstrap: dropdown.js v3.0.2 * http://getbootstrap.com/javascript/#dropdowns * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/modal.js b/js/modal.js index 5feca4b1b..dac50c6c6 100644 --- a/js/modal.js +++ b/js/modal.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: modal.js v3.0.1 + * Bootstrap: modal.js v3.0.2 * http://getbootstrap.com/javascript/#modals * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/popover.js b/js/popover.js index 74c9ba1f6..35b488550 100644 --- a/js/popover.js +++ b/js/popover.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: popover.js v3.0.1 + * Bootstrap: popover.js v3.0.2 * http://getbootstrap.com/javascript/#popovers * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/scrollspy.js b/js/scrollspy.js index d9e008bdf..1d2fc7859 100644 --- a/js/scrollspy.js +++ b/js/scrollspy.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: scrollspy.js v3.0.1 + * Bootstrap: scrollspy.js v3.0.2 * http://getbootstrap.com/javascript/#scrollspy * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/tab.js b/js/tab.js index 7f1962b9b..c803b89bb 100644 --- a/js/tab.js +++ b/js/tab.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: tab.js v3.0.1 + * Bootstrap: tab.js v3.0.2 * http://getbootstrap.com/javascript/#tabs * ======================================================================== * Copyright 2013 Twitter, Inc. diff --git a/js/tooltip.js b/js/tooltip.js index 60c01825d..9e6177554 100644 --- a/js/tooltip.js +++ b/js/tooltip.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: tooltip.js v3.0.1 + * Bootstrap: tooltip.js v3.0.2 * http://getbootstrap.com/javascript/#tooltip * Inspired by the original jQuery.tipsy by Jason Frame * ======================================================================== diff --git a/js/transition.js b/js/transition.js index d3d36bd75..a692dfda9 100644 --- a/js/transition.js +++ b/js/transition.js @@ -1,5 +1,5 @@ /* ======================================================================== - * Bootstrap: transition.js v3.0.1 + * Bootstrap: transition.js v3.0.2 * http://getbootstrap.com/javascript/#transitions * ======================================================================== * Copyright 2013 Twitter, Inc. -- cgit v1.2.3 From 934d1bcae588a278900018abb648242eb05328b3 Mon Sep 17 00:00:00 2001 From: Nathan Muir Date: Tue, 3 Sep 2013 12:23:51 +1000 Subject: Add unit test for #9920 Merges #10385 --- js/tests/unit/button.js | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'js') diff --git a/js/tests/unit/button.js b/js/tests/unit/button.js index 16284e0ce..115edefaf 100644 --- a/js/tests/unit/button.js +++ b/js/tests/unit/button.js @@ -111,6 +111,12 @@ $(function () { ok(!btn1.find('input').prop('checked'), 'btn1 is checked') ok(btn2.hasClass('active'), 'btn2 has active class') ok(btn2.find('input').prop('checked'), 'btn2 is checked') + + btn2.find('input').click() /* clicking an already checked radio should not un-check it */ + ok(!btn1.hasClass('active'), 'btn1 does not have active class') + ok(!btn1.find('input').prop('checked'), 'btn1 is checked') + ok(btn2.hasClass('active'), 'btn2 has active class') + ok(btn2.find('input').prop('checked'), 'btn2 is checked') }) }) -- cgit v1.2.3 From 5d6e9212a642430719702ead322103e19c6aa782 Mon Sep 17 00:00:00 2001 From: Brian Leonard Date: Sun, 1 Sep 2013 22:23:31 -0700 Subject: Don't deselect radio buttons in data-toggle; fixes #9920 Merges #10787 --- js/button.js | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'js') diff --git a/js/button.js b/js/button.js index 0145689dd..3c1613506 100644 --- a/js/button.js +++ b/js/button.js @@ -54,15 +54,21 @@ Button.prototype.toggle = function () { var $parent = this.$element.closest('[data-toggle="buttons"]') + var changed = true if ($parent.length) { var $input = this.$element.find('input') - .prop('checked', !this.$element.hasClass('active')) - .trigger('change') - if ($input.prop('type') === 'radio') $parent.find('.active').removeClass('active') + if ($input.prop('type') === 'radio') { + // see if clicking on current one + if ($input.prop('checked') && this.$element.hasClass('active')) + changed = false + else + $parent.find('.active').removeClass('active') + } + if (changed) $input.prop('checked', !this.$element.hasClass('active')).trigger('change') } - this.$element.toggleClass('active') + if (changed) this.$element.toggleClass('active') } -- cgit v1.2.3 From 7545da2e3c5488b1bcc9c70fecac759232466756 Mon Sep 17 00:00:00 2001 From: fat Date: Thu, 14 Nov 2013 23:58:29 -0800 Subject: fixes #11477 and updates slid event in carousel with namespace --- js/carousel.js | 8 ++++---- js/scrollspy.js | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'js') diff --git a/js/carousel.js b/js/carousel.js index 902d4d781..a31bb071f 100644 --- a/js/carousel.js +++ b/js/carousel.js @@ -69,7 +69,7 @@ if (pos > (this.$items.length - 1) || pos < 0) return - if (this.sliding) return this.$element.one('slid', function () { that.to(pos) }) + if (this.sliding) return this.$element.one('slid.bs.carousel', function () { that.to(pos) }) if (activeIndex == pos) return this.pause().cycle() return this.slide(pos > activeIndex ? 'next' : 'prev', $(this.$items[pos])) @@ -121,7 +121,7 @@ if (this.$indicators.length) { this.$indicators.find('.active').removeClass('active') - this.$element.one('slid', function () { + this.$element.one('slid.bs.carousel', function () { var $nextIndicator = $(that.$indicators.children()[that.getActiveIndex()]) $nextIndicator && $nextIndicator.addClass('active') }) @@ -139,7 +139,7 @@ $next.removeClass([type, direction].join(' ')).addClass('active') $active.removeClass(['active', direction].join(' ')) that.sliding = false - setTimeout(function () { that.$element.trigger('slid') }, 0) + setTimeout(function () { that.$element.trigger('slid.bs.carousel') }, 0) }) .emulateTransitionEnd(600) } else { @@ -148,7 +148,7 @@ $active.removeClass('active') $next.addClass('active') this.sliding = false - this.$element.trigger('slid') + this.$element.trigger('slid.bs.carousel') } isCycling && this.cycle() diff --git a/js/scrollspy.js b/js/scrollspy.js index 1d2fc7859..b11ecdf29 100644 --- a/js/scrollspy.js +++ b/js/scrollspy.js @@ -113,7 +113,7 @@ .addClass('active') } - active.trigger('activate') + active.trigger('activate.bs.scrollspy') } -- cgit v1.2.3 From 56f6847ed60b5a8a15861a5db31676fe9901ff41 Mon Sep 17 00:00:00 2001 From: "Cina S." Date: Sat, 16 Nov 2013 09:43:47 -0600 Subject: Add missing data namespace for dropdown --- js/dropdown.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'js') diff --git a/js/dropdown.js b/js/dropdown.js index d5da638de..2bf65e5df 100644 --- a/js/dropdown.js +++ b/js/dropdown.js @@ -123,9 +123,9 @@ $.fn.dropdown = function (option) { return this.each(function () { var $this = $(this) - var data = $this.data('dropdown') + var data = $this.data('bs.dropdown') - if (!data) $this.data('dropdown', (data = new Dropdown(this))) + if (!data) $this.data('bs.dropdown', (data = new Dropdown(this))) if (typeof option == 'string') data[option].call($this) }) } -- cgit v1.2.3 From ad86d9a51bca001a52969d6cae65957023e30e9c Mon Sep 17 00:00:00 2001 From: Valera Rozuvan Date: Mon, 18 Nov 2013 11:55:33 +0200 Subject: Update dropdown.js --- js/dropdown.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'js') diff --git a/js/dropdown.js b/js/dropdown.js index d5da638de..ecce5af78 100644 --- a/js/dropdown.js +++ b/js/dropdown.js @@ -41,7 +41,7 @@ if (!isActive) { if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) { - // if mobile we we use a backdrop because click events don't delegate + // if mobile we use a backdrop because click events don't delegate $('