react-redux-toastr
Advanced tools
Comparing version 7.4.3 to 7.4.4
{ | ||
"name": "react-redux-toastr", | ||
"version": "7.4.3", | ||
"version": "7.4.4", | ||
"description": "react-redux-toastr is a React toastr message implemented with Redux", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -77,4 +77,5 @@ import React, {isValidElement} from 'react'; // eslint-disable-line no-unused-vars | ||
this.props.addToMemory(item.id); | ||
// | ||
this.closeButton.focus(); | ||
if (this.closeButton !== undefined) { | ||
this.closeButton.focus(); | ||
} | ||
} | ||
@@ -89,3 +90,5 @@ | ||
setTimeout(function() { | ||
document.getElementsByClassName('toastr-control')[0].focus(); | ||
if (document.getElementsByClassName('toastr-control').length > 0) { | ||
document.getElementsByClassName('toastr-control')[0].focus(); | ||
} | ||
}, 50); | ||
@@ -92,0 +95,0 @@ } |
@@ -56,3 +56,5 @@ import React from 'react'; | ||
// when toast loads the toast close button automatically focuses on the toast control | ||
this.closeButton.focus(); | ||
if (this.closeButton !== undefined) { | ||
this.closeButton.focus(); | ||
} | ||
} | ||
@@ -64,3 +66,5 @@ | ||
setTimeout(function() { | ||
document.getElementsByClassName('toastr-control')[0].focus(); | ||
if (document.getElementsByClassName('toastr-control').length > 0) { | ||
document.getElementsByClassName('toastr-control')[0].focus(); | ||
} | ||
}, 50); | ||
@@ -67,0 +71,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
135215
2320