← Back

Rotate Counter Clockwise

Install

npm install @svg-animated-icons/react

CLI

Copy an icon component straight into your project — shadcn-style. Replace {icon} with an icon name like arrow-left.

terminal
npx @svg-animated-icons/cli add {icon} --react
FlagDescription
--dest <dir>Destination directory (default: components/animated-icons)

Or copy the component with the CLI

CLI
npx @svg-animated-icons/cli add rotate-counter-clockwise --react

Code

React
// Generated by @svg-animated-icons/cli
// You own this file — edit it freely.

import React from "react";

type Props = {
  disableHover?: boolean;
  className?: string;
};

export function RotateCounterClockwiseIcon({ disableHover, className }: Props) {
  const classes = [
    "ai-rotate-counter-clockwise-icon",
    disableHover ? "no-hover" : "",
    className ?? "",
  ]
    .filter(Boolean)
    .join(" ");

  return (
    <>
      <style>{`
.ai-rotate-counter-clockwise-icon {
  width: 1em;
  height: 1em;
  display: inline-block;
  cursor: pointer;
  overflow: visible;
}

.ai-rotate-counter-clockwise-icon * {
  transform-box: fill-box;
}

.ai-rotate-counter-clockwise-icon.no-hover * {
  transform: none;
  opacity: 1;
  animation: none;
}

.ai-rotate-counter-clockwise-icon .arrow {
  transform-box: view-box;
  transform-origin: 7.5px 7.5px;
}

.ai-rotate-counter-clockwise-icon:not(.no-hover):hover .arrow {
  animation: ai-rotate-counter-clockwise-spin 700ms linear;
}

@keyframes ai-rotate-counter-clockwise-spin {
  from { transform: rotate(0); }
  to { transform: rotate(-360deg); }
}
`}</style>
      <svg
        xmlns="http://www.w3.org/2000/svg"
        className={classes}
        viewBox="0 0 15 15"
        fill="none"
      >
        <path className="arrow" d="M9.65332 4.00808C10.4097 4.08488 11 4.72361 11 5.50027V12.5003L10.9922 12.6536C10.9205 13.3596 10.3593 13.9208 9.65332 13.9925L9.5 14.0003H2.5L2.34668 13.9925C1.64071 13.9208 1.07952 13.3596 1.00781 12.6536L1 12.5003V5.50027C1 4.72361 1.59028 4.08488 2.34668 4.00808L2.5 4.00027H9.5L9.65332 4.00808ZM2.5 5.00027C2.22386 5.00027 2 5.22413 2 5.50027V12.5003C2.00003 12.7764 2.22388 13.0003 2.5 13.0003H9.5C9.77612 13.0003 9.99997 12.7764 10 12.5003V5.50027C10 5.22413 9.77614 5.00027 9.5 5.00027H2.5ZM7.59668 0.0637466C7.76077 -0.0636113 7.99965 0.0533557 8 0.261012V1.00027L8.37988 1.00418C10.2476 1.04836 11.6658 1.43172 12.6172 2.38308C13.632 3.39793 14 4.94411 14 7.00027C14 7.27638 13.7761 7.50027 13.5 7.50027C13.2239 7.50027 13 7.27638 13 7.00027C13 5.01892 12.6359 3.81588 11.9102 3.09011C11.2297 2.40969 10.1298 2.04681 8.3623 2.00418L8 2.00027V2.73953C7.99971 2.94726 7.76079 3.06422 7.59668 2.93679L6.00391 1.69754C5.87524 1.59744 5.87523 1.40309 6.00391 1.303L7.59668 0.0637466Z" fill="currentColor"/>
      </svg>
    </>
  );
}