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

@qnkur/segmented

v0.1.1

Published

A React component for creating stunning, retro-style segmented displays. This package provides a flexible `<SegmentedDisplay>` component that leverages the [DSEG font family](https://github.com/keshikan/DSEG) by Keshikan.

Readme

@qnkur/segmented

A React component for creating stunning, retro-style segmented displays. This package provides a flexible <SegmentedDisplay> component that leverages the DSEG font family by Keshikan.

Docs & Live Demo

Features

  • Flexible Styling: Easily customize with Tailwind CSS or standard CSS classes.
  • Multiple Font Styles: Supports all 48 font variations from the DSEG font family.
  • 7 & 14 Segments: Includes both 7-segment and 14-segment font styles.
  • Realistic Effect: Renders "unlit" segments in the background for a more authentic display appearance.
  • TypeScript Support: Fully typed for a superior developer experience.

Prerequisites

This component is designed to be styled with utility classes. For the best experience, your project should be set up with Tailwind CSS.

Installation

To get started, install the component and its peer dependencies using your preferred package manager:

# pnpm
pnpm install @qnkur/segmented dseg

# npm
npm install @qnkur/segmented dseg

# yarn
yarn add @qnkur/segmented dseg

# bun
bun install @qnkur/segmented dseg

Usage

1. Configure Tailwind CSS

You need to add the path to the @qnkur/segmented package in your tailwind.config.js file. This allows Tailwind to discover the component's classes and include them in your final stylesheet.

// tailwind.config.js
module.exports = {
  content: [
    "./src/**/*.{js,ts,jsx,tsx}",
    // Add the path to the component library
    "./node_modules/@qnkur/segmented/dist/**/*.js",
  ],
  theme: {
    extend: {},
  },
  plugins: [],
}

2. Import CSS and Component

In your root layout or main application file (e.g., layout.tsx or App.tsx), import the dseg font styles. Then, import the component where you want to use it.

import { SegmentedDisplay } from "@qnkur/segmented"
import "dseg/css/dseg.css"

function MyComponent() {
  return <SegmentedDisplay>Hello World</SegmentedDisplay>
}

3. Advanced Usage

Combine props to create a more customized display. You can control the font family, weight, style, and more.

<SegmentedDisplay
  fontFamily="DSEG7Classic"
  fontWeight="bold"
  fontStyle="italic"
  unlitSegmentOpacity={10}
  className="text-2xl text-red-500"
>
  -45.6°C
</SegmentedDisplay>

Component Props

The <SegmentedDisplay> component accepts the following props:

| Prop | Type | Default | Description | | :-------------------- | :------------------------------ | :-------------------- | :------------------------------------------------------------------------------- | | children | React.ReactNode | Required | The content to display inside the component. | | fontFamily | FontName | 'DSEG14ClassicMini' | The DSEG font family to use. | | fontStyle | 'normal' \| 'italic' | 'normal' | The font style. | | fontWeight | 'light' \| 'normal' \| 'bold' | 'normal' | The font weight. | | className | string | undefined | Additional CSS classes for custom styling. | | unlitSegmentOpacity | number | 15 | The opacity of the unlit background segments (from 0 to 100). |

Acknowledgements

  • The DSEG fonts are created by keshikan and are licensed under the SIL Open Font License, Version 1.1.

License

This package is licensed under the MIT License.