From ab2fc63d08b8c53d6f29bcfd73b7f2d5ceaacacd Mon Sep 17 00:00:00 2001 From: Pierre-Denis Vanduynslager Date: Sun, 22 May 2016 02:16:27 -0400 Subject: [PATCH 001/419] Dropdown: remove dependency to role="menu", role="listbox" a and li elements => fix keyboard navigation --- js/src/dropdown.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/js/src/dropdown.js b/js/src/dropdown.js index 92f841bc4..a9786a534 100644 --- a/js/src/dropdown.js +++ b/js/src/dropdown.js @@ -44,11 +44,9 @@ const Dropdown = (($) => { BACKDROP : '.dropdown-backdrop', DATA_TOGGLE : '[data-toggle="dropdown"]', FORM_CHILD : '.dropdown form', - ROLE_MENU : '[role="menu"]', - ROLE_LISTBOX : '[role="listbox"]', + MENU : '.dropdown-menu', NAVBAR_NAV : '.navbar-nav', - VISIBLE_ITEMS : '[role="menu"] li:not(.disabled) a, ' - + '[role="listbox"] li:not(.disabled) a' + VISIBLE_ITEMS : '.dropdown-menu .dropdown-item:not(.disabled)' } @@ -268,8 +266,7 @@ const Dropdown = (($) => { $(document) .on(Event.KEYDOWN_DATA_API, Selector.DATA_TOGGLE, Dropdown._dataApiKeydownHandler) - .on(Event.KEYDOWN_DATA_API, Selector.ROLE_MENU, Dropdown._dataApiKeydownHandler) - .on(Event.KEYDOWN_DATA_API, Selector.ROLE_LISTBOX, Dropdown._dataApiKeydownHandler) + .on(Event.KEYDOWN_DATA_API, Selector.MENU, Dropdown._dataApiKeydownHandler) .on(Event.CLICK_DATA_API, Dropdown._clearMenus) .on(Event.CLICK_DATA_API, Selector.DATA_TOGGLE, Dropdown.prototype.toggle) .on(Event.CLICK_DATA_API, Selector.FORM_CHILD, (e) => { From 6fcf69657020816bf4ead830c7ece2ca55fe7e9a Mon Sep 17 00:00:00 2001 From: Pierre-Denis Vanduynslager Date: Wed, 28 Dec 2016 21:20:24 -0500 Subject: [PATCH 002/419] Change last reference from tags over to badges. --- scss/mixins/_badge.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scss/mixins/_badge.scss b/scss/mixins/_badge.scss index 77206b9a5..9fa44b647 100644 --- a/scss/mixins/_badge.scss +++ b/scss/mixins/_badge.scss @@ -1,4 +1,4 @@ -// Tags +// Badges @mixin badge-variant($color) { background-color: $color; From d2906950d9d0e675f27fa52e9685b7e5c5785e0d Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Wed, 28 Dec 2016 16:36:55 -0800 Subject: [PATCH 003/419] consistent punctuation it's important, yo --- docs/components/navbar.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/components/navbar.md b/docs/components/navbar.md index d2553de79..b0ad95ab9 100644 --- a/docs/components/navbar.md +++ b/docs/components/navbar.md @@ -28,8 +28,8 @@ Read on for an example and list of supported sub-components. Navbars come with built-in support for a handful of sub-components. Choose from the following as needed: -- `.navbar-brand` for your company, product, or project name -- `.navbar-nav` for a full-height and lightweight navigation (including support for dropdowns) +- `.navbar-brand` for your company, product, or project name. +- `.navbar-nav` for a full-height and lightweight navigation (including support for dropdowns). - `.navbar-toggler` for use with our collapse plugin and other [navigation toggling](#collapsible-content) behaviors. - Inline forms with `.float-` utilities for form controls and components. - `.navbar-text` for adding vertically centered strings of text. From 2c8675bbf6241724bc2ef775526d8b65f7965b7a Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Wed, 28 Dec 2016 16:37:04 -0800 Subject: [PATCH 004/419] better describe example --- docs/components/navbar.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/components/navbar.md b/docs/components/navbar.md index b0ad95ab9..4248e46d6 100644 --- a/docs/components/navbar.md +++ b/docs/components/navbar.md @@ -36,7 +36,7 @@ Navbars come with built-in support for a handful of sub-components. Choose from - `.form-inline` for form controls and more. - `.collapse.navbar-collapse` for grouping and hiding navbar contents by a parent breakpoint. -Here's an example of all the sub-components included in a responsive light-themed navbar. +Here's an example of all the sub-components included in a responsive light-themed navbar that automatically collapses at the `md` (medium) breakpoint. {% example html %} -