react-redux-toastr
Advanced tools
Comparing version 7.2.6 to 7.3.0
@@ -122,7 +122,9 @@ 'use strict'; | ||
ToastrBox.prototype.mouseLeave = function mouseLeave() { | ||
var removeOnHover = this.props.item.options.removeOnHover; | ||
var _props$item$options2 = this.props.item.options, | ||
removeOnHover = _props$item$options2.removeOnHover, | ||
removeOnHoverTimeOut = _props$item$options2.removeOnHoverTimeOut; | ||
if (!this.isHiding && (removeOnHover || this.shouldClose)) { | ||
var interval = removeOnHover === true ? 1000 : removeOnHover; | ||
var interval = removeOnHover === true ? removeOnHoverTimeOut || 1000 : removeOnHover; | ||
this._setIntervalId(setTimeout(this._removeToastr, interval)); | ||
@@ -129,0 +131,0 @@ |
{ | ||
"name": "react-redux-toastr", | ||
"version": "7.2.6", | ||
"version": "7.3.0", | ||
"description": "react-redux-toastr is a React toastr message implemented with Redux", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -149,3 +149,3 @@ ## `react-redux-toastr` [demo](http://diegoddox.github.io/react-redux-toastr/) | ||
Each of these methods can take up to three arguments the `title` a `message` and `options`. | ||
In `options` you can specify `timeOut` `icon` `onShowComplete` `onHideComplete` `className` `component` `removeOnHover`, `showCloseButton`, `onCloseButtonClick`, `progressBar`, `transitionIn`, `position`, `attention`, `onAttentionClick` and `transitionOut`. | ||
In `options` you can specify `timeOut` `icon` `onShowComplete` `onHideComplete` `className` `component` `removeOnHover`,`removeOnHoverTimeOut`,`showCloseButton`, `onCloseButtonClick`, `progressBar`, `transitionIn`, `position`, `attention`, `onAttentionClick` and `transitionOut`. | ||
@@ -208,3 +208,4 @@ ``` javascript | ||
onHideComplete: () => console.log('HIDE: animation is done'), | ||
removeOnHover: false // Default value is false | ||
removeOnHover: false, // Default value is false | ||
removeOnHoverTimeOut: 1000, // Default value is 1000 | ||
component: React.Component | ||
@@ -211,0 +212,0 @@ }; |
@@ -110,6 +110,6 @@ import React, {isValidElement} from 'react'; // eslint-disable-line no-unused-vars | ||
mouseLeave() { | ||
const {removeOnHover} = this.props.item.options; | ||
const {removeOnHover,removeOnHoverTimeOut} = this.props.item.options; | ||
if (!this.isHiding && (removeOnHover || this.shouldClose)) { | ||
const interval = removeOnHover === true ? 1000 : removeOnHover; | ||
const interval = removeOnHover === true ? (removeOnHoverTimeOut || 1000) : removeOnHover; | ||
this._setIntervalId(setTimeout(this._removeToastr, interval)); | ||
@@ -116,0 +116,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
133226
2194
329