29 lines
2.9 KiB
JSON
29 lines
2.9 KiB
JSON
{
|
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
"name": "paintbrush-icon",
|
|
"type": "registry:ui",
|
|
"title": "Paintbrush Icon",
|
|
"description": "Paintbrush icon component.",
|
|
"dependencies": [
|
|
"motion"
|
|
],
|
|
"files": [
|
|
{
|
|
"path": "registry/icons/paintbrush/index.tsx",
|
|
"content": "'use client';\n\nimport * as React from 'react';\nimport { motion, type Variants } from 'motion/react';\n\nimport {\n getVariants,\n useAnimateIconContext,\n IconWrapper,\n type IconProps,\n} from '@/components/animate-ui/icons/icon';\n\ntype PaintbrushProps = IconProps<keyof typeof animations>;\n\nconst animations = {\n default: {\n group: {\n initial: {\n rotate: 0,\n transition: { duration: 0.6, ease: 'easeInOut' },\n },\n animate: {\n rotate: [0, -6, 6, 0],\n transformOrigin: 'top right',\n transition: { duration: 0.6, ease: 'easeInOut' },\n },\n },\n path1: {},\n path2: {},\n path3: {},\n } satisfies Record<string, Variants>,\n} as const;\n\nfunction IconComponent({ size, ...props }: PaintbrushProps) {\n const { controls } = useAnimateIconContext();\n const variants = getVariants(animations);\n\n return (\n <motion.svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width={size}\n height={size}\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth={2}\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n variants={variants.group}\n initial=\"initial\"\n animate={controls}\n {...props}\n >\n <motion.path\n d=\"m14.622 17.897-10.68-2.913\"\n variants={variants.path1}\n initial=\"initial\"\n animate={controls}\n />\n <motion.path\n d=\"M18.376 2.622a1 1 0 1 1 3.002 3.002L17.36 9.643a.5.5 0 0 0 0 .707l.944.944a2.41 2.41 0 0 1 0 3.408l-.944.944a.5.5 0 0 1-.707 0L8.354 7.348a.5.5 0 0 1 0-.707l.944-.944a2.41 2.41 0 0 1 3.408 0l.944.944a.5.5 0 0 0 .707 0z\"\n variants={variants.path2}\n initial=\"initial\"\n animate={controls}\n />\n <motion.path\n d=\"M9 8c-1.804 2.71-3.97 3.46-6.583 3.948a.507.507 0 0 0-.302.819l7.32 8.883a1 1 0 0 0 1.185.204C12.735 20.405 16 16.792 16 15\"\n variants={variants.path3}\n initial=\"initial\"\n animate={controls}\n />\n </motion.svg>\n );\n}\n\nfunction Paintbrush(props: PaintbrushProps) {\n return <IconWrapper icon={IconComponent} {...props} />;\n}\n\nexport {\n animations,\n Paintbrush,\n Paintbrush as PaintbrushIcon,\n type PaintbrushProps,\n type PaintbrushProps as PaintbrushIconProps,\n};\n",
|
|
"type": "registry:ui",
|
|
"target": "components/animate-ui/icons/paintbrush.tsx"
|
|
}
|
|
],
|
|
"meta": {
|
|
"keywords": [
|
|
"brush",
|
|
"paintbrush",
|
|
"design",
|
|
"color",
|
|
"colour",
|
|
"decoration",
|
|
"diy"
|
|
]
|
|
}
|
|
} |