Skip to content

Commit

Permalink
fix: remove incorrect attribute in popup menu item
Browse files Browse the repository at this point in the history
  • Loading branch information
barmac committed Jun 21, 2024
1 parent 1ed8694 commit 774daa5
Show file tree
Hide file tree
Showing 4 changed files with 52 additions and 1 deletion.
1 change: 0 additions & 1 deletion lib/features/popup-menu/PopupMenuItem.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ export default function PopupMenuItem(props) {
onMouseEnter=${ onMouseEnter }
onMouseLeave=${ onMouseLeave }
onDragStart=${ (event) => onAction(event, entry, 'dragstart') }
aria-role="button"
draggable=${ true }
>
<div class="djs-popup-entry-content">
Expand Down
39 changes: 39 additions & 0 deletions package-lock.json

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

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
],
"devDependencies": {
"@babel/core": "^7.23.9",
"@bpmn-io/a11y": "^0.1.0",
"@testing-library/preact": "^3.2.3",
"babel-loader": "^9.1.3",
"babel-plugin-istanbul": "^6.1.1",
Expand Down
12 changes: 12 additions & 0 deletions test/spec/features/popup-menu/PopupMenuComponentSpec.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import { expectToBeAccessible } from '@bpmn-io/a11y';

import PopupMenuComponent from 'lib/features/popup-menu/PopupMenuComponent';

import {
Expand Down Expand Up @@ -713,6 +715,16 @@ describe('features/popup-menu - <PopupMenu>', function() {
// then
expect(searchInput.getAttribute('aria-label')).to.eql('Search');
});


it('should report no violations', async function() {

// given
await createPopupMenu({ container, entries, title: 'Search', search: true });

// then
await expectToBeAccessible(container);
});
});


Expand Down

0 comments on commit 774daa5

Please sign in to comment.