Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
A stepper library, for use in any type of flow, onboarding, quiz. With some helpers for animating between steps but without getting too in the way.
A stepper library, for use in any type of flow, onboarding, quiz. With some helpers for animating between steps but without getting too in the way.
import React from 'react'
import { Hustler, Step } from 'hustler'
import cx from 'classnames'
import Layout from './Layout'
import StepOne from './StepOne'
import StepTwo from './StepTwo'
import StepThree from './StepThree'
import StepFour from './StepFour'
class Quiz extends React.Component {
constructor () {
super()
this.state = {
products: []
}
}
render () {
return (
<Layout>
<Hustler activeIndex={0} transitionSpeed={400}>
<Step>
{({ next, goTo, active, hiding, activeIndex }) => (
<div className={cx('step__wrapper', {
'is-active': active,
'is-hiding': hiding
})}>
<StepOne next={next} />
</div>
)}
</Step>
<Step>
{({ next, prev, goTo, active, hiding, activeIndex }) => (
<div className={cx('step__wrapper', {
'is-active': active,
'is-hiding': hiding
})}>
<StepTwo next={next} step={activeIndex} prev={prev} handleProduct={(i) => this.setState({products: i})} />
</div>
)}
</Step>
<Step>
{({ next, prev, goTo, active, hiding, activeIndex }) => (
<div className={cx('step__wrapper', {
'is-active': active,
'is-hiding': hiding
})}>
<StepThree next={next} step={activeIndex} prev={prev} />
</div>
)}
</Step>
<Step>
{({ next, prev, goTo, active, hiding, activeIndex }) => (
<div className={cx('step__wrapper', {
'is-active': active,
'is-hiding': hiding
})}>
<StepFour next={next} step={activeIndex} prev={prev} />
</div>
)}
</Step>
</Hustler>
</Layout>
)
}
}
next
- goes to the next step if there is one
prev
- goes to the previous step if there is one
goTo
- allows you to jump to any step 0
being the root step
hiding
- a simple set timeout for applying animations between steps, you could also apply set timeouts on the next/prev call to add additional animations within your own components
active
- the current active step, can be used again for animating
activeIndex
- the current index, helpful if you want to have some ui for visualizing where you are in the flow, or numbered steps like step 3 of 7 for example.
MIT License
FAQs
A stepper library, for use in any type of flow, onboarding, quiz. With some helpers for animating between steps but without getting too in the way.
The npm package hustler receives a total of 2 weekly downloads. As such, hustler popularity was classified as not popular.
We found that hustler 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 uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.