Skip to content

Commit

Permalink
Hidden dropdowns (#1051)
Browse files Browse the repository at this point in the history
* #1050 - fix dropdown lists with hidden elements

* 📦 v1.2.3
  • Loading branch information
paulcpederson authored and macandcheese committed Jan 23, 2019
1 parent 4527df1 commit 39790af
Show file tree
Hide file tree
Showing 18 changed files with 32 additions and 22 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## [1.2.3]

### Fixes
- fix dropdown arrow keys with hidden elements (#1050)

## [1.2.2]

### Fixes
Expand Down Expand Up @@ -1413,6 +1418,7 @@ Begin foundational sass for the framework.
- CSS Reset
- Grunt Workflows

[1.2.3]: https://github.com/esri/calcite-web/compare/v1.2.2...v1.2.3
[1.2.2]: https://github.com/esri/calcite-web/compare/v1.2.1...v1.2.2
[1.2.1]: https://github.com/esri/calcite-web/compare/v1.2.0...v1.2.1
[1.2.0]: https://github.com/esri/calcite-web/compare/v1.1.0...v1.2.0
Expand Down
2 changes: 1 addition & 1 deletion dist/css/calcite-web-dark.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
* Calcite Web - Calcite Design Components in CSS, JS and HTML
* @version v1.2.1
* @version v1.2.3
* @license Apache-2.0
* @copyright 2018 Esri
* @link https://github.com/Esri/calcite-web
Expand Down
2 changes: 1 addition & 1 deletion dist/css/calcite-web-dark.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/css/calcite-web-e-commerce.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
* Calcite Web - Calcite Design Components in CSS, JS and HTML
* @version v1.2.1
* @version v1.2.3
* @license Apache-2.0
* @copyright 2018 Esri
* @link https://github.com/Esri/calcite-web
Expand Down
2 changes: 1 addition & 1 deletion dist/css/calcite-web-e-commerce.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/css/calcite-web-marketing.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
* Calcite Web - Calcite Design Components in CSS, JS and HTML
* @version v1.2.1
* @version v1.2.3
* @license Apache-2.0
* @copyright 2018 Esri
* @link https://github.com/Esri/calcite-web
Expand Down
2 changes: 1 addition & 1 deletion dist/css/calcite-web-marketing.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/css/calcite-web-no-fonts.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
* Calcite Web - Calcite Design Components in CSS, JS and HTML
* @version v1.2.1
* @version v1.2.3
* @license Apache-2.0
* @copyright 2018 Esri
* @link https://github.com/Esri/calcite-web
Expand Down
2 changes: 1 addition & 1 deletion dist/css/calcite-web-no-fonts.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/css/calcite-web.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
* Calcite Web - Calcite Design Components in CSS, JS and HTML
* @version v1.2.1
* @version v1.2.3
* @license Apache-2.0
* @copyright 2018 Esri
* @link https://github.com/Esri/calcite-web
Expand Down
2 changes: 1 addition & 1 deletion dist/css/calcite-web.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/js/calcite-web-marketing.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
* Calcite Web - Calcite Design Components in CSS, JS and HTML
* @version v1.2.1
* @version v1.2.3
* @license Apache-2.0
* @copyright 2018 Esri
* @link https://github.com/Esri/calcite-web
Expand Down
2 changes: 1 addition & 1 deletion dist/js/calcite-web-marketing.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 6 additions & 4 deletions dist/js/calcite-web.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*!
* Calcite Web - Calcite Design Components in CSS, JS and HTML
* @version v1.2.1
* @version v1.2.3
* @license Apache-2.0
* @copyright 2018 Esri
* @link https://github.com/Esri/calcite-web
Expand Down Expand Up @@ -580,15 +580,17 @@ function dropownFocusOn (options) {
function arrowDown () {
var dropdown = dropdownIsOpen();
if (dropdown) {
var links = findElements('.dropdown-link', dropdown);
var links = findElements('.dropdown-link', dropdown)
.filter(function (link) { return link.offsetParent !== null; });
bus.emit('dropdown:focus', {links: links, forward: true});
}
}

function arrowUp () {
var dropdown = dropdownIsOpen();
if (dropdown) {
var links = findElements('.dropdown-link', dropdown);
var links = findElements('.dropdown-link', dropdown)
.filter(function (link) { return link.offsetParent !== null; });
bus.emit('dropdown:focus', {links: links, forward: false});
}
}
Expand Down Expand Up @@ -1404,7 +1406,7 @@ function extend (plugin) {
// │ Public API │
// └────────────┘
// define all public api methods
var version = '1.2.0';
var version = '1.2.3';
var click$1 = click;
var addEvent = add$1;
var removeEvent = remove$1;
Expand Down
4 changes: 2 additions & 2 deletions dist/js/calcite-web.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion es6.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ function extend (plugin) {
// │ Public API │
// └────────────┘
// define all public api methods
var version = '1.2.0';
var version = '1.2.3';
var click = event.click;
var addEvent = event.add;
var removeEvent = event.remove;
Expand Down
6 changes: 4 additions & 2 deletions lib/js/patterns/dropdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,15 +105,17 @@ function dropownFocusOn (options) {
function arrowDown () {
var dropdown = dropdownIsOpen();
if (dropdown) {
var links = dom.findElements('.dropdown-link', dropdown);
var links = dom.findElements('.dropdown-link', dropdown)
.filter(link => link.offsetParent !== null);
bus.emit('dropdown:focus', {links: links, forward: true});
}
}

function arrowUp () {
var dropdown = dropdownIsOpen();
if (dropdown) {
var links = dom.findElements('.dropdown-link', dropdown);
var links = dom.findElements('.dropdown-link', dropdown)
.filter(link => link.offsetParent !== null);
bus.emit('dropdown:focus', {links: links, forward: false});
}
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "calcite-web",
"version": "1.2.2",
"version": "1.2.3",
"description": "SASS & CSS Framework for Esri websites",
"private": true,
"homepage": "https://github.com/esri/calcite-web",
Expand Down

0 comments on commit 39790af

Please sign in to comment.