Production-ready animations, transitions, backgrounds, and scenes for Remotion
TypeScript ai-agentsclaude-codedemo-videomcpmcp-servermodel-context-protocolmotion-designproduct-demoreactremotionshadcnvideo
feat: icon bookmark
dev_wandry530a747345ea
diff --git a/components/docs/icons-gallery.tsx b/components/docs/icons-gallery.tsxindex de86b70d..7efe0261 100644--- a/components/docs/icons-gallery.tsx+++ b/components/docs/icons-gallery.tsx@@ -14,6 +14,7 @@ import { ArrowLeftIconStatic } from "@/registry/remocn/icon-arrow-left";import { ArrowRightIconStatic } from "@/registry/remocn/icon-arrow-right";import { ArrowUpIconStatic } from "@/registry/remocn/icon-arrow-up";import { BellIconStatic } from "@/registry/remocn/icon-bell";+import { BookmarkIconStatic } from "@/registry/remocn/icon-bookmark";import { CameraIconStatic } from "@/registry/remocn/icon-camera";import { CheckCircleIconStatic } from "@/registry/remocn/icon-check-circle";import { CheckIconStatic } from "@/registry/remocn/icon-check";@@ -248,6 +249,12 @@ export const ICONS: IconEntry[] = [category: "Actions & UI",Static: LinkIconStatic,},+ {+ name: "icon-bookmark",+ label: "Bookmark",+ category: "Actions & UI",+ Static: BookmarkIconStatic,+ },{name: "icon-play",label: "Play",diff --git a/registry/__index__.tsx b/registry/__index__.tsxindex da7eb7dc..7b23cf67 100644--- a/registry/__index__.tsx+++ b/registry/__index__.tsx@@ -30,6 +30,7 @@ import { iconArrowLeftConfig } from "@/registry/remocn/icon-arrow-left/config";import { iconArrowRightConfig } from "@/registry/remocn/icon-arrow-right/config";import { iconArrowUpConfig } from "@/registry/remocn/icon-arrow-up/config";import { iconBellConfig } from "@/registry/remocn/icon-bell/config";+import { iconBookmarkConfig } from "@/registry/remocn/icon-bookmark/config";import { iconCameraConfig } from "@/registry/remocn/icon-camera/config";import { iconCheckCircleConfig } from "@/registry/remocn/icon-check-circle/config";import { iconCheckConfig } from "@/registry/remocn/icon-check/config";@@ -651,6 +652,13 @@ const registry: Record<string, RegistryEntry> = {})),config: iconBellConfig,},+ "icon-bookmark": {+ load: () =>+ import("@/registry/remocn/icon-bookmark").then((m) => ({+ default: m.BookmarkIcon,+ })),+ config: iconBookmarkConfig,+ },"icon-camera": {load: () =>import("@/registry/remocn/icon-camera").then((m) => ({diff --git a/registry/remocn/icon-bookmark/config.ts b/registry/remocn/icon-bookmark/config.tsnew file mode 100644index 00000000..57482c46--- /dev/null+++ b/registry/remocn/icon-bookmark/config.ts@@ -0,0 +1,44 @@+import { type ComponentConfig, FPS } from "@/lib/customizer-config";++export const iconBookmarkConfig: ComponentConfig = {+ componentName: "BookmarkIcon",+ importPath: "@/components/remocn/icon-bookmark",+ 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-bookmark/index.tsx b/registry/remocn/icon-bookmark/index.tsxnew file mode 100644index 00000000..277e4887--- /dev/null+++ b/registry/remocn/icon-bookmark/index.tsx@@ -0,0 +1,106 @@+"use client";++import { Easing, interpolate } from "remotion";+import {+ drawnPathProps,+ type IconAnimationProps,+ useIconAnimation,+} from "@/lib/remocn-icons";++const BOOKMARK_PATH =+ "M17 3a2 2 0 0 1 2 2v15a1 1 0 0 1-1.496.868l-4.512-2.578a2 2 0 0 0-1.984 0l-4.512 2.578A1 1 0 0 1 5 20V5a2 2 0 0 1 2-2z";++const TIMINGS = {+ drawDurationInFrames: 14,+ actionDelayInFrames: 2,+ actionDurationInFrames: 20,+ loop: false,+} as const;++export function BookmarkIcon({+ 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 drop = acting+ ? interpolate(actionProgress, [0, 0.4, 0.6, 1], [-3, 0.5, -0.2, 0], {+ extrapolateLeft: "clamp",+ extrapolateRight: "clamp",+ easing: Easing.inOut(Easing.quad),+ })+ : 0;+ const tilt = acting+ ? interpolate(actionProgress, [0, 0.35, 0.7], [0, -6, 0], {+ extrapolateLeft: "clamp",+ extrapolateRight: "clamp",+ easing: Easing.inOut(Easing.quad),+ })+ : 0;++ const dash = drawnPathProps(BOOKMARK_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(${tilt} 12 3) translate(0 ${drop})`}>+ <path+ d={BOOKMARK_PATH}+ strokeDasharray={dash.strokeDasharray}+ strokeDashoffset={dash.strokeDashoffset}+ />+ </g>+ </svg>+ );+}++export function BookmarkIconStatic({+ 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={BOOKMARK_PATH} />+ </svg>+ );+}diff --git a/registry/remocn/registry.json b/registry/remocn/registry.jsonindex 2cebe211..da53ca99 100644--- a/registry/remocn/registry.json+++ b/registry/remocn/registry.json@@ -2074,6 +2074,21 @@}]},+ {+ "name": "icon-bookmark",+ "type": "registry:component",+ "title": "Bookmark",+ "description": "Animated Lucide bookmark icon — draws on, then drops into place from above with a spring landing.",+ "dependencies": ["remotion"],+ "registryDependencies": ["@remocn/icons-core"],+ "files": [+ {+ "path": "icon-bookmark/index.tsx",+ "type": "registry:component",+ "target": "components/remocn/icon-bookmark.tsx"+ }+ ]+ },{"name": "icon-sparkles","type": "registry:component",