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

@dax-ui/skeleton

v0.8.0

Published

dax-ui Skeleton: loading placeholders for text, avatars, cards and detail fields

Readme

@dax-ui/skeleton

Loading placeholders in the shape of the content to come: lines of text, circles, and (rounded) rectangles, with a pulse or wave animation. Ready-made compositions cover a paragraph, a read-only "label + value" field and an avatar beside text.

Installation

pnpm add @dax-ui/skeleton

MUI and Emotion are included; the app only needs React 18 or 19.

One-time setup per app (skip if the app already uses dax-ui): install @dax-ui/theme and wrap the app in its UIProvider.

pnpm add @dax-ui/theme

Usage

import { Skeleton, SkeletonAvatarRow, SkeletonField, SkeletonText } from '@dax-ui/skeleton';

// One line of text, as tall as the surrounding font
<Skeleton width={160} />

// Shapes
<Skeleton variant="circle" width={40} />
<Skeleton variant="rounded" width="100%" height={120} radius={16} />

// A paragraph: four lines, the last one 40% wide
<Skeleton lines={4} lastLineWidth="40%" />
<SkeletonText lines={3} fontSize={14} />

// Placeholders for a detail field and a comment
<SkeletonField />
<SkeletonAvatarRow lines={2} />

// Animation: pulse (default), wave or none
<Skeleton animation="wave" />

Skeletons are hidden from screen readers. Mark the region that is loading instead, e.g. <div aria-busy="true"> plus a visually hidden "Loading…" message.

Colors

colors takes base (the shape's fill) and highlight (the band that sweeps across with animation="wave"). The defaults follow light and dark mode. To recolor every skeleton inside an area, set the CSS variables on any ancestor:

<Skeleton colors={{ base: 'rgba(255, 255, 255, 0.2)' }} />

<div style={{ '--dax-skeleton-base': 'rgba(255, 255, 255, 0.2)' }}>…</div>

DEFAULT_SKELETON_COLORS and DEFAULT_SKELETON_DARK_COLORS hold the defaults.

Props

Skeleton

| Prop | Type | Default | Description | | --- | --- | --- | --- | | animation | "pulse" \| "wave" \| "none" | pulse | How the placeholder moves. Every animation stops for viewers who ask for reduced motion. | | className | string | | Class name on the root element. | | colors | Partial<SkeletonColors> | | Overrides the placeholder colors, e.g. { base: 'rgba(255, 255, 255, 0.2)' } on a dark background. Unset keys keep the defaults (which follow light and dark mode). | | height | string \| number | | Height: a number in px or any CSS length. Text lines take the height of the surrounding font; a circle with only a width is as tall as it is wide. | | lastLineWidth | string \| number | 60% | Width of the last of several lines. | | lineGap | string \| number | 6 | Space between lines, in px or any CSS length. | | lines | number | 1 | Number of text lines (with variant="text"). The last line is shorter (lastLineWidth), so the block reads as a paragraph. | | radius | string \| number | | Corner radius of rect and rounded shapes, in px or any CSS length. | | style | CSSProperties | | Inline styles on the root element. | | sx | SxProps<Theme> | | Style overrides on the root element. | | variant | "text" \| "circle" \| "rect" \| "rounded" | text | Shape of the placeholder. | | width | string \| number | | Width: a number in px or any CSS length, e.g. '60%'. Text lines fill their container by default. |

SkeletonText

| Prop | Type | Default | Description | | --- | --- | --- | --- | | animation | "pulse" \| "wave" \| "none" | pulse | How the placeholder moves. Every animation stops for viewers who ask for reduced motion. | | className | string | | Class name on the root element. | | colors | Partial<SkeletonColors> | | Overrides the placeholder colors, e.g. { base: 'rgba(255, 255, 255, 0.2)' } on a dark background. Unset keys keep the defaults (which follow light and dark mode). | | fontSize | string \| number | 16 | Font size the lines stand in for, which sets their height, in px or any CSS length. | | lastLineWidth | string \| number | 60% | Width of the last line. | | lineGap | string \| number | 6 | Space between lines, in px or any CSS length. | | lines | number | 3 | Number of lines. The last one is shorter. | | style | CSSProperties | | Inline styles on the root element. | | sx | SxProps<Theme> | | Style overrides on the root element. | | width | string \| number | 100% | Width of the whole block. |

SkeletonField

| Prop | Type | Default | Description | | --- | --- | --- | --- | | animation | "pulse" \| "wave" \| "none" | pulse | How the placeholder moves. Every animation stops for viewers who ask for reduced motion. | | className | string | | Class name on the root element. | | colors | Partial<SkeletonColors> | | Overrides the placeholder colors, e.g. { base: 'rgba(255, 255, 255, 0.2)' } on a dark background. Unset keys keep the defaults (which follow light and dark mode). | | icon | boolean | true | Shows a small square where the field's icon goes. | | labelWidth | string \| number | 88 | Width of the label line. | | orientation | "stacked" \| "inline" | stacked | stacked puts the value under the label; inline puts them side by side. | | size | "sm" \| "md" \| "lg" | md | Matches the sizes of @dax-ui/detail-field: sm, md or lg. | | style | CSSProperties | | Inline styles on the root element. | | sx | SxProps<Theme> | | Style overrides on the root element. | | valueLines | number | 1 | Number of value lines, for long values such as descriptions. | | valueWidth | string \| number | 65% | Width of the value line. |

SkeletonAvatarRow

| Prop | Type | Default | Description | | --- | --- | --- | --- | | animation | "pulse" \| "wave" \| "none" | pulse | How the placeholder moves. Every animation stops for viewers who ask for reduced motion. | | avatarSize | number | 40 | Avatar size in px. | | avatarVariant | "circle" \| "rounded" | circle | Avatar shape. | | className | string | | Class name on the root element. | | colors | Partial<SkeletonColors> | | Overrides the placeholder colors, e.g. { base: 'rgba(255, 255, 255, 0.2)' } on a dark background. Unset keys keep the defaults (which follow light and dark mode). | | lines | number | 2 | Number of text lines beside the avatar: a name, then shorter details. | | style | CSSProperties | | Inline styles on the root element. | | sx | SxProps<Theme> | | Style overrides on the root element. | | width | string \| number | 100% | Width of the text block. |