Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
react-headless-multi-stepper
Advanced tools
Design your own Multi Stepper component without having to worry about the logic. Then this tiny and performant package is for you. `react-headless-multi-stepper` is ideal if you are working with a utility-based css framework like TailwindCSS. `react-headl
Design your own Multi Stepper component without having to worry about the logic. Then this tiny and performant package is for you. react-headless-multi-stepper
is ideal if you are working with a utility-based css framework like TailwindCSS. react-headless-multi-stepper
offers plenty of customization through generics and is also fully typed.
yarn add react-headless-multi-stepper
import { MultiStepper } from "react-headless-multi-stepper";
...
return (
<MultiStepper
{...args}
RootContainer={<div />}
MainLabelContainer={<ul />}
SubLabelContainer={<ul />}
ContentContainer={<div />}
onChange={(step)}
onCompleted={() => alert("onCompleted")}
renderMainLabel={(props) => <li>{props.label}</li>}
renderSubLabel={(props) => <li>{props.label}</li>}
>
<MultiStepper.VerticalStep name="1" label="step 1">
<MultiStepper.HorizontalStep name="1.1" label="1.1">
{({ goPrevious, goNext }) => (
<div>
Content 1.1
<button onClick={goPrevious}>previous</button>
<button onClick={goNext}>next</button>
</div>
)}
</MultiStepper.HorizontalStep>
<MultiStepper.HorizontalStep name="1.2" label="1.2">
{({ goPrevious, goNext }) => (
<div>
Content 1.2
<button onClick={goPrevious}>previous</button>
<button onClick={goNext}>next</button>
</div>
)}
</MultiStepper.HorizontalStep>
<MultiStepper.HorizontalStep name="1.3" label="1.3">
{({ goPrevious, goNext }) => (
<div>
Content 1.3
<button onClick={goPrevious}>previous</button>
<button onClick={goNext}>next</button>
</div>
)}
</MultiStepper.HorizontalStep>
</MultiStepper.VerticalStep>
<MultiStepper.VerticalStep name="2" label="step 2">
<MultiStepper.HorizontalStep name="2.1" label="2.1">
{({ goPrevious, goNext }) => (
<div>
Content 2.1
<button onClick={goPrevious}>previous</button>
<button onClick={goNext}>next</button>
</div>
)}
</MultiStepper.HorizontalStep>
<MultiStepper.HorizontalStep name="2.2" label="2.2">
{({ goPrevious, goNext }) => (
<div>
Content 2.2
<button onClick={goPrevious}>previous</button>
<button onClick={goNext}>next</button>
</div>
)}
</MultiStepper.HorizontalStep>
<MultiStepper.HorizontalStep name="2.3" label="2.3">
{({ goPrevious, goNext }) => (
<div>
Content 2.3
<button onClick={goPrevious}>previous</button>
<button onClick={goNext}>next</button>
</div>
)}
</MultiStepper.HorizontalStep>
</MultiStepper.VerticalStep>
<MultiStepper.VerticalStep name="3" label="step 3">
<MultiStepper.HorizontalStep name="3.1" label="3.1">
{({ goPrevious, goNext }) => (
<div>
Content 3.1
<button onClick={goPrevious}>previous</button>
<button onClick={goNext}>next</button>
</div>
)}
</MultiStepper.HorizontalStep>
</MultiStepper.VerticalStep>
</MultiStepper>
);
An example of a styled version can be found in stories/MultiStepper.stories.tsx.
The following table contains all optional and required props for the MultiStepper. The library is strictly typed and uses generics to support many different kinds of data.
Name | Type | Default | Description |
---|---|---|---|
dataTestId | string | Places a data-testid on several elements | |
RootContainer | React.ReactElement | div | Root element of the MultiStepper. |
MainLabelContainer | React.ReactElement | ul | Containing element for the main labels. |
SubLabelContainer | React.ReactElement | ul | Containing element for the sub labels. |
ContentContainer | React.ReactElement | div | Containing element for the SubLabelContainer and step content. |
renderMainLabel* | IRenderLabel ** | Render prop for the label of the vertical step. | |
renderSubLabel* | IRenderLabel ** | Render prop for the label of the horizontal step. | |
onChange* | (name: string) => void | Fires for every next and previous navigation action. Name refers to the newly activated step. | |
onCompleted* | () => void | Fires on completion of the entire flow. | |
children* | React.ReactElement <IVerticalStep>[] | A number of VerticalStep components. |
*these are required
**IRenderLabel contains all information to render your horizontal or vertical label (i.e. activeIndex, label, name, index, array).
The following table contains all optional and required props for the VerticalStep component. VerticalSteps are placed as children inside the MultiStepper.
Name | Type | Description |
---|---|---|
name* | string | Unique string to distinguish between all vertical steps |
label* | string | Display this value to the user in the stepper. |
children* | React.ReactElement<IHorizontalStep> or React.ReactElement<IHorizontalStep>[] | A number of HorizontalStep components. |
*these are required
The following table contains all optional and required props for the HorizontalStep component. HorizontalSteps are placed as children inside the VerticalStep.
Name | Type | Description |
---|---|---|
name* | string | Unique string to distinguish between all horizontal steps |
label* | string | Display this value to the user in the stepper. |
children* | ({goPrevious,goNext}) | Render prop for children |
*these are required
** IHorizontalStep: goPrevious and goNext are both callback functions that return nothing.
FAQs
Design your own Multi Stepper component without having to worry about the logic. Then this tiny and performant package is for you. `react-headless-multi-stepper` is ideal if you are working with a utility-based css framework like TailwindCSS. `react-headl
The npm package react-headless-multi-stepper receives a total of 0 weekly downloads. As such, react-headless-multi-stepper popularity was classified as not popular.
We found that react-headless-multi-stepper 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’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.