Socket
Socket
Sign inDemoInstall

react-redux-toastr

Package Overview
Dependencies
Maintainers
1
Versions
134
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-redux-toastr - npm Package Compare versions

Comparing version 7.1.3 to 7.1.4

50

CHANGELOG.md

@@ -1,2 +0,2 @@

#7.0.0
# 7.0.0

@@ -16,18 +16,16 @@ # Breaking Changes

#5.0.0
# 5.0.0
Custom `id` for the `toastr` and `confirm`
#4.4.6
# 4.4.6
Fix animation side effect.
(issue)[https://github.com/diegoddox/react-redux-toastr/issues/102]
#4.2.1
# 4.2.1
Add method `removeByType`.
#4.1.0
# 4.1.0
Migrate frm less to scss
#4.0.0
# 4.0.0
Add light style.

@@ -37,15 +35,16 @@ toastr option icon can be a react component.

#3.11.0
# 3.11.0
Add option `preventDuplicates`
#3.8.0
# 3.8.0
add `showCloseButton` in the `confirm` `props`
clsoe confirm on `esc` and `enter`
#3.6.3
# 3.6.3
Fix time-travel issue #43
#3.6.0
# 3.6.0
add extra options to the `toastr`, now u can prevent the `toastr` closing on mouseLeave and on Click.
```
```js
{

@@ -57,6 +56,6 @@ removeOnHover: false,

#3.1.4
# 3.1.4
Add the font-icons to the lib folder.
#3.0.0
# 3.0.0
Remove `dangerouslysetinnerhtml` and implment `component` `option`.

@@ -66,17 +65,20 @@

#2.1.0
# 2.1.0
change ReduxToastr props name from `confirm` to `confirmOptions`
the `message` method can close automaticly you you provide a `timeout` in the `message` options
#1.1.0
the `message` method can close automaticly you you provide a `timeout` in the `message` options
# 1.1.0
Improve the code end fix [issue](https://github.com/diegoddox/redux-toastr/issues/3)
#1.0.2
# 1.0.2
fix [issue](https://github.com/diegoddox/redux-toastr/issues/1)
#1.0.1
# 1.0.1
##### Fix icons
#1.0.0
# 1.0.0
##### add confirm method
##### add css prefix
#0.4.0
# 0.4.0
#### add method message

@@ -86,6 +88,6 @@ #### add option newestOnTop

#0.3.1
# 0.3.1
Nothing new just some problems with npm readme.md file
#0.3.0
# 0.3.0
You don't need to add the google font link to the head of you project

@@ -7,3 +7,3 @@ 'use strict';

var toastr = {
maxAnimationDelay: 2000,
maxAnimationDelay: 6000,
newestOnTop: true,

@@ -10,0 +10,0 @@ position: 'top-right',

@@ -9,2 +9,3 @@ 'use strict';

exports.toastrWarn = toastrWarn;
exports.createReducer = createReducer;

@@ -26,3 +27,3 @@ exports.isBrowser = isBrowser;

function whichTransitionEvent() {
function whichAnimationEvent() {
var t = void 0;

@@ -32,6 +33,6 @@ var el = document.createElement('fakeelement');

var transitions = {
transition: 'transitionend',
OTransition: 'oTransitionEnd',
MozTransition: 'transitionend',
WebkitTransition: 'webkitTransitionEnd'
animation: 'animationend',
oanimation: 'oanimationend',
MSAnimation: 'MSAnimationEnd',
webkitAnimation: 'webkitAnimationEnd'
};

@@ -53,9 +54,7 @@

var toastrWarn;
if (process.env.NODE_ENV === 'production') {
toastrWarn = function toastrWarn() {};
} else {
toastrWarn = function toastrWarn(message) {
console.warn('[react-redux-toastr] ' + message);
};
function toastrWarn(message) {
if (process.env.NODE_ENV === 'production') {
return null;
}
console.warn('[react-redux-toastr] ' + message);
}

@@ -135,5 +134,5 @@

// if css animation is failed - dispatch event manually
var transitionEndName = whichTransitionEvent();
var animationEnd = whichAnimationEvent();
var timeoutId = setTimeout(function () {
var e = new Event('transitionend');
var e = new Event(animationEnd);
toastrWarn('The toastr box was closed automatically, please check \'transitionOut\' prop value');

@@ -148,7 +147,6 @@ node.dispatchEvent(e);

e.stopPropagation();
node.removeEventListener(node, runOnce);
node.removeEventListener(animationEnd, runOnce);
callback && callback(e);
};
node.addEventListener(transitionEndName, runOnce);
node.addEventListener(animationEnd, runOnce);
}

@@ -155,0 +153,0 @@

{
"name": "react-redux-toastr",
"version": "7.1.3",
"version": "7.1.4",
"description": "react-redux-toastr is a React toastr message implemented with Redux",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

## `react-redux-toastr` [demo](http://diegoddox.github.io/react-redux-toastr/)
[![NPM](https://nodei.co/npm/react-redux-toastr.png)](https://nodei.co/npm/react-redux-toastr/)
![react-redux-toastr](https://raw.githubusercontent.com/diegoddox/react-redux-toastr/master/assets/toastr.png?style=centerme)

@@ -4,0 +6,0 @@

let toastr = {
maxAnimationDelay: 2000,
maxAnimationDelay: 6000,
newestOnTop: true,

@@ -4,0 +4,0 @@ position: 'top-right',

import config from './config';
function whichTransitionEvent() {
function whichAnimationEvent() {
let t;

@@ -8,6 +8,6 @@ const el = document.createElement('fakeelement');

const transitions = {
transition: 'transitionend',
OTransition: 'oTransitionEnd',
MozTransition: 'transitionend',
WebkitTransition: 'webkitTransitionEnd'
animation: 'animationend',
oanimation: 'oanimationend',
MSAnimation: 'MSAnimationEnd',
webkitAnimation: 'webkitAnimationEnd'
};

@@ -29,9 +29,7 @@

var toastrWarn;
if (process.env.NODE_ENV === 'production') {
toastrWarn = () => {};
} else {
toastrWarn = (message) => {
console.warn(`[react-redux-toastr] ${message}`);
};
export function toastrWarn(message) {
if (process.env.NODE_ENV === 'production') {
return null;
}
console.warn(`[react-redux-toastr] ${message}`);
}

@@ -102,5 +100,5 @@

// if css animation is failed - dispatch event manually
const transitionEndName = whichTransitionEvent();
const animationEnd = whichAnimationEvent();
const timeoutId = setTimeout(function() {
var e = new Event('transitionend');
const e = new Event(animationEnd);
toastrWarn('The toastr box was closed automatically, please check \'transitionOut\' prop value');

@@ -115,7 +113,6 @@ node.dispatchEvent(e);

e.stopPropagation();
node.removeEventListener(node, runOnce);
node.removeEventListener(animationEnd, runOnce);
callback && callback(e);
};
node.addEventListener(transitionEndName, runOnce);
node.addEventListener(animationEnd, runOnce);
}

@@ -122,0 +119,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc