aboutsummaryrefslogtreecommitdiff
path: root/js/tests/unit/dropdown.js
AgeCommit message (Collapse)AuthorFilesLines
2021-09-15Merge duplicate test.XhmikosR1-34/+2
2021-09-15tests: comply to the new rulesXhmikosR1-87/+87
Use `assert.strictEqual`/`assert.true`/`assert.false`
2021-04-15Remove aria-haspopup from dropdowns (#33624)Patrick H. Lauke1-1/+1
`aria-haspopup="true"` is really intended to signal that an ARIA `menu` will be opened on activation. as a result, some assistive technologies will announce controls with `aria-haspopup="true"` as a menu or menu item (e.g. JAWS and NVDA). In addition, `aria-haspopup` seems to trigger a bug in Edge/Narrator where the `aria-expanded` state is not correctly announced at the moment when `aria-haspopup` is present. This now makes the dropdown button more like a generic disclosure widget control - see also https://www.w3.org/TR/wai-aria-practices-1.2/examples/disclosure/disclosure-navigation.html01
2020-11-24Backport #32224XhmikosR1-6/+6
Be consistent with Popper's name.
2020-09-10Comply to the new rulesXhmikosR1-2/+2
2020-04-28Backport #30633Martijn Cuppens1-3/+3
Remove caret element
2020-04-07Fix event propagation from inactive and disabled dropdowns (#30510) (#30511)luktom1-0/+64
2019-11-02backport #29523: skip hidden dropdowns while focusingJohann-S1-0/+41
2019-08-27Backport #29298Johann-S1-1/+36
dropdown show method should do the same as toggle
2019-08-27Backport #29277Johann-S1-1/+45
dropdown - destroy old popper.js references
2019-08-27Backport #29251Johann-S1-0/+26
allow to pass popper.js configuration for tooltip/popover and dropdown
2019-06-19Add missing dropdown unit test for closing with ESC (#28929)Patrick H. Lauke1-0/+39
Backport of the unit test from https://github.com/twbs/bootstrap/pull/28928
2019-06-18Don't open dropdown on ESC on trigger element (#28912)Patrick H. Lauke1-0/+25
* Don't open dropdown on ESC on trigger element Closes #28751
2019-02-05Move dropdown offset function logic into private function. (#28138)Jason Golieb1-0/+55
2018-10-20Add `show` and `hide` methods to dropdown (#27370)galczo51-0/+264
2018-09-13throw error when folks try to use a bad selectorJohann-S1-24/+0
2018-06-25feat(dropdown): add original click eventjakubhonisek1-0/+68
2018-05-22chore(deps): update qunit and karma-qunitJohann-S1-0/+1
2018-04-13fix issue related to Object.keys and Dropdown issueJohann-S1-21/+21
2018-04-10v4 improve coverage (#25945)Johann-S1-0/+112
* Improve code coverage for our Button plugin * improve coverage for our Alert plugin * test tooltip update method * test update and dispose for dropdown * increase code coverage requirements
2018-03-26Fix skip element disabled via attribute when using keyboard navigationvsn4ik1-19/+21
2018-02-11Dropdown - Allow to disable Popper.js style (#24092)Johann-S1-0/+30
* Dropdown - Allow to disable Popper.js style * Update dropdown.js * Update dropdown.html * copy changes
2018-01-11Comply to the new rules.XhmikosR1-382/+418
2017-12-12dropdown: add boundary config option (#24976)Troy Morehouse1-0/+44
2017-10-27Fix unit tests.Johann-S1-141/+184
2017-10-27Dropdown handle keydown on input and textarea.Pierre-Denis Vanduynslager1-5/+141
2017-08-23Tweak ESLint rules.XhmikosR1-2/+2
2017-07-04Dropdown - Disable applyStyle modifier instead of removing inline style ↵Johann-S1-0/+29
applied by Popper.js
2017-06-14Fix unit tests with no assertionJohann-S1-11/+23
2017-05-14Fix unit tests + Update Popper to 1.6.0Johann-S1-24/+24
2017-02-08Fixes #21941Pierre-Denis Vanduynslager1-5/+11
2017-01-20Harmonize document.activeElement comparisonPierre-Denis Vanduynslager1-3/+3
2017-01-20Refactor test to event and asyncPierre-Denis Vanduynslager1-64/+141
2017-01-20Add unit test for keyboard navigationPierre-Denis Vanduynslager1-0/+34
2017-01-20Fix test to retrieve the proper item instead of it's parentPierre-Denis Vanduynslager1-1/+1
2017-01-06Update dropdown unit test to new markupPierre-Denis Vanduynslager1-137/+136
2017-01-02Dropdown: close menu when focusing outside element (#21375)Pierre-Denis Vanduynslager1-0/+60
* Close dropdown menu when focusing an outside element * Update unit test to new markup
2016-12-07Rename `.active` to `.show`Starsam801-17/+17
2016-11-24Make JS compliant with the new ESLint rules.Bardi Harborow1-1/+1
2016-10-25Use a single class name for opened/expanded/shown state of widgetsJohann-S1-17/+17
2015-10-02Add throw error for undefined method on pluginsJohann-S1-0/+12
2015-07-27Fix triggering of {shown,hidden}.bs.dropdown events so relatedTarget gets ↵Johann-S1-0/+32
set properly Fixes #16828 Closes #16865
2015-06-02generalize dropdowns / drop role="menu"Patrick H. Lauke1-5/+5
as role="menu" is a very specific (and strict) ARIA pattern for desktop-like application menus, and our dropdowns are often used as pure navigation dropdowns, this change abandons ARIA menus for a more open-ended and light-weight approach (see http://heydonworks.com/practical_aria_examples/#submenus and http://www.w3.org/WAI/tutorials/menus/flyout/#improve-screen-reader-support-using-wai-aria) note that in dropdown.js, switched to now target ``.dropdown-menu`` instead of ``role["menu"]`` - this also prevents bootstrap scripts from "bleeding" into non-bootstrap components on the same page. also removed the ``role=["listbox"]`` part, which appears to be vestigial/unused (only place in bootstrap that uses that role are carousels, and their key handling is done separately)
2015-03-21Fix #16072: Clicking into input field within dropdown no longer closes the ↵Emmanuel Bourgerie1-0/+38
dropdown Closes #16073 by merging it
2015-03-09Disable jQuery event aliases when running test suiteChris Rebert1-21/+21
To ensure that we don't accidentally use any of the aliases. This should prevent any future regressions from #12761. Also updates the test suite since it now can't use these aliases either.
2015-03-03[Fixes #15953] Implement assert.expect in each unit testKevin Kirsche1-0/+15
[Fixes #15953] Implement `assert.expect` in each unit test
2015-02-26Unit tests: Use new names of module hooksHeinrich Fenkart1-2/+2
Refs #15893
2015-02-26Dropdowns: Skip `.disabled` instead of `.divider` on keydown eventvsn4ik1-0/+21
Fixes #15147. Closes #15520 by merging it.
2015-02-25Dropdown unit tests: Tiny style changesHeinrich Fenkart1-3/+5
2015-02-24Add unit test of aria-expanded to dropdown suiteKevin Kirsche1-0/+47
Redo of #15876