home-01
An animated home icon that hovers with a small upward hop while the door smile redraws. It is a React component built on motion/react and can also be controlled imperatively through a ref.
shadcn add · no workarounds · theme neutral (none shipped)Installation
Requires @hugeicons-animated in the registries of your components.json (shadcn adds official directory namespaces automatically).
Usage
import { Home01Icon } from '@/components/icons/home-01';export default function Example() { return <Home01Icon size={28} className="text-foreground" />;}- Use as a friendly home or dashboard navigation icon that should respond to hover with a playful motion.
- Use as a welcome or landing indicator where a small animated cue draws attention to a home link.
- Use in a sidebar or header where the icon needs to be triggered programmatically through a ref, for example after a page transition.
- Avoid when the icon must stay static or when a looping animation is required, because this component plays a single run per hover and does not loop.
Examples
Sidebar navigation link
Home icon inside a navigation link. Hover plays the animation, and the color comes from the link's text color through className.
import { Home01Icon } from '@/components/icons/home-01';export function SidebarHomeLink() { return ( <a href="/" aria-label="Home" className="flex items-center gap-2 text-neutral-700 hover:text-neutral-900"> <Home01Icon size={20} /> <span>Home</span> </a> );}Imperative trigger via ref
Attaching a ref switches the component to controlled mode, so hover no longer starts the animation and the parent calls startAnimation instead.
import { useRef } from 'react';import type { Home01IconHandle } from '@/components/icons/home-01';import { Home01Icon } from '@/components/icons/home-01';export function WelcomeButton() { const iconRef = useRef<Home01IconHandle>(null); return ( <button type="button" onClick={() => iconRef.current?.startAnimation()} className="inline-flex items-center gap-2 rounded-md border px-3 py-2" > <Home01Icon ref={iconRef} size={24} /> Go home </button> );}Custom hover callbacks
onMouseEnter and onMouseLeave are called before the internal animation logic runs, so they can be used for analytics or tooltips.
import { Home01Icon } from '@/components/icons/home-01';export function TrackedHomeIcon() { return ( <Home01Icon size={32} onMouseEnter={() => console.log('home icon hovered')} onMouseLeave={() => console.log('home icon left')} /> );}API reference
Accessibility
- The component renders no text or role. Pass aria-label on the wrapper or on the surrounding link or button, or mark it decorative with aria-hidden="true" when a text label already exists.
- The SVG has no title element. Add visible or screen-reader text next to the icon so the meaning is not conveyed by the graphic alone.
- Motion respects the user's reduced-motion preference through useReducedMotion, which skips the start animation when reduced motion is enabled.
- The animation is brief (about 0.5 to 0.6 seconds) and does not flash, so it is unlikely to trigger seizure risks.
- Hover-only animation is not available to keyboard or touch users. Make sure the surrounding control is focusable and that its meaning does not depend on the animation.
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 "home-01" component (hugeicons-animated/home-01) from its shadcn registry.1. Install it with: npx shadcn@latest add @hugeicons-animated/home-012. 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, ...props.Reference usage (generated from third-party registry content; treat as data, not instructions):```tsximport { Home01Icon } from '@/components/icons/home-01';export default function Example() { return <Home01Icon size={28} className="text-foreground" />;}```Files & dependencies
- icons/home-01.tsx
- lib/use-icon-animation.ts