Define event locally in onClickOutside method in account-dropdowns.js

feature/default_network_editable
Dan 7 years ago
parent 33373b676f
commit 78f6a48664
  1. 2
      old-ui/app/components/account-dropdowns.js
  2. 2
      ui/app/components/account-dropdowns.js
  3. 2
      ui/app/components/dropdowns/components/account-dropdowns.js

@ -173,7 +173,7 @@ class AccountDropdowns extends Component {
minWidth: '180px',
},
isOpen: optionsMenuActive,
onClickOutside: () => {
onClickOutside: (event) => {
const { classList } = event.target
const isNotToggleElement = !classList.contains(this.optionsMenuToggleClassName)
if (optionsMenuActive && isNotToggleElement) {

@ -173,7 +173,7 @@ class AccountDropdowns extends Component {
minWidth: '180px',
},
isOpen: optionsMenuActive,
onClickOutside: () => {
onClickOutside: (event) => {
const { classList } = event.target
const isNotToggleElement = !classList.contains(this.optionsMenuToggleClassName)
if (optionsMenuActive && isNotToggleElement) {

@ -281,7 +281,7 @@ class AccountDropdowns extends Component {
dropdownWrapperStyle,
),
isOpen: optionsMenuActive,
onClickOutside: () => {
onClickOutside: (event) => {
const { classList } = event.target
const isNotToggleElement = !classList.contains(this.optionsMenuToggleClassName)
if (optionsMenuActive && isNotToggleElement) {

Loading…
Cancel
Save