From bfa714ae1e91e2f77017d02489cbc39fada032c7 Mon Sep 17 00:00:00 2001 From: Max Beatty Date: Thu, 4 Aug 2016 13:47:30 -0700 Subject: prevent navigating to area href when modal target. fixes #18796 --- js/src/modal.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'js/src') diff --git a/js/src/modal.js b/js/src/modal.js index 9b3a99ddd..fd13a687c 100644 --- a/js/src/modal.js +++ b/js/src/modal.js @@ -491,7 +491,7 @@ const Modal = (($) => { let config = $(target).data(DATA_KEY) ? 'toggle' : $.extend({}, $(target).data(), $(this).data()) - if (this.tagName === 'A') { + if (this.tagName === 'A' || this.tagName === 'AREA') { event.preventDefault() } -- cgit v1.2.3 From b110070dcd5b957c1674bd08238e96faa9c2691e Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Sat, 26 Nov 2016 01:04:02 -0800 Subject: Follow up fix to #19953 for linting error in builds See https://travis-ci.org/twbs/bootstrap/jobs/179010884 for build failure --- js/src/dropdown.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'js/src') diff --git a/js/src/dropdown.js b/js/src/dropdown.js index 324eef793..8b2164aa9 100644 --- a/js/src/dropdown.js +++ b/js/src/dropdown.js @@ -239,7 +239,7 @@ const Dropdown = (($) => { return } - let items = $(parent).find(Selector.VISIBLE_ITEMS).get() + const items = $(parent).find(Selector.VISIBLE_ITEMS).get() if (!items.length) { return -- cgit v1.2.3