maxmotion-edit

Activated when user message contains an <editor /> XML tag (injected by Max Client Video Editor). Guides how to edit Remotion project clips (maxmotion.json) and sequences (.tsx source code).

Safety Notice

This listing is imported from skills.sh public index metadata. Review upstream SKILL.md and repository scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "maxmotion-edit" with this command: npx skills add maxgent-ai/maxgent-plugin/maxgent-ai-maxgent-plugin-maxmotion-edit

Maxmotion Video Editor Skill

The user's message contains an <editor /> tag with project path and selected element.

Context Format

<editor project="<path>" type="<type>" id="<id>" name="<name>" frame="<from>-<end>" />

Core Rule: Code First, JSON for Simple Edits

TaskApproach
Create new content (new video segment, composition, animation)Write Remotion code in <project>/src/*.tsx
Modify existing clip properties (color, text, animation)Edit <project>/maxmotion.json
Modify existing sequence content/logicEdit <project>/src/*.tsx source code

Never hand-write large maxmotion.json from scratch. JSON clips are for simple overlay elements (solid rects, text labels). Creative content should be Remotion components in code.

Routing (for existing elements)

Selected TypeHow to Operate
solid, text, image, video, audio, componentEdit <project>/maxmotion.json
sequenceEdit <project>/src/*.tsx source code

Operations

OperationClip (JSON)Sequence (Code)
AddCreate clip, append to tracks[].clips[]Add <Sequence> in .tsx
UpdateFind by id, modify fieldsFind <Sequence name="">, modify code
DeleteRemove from tracks[].clips[]Remove <Sequence> block

AI vs UI Boundary

AI handles — content, color, animation, code logic, batch operations, add/delete elements, create new compositions

User handles in Editor UI — timing (drag timeline), position (drag canvas), resize, opacity

If the user asks to move/resize/adjust timing, reply suggesting they do it in the Editor UI. Match the user's language (Chinese/English).

JSON Schema (maxmotion.json)

{
  "schemaVersion": 4,
  "timelines": {
    "<compositionId>": {
      "tracks": [{
        "id": "track_xxx",
        "name": "Text",
        "visible": true, "locked": false, "muted": false,
        "clips": [{
          "id": "clip_xxx",
          "timing": { "from": 0, "duration": 150 },
          "content": { "type": "solid", "color": "#3b82f6" },
          "style": { "x": 100, "y": 100, "width": 200, "height": 200 },
          "animation": { "fadeIn": 15, "fadeOut": 15 }
        }]
      }],
      "sequenceOverrides": []
    }
  },
  "assets": {
    "<assetId>": {
      "id": "<assetId>",
      "type": "image",
      "filename": "original-name.png",
      "url": "stored-filename-in-public.png"
    }
  }
}

Clip Fields

fieldtyperequireddescription
idstringyesUnique ID: clip_<base36-timestamp>_<random6>
timingobjectyes{ from: number, duration: number } (frames, NOT flat)
contentobjectyesSee Content Types below
styleobjectyesSee Clip Style below
animationobjectnoSee Clip Animation below

Important: from and duration must be nested inside timing, not flat on the clip object. Flat from/duration will crash the renderer.

Clip Content Types

typefields
solidcolor
texttext, fontSize, color, fontFamily?, align?
imageassetId
videoassetId, playbackRate?, volume?
audioassetId, volume?
componentcomponentId, props

Clip Style

fieldtyperequireddescription
xnumberyesX position (px)
ynumberyesY position (px)
widthnumberyesWidth (px)
heightnumberyesHeight (px)
opacitynumberno0-1, default 1
rotationnumbernoDegrees
borderRadiusnumbernoPixels
transform3dobjectno{ perspective?, rotateX?, rotateY?, rotateZ?, translateZ? }

Clip Animation

fieldtypedescription
fadeInnumberFade-in frames
fadeOutnumberFade-out frames
springConfigobject{ mass?, damping?, stiffness? }

Sequence Overrides

timelines.<compositionId>.sequenceOverrides can override properties of code-defined <Sequence> elements:

fieldtypedescription
idstringSequence ID (required)
namestringSequence name (for matching)
fromnumberOverride start frame
durationnumberOverride duration frames
visiblebooleanShow/hide (default true)
styleobject{ x?, y?, width?, height?, opacity? }

Asset Schema

Clips with assetId (image/video/audio) reference entries in assets. Each asset key is the asset ID.

fieldtypedescription
idstringSame as the key in assets object
typestringimage | video | audio
filenamestringOriginal display name (e.g. photo.png)
urlstringFilename in public/ directory or full HTTP URL

Important: Use url (not src) and filename (not name). Wrong field names will crash the renderer.

Timing

All values are frames. Get fps from <project>/src/Root.tsx:

<Composition id="Main" fps={30} width={1920} height={1080} ... />

Convert: seconds * fps = frames

Remotion Code Pattern

import { AbsoluteFill, Sequence, useCurrentFrame, interpolate } from 'remotion';

export const MyComp = () => (
  <AbsoluteFill>
    <Sequence from={0} durationInFrames={90} name="intro">
      <h1 style={{ fontSize: 60 }}>Title</h1>
    </Sequence>
  </AbsoluteFill>
);

When creating new content, write proper Remotion components using Sequence, AbsoluteFill, useCurrentFrame, interpolate, spring, etc. Register in Root.tsx via <Composition>.

Remotion Quick Reference

Project Structure

video/
├── src/
│   ├── index.ts          # registerRoot(RemotionRoot)
│   ├── Root.tsx           # <Composition> registration
│   └── MyComp.tsx         # Component implementation
├── public/                # Static assets (images, fonts, videos)
├── remotion.config.ts     # Remotion config
└── maxmotion.json         # Editor timeline data

Core Components

ComponentPurposeExample
<Composition>Register a video (in Root.tsx)<Composition id="Main" component={MyComp} fps={30} width={1920} height={1080} durationInFrames={300} />
<AbsoluteFill>Full-screen container (position: absolute, inset: 0)<AbsoluteFill style={{ backgroundColor: '#000' }}>
<Sequence>Time-scoped section<Sequence from={30} durationInFrames={60} name="intro">
<Video>Video playback<Video src={staticFile('clip.mp4')} />
<Audio>Audio playback<Audio src={staticFile('music.mp3')} volume={0.5} />
<Img>Image (preloaded)<Img src={staticFile('logo.png')} />
<Series>Sequential sequences (auto-calculates from)<Series><Series.Sequence durationInFrames={60}>...</Series.Sequence></Series>

Core Hooks

HookReturnsUsage
useCurrentFrame()numberCurrent frame (0-based, resets inside each <Sequence>)
useVideoConfig(){ fps, width, height, durationInFrames }Composition config

Animation Utilities

import { interpolate, spring, Easing } from 'remotion';

// Linear interpolation
const opacity = interpolate(frame, [0, 30], [0, 1], { extrapolateRight: 'clamp' });

// Spring animation
const scale = spring({ frame, fps, config: { damping: 12, stiffness: 200 } });

// With easing
const x = interpolate(frame, [0, 60], [0, 500], { easing: Easing.bezier(0.25, 0.1, 0.25, 1) });

Static Assets

import { staticFile } from 'remotion';
// References files in public/ directory
<Img src={staticFile('logo.png')} />
<Video src={staticFile('intro.mp4')} />

Validation

After editing maxmotion.json, always run validation to catch schema errors:

cd <project> && npx maxmotion validate

If validation fails, fix the errors before telling the user the edit is done.

Notes

  • After editing JSON: user needs to refresh Editor. After editing .tsx: HMR auto-updates.
  • New clip IDs: clip_<base36-timestamp>_<random6>. Keep 2-space JSON indent.
  • The first <Composition> in Root.tsx is selected by default in the Editor. After creating a new composition, remove empty/unused ones (e.g. components returning null) to avoid a black screen.

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

General

audio-transcribe

No summary provided by upstream source.

Repository SourceNeeds Review
General

youtube-download

No summary provided by upstream source.

Repository SourceNeeds Review
General

video-gen

No summary provided by upstream source.

Repository SourceNeeds Review