npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@xsolla/xui-stepper

v0.108.0

Published

A cross-platform React stepper component that displays progress through a sequence of steps, supporting horizontal and vertical layouts with multiple step states.

Readme

Stepper

A cross-platform React stepper component that displays progress through a sequence of steps, supporting horizontal and vertical layouts with multiple step states.

Installation

npm install @xsolla/xui-stepper
# or
yarn add @xsolla/xui-stepper

Demo

Basic Stepper

import * as React from 'react';
import { Stepper } from '@xsolla/xui-stepper';

export default function BasicStepper() {
  const steps = [
    { title: 'Account', state: 'complete' as const },
    { title: 'Payment', state: 'current' as const },
    { title: 'Review', state: 'incomplete' as const },
  ];

  return <Stepper steps={steps} />;
}

Vertical Stepper

import * as React from 'react';
import { Stepper } from '@xsolla/xui-stepper';

export default function VerticalStepper() {
  const steps = [
    { title: 'Step 1', description: 'Account details', state: 'complete' as const },
    { title: 'Step 2', description: 'Payment method', state: 'current' as const },
    { title: 'Step 3', description: 'Order review', state: 'incomplete' as const },
  ];

  return <Stepper steps={steps} direction="vertical" />;
}

With States

import * as React from 'react';
import { Stepper } from '@xsolla/xui-stepper';

export default function StepStates() {
  const steps = [
    { title: 'Complete', state: 'complete' as const },
    { title: 'Warning', state: 'warning' as const },
    { title: 'Alert', state: 'alert' as const },
    { title: 'Loading', state: 'loading' as const },
    { title: 'Current', state: 'current' as const },
    { title: 'Incomplete', state: 'incomplete' as const },
  ];

  return <Stepper steps={steps} />;
}

Anatomy

import { Stepper } from '@xsolla/xui-stepper';

<Stepper
  steps={steps}              // Array of step objects
  direction="horizontal"     // horizontal or vertical
  size="md"                   // s or m
  variantUI="current"        // current or simple
  palette="brand"            // brand or brandSecondary
  tail={false}               // Show connecting line (simple variant)
  onClick={handleClick}      // Step click handler
  aria-label="Checkout"      // Accessible label
/>

Examples

Checkout Flow

import * as React from 'react';
import { Stepper } from '@xsolla/xui-stepper';

export default function CheckoutFlow() {
  const [currentStep, setCurrentStep] = React.useState(1);

  const steps = [
    { title: 'Cart', state: currentStep > 0 ? 'complete' as const : 'incomplete' as const },
    { title: 'Shipping', state: currentStep === 1 ? 'current' as const : currentStep > 1 ? 'complete' as const : 'incomplete' as const },
    { title: 'Payment', state: currentStep === 2 ? 'current' as const : currentStep > 2 ? 'complete' as const : 'incomplete' as const },
    { title: 'Confirm', state: currentStep === 3 ? 'current' as const : 'incomplete' as const },
  ];

  return (
    <div>
      <Stepper
        steps={steps}
        onClick={({ number }) => setCurrentStep(number)}
      />
      <div style={{ marginTop: 24 }}>
        <button onClick={() => setCurrentStep(Math.max(0, currentStep - 1))}>Back</button>
        <button onClick={() => setCurrentStep(Math.min(3, currentStep + 1))}>Next</button>
      </div>
    </div>
  );
}

Registration Steps

import * as React from 'react';
import { Stepper } from '@xsolla/xui-stepper';

export default function RegistrationSteps() {
  const steps = [
    { title: 'Email', description: 'Verify your email', state: 'complete' as const },
    { title: 'Profile', description: 'Set up your profile', state: 'current' as const },
    { title: 'Preferences', description: 'Customize settings', state: 'incomplete' as const },
  ];

  return (
    <Stepper
      steps={steps}
      direction="vertical"
      variantUI="current"
      size="md"
    />
  );
}

Simple Variant with Tail

import * as React from 'react';
import { Stepper } from '@xsolla/xui-stepper';

export default function SimpleStepper() {
  const steps = [
    { title: 'Step 1', state: 'complete' as const },
    { title: 'Step 2', state: 'current' as const },
    { title: 'Step 3', state: 'incomplete' as const },
  ];

  return <Stepper steps={steps} variantUI="simple" tail />;
}

Order Tracking

import * as React from 'react';
import { Stepper } from '@xsolla/xui-stepper';

export default function OrderTracking() {
  const steps = [
    { title: 'Order Placed', description: 'Jan 20, 2024', state: 'complete' as const },
    { title: 'Processing', description: 'Jan 21, 2024', state: 'complete' as const },
    { title: 'Shipped', description: 'In transit', state: 'loading' as const },
    { title: 'Delivered', state: 'incomplete' as const },
  ];

  return (
    <Stepper
      steps={steps}
      direction="vertical"
      palette="brand"
    />
  );
}

API Reference

Stepper

StepperProps:

| Prop | Type | Default | Description | | :--- | :--- | :------ | :---------- | | steps | StepType[] | - | Array of step definitions. | | direction | "horizontal" \| "vertical" | "horizontal" | Layout direction. | | size | "sm" \| "md" | "md" | Step size. | | variantUI | "current" \| "simple" | "current" | Visual variant. | | palette | "brand" \| "brandSecondary" | "brand" | Color palette. | | tail | boolean | false | Show connecting lines (simple variant). | | onClick | StepClickType | - | Step click handler. | | aria-label | string | - | Accessible label for stepper. |

StepType:

interface StepType {
  title: string | ReactElement;
  description?: string | ReactElement;
  state?: "current" | "incomplete" | "loading" | "complete" | "alert" | "warning";
  disabled?: boolean;
  key?: string;
  noClick?: boolean;
}

StepClickType:

type StepClickType = ({ number, step }: { number: number; step: StepType }) => void;

Step States

| State | Description | | :---- | :---------- | | current | Active step, highlighted with brand color | | complete | Finished step with checkmark | | incomplete | Future step, muted appearance | | loading | Step in progress with spinner | | alert | Error state with alert color | | warning | Warning state with warning color |

UI Variants

| Variant | Description | | :------ | :---------- | | current | Traditional stepper with step indicators and border line | | simple | Minimalist stepper with optional connecting tail |

Accessibility

  • Stepper uses role="navigation" for semantic meaning
  • Each step is keyboard accessible when clickable
  • aria-label provides context for screen readers
  • Step states are conveyed through visual and accessible means
  • Disabled steps are properly announced