Research
Security News
Kill Switch Hidden in npm Packages Typosquatting Chalk and Chokidar
Socket researchers found several malicious npm packages typosquatting Chalk and Chokidar, targeting Node.js developers with kill switches and data theft.
react-css-collapse
Advanced tools
Component-wrapper for collapse animation with css for elements with variable and dynamic height
Component-wrapper for collapse animation with css for elements with variable and dynamic height
Using npm:
npm install --save react-css-collapse
Then with a module bundler like webpack, use as you would anything else:
import Collapse from 'react-css-collapse';
<Collapse isOpen={true || false}>
<div>Random content</div>
</Collapse>
isOpen
: PropTypes.boolean.isRequiredExpands or collapses content.
children
: PropTypes.node.isRequiredOne or multiple children with static, variable or dynamic height.
<Collapse isOpen={true}>
<p>Paragraph of text</p>
<p>Another paragraph is also OK</p>
<p>Images and any other content are ok too</p>
<img src="cutecat.gif" />
</Collapse>
onRest
: PropTypes.funcCallback function for when your transition on height
(specified in className
) is finished. It can be used to trigger any function after transition is done.
className
: PropType.stringYou can specify a className with your desired style and animation
.react-css-collapse-transition {
transition: height 250ms cubic-bezier(.4, 0, .2, 1);
}
To run example covering all features, use npm run storybook
.
git clone [repo]
cd [repo]
npm install
npm run storybook
Open http://localhost:6006 🎆
3.3.1
July 05, 2018
FAQs
Component-wrapper for collapse animation with css for elements with variable and dynamic height
The npm package react-css-collapse receives a total of 3,171 weekly downloads. As such, react-css-collapse popularity was classified as popular.
We found that react-css-collapse demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers found several malicious npm packages typosquatting Chalk and Chokidar, targeting Node.js developers with kill switches and data theft.
Security News
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
Product
Socket now supports uv.lock files to ensure consistent, secure dependency resolution for Python projects and enhance supply chain security.