Skip to content

Production-ready animations, transitions, backgrounds, and scenes for Remotion

feat: icon monitor

dev_wandryc37ed6dedf0a
diff --git a/components/docs/icons-gallery.tsx b/components/docs/icons-gallery.tsx
index bbeadca6..b57e7b5f 100644
--- a/components/docs/icons-gallery.tsx
+++ b/components/docs/icons-gallery.tsx
@@ -55,6 +55,7 @@ import { MaximizeIconStatic } from "@/registry/remocn/icon-maximize";
import { MenuIconStatic } from "@/registry/remocn/icon-menu";
import { MessageCircleIconStatic } from "@/registry/remocn/icon-message-circle";
import { MicIconStatic } from "@/registry/remocn/icon-mic";
+import { MonitorIconStatic } from "@/registry/remocn/icon-monitor";
import { MoreHorizontalIconStatic } from "@/registry/remocn/icon-more-horizontal";
import { PartyPopperIconStatic } from "@/registry/remocn/icon-party-popper";
import { PauseIconStatic } from "@/registry/remocn/icon-pause";
@@ -245,6 +246,12 @@ export const ICONS: IconEntry[] = [
category: "Files & dev",
Static: GlobeIconStatic,
},
+ {
+ name: "icon-monitor",
+ label: "Monitor",
+ category: "Devices & theme",
+ Static: MonitorIconStatic,
+ },
{
name: "icon-search",
label: "Search",
diff --git a/registry/__index__.tsx b/registry/__index__.tsx
index bd98c754..22ca5ef2 100644
--- a/registry/__index__.tsx
+++ b/registry/__index__.tsx
@@ -71,6 +71,7 @@ import { iconMaximizeConfig } from "@/registry/remocn/icon-maximize/config";
import { iconMenuConfig } from "@/registry/remocn/icon-menu/config";
import { iconMessageCircleConfig } from "@/registry/remocn/icon-message-circle/config";
import { iconMicConfig } from "@/registry/remocn/icon-mic/config";
+import { iconMonitorConfig } from "@/registry/remocn/icon-monitor/config";
import { iconMoreHorizontalConfig } from "@/registry/remocn/icon-more-horizontal/config";
import { iconPartyPopperConfig } from "@/registry/remocn/icon-party-popper/config";
import { iconPauseConfig } from "@/registry/remocn/icon-pause/config";
@@ -958,6 +959,13 @@ const registry: Record<string, RegistryEntry> = {
})),
config: iconMicConfig,
},
+ "icon-monitor": {
+ load: () =>
+ import("@/registry/remocn/icon-monitor").then((m) => ({
+ default: m.MonitorIcon,
+ })),
+ config: iconMonitorConfig,
+ },
"icon-more-horizontal": {
load: () =>
import("@/registry/remocn/icon-more-horizontal").then((m) => ({
diff --git a/registry/remocn/icon-monitor/config.ts b/registry/remocn/icon-monitor/config.ts
new file mode 100644
index 00000000..e3f9fd89
--- /dev/null
+++ b/registry/remocn/icon-monitor/config.ts
@@ -0,0 +1,44 @@
+import { type ComponentConfig, FPS } from "@/lib/customizer-config";
+
+export const iconMonitorConfig: ComponentConfig = {
+ componentName: "MonitorIcon",
+ importPath: "@/components/remocn/icon-monitor",
+ 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: 75,
+ fps: FPS,
+ compositionWidth: 48,
+ compositionHeight: 48,
+};
diff --git a/registry/remocn/icon-monitor/index.tsx b/registry/remocn/icon-monitor/index.tsx
new file mode 100644
index 00000000..fef329cf
--- /dev/null
+++ b/registry/remocn/icon-monitor/index.tsx
@@ -0,0 +1,138 @@
+"use client";
+
+import { Easing, interpolate } from "remotion";
+import {
+ drawnPathProps,
+ type IconAnimationProps,
+ useIconAnimation,
+} from "@/lib/remocn-icons";
+
+const SCREEN_PATH =
+ "M4 3H20A2 2 0 0 1 22 5V15A2 2 0 0 1 20 17H4A2 2 0 0 1 2 15V5A2 2 0 0 1 4 3Z";
+const BASE_PATH = "M8 21H16";
+const NECK_PATH = "M12 17V21";
+
+const SCREEN_CY = 10;
+
+const TIMINGS = {
+ drawDurationInFrames: 16,
+ actionDelayInFrames: 2,
+ actionDurationInFrames: 18,
+ loop: false,
+} as const;
+
+export function MonitorIcon({
+ animation = "both",
+ loop,
+ speed,
+ size = 48,
+ color = "currentColor",
+ strokeWidth = 2,
+ className,
+}: IconAnimationProps) {
+ const { drawProgress, scaleIn, actionProgress, actionFrame } =
+ useIconAnimation({ animation, loop, speed }, TIMINGS);
+
+ const linearDraw = 1 - (1 - drawProgress) ** (1 / 3);
+ const acting = animation !== "draw" && actionFrame >= 0;
+
+ const standDraw = interpolate(linearDraw, [0, 0.5], [0, 1], {
+ extrapolateLeft: "clamp",
+ extrapolateRight: "clamp",
+ easing: Easing.out(Easing.quad),
+ });
+ const screenDraw = interpolate(linearDraw, [0.35, 1], [0, 1], {
+ extrapolateLeft: "clamp",
+ extrapolateRight: "clamp",
+ easing: Easing.out(Easing.quad),
+ });
+
+ const screenYScale = acting
+ ? interpolate(actionProgress, [0, 0.45, 1], [0.92, 1.04, 1], {
+ extrapolateLeft: "clamp",
+ extrapolateRight: "clamp",
+ easing: Easing.out(Easing.quad),
+ })
+ : 1;
+ const pop = acting
+ ? interpolate(actionProgress, [0.5, 0.7, 1], [1, 1.02, 1], {
+ extrapolateLeft: "clamp",
+ extrapolateRight: "clamp",
+ easing: Easing.inOut(Easing.quad),
+ })
+ : 1;
+
+ const screen = drawnPathProps(SCREEN_PATH, acting ? 1 : screenDraw);
+ const base = drawnPathProps(BASE_PATH, acting ? 1 : standDraw);
+ const neck = drawnPathProps(NECK_PATH, acting ? 1 : standDraw);
+
+ const scale = (0.85 + 0.15 * scaleIn) * pop;
+ const screenTransform = `translate(0 ${SCREEN_CY * (1 - screenYScale)}) scale(1 ${screenYScale})`;
+
+ 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={screenTransform}>
+ <path
+ d={SCREEN_PATH}
+ strokeDasharray={screen.strokeDasharray}
+ strokeDashoffset={screen.strokeDashoffset}
+ />
+ </g>
+ <path
+ d={BASE_PATH}
+ strokeDasharray={base.strokeDasharray}
+ strokeDashoffset={base.strokeDashoffset}
+ />
+ <path
+ d={NECK_PATH}
+ strokeDasharray={neck.strokeDasharray}
+ strokeDashoffset={neck.strokeDashoffset}
+ />
+ </svg>
+ );
+}
+
+export function MonitorIconStatic({
+ 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"
+ >
+ <rect width="20" height="14" x="2" y="3" rx="2" />
+ <line x1="8" x2="16" y1="21" y2="21" />
+ <line x1="12" x2="12" y1="17" y2="21" />
+ </svg>
+ );
+}
diff --git a/registry/remocn/registry.json b/registry/remocn/registry.json
index d74d7e75..5284128d 100644
--- a/registry/remocn/registry.json
+++ b/registry/remocn/registry.json
@@ -2434,6 +2434,21 @@
}
]
},
+ {
+ "name": "icon-monitor",
+ "type": "registry:component",
+ "title": "Monitor",
+ "description": "Animated Lucide monitor icon — the stand draws, then the screen powers on with a CRT-style unsquash.",
+ "dependencies": ["remotion"],
+ "registryDependencies": ["@remocn/icons-core"],
+ "files": [
+ {
+ "path": "icon-monitor/index.tsx",
+ "type": "registry:component",
+ "target": "components/remocn/icon-monitor.tsx"
+ }
+ ]
+ },
{
"name": "icon-user",
"type": "registry:component",