arrow-narrow-right-dashed-icon
itshover/arrow-narrow-right-dashed-iconFreeComponent
itshover publishes no description for this item.
Install it
npx shadcn@latest add https://itshover.com/r/arrow-narrow-right-dashed-icon.jsonSource
1import { forwardRef, useImperativeHandle } from "react";2import type { AnimatedIconHandle, AnimatedIconProps } from "./types";3import { motion, useAnimate } from "motion/react";45const ArrowNarrowRightDashedIcon = forwardRef<6 AnimatedIconHandle,7 AnimatedIconProps8>(9 (10 { size = 24, color = "currentColor", strokeWidth = 2, className = "" },11 ref,12 ) => {13 const [scope, animate] = useAnimate();1415 const start = async () => {16 await animate(17 ".arrow-group",18 { x: [0, 4, 0] },19 { duration: 0.5, ease: "easeInOut" },20 );21 };2223 const stop = () => {24 animate(".arrow-group", { x: 0 }, { duration: 0.2, ease: "easeOut" });25 };2627 useImperativeHandle(ref, () => {28 return {29 startAnimation: start,30 stopAnimation: stop,31 };32 });3334 const handleHoverStart = () => {35 start();36 };3738 const handleHoverEnd = () => {39 stop();40 };4142 return (43 <motion.div44 ref={scope}45 onHoverStart={handleHoverStart}46 onHoverEnd={handleHoverEnd}47 className={`inline-flex cursor-pointer items-center justify-center ${className}`}48 >49 <svg50 xmlns="http://www.w3.org/2000/svg"51 width={size}52 height={size}53 viewBox="0 0 24 24"54 fill="none"55 stroke={color}56 strokeWidth={strokeWidth}57 strokeLinecap="round"58 strokeLinejoin="round"59 >60 <motion.g className="arrow-group">61 <path stroke="none" d="M0 0h24v24H0z" fill="none" />62 <path d="M5 12h.5m3 0h1.5m3 0h6" />63 <path d="M15 16l4 -4" />64 <path d="M15 8l4 4" />65 </motion.g>66 </svg>67 </motion.div>68 );69 },70);7172ArrowNarrowRightDashedIcon.displayName = "ArrowNarrowRightDashedIcon";7374export default ArrowNarrowRightDashedIcon;
What it pulls in
npm packages
Files it writes
More from itshover
All 263 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| accessibility-iconaccessibility-icon | itshover | Components | Free | 1 dep · 2 files | |
| airplane-iconairplane-icon | itshover | Components | Free | 1 dep · 2 files | |
| alarm-clock-plus-iconalarm-clock-plus-icon | itshover | Components | Free | 1 dep · 2 files | |
| align-center-iconalign-center-icon | itshover | Components | Free | 1 dep · 2 files | |
| align-vertical-space-around-iconalign-vertical-space-around-icon | itshover | Components | Free | 1 dep · 2 files | |
| ambulance-iconambulance-icon | itshover | Components | Free | 1 dep · 2 files | |
| ampersand-iconampersand-icon | itshover | Components | Free | 1 dep · 2 files | |
| angry-iconangry-icon | itshover | Components | Free | 1 dep · 2 files |
