Production-ready animations, transitions, backgrounds, and scenes for Remotion
TypeScript ai-agentsclaude-codedemo-videomcpmcp-servermodel-context-protocolmotion-designproduct-demoreactremotionshadcnvideo
feat: icon folder
dev_wandry0ef18120056a
diff --git a/components/docs/icons-gallery.tsx b/components/docs/icons-gallery.tsxindex f194b735..caea443c 100644--- a/components/docs/icons-gallery.tsx+++ b/components/docs/icons-gallery.tsx@@ -32,6 +32,7 @@ import { EyeOffIconStatic } from "@/registry/remocn/icon-eye-off";import { EyeIconStatic } from "@/registry/remocn/icon-eye";import { FilterIconStatic } from "@/registry/remocn/icon-filter";import { FlameIconStatic } from "@/registry/remocn/icon-flame";+import { FolderIconStatic } from "@/registry/remocn/icon-folder";import { HeartIconStatic } from "@/registry/remocn/icon-heart";import { HelpCircleIconStatic } from "@/registry/remocn/icon-help-circle";import { HomeIconStatic } from "@/registry/remocn/icon-home";@@ -196,6 +197,12 @@ export const ICONS: IconEntry[] = [category: "Files & dev",Static: HomeIconStatic,},+ {+ name: "icon-folder",+ label: "Folder",+ category: "Files & dev",+ Static: FolderIconStatic,+ },{name: "icon-search",label: "Search",diff --git a/registry/__index__.tsx b/registry/__index__.tsxindex 561ad5d6..4dc180fc 100644--- a/registry/__index__.tsx+++ b/registry/__index__.tsx@@ -48,6 +48,7 @@ import { iconEyeOffConfig } from "@/registry/remocn/icon-eye-off/config";import { iconEyeConfig } from "@/registry/remocn/icon-eye/config";import { iconFilterConfig } from "@/registry/remocn/icon-filter/config";import { iconFlameConfig } from "@/registry/remocn/icon-flame/config";+import { iconFolderConfig } from "@/registry/remocn/icon-folder/config";import { iconHeartConfig } from "@/registry/remocn/icon-heart/config";import { iconHelpCircleConfig } from "@/registry/remocn/icon-help-circle/config";import { iconHomeConfig } from "@/registry/remocn/icon-home/config";@@ -790,6 +791,13 @@ const registry: Record<string, RegistryEntry> = {})),config: iconFlameConfig,},+ "icon-folder": {+ load: () =>+ import("@/registry/remocn/icon-folder").then((m) => ({+ default: m.FolderIcon,+ })),+ config: iconFolderConfig,+ },"icon-heart": {load: () =>import("@/registry/remocn/icon-heart").then((m) => ({diff --git a/registry/remocn/icon-folder/config.ts b/registry/remocn/icon-folder/config.tsnew file mode 100644index 00000000..1390d8a8--- /dev/null+++ b/registry/remocn/icon-folder/config.ts@@ -0,0 +1,44 @@+import { type ComponentConfig, FPS } from "@/lib/customizer-config";++export const iconFolderConfig: ComponentConfig = {+ componentName: "FolderIcon",+ importPath: "@/components/remocn/icon-folder",+ controls: {+ animation: {+ type: "select",+ default: "both",+ options: ["draw", "action", "both"],+ label: "Animation",+ },+ loop: {+ type: "boolean",+ default: false,+ label: "Loop",+ },+ size: {+ type: "number",+ default: 48,+ min: 24,+ max: 200,+ step: 4,+ label: "Size",+ },+ color: {+ type: "color",+ default: "#171717",+ label: "Color",+ },+ strokeWidth: {+ type: "number",+ default: 2,+ min: 1,+ max: 3,+ step: 0.25,+ label: "Stroke width",+ },+ },+ durationInFrames: 70,+ fps: FPS,+ compositionWidth: 48,+ compositionHeight: 48,+};diff --git a/registry/remocn/icon-folder/index.tsx b/registry/remocn/icon-folder/index.tsxnew file mode 100644index 00000000..47f5739d--- /dev/null+++ b/registry/remocn/icon-folder/index.tsx@@ -0,0 +1,103 @@+"use client";++import { Easing, interpolate } from "remotion";+import {+ drawnPathProps,+ type IconAnimationProps,+ useIconAnimation,+} from "@/lib/remocn-icons";++const FOLDER_PATH =+ "M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z";++const PIVOT_X = 4;+const PIVOT_Y = 20;++const TIMINGS = {+ drawDurationInFrames: 14,+ actionDelayInFrames: 2,+ actionDurationInFrames: 20,+ loop: false,+} as const;++export function FolderIcon({+ animation = "both",+ loop,+ speed,+ size = 48,+ color = "currentColor",+ strokeWidth = 2,+ className,+}: IconAnimationProps) {+ const { drawProgress, scaleIn, actionProgress, actionFrame } =+ useIconAnimation({ animation, loop, speed }, TIMINGS);++ const acting = animation !== "draw" && actionFrame >= 0;++ const peek = acting+ ? interpolate(actionProgress, [0, 0.45, 1], [0, -4, 0], {+ extrapolateLeft: "clamp",+ extrapolateRight: "clamp",+ easing: Easing.inOut(Easing.quad),+ })+ : 0;++ const folder = drawnPathProps(FOLDER_PATH, drawProgress);++ const scale = 0.85 + 0.15 * scaleIn;++ return (+ <svg+ className={className}+ width={size}+ height={size}+ viewBox="0 0 24 24"+ fill="none"+ stroke={color}+ strokeWidth={strokeWidth}+ strokeLinecap="round"+ strokeLinejoin="round"+ style={{+ overflow: "visible",+ transformOrigin: "center",+ transform: `scale(${scale})`,+ }}+ >+ <g transform={`rotate(${peek} ${PIVOT_X} ${PIVOT_Y})`}>+ <path+ d={FOLDER_PATH}+ strokeDasharray={folder.strokeDasharray}+ strokeDashoffset={folder.strokeDashoffset}+ />+ </g>+ </svg>+ );+}++export function FolderIconStatic({+ size = 48,+ color = "currentColor",+ strokeWidth = 2,+ className,+}: {+ size?: number;+ color?: string;+ strokeWidth?: number;+ className?: string;+}) {+ return (+ <svg+ className={className}+ width={size}+ height={size}+ viewBox="0 0 24 24"+ fill="none"+ stroke={color}+ strokeWidth={strokeWidth}+ strokeLinecap="round"+ strokeLinejoin="round"+ >+ <path d={FOLDER_PATH} />+ </svg>+ );+}diff --git a/registry/remocn/registry.json b/registry/remocn/registry.jsonindex bde7ccd6..6a7dc251 100644--- a/registry/remocn/registry.json+++ b/registry/remocn/registry.json@@ -2329,6 +2329,21 @@}]},+ {+ "name": "icon-folder",+ "type": "registry:component",+ "title": "Folder",+ "description": "Animated Lucide folder icon — draws on, then the folder tips open for a peek and closes.",+ "dependencies": ["remotion"],+ "registryDependencies": ["@remocn/icons-core"],+ "files": [+ {+ "path": "icon-folder/index.tsx",+ "type": "registry:component",+ "target": "components/remocn/icon-folder.tsx"+ }+ ]+ },{"name": "icon-user","type": "registry:component",