Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-css-collapse

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-css-collapse - npm Package Compare versions

Comparing version 3.0.2 to 3.1.0

.prettierrc

12

CHANGELOG.md
# Changelog
# 3.1.0
> Nov 15, 2017
* :nut_and_bolt: **New** Add prettier-eslint 💅
* :nut_and_bolt: **New** Support react 15.x || 16.x 🕺🏼 . Solving [#14](https://github.com/SparebankenVest/react-css-collapse/issues/14)
* :tada: **Enhancement** Upgrade storybook 🙏
# 3.0.2

@@ -46,1 +52,7 @@ > May 04, 2017

* :nut_and_bolt: **New** Created `Collapse` component
## Examples
* :nut_and_bolt: **New**
* :tada: **Enhancement**
* :bug: **Bugfix**
* :boom: **Breaking**

11

lib/components/Collapse.js

@@ -88,8 +88,13 @@ 'use strict';

value: function onTransitionEnd(e) {
if (this.props.isOpen) {
var _props = this.props,
onRest = _props.onRest,
isOpen = _props.isOpen;
if (isOpen) {
this.setExpanded();
}
if (this.props.onRest && e.target === this.content && e.propertyName === 'height') {
this.props.onRest();
if (onRest && e.target === this.content && e.propertyName === 'height') {
onRest();
}

@@ -96,0 +101,0 @@ }

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

var _storybook = require('@kadira/storybook');
var _addonActions = require('@storybook/addon-actions');

@@ -89,3 +89,5 @@ var _Collapse = require('../components/Collapse');

className: 'react-css-collapse-transition',
onRest: (0, _storybook.action)(element.name + ' is now ' + (_this2.state.index === index ? 'open' : 'closed'))
onRest: function onRest() {
return (0, _addonActions.action)('onRest');
}
},

@@ -92,0 +94,0 @@ _react2.default.createElement(

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

var _storybook = require('@kadira/storybook');
var _react3 = require('@storybook/react');

@@ -18,5 +18,5 @@ var _App = require('./App');

(0, _storybook.storiesOf)('Collapse', module).add('default', function () {
(0, _react3.storiesOf)('Collapse', module).add('default', function () {
return _react2.default.createElement(_App2.default, { elements: _data.elements });
});
//# sourceMappingURL=collapse.stories.js.map

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

var _storybook = require('@kadira/storybook');
var _react3 = require('@storybook/react');

@@ -19,5 +19,5 @@ var _App = require('./App');

var elements = (0, _data.createElements)(1000);
(0, _storybook.storiesOf)('Collapse', module).add('long list', function () {
(0, _react3.storiesOf)('Collapse', module).add('long list', function () {
return _react2.default.createElement(_App2.default, { elements: elements });
});
//# sourceMappingURL=perf.stories.js.map
{
"name": "react-css-collapse",
"version": "3.0.2",
"version": "3.1.0",
"description": "Component-wrapper for collapse animation with css for elements with variable and dynamic height",

@@ -25,3 +25,5 @@ "authors": [

"build": "npm test && npm run eslint && npm run clean && npm run babel",
"eslint": "eslint src/**/*.js* test/**/*.js",
"eslint": "eslint --ext .jsx,.js src/",
"eslint:fix": "eslint --ext .jsx,.js src/ --fix",
"prettier-eslint": "prettier-eslint --write \"src/**/*.js\" \"src/**/*.jsx\"",
"prepublish": "npm run build",

@@ -33,10 +35,11 @@ "start": "npm run babel -- -w",

"peerDependencies": {
"react": "^15.4.2",
"react-dom": "^15.4.2"
"react": "15.x || 16.x",
"react-dom": "15.x || 16.x"
},
"devDependencies": {
"@kadira/storybook": "^2.35.3",
"@storybook/addon-actions": "^3.2.12",
"@storybook/react": "^3.3.0-alpha.0",
"babel-cli": "^6.24.0",
"babel-eslint": "^7.1.1",
"babel-loader": "^6.4.1",
"babel-eslint": "^8.0.2",
"babel-loader": "^7.1.2",
"babel-plugin-transform-object-rest-spread": "^6.19.0",

@@ -48,14 +51,17 @@ "babel-preset-latest": "^6.24.0",

"chai": "^3.5.0",
"enzyme": "^2.6.0",
"eslint": "^3.17.1",
"eslint-config-airbnb": "^14.1.0",
"eslint-plugin-import": "^2.2.0",
"eslint-plugin-jsx-a11y": "^4.0.0",
"eslint-plugin-react": "^6.7.1",
"enzyme": "^3.2.0",
"enzyme-adapter-react-16": "^1.1.0",
"eslint": "^3.19.0",
"eslint-config-airbnb": "^15.1.0",
"eslint-plugin-import": "^2.7.0",
"eslint-plugin-jsx-a11y": "^5.1.1",
"eslint-plugin-react": "^7.1.0",
"jsdom": "^9.12.0",
"mocha": "^3.1.2",
"prop-types": "^15.5.8",
"react": "15.4.2",
"react-addons-test-utils": "^15.3.2",
"react-dom": "15.4.2",
"prettier": "^1.8.2",
"prettier-eslint": "^8.2.1",
"prettier-eslint-cli": "^4.3.2",
"prop-types": "^15.6.0",
"react": "^16.1.1",
"react-dom": "^16.1.1",
"sinon": "^2.1.0"

@@ -62,0 +68,0 @@ },

# react-css-collapse
Component-wrapper for collapse animation with css for elements with variable and dynamic height
[![Build Status](https://travis-ci.org/SparebankenVest/react-css-collapse.svg?branch=master)](https://travis-ci.org/SparebankenVest/react-css-collapse)
[![npm version](https://img.shields.io/npm/v/react-css-collapse.svg?style=flat-square)](https://www.npmjs.com/package/react-css-collapse)
[![npm downloads](https://img.shields.io/npm/dm/react-css-collapse.svg?style=flat-square)](https://www.npmjs.com/package/react-css-collapse)
## Installation

@@ -5,0 +9,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

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