buildreel
Turns your Claude Code session into a 30-second build-in-public video: it records the moments, films your app, and gives you an editing table before anything is shared.
何をするか
- プロンプトの上の帯・欄・トーストを描く
- /reel を足す
- ツールの呼び出しを見張る
- session.append・session.startにフックする
- プロセスを起こす
良いところ
- ネットワークに出ない
- TypeScript で書かれている
- デスクトップ専用の分岐がある
- エラーを扱う
作り始めるためのコード
2 種類あります。上のデザインから modscode が書いた雛形と、その Mod 自身のコードのうち描いている部分です。
雛形(register.tsx)
import type { Register } from 'claude-code'
// Drawn like buildreel by Meffysto (pane, band, toast), as modscode read it from the mod's code:
// https://modscode.com/gallery/menufactory43-buildreel/
// Written by modscode from that reading, not copied from the mod: use it as you like.
// Each value below stands for one the mod works out at run time; put in your own.
export const register: Register = on => {
// the band above the prompt; what else goes there is drawn under it
on('ui.render', { component: 'AbovePrompt' }, async ($, e, next) => {
const { Box, Text } = $.ui.resolve(e)
const length = '…'
const shots = '…'
return (
<Box flexDirection="column">
<Box>
<Text color="red" bold>
● REC
{" "}
</Text>
<Text dimColor>
0
{" · "}
{length}
{" "}
moments
{" · "}
{`${shots}`}
{" ·"}
{" "}
</Text>
<Text>
/reel to edit
</Text>
</Box>
{await next(e)}
</Box>
)
})
// the pane: open it with $.ui.open({ id: 'my-pane', title: "Buildreel" })
on('ui.render', { component: 'Pane', requestId: 'my-pane' }, async ($, e) => {
const { Box, Text, Button, Input } = $.ui.resolve(e)
const project = '…'
const plans = '…'
const local = '…'
const status = '…'
const name = '…'
const untitled = '…'
const clockTime = '…'
const startLabel = '…'
const clockTime2 = '…'
const label = '…'
const captionOf = '…'
const caption = '…'
const value = '…'
const post = '…'
return (
<Box flexDirection="column">
<Text bold>
{project}
{" · "}
{`${plans}`}
</Text>
<Text dimColor>
{`${local}`}
</Text>
<Text color="yellow">
{status}
</Text>
<Text>
{" "}
</Text>
<Box>
<Text>
Cuts
{" "}
</Text>
<Box>
<Button variant="primary" label={`${name} ✓`} />
<Text>
{" "}
</Text>
</Box>
<Box>
<Button variant="primary" label={`${name} ✓`} />
<Text>
{" "}
</Text>
</Box>
<Box>
<Button variant="primary" label={`${name} ✓`} />
<Text>
{" "}
</Text>
</Box>
<Button label="+ New cut" />
<Text>
{" "}
</Text>
<Button label="↻ Let Claude pick" />
</Box>
<Input label="Name of the cut" value={`${untitled}`} submitLabel="keep" />
<Text>
{" "}
</Text>
<Box>
<Text>
Start
{" "}
</Text>
<Button label="◀" />
<Text>
{" "}
{clockTime}
{" "}
{startLabel}
{" "}
</Text>
<Button label="▶" />
</Box>
<Box>
<Text>
End
{" "}
</Text>
<Button label="◀" />
<Text>
{" "}
{clockTime2}
{" "}
· end of the session
{" "}
</Text>
<Button label="▶" />
</Box>
<Text>
{" "}
</Text>
<Box>
<Button plain label="[x]" />
<Button plain label={`${label}`} />
</Box>
<Box>
<Button plain label="[x]" />
<Button plain label={`${label}`} />
</Box>
<Box>
<Button plain label="[x]" />
<Button plain label={`${label}`} />
</Box>
<Text>
{" "}
</Text>
<Input label={`${captionOf}`} value={`${caption}`} submitLabel="keep" />
<Text>
{" "}
</Text>
<Box>
<Button variant="primary" label="Rendering…" />
<Text>
{" "}
</Text>
<Button label="Open" />
<Text>
{" "}
</Text>
<Button label="Show in Finder" />
</Box>
<Box flexDirection="column">
<Text>
{" "}
</Text>
<Text bold>
Post for X
</Text>
<Text>
{post}
</Text>
<Button label="Copy the post" />
</Box>
</Box>
)
})
on('session.start', async ($, e, next) => {
const recipeBy = '…'
const serverOff = '…'
await $.ui.toast(`${recipeBy}`)
await $.ui.toast(`${serverOff}`)
return next(e)
})
}
Mod 自身のコード
Mod のライセンス(MIT)に従って載せています。全文は下にあります。写すときは著作権表示を残してください。
hooks/register.tsx 606〜623 行 · バンド
on('ui.render', { component: 'AbovePrompt' }, async ($, e, next) => {
const session = await read($, sessionRef)
if (!active || !session || session.moments.length === 0 || e.props.hasSurvey) return next(e)
const t = UI[lang]
const { Box, Text } = $.ui.resolve(e)
const shots = session.moments.filter(m => m.kind === 'capture').length
return (
<Box>
<Text color="red" bold>
● REC{' '}
</Text>
<Text dimColor>
{formatDuration(activeTime([session.startedAt, ...session.moments.map(m => m.at)]), lang)} · {session.moments.length} {t.moments} · {t.shots(shots)} ·{' '}
</Text>
<Text>{t.toEdit}</Text>
</Box>
)
})hooks/register.tsx 625〜784 行 · ペイン
on('ui.render', { component: 'Pane', requestId: PANE }, async ($, e) => {
const t = UI[lang]
const { Box, Text, Button } = $.ui.resolve(e)
const Input = e.surface !== 'mobile' ? $.ui.resolve(e).Input : null
const Image = e.surface === 'terminal' ? $.ui.resolve(e).Image : null
const session = await read($, sessionRef)
const edit = await read($, editRef)
if (!active) return <Text dimColor>{t.notProject}</Text>
if (!session) return <Text dimColor>{t.noSession}</Text>
const cuts = await read($, cutsRef)
const rendering = await read($, renderingRef)
const scenes = buildScenes(session, edit.from, lang, edit.to, edit.picks)
const kept = applyEdit(scenes, edit)
const selected = scenes.find(s => s.id === edit.selected) ?? scenes[0]!
const points = startPoints(session)
const start = edit.from ?? session.startedAt
const startMoment = session.moments.find(m => m.at === start)
const set = (fn: (edit: Edit) => Edit) => update($, editRef, fn)
const lastAt = session.moments.at(-1)?.at ?? session.startedAt
const moveStart = (step: number) =>
set(ed => {
const allowed = points.filter(p => ed.to === null || p < ed.to)
const i = Math.max(0, allowed.indexOf(ed.from ?? session.startedAt))
const at = allowed[Math.min(allowed.length - 1, Math.max(0, i + step))] ?? session.startedAt
return { ...ed, from: at === session.startedAt ? null : at }
})
// La fin se règle sur les mêmes repères ; tout au bout, c'est « fin de la session » (null).
const moveEnd = (step: number) =>
set(ed => {
const begin = ed.from ?? session.startedAt
const allowed = [...points.filter(p => p > begin), lastAt].filter((p, i, all) => all.indexOf(p) === i)
const i = ed.to === null ? allowed.length - 1 : Math.max(0, allowed.indexOf(ed.to))
const at = allowed[Math.min(allowed.length - 1, Math.max(0, i + step))] ?? lastAt
return { ...ed, to: at === lastAt ? null : at }
})
const endMoment = edit.to === null ? null : session.moments.find(m => m.at === edit.to)
let thumb: string | null = null
if (selected.thumb && Image) {
try {
thumb = ((await $.fs.read(selected.thumb, { as: 'bytes' })) as { base64: string }).base64
} catch {
thumb = null
}
}
const label = (scene: Scene, i: number) =>
`${scene.id === selected.id ? '›' : ' '} ${i + 1}. ${t.kind[scene.kind]}${scene.chip ? ` ${scene.chip}` : ''} · ${
edit.captions[scene.id] ?? scene.caption
}`
const startLabel =
startMoment?.kind === 'commit'
? `· ${startMoment.label}`
: start === session.startedAt
? `· ${t.sessionStart}`
: `· ${t.capture}`
return (
<Box flexDirection="column">
<Text bold>
{session.project} · {t.plans(kept.length, Math.round(runtime(kept)))}
</Text>
<Text dimColor>{t.local(tilde(session.dir))}</Text>
{edit.status && <Text color={rendering ? 'yellow' : edit.output ? 'green' : undefined}>{edit.status}</Text>}
<Text> </Text>
<Box>
<Text>{t.cuts} </Text>
{cuts.map(cut => (
<Box key={`cutbox-${cut.id}`}>
<Button
key={`cut-${cut.id}`}
variant={cut.id === edit.cutId ? 'primary' : 'secondary'}
label={`${cut.name}${cut.output ? ' ✓' : ''}`}
onPress={() => set(() => ({ ...cut, cutId: cut.id, status: cut.output ? t.ready(tilde(cut.output)) : null }))}
/>
<Text> </Text>
</Box>
))}
<Button
key="new-cut"
label={t.newCut}
onPress={async () => {
await set(() => ({ ...emptyEdit }))
void direct($)
}}
/>
<Text> </Text>
<Button key="direct" label={t.direct} onPress={() => void direct($)} />
</Box>
{Input && (
<Input
key="cut-name"
label={t.cutName}
value={edit.name ?? t.untitled(cuts.length + (edit.cutId ? 0 : 1))}
submitLabel={t.keep}
onSubmit={(value: string) => set(ed => ({ ...ed, name: value.trim() || null }))}
/>
)}
<Text> </Text>
<Box>
<Text>{t.start} </Text>
<Button key="from-prev" label="◀" onPress={() => moveStart(-1)} />
<Text>
{' '}
{clockTime(start)} {startLabel}{' '}
</Text>
<Button key="from-next" label="▶" onPress={() => moveStart(1)} />
</Box>
<Box>
<Text>{t.end} </Text>
<Button key="to-prev" label="◀" onPress={() => moveEnd(-1)} />
<Text>
{' '}
{clockTime(edit.to ?? lastAt)}{' '}
{edit.to === null
? `· ${t.sessionEnd}`
: endMoment?.kind === 'commit'
? `· ${endMoment.label}`
: `· ${t.capture}`}{' '}
</Text>
<Button key="to-next" label="▶" onPress={() => moveEnd(1)} />
</Box>
<Text> </Text>
{scenes.map((scene, i) => {
const isKept = !edit.dropped.includes(scene.id)
return (
<Box key={`row-${scene.id}`}>
<Button
key={`keep-${scene.id}`}
plain
label={isKept ? '[x]' : '[ ]'}
onPress={() =>
set(ed => ({
...ed,
dropped: isKept ? [...ed.dropped, scene.id] : ed.dropped.filter(id => id !== scene.id),
}))
}
/>
<Button
key={`sel-${scene.id}`}
plain
label={label(scene, i)}
onPress={() => set(ed => ({ ...ed, selected: scene.id }))}
/>
</Box>
)
})}
<Text> </Text>
{Input && (
<Input
key="caption"
label={t.captionOf(scenes.indexOf(selected) + 1)}
value={edit.captions[selected.id] ?? selected.caption}
submitLabel={t.keep}
onSubmit={(value: string) =>
set(ed => ({ ...ed, captions: { ...ed.captions, [selected.id]: value.trim() } }))
}ライセンスの全文(MIT)
MIT License Copyright (c) 2026 Meffysto Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
コードが呼ぶもの
プログラム起動ファイル書き込み環境変数Claude を動かすツール呼び出し
コードから読み取ったデザイン
読み取ったコミットのソースから描いたもので、動かした結果ではありません。一覧は 3 回描き、条件はデスクトップアプリで描く最初の分岐を取り、動かしたときにだけ決まる値は仮の例(点線の下線)にするか省きます。色と書体はこのサイトのものです。
コードから読めること
2026-10-06 に読んだコミット a137942df71b のソースから。最初のまとまりが載せる条件で、残りは自分で判断するための材料です。後のコミットは、次に読むまで見ていません。
| 載せる条件: 確かめやすいコード | |
|---|---|
| 入口を読んだ | hooks/hooks.json が名指すモジュールをすべて読んだ。hooks/register.tsx |
| 解析できる | すべてのファイルが TypeScript か JavaScript として解析できる。2 ファイルを解析 |
| コードが Mod の中で完結 | import は Mod 自身のファイルかエンジンのモジュールだけ。パッケージも require もない。コードはすべて Mod の中 |
| 読める | 圧縮した行・eval・new Function・計算した道の import()・符号化した塊がない。圧縮・eval・符号化した塊なし |
| 呼び出しが見える | 通信とプログラム起動はその場で $.http.fetch・$.process.run と書き、他へ渡さない。外への呼び出しはすべてその場の $ で |
| 入れる前に自分で判断する材料 | |
| 描く場所 | コードから読んだ、描く先。ターミナル・デスクトップアプリ・両方・何も描かない(フックだけ: 見張りやプロンプトの書き換え)のどれか。出すだけで、外す理由にはしない。ターミナルとデスクトップアプリに同じように描く |
| 入れる手順 | リポジトリ自身の .claude-plugin/marketplace.json にこの Mod が載っていて、ページに書いた手順でそのマーケットプレイスから入れられるか。リポジトリの .claude-plugin/marketplace.json に載っており、そこから入れられる |
| Windows のプログラム | $.process で起動するプログラムが Windows にあるか(tail・date・open・osascript・/usr/… などは無い)。hooks/register.tsx:797 open(Windows にない); hooks/register.tsx:800 open(Windows にない) |
| 通信 | fetch の送り先(https のホスト)がコードに書いてあるか。通信なし |
| プログラム | 起動するプログラムの名前がコードに書いてあり、シェル・インタプリタ・通信用の道具でないか。hooks/register.tsx:255 node(シェル・インタプリタ); hooks/register.tsx:300 node(シェル・インタプリタ); hooks/register.tsx:338 node(シェル・インタプリタ); hooks/register.tsx:368 node(シェル・インタプリタ); hooks/register.tsx:461 node(シェル・インタプリタ) |
| 読んで送る | ファイルや環境変数を読み、かつ通信するか。reads environment variables and files and reaches the network |
| ソースの鍵 | ソースに API キーや秘密鍵らしきものがあるか。ソースに鍵なし |
| ライセンス | オープンなライセンス(MIT・Apache-2.0・BSD・ISC・Unlicense・0BSD・CC0)で全文があれば、modscode にコードを載せる。違えばリンクだけ。MIT |
コードの文面を読んだだけで、安全の審査ではありません。動かしてはおらず、起動するプログラムの中で何が起きるかも見えません。入れる前の確認はあなたの役目です。 載せる条件
入れる
入れる前に、必ず自分で確かめてください。Mod はサンドボックスなしで、あなたの権限で動きます。modscode はこのコードの安全を保証しません。下のコードを読み(またはフォルダーで claude plugin validate .)、触るものを見て、読んだコミットを入れてください。
リポジトリがそのままマーケットプレイスです。このマーケットプレイスを足し(ターミナルでは次のコマンド、デスクトップアプリではプラグインの設定)、そこから Mod を入れます。
/plugin marketplace add menufactory43/buildreel/plugin install buildreel@buildreel入るのはマーケットプレイスの最新のコミットで、ここで読んだもの(a137942df71b)と違うことがあります。入れる前に見比べてください。
Claude に聞く
modscode のコネクタを入れると、Claude がこのデザイン・コードが触るもの・コードを読んで、それをもとに作れます。たとえば:
modscode のデザイン「menufactory43-buildreel」をコードごと読んで、同じようなペインを作って似たデザイン
-
Claude に頼む…2h 10m · █████░░░✓ build ✓ build ✓ buildJavaKotlin3 Python■ ok 3 ■ ok 3 ■ ok 3 Razor proven 3 Razor proven 3 Razor proven 3Phases ──────── 3/3build Pythonbuild Pythonbuild Python… 3 more phasesLua ──────── 3/Kotlin■ the whole upgrade Ruby■ build build Ruby■ build build Ruby■ build build Ruby … 3 moreNext ──────── PythonRuby (by hand)Podsclick a button, or ctrl+x tab then Tab, EnterAttention ──────── 3! Scala ! Scala ! Scala … 3 moreSession ──────── okJava
-
slop Edit1 of 3accepteditrejectClaude に頼む…
-
Claude に頼む…Skins0 Your promptadd rate limiting to the hub api0 Tool rows: finished, running, failedYour prompt Spinner0 Folded group of reads and searches●main · note 3 · note 3 · note 30 Edit diff cardDesktop only; the terminal keeps Claude Code's diff.0 Shell output cardDesktop only.0 Code block cardDesktop only; the terminal keeps Claude Code's markdown.0 TableAccentAccentAccentAccentAccentAccentAccentAccentAccentAccentAccentAccentCopyAccentAccentAccentAccentAccentAccentAccentAccentAccentAccentAccentAccentCopyAccentAccentAccentAccentAccentAccentAccentAccentAccentAccentAccentAccentCopy0 SpinnerAccent SpinnerSpinnerSpinner… 2h 10m0 Band above the prompt: normal, then nudging to compact█████░░░ 42% build█████░░░ 42% build█████░░░ 42% buildContext is 42% full0 Compact now0 Band above a questionTable BashBashBash0 Turn footer (terminal)3 build in 2h 10m · Grep · +3 −3
-
Claude に頼む…agent-discoverbuildbuildbuildRefreshMCP Browse/3Tab / shift+Tab move · Enter presses · ↑↓ scroll · Esc back to the promptBrowse...Audit asks:DeclineAcceptDeclineCancelAudit asks:DeclineAcceptDeclineCancelAudit asks:DeclineAcceptDeclineCancel
-
Claude に頼む…Fanyi settingsOnAPI · OpusenOn this MacAPIHost src/ SaveKey K · paste a new one, Enter SaveOpus↻ RefreshCustom model model id, for an API that lists none UseFanyi settingsHostClose
-
Claude に頼む…Glossary BrowserGlossary openContextsContextsContexts▲ prevWrite1/Glossary▼ nextContexts