Socket
Socket
Sign inDemoInstall

@uppy/informer

Package Overview
Dependencies
Maintainers
8
Versions
74
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@uppy/informer - npm Package Compare versions

Comparing version 2.1.0 to 3.0.0-beta

16

lib/FadeIn.js

@@ -1,11 +0,7 @@

"use strict";
var _preact = require("preact");
import { h, Component, createRef } from 'preact';
const TRANSITION_MS = 300;
class FadeIn extends _preact.Component {
export default class FadeIn extends Component {
constructor() {
super(...arguments);
this.ref = (0, _preact.createRef)();
this.ref = createRef();
}

@@ -29,3 +25,3 @@

} = this.props;
return (0, _preact.h)("div", {
return h("div", {
className: "uppy-Informer-animated",

@@ -36,4 +32,2 @@ ref: this.ref

}
module.exports = FadeIn;
}

@@ -1,3 +0,1 @@

"use strict";
module.exports = require("./Informer.js");
export { default } from "./Informer.js";

@@ -1,16 +0,10 @@

"use strict";
var _preact = require("preact");
var _core = require("@uppy/core");
/* eslint-disable jsx-a11y/no-noninteractive-element-interactions */
/* eslint-disable jsx-a11y/click-events-have-key-events */
const FadeIn = require("./FadeIn.js");
const TransitionGroup = require("./TransitionGroup.js");
import { h } from 'preact';
import { UIPlugin } from '@uppy/core';
import FadeIn from "./FadeIn.js";
import TransitionGroup from './TransitionGroup.js';
const packageJson = {
"version": "2.1.0"
"version": "3.0.0-beta"
};

@@ -25,3 +19,3 @@ /**

class Informer extends _core.UIPlugin {
export default class Informer extends UIPlugin {
constructor(uppy, opts) {

@@ -31,9 +25,9 @@ super(uppy, opts);

this.render = state => {
return (0, _preact.h)("div", {
return h("div", {
className: "uppy uppy-Informer"
}, (0, _preact.h)(TransitionGroup, null, state.info.map(info => (0, _preact.h)(FadeIn, {
}, h(TransitionGroup, null, state.info.map(info => h(FadeIn, {
key: info.message
}, (0, _preact.h)("p", {
}, h("p", {
role: "alert"
}, info.message, ' ', info.details && (0, _preact.h)("span", {
}, info.message, ' ', info.details && h("span", {
"aria-label": info.details,

@@ -70,4 +64,2 @@ "data-microtip-position": "top-left",

}
Informer.VERSION = packageJson.version;
module.exports = Informer;
Informer.VERSION = packageJson.version;

@@ -1,5 +0,1 @@

"use strict";
var _preact = require("preact");
/* eslint-disable */

@@ -10,2 +6,4 @@

*/
import { Component, cloneElement, h, toChildArray } from 'preact';
function assign(obj, props) {

@@ -86,3 +84,3 @@ return Object.assign(obj, props);

class TransitionGroup extends _preact.Component {
class TransitionGroup extends Component {
constructor(props, context) {

@@ -92,3 +90,3 @@ super(props, context);

this.state = {
children: getChildMapping((0, _preact.toChildArray)((0, _preact.toChildArray)(this.props.children)) || [])
children: getChildMapping(toChildArray(toChildArray(this.props.children)) || [])
};

@@ -119,3 +117,3 @@ this.performAppear = this.performAppear.bind(this);

componentWillReceiveProps(nextProps) {
const nextChildMapping = getChildMapping((0, _preact.toChildArray)(nextProps.children) || []);
const nextChildMapping = getChildMapping(toChildArray(nextProps.children) || []);
const prevChildMapping = this.state.children;

@@ -194,3 +192,3 @@ this.setState(prevState => ({

const currentChildMapping = getChildMapping((0, _preact.toChildArray)(this.props.children) || []);
const currentChildMapping = getChildMapping(toChildArray(this.props.children) || []);

@@ -225,3 +223,3 @@ if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) {

const currentChildMapping = getChildMapping((0, _preact.toChildArray)(this.props.children) || []);
const currentChildMapping = getChildMapping(toChildArray(this.props.children) || []);

@@ -272,3 +270,3 @@ if (!currentChildMapping || !currentChildMapping.hasOwnProperty(key)) {

delete this.currentlyTransitioningKeys[key];
const currentChildMapping = getChildMapping((0, _preact.toChildArray)(this.props.children) || []);
const currentChildMapping = getChildMapping(toChildArray(this.props.children) || []);

@@ -313,3 +311,3 @@ if (currentChildMapping && currentChildMapping.hasOwnProperty(key)) {

const ref = linkRef(this, key),
el = (0, _preact.cloneElement)(childFactory(child), {
el = cloneElement(childFactory(child), {
ref,

@@ -323,3 +321,3 @@ key

return (0, _preact.h)(component, props, childrenToRender);
return h(component, props, childrenToRender);
}

@@ -333,2 +331,2 @@

};
module.exports = TransitionGroup;
export default TransitionGroup;
{
"name": "@uppy/informer",
"description": "A notification and error pop-up bar for Uppy.",
"version": "2.1.0",
"version": "3.0.0-beta",
"license": "MIT",

@@ -27,8 +27,9 @@ "main": "lib/index.js",

"dependencies": {
"@uppy/utils": "^4.1.0",
"@uppy/utils": "^5.0.0-beta",
"preact": "^10.5.13"
},
"peerDependencies": {
"@uppy/core": "^2.3.0"
}
"@uppy/core": "^3.0.0-beta"
},
"stableVersion": "2.1.0"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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