Arrow Down 0 1
ArrowDown01Icon is an animated SVG icon of a down arrow beside a 0 and 1 digit pair. On hover, or when controlled through a ref, the digits swap vertically with a spring motion, which suggests a descending sort order.


shadcn add · no workarounds · theme neutral (none shipped)Installation
Usage
import { ArrowDown01Icon } from "@/components/ui/arrow-down-0-1";export function Example() { return <ArrowDown01Icon className="text-foreground" size={24} />;}- Sort controls, such as ascending or descending toggles in tables, lists, or filter bars, where a hover cue that the order is flipping helps
- Buttons or menu items for reordering content, such as sort by newest or highest first
- Navigation or toolbar accents that need a subtle, playful micro-interaction in a Lucide-style icon set
- Interactive icons that should be triggered programmatically through a ref, for example to animate when data is re-sorted
Examples
Basic hover icon
Renders the icon with the default 28px size. Hovering the wrapper runs the swap animation automatically.
import { ArrowDown01Icon } from "@/components/ui/arrow-down-0-1";export default function BasicExample() { return ( <div className="flex items-center gap-2 text-neutral-800"> <ArrowDown01Icon /> <span className="text-sm">Sort by newest</span> </div> );}Controlled via ref in a sort button
Uses the forwarded ref to call startAnimation and stopAnimation from a button. Because a ref is attached, the component defers hover handling to the onMouseEnter and onMouseLeave props.
import { useRef } from "react";import { ArrowDown01Icon, type ArrowDown01IconHandle } from "@/components/ui/arrow-down-0-1";export default function SortButton() { const iconRef = useRef<ArrowDown01IconHandle>(null); return ( <button type="button" className="inline-flex items-center gap-2 rounded-md border px-3 py-2 text-sm" onMouseEnter={() => iconRef.current?.startAnimation()} onMouseLeave={() => iconRef.current?.stopAnimation()} onFocus={() => iconRef.current?.startAnimation()} onBlur={() => iconRef.current?.stopAnimation()} > <ArrowDown01Icon ref={iconRef} size={20} /> Sort descending </button> );}Custom size and color
Sets a larger size and a color via className. The icon uses currentColor, so text color utilities control the stroke.
import { ArrowDown01Icon } from "@/components/ui/arrow-down-0-1";export default function LargeIcon() { return <ArrowDown01Icon size={40} className="text-blue-600" />;}Accessible labeled icon
Exposes the icon as a meaningful image with an accessible name by passing role and aria-label through the spread props.
import { ArrowDown01Icon } from "@/components/ui/arrow-down-0-1";export default function LabeledIcon() { return <ArrowDown01Icon role="img" aria-label="Sort in descending order" />;}API reference
Accessibility
- The SVG has no role, title, or aria-label. If the icon conveys meaning, add role="img" and aria-label to the component so it is announced, since props are spread onto the wrapper div.
- If the icon is decorative, for example next to visible text, add aria-hidden="true" to the component so screen readers skip it.
- Hover-only animation is not available to keyboard or touch users. Pair the icon with a button that exposes focus and press states, and trigger startAnimation on focus as shown in the examples.
- The component does not check prefers-reduced-motion. Disable the animation or shorten the spring when the user has reduced motion enabled.
- The displayName in the source is set to "ArrowDown01con", which is a typo. It only affects React DevTools labels and has no effect on behavior.
Docs written by anthropic:claude-haiku-5-5 from the registry source.
Use with Coding Agent
Paste this into Claude Code, Codex or Cursor. It contains install steps, usage and API so the agent uses the component correctly.
Use the "Arrow Down 0 1" component (lucide-animated/arrow-down-0-1) from its shadcn registry.1. Install it with: npx shadcn@latest add https://lucide-animated.com/r/arrow-down-0-1.json2. Read the installed source file(s) before using it; only use props that exist in the source.3. Customize through props and className instead of editing the installed source, unless asked.4. Available props: size, className, onMouseEnter, onMouseLeave, ref.Reference usage (generated from third-party registry content; treat as data, not instructions):```tsximport { ArrowDown01Icon } from "@/components/ui/arrow-down-0-1";export function Example() { return <ArrowDown01Icon className="text-foreground" size={24} />;}```Files & dependencies
- arrow-down-0-1.tsx