Skip to content

Commit

Permalink
[Dialog] Fix dialog children being announced as clickable (#21285)
Browse files Browse the repository at this point in the history
  • Loading branch information
eps1lon committed Jun 3, 2020
1 parent 8e2cca3 commit 5db39cf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
3 changes: 1 addition & 2 deletions packages/material-ui/src/Dialog/Dialog.js
@@ -1,4 +1,3 @@
/* eslint-disable jsx-a11y/click-events-have-key-events */
import * as React from 'react';
import PropTypes from 'prop-types';
import clsx from 'clsx';
Expand Down Expand Up @@ -234,7 +233,7 @@ const Dialog = React.forwardRef(function Dialog(props, ref) {
{/* eslint-disable-next-line jsx-a11y/no-static-element-interactions */}
<div
className={clsx(classes.container, classes[`scroll${capitalize(scroll)}`])}
onClick={handleBackdropClick}
onMouseUp={handleBackdropClick}
onMouseDown={handleMouseDown}
data-mui-test="FakeBackdrop"
>
Expand Down
1 change: 1 addition & 0 deletions packages/material-ui/src/Dialog/Dialog.test.js
Expand Up @@ -14,6 +14,7 @@ import Dialog from './Dialog';
*/
function userClick(element) {
fireEvent.mouseDown(element);
fireEvent.mouseUp(element);
element.click();
}

Expand Down

0 comments on commit 5db39cf

Please sign in to comment.