modscode JA

modscode / Gallery / heavens-feel

heavens-feel

Heaven's Feel cast for your agents: Sakura watches over the main session, Servants answer every subagent

Code you can checkTerminal + desktopPaneBandToastBoxButtonMarkdownSvgText

What it does

  • Draws a pane, a band above the prompt, toasts
  • Adds /hf
  • Watches tool calls and can refuse them
  • Hooks agent.spawn, config.set, prompt.submit, session.append and 6 more
  • Keeps its own state between turns

Good points

  • No network calls
  • Starts no processes
  • Written in TypeScript
  • Has a desktop-specific branch

Code to start from

Two kinds: a starter modscode writes from the design above, and the lines of the mod's own code that draw it.

Starter (register.tsx)

register.tsx
import type { Register } from 'claude-code'

// Drawn like heavens-feel by Yedidya Kfir (pane, band, toast), as modscode read it from the mod's code:
// https://modscode.com/gallery/yedidyakfir-heavens-feel/
// 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 pane: open it with $.ui.open({ id: 'my-pane', title: "Sakura's room" })
  on('ui.render', { component: 'Pane', requestId: 'my-pane' }, async ($, e) => {
    const { Box, Button, Text, Markdown } = $.ui.resolve(e)
    const nameOf = '…'
    const statusOf = '…'
    const title = '…'
    const allegianceOf = '…'
    const activity = '…'
    const line = '…'
    const split = '…'
    const description = '…'
    const length = '…'
    const clipText = '…'
    const outcome = '…'
    const icon = '…'
    const text = '…'
    const outcome2 = '…'
    const icon2 = '…'
    const text2 = '…'
    const outcome3 = '…'
    const icon3 = '…'
    const text3 = '…'
    const outcome4 = '…'
    const icon4 = '…'
    const text4 = '…'
    const outcome5 = '…'
    const icon5 = '…'
    const text5 = '…'
    const outcome6 = '…'
    const icon6 = '…'
    const text6 = '…'
    const outcome7 = '…'
    const icon7 = '…'
    const text7 = '…'
    const outcome8 = '…'
    const icon8 = '…'
    const text8 = '…'
    const outcome9 = '…'
    const icon9 = '…'
    const text9 = '…'
    return (
      <Box flexDirection="column">
        <Box flexDirection="row" columnGap={2}>
          <Button label="◂ Sakura" hotkey="b" plain />
          <Box flexGrow={1} />
        </Box>
        <Box flexDirection="row" justifyContent="space-between" marginTop={1}>
          <Text bold>
            {"✦ "}
            {nameOf}
          </Text>
          <Text dimColor>
            {statusOf}
          </Text>
        </Box>
        <Text dimColor italic>
          {title}
          {" · "}
          {allegianceOf}
        </Text>
        <Box justifyContent="center" marginY={1}>
          <Text>
            ◆
          </Text>
        </Box>
        <Box flexDirection="row" columnGap={1}>
          finished
          <Box flexShrink={1} minWidth={0}>
            <Text wrap="truncate-end">
              {activity}
            </Text>
          </Box>
        </Box>
        <Box borderStyle="round" paddingX={1} marginTop={1}>
          <Text wrap="wrap" italic>
            「
            {line}
            」
          </Text>
        </Box>
        <Box marginTop={1}>
          <Text>
            {"── ✦ "}
            {split}
            's report ✦ ──
          </Text>
        </Box>
        <Text dimColor wrap="truncate-end">
          {description}
        </Text>
        <Text dimColor>
          Nothing to read yet. The summons has only begun.
        </Text>
        <Text dimColor>
          {"… "}
          {length}
          {" earlier rows"}
        </Text>
        <Box flexDirection="column">
          <Box flexDirection="row" columnGap={1}>
            <Text>
              ●
            </Text>
            <Box flexShrink={1} minWidth={0}>
              <Markdown text={`${clipText}`} />
            </Box>
          </Box>
          <Box flexDirection="row" columnGap={1}>
            <Text>
              {outcome}
            </Text>
            <Text dimColor wrap="truncate-end">
              {icon}
              {" "}
              {text}
            </Text>
          </Box>
          <Box flexDirection="row" columnGap={1}>
            <Text>
              {outcome2}
            </Text>
            <Text dimColor wrap="truncate-end">
              {icon2}
              {" "}
              {text2}
            </Text>
          </Box>
          <Box flexDirection="row" columnGap={1}>
            <Text>
              {outcome3}
            </Text>
            <Text dimColor wrap="truncate-end">
              {icon3}
              {" "}
              {text3}
            </Text>
          </Box>
        </Box>
        <Box flexDirection="column">
          <Box flexDirection="row" columnGap={1}>
            <Text>
              ●
            </Text>
            <Box flexShrink={1} minWidth={0}>
              <Markdown text={`${clipText}`} />
            </Box>
          </Box>
          <Box flexDirection="row" columnGap={1}>
            <Text>
              {outcome4}
            </Text>
            <Text dimColor wrap="truncate-end">
              {icon4}
              {" "}
              {text4}
            </Text>
          </Box>
          <Box flexDirection="row" columnGap={1}>
            <Text>
              {outcome5}
            </Text>
            <Text dimColor wrap="truncate-end">
              {icon5}
              {" "}
              {text5}
            </Text>
          </Box>
          <Box flexDirection="row" columnGap={1}>
            <Text>
              {outcome6}
            </Text>
            <Text dimColor wrap="truncate-end">
              {icon6}
              {" "}
              {text6}
            </Text>
          </Box>
        </Box>
        <Box flexDirection="column">
          <Box flexDirection="row" columnGap={1}>
            <Text>
              ●
            </Text>
            <Box flexShrink={1} minWidth={0}>
              <Markdown text={`${clipText}`} />
            </Box>
          </Box>
          <Box flexDirection="row" columnGap={1}>
            <Text>
              {outcome7}
            </Text>
            <Text dimColor wrap="truncate-end">
              {icon7}
              {" "}
              {text7}
            </Text>
          </Box>
          <Box flexDirection="row" columnGap={1}>
            <Text>
              {outcome8}
            </Text>
            <Text dimColor wrap="truncate-end">
              {icon8}
              {" "}
              {text8}
            </Text>
          </Box>
          <Box flexDirection="row" columnGap={1}>
            <Text>
              {outcome9}
            </Text>
            <Text dimColor wrap="truncate-end">
              {icon9}
              {" "}
              {text9}
            </Text>
          </Box>
        </Box>
      </Box>
    )
  })

  // the band above the prompt; what else goes there is drawn under it
  on('ui.render', { component: 'AbovePrompt' }, async ($, e, next) => {
    const { Box, Text, Button } = $.ui.resolve(e)
    const MOOD_LABEL = '…'
    const icon = '…'
    const text = '…'
    const text2 = '…'
    const nameOf = '…'
    const nameOf2 = '…'
    const nameOf3 = '…'
    return (
      <Box flexDirection="column">
        <Box flexDirection="row" columnGap={2}>
          <Box flexShrink={0} />
          <Box flexDirection="column" flexGrow={1} flexShrink={1} minWidth={0}>
            <Box flexDirection="row" columnGap={1}>
              <Box flexShrink={0} columnGap={1}>
                <Text>
                  ✸
                </Text>
                <Text bold>
                  Sakura
                </Text>
                <Text color="#1a1320" bold>
                  {` ${MOOD_LABEL} `}
                </Text>
              </Box>
              <Box flexGrow={1} />
              <Box flexShrink={0}>
                <Button label="open pane" plain />
              </Box>
            </Box>
            <Text wrap="truncate-end">
              {icon}
              {" "}
              {text}
            </Text>
            <Box borderStyle="round" paddingX={1}>
              <Text wrap="wrap" italic>
                「
                {text2}
                」
              </Text>
            </Box>
            <Box flexDirection="row" columnGap={1}>
              <Box flexDirection="column">
                <Text>
                  ◆
                </Text>
                <Text bold wrap="truncate-end">
                  {nameOf}
                </Text>
                <Text dimColor wrap="truncate-end">
                  done
                </Text>
              </Box>
              <Box flexDirection="column">
                <Text>
                  ◆
                </Text>
                <Text bold wrap="truncate-end">
                  {nameOf2}
                </Text>
                <Text dimColor wrap="truncate-end">
                  done
                </Text>
              </Box>
              <Box flexDirection="column">
                <Text>
                  ◆
                </Text>
                <Text bold wrap="truncate-end">
                  {nameOf3}
                </Text>
                <Text dimColor wrap="truncate-end">
                  done
                </Text>
              </Box>
            </Box>
          </Box>
        </Box>
        {await next(e)}
      </Box>
    )
  })

  on('session.start', async ($, e, next) => {
    const why = '…'
    await $.ui.toast(`Sakura is not herself (${why}). /compact helps, or /hf dark off.`)
    return next(e)
  })
}

The mod's own code

Shown under the mod's licence (MIT); its text is below. Keep the notice if you copy these lines.

hooks/register.tsx lines 449–460 · Pane
  on('ui.render', { component: 'Pane', requestId: PANE }, async ($, e) => {
    const view = await readView($)
    const chosen = (await read($, viewing)) || e.props.view.agentId || ''
    const agent = chosen ? (view.agents[chosen] ?? rt.pastAgents.get(chosen)) : undefined
    const servant = agent ? { agent, messages: await agentMessages($, agent.id), canGoBack: !e.props.view.agentId } : undefined
    const controls = {
      view: (id: string) => void update($, viewing, () => id),
      back: () => void update($, viewing, () => ''),
      openTasks: () => void $.command.run({ command: 'tasks' }).catch(() => {}),
    }
    return drawPane($.ui.resolve(e), e, view, settings, bond, servant, controls)
  })
hooks/views.tsx lines 347–406 · Pane
export const drawPane = (
  ui: any,
  e: PaneEvent,
  view: View,
  settings: Settings,
  bond: Record<string, number>,
  servant: ServantView | undefined,
  controls: PaneControls,
) => {
  if (servant) return drawServantRoom(ui, e, view, servant, controls)
  const { Box, Text } = ui
  const { mood: currentMood, isDark, agents: all, bubble: line, now } = view
  const isTerminal = e.surface === 'terminal'
  const accent = isDark ? DARK_ACCENT : CAST.sakura.accent
  const size = portraitSize(e)
  const width = Math.max(10, e.props.bodyColumns - 2)
  const roster = sortedAgents(all)
  const running = roster.filter(agent => !agent.endedAt).length

  const portrait = (() => {
    if (isTerminal) return liveRaster(ui, PANE, 'portrait', 1, now, at => portraitFrame(size, sceneAt(at, false)))
    if ('Svg' in ui) return sakuraSvg(ui, size, scene => portraitFrame(size, scene), blinkFrame(size, isDark), SVG_PIXEL_HD, view)
    return <Text color={hex(accent)}>{isDark ? '(◣_◢)' : '(´• ᴗ •`)'}</Text>
  })()

  return (
    <Box flexDirection="column" width={width}>
      <Box flexDirection="row" justifyContent="space-between">
        <Text bold color={hex(accent)}>
          {isDark ? '✸' : '❀'} Sakura Matou
        </Text>
        <Text color={hex(accent)}>{hearts(bond.sakura ?? 0)}</Text>
      </Box>
      <Text dimColor italic>{isDark ? 'the shadow that waits at home' : `${CAST.sakura.title} · Master of Rider`}</Text>
      <Box justifyContent="center" marginY={1}>{portrait}</Box>
      <Box flexDirection="row" columnGap={1}>
        {moodPill(ui, currentMood, accent)}
        <Box flexShrink={1} minWidth={0}>
          <Text color={hex(accent)} wrap="truncate-end">{view.activity.icon} {view.activity.text}</Text>
        </Box>
      </Box>
      {line.text ? (
        <Box borderStyle="round" borderColor={hex(accent)} paddingX={1} marginTop={1}>
          <Text wrap="wrap" italic>「{line.text}」</Text>
        </Box>
      ) : null}
      <Box flexDirection="column" marginTop={1}>
        {shadowGauge(ui, view.ctx, settings.darkThreshold)}
        {clockLine(ui, now, settings, running)}
      </Box>
      {roster.length > 0 ? (
        <Box marginTop={1}>
          <Text color={hex(accent)}>── ✦ Servants ✦ ──</Text>
        </Box>
      ) : null}
      {roster.slice(0, ROSTER_LIMIT).map((agent, i) => servantCard(ui, e.surface, agent, view, width, i, () => controls.view(agent.id)))}
      {roster.length > ROSTER_LIMIT ? <Text dimColor>+{roster.length - ROSTER_LIMIT} more</Text> : null}
    </Box>
  )
}
hooks/views.tsx lines 305–345 · Pane
const drawServantRoom = (ui: any, e: PaneEvent, view: View, servant: ServantView, controls: PaneControls) => {
  const { Box, Text, Button } = ui
  const { agent, messages } = servant
  const entry = CAST[agent.character]
  const accent = agent.isError ? DARK_ACCENT : entry.accent
  const width = Math.max(10, e.props.bodyColumns - 2)
  const recent = messages.slice(-TRANSCRIPT_ROWS)
  return (
    <Box flexDirection="column" width={width}>
      <Box flexDirection="row" columnGap={2}>
        {servant.canGoBack ? <Button key="back" label="◂ Sakura" hotkey="b" plain onPress={controls.back} /> : null}
        <Box flexGrow={1} />
        {e.surface === 'terminal' ? <Button key="tasks" label="/tasks" hotkey="t" plain onPress={controls.openTasks} /> : null}
      </Box>
      <Box flexDirection="row" justifyContent="space-between" marginTop={1}>
        <Text bold color={hex(accent)}>✦ {nameOf(agent)}</Text>
        <Text dimColor>{statusOf(agent, view.now)}</Text>
      </Box>
      <Text dimColor italic>{entry.title} · {allegianceOf(agent.character)}</Text>
      <Box justifyContent="center" marginY={1}>{miniArt(ui, e.surface, PANE, `viewed:${agent.id}`, agent.id, 2, view)}</Box>
      <Box flexDirection="row" columnGap={1}>
        {moodPill(ui, agent.endedAt ? 'done' : agent.mood, accent)}
        <Box flexShrink={1} minWidth={0}>
          <Text color={hex(accent)} wrap="truncate-end">{agent.activity}</Text>
        </Box>
      </Box>
      {agent.line ? (
        <Box borderStyle="round" borderColor={hex(accent)} paddingX={1} marginTop={1}>
          <Text wrap="wrap" italic>「{agent.line}」</Text>
        </Box>
      ) : null}
      <Box marginTop={1}>
        <Text color={hex(accent)}>── ✦ {entry.name.split(' ')[0]}'s report ✦ ──</Text>
      </Box>
      <Text dimColor wrap="truncate-end">{agent.description}</Text>
      {recent.length === 0 ? <Text dimColor>Nothing to read yet. The summons has only begun.</Text> : null}
      {messages.length > recent.length ? <Text dimColor>… {messages.length - recent.length} earlier rows</Text> : null}
      {recent.map((message, i) => transcriptRow(ui, message, i, accent))}
    </Box>
  )
}
hooks/views.tsx lines 172–184 · Pane
const miniArt = (ui: any, surface: string, requestId: string, key: string, id: string, scale: 1 | 2, view: View) => {
  const frameAt = agentMiniAt(id)
  const character = rt.agents[id]?.character ?? 'sakura'
  const accent = CAST[character].accent
  if (surface === 'terminal') return liveRaster(ui, requestId, key, scale, view.now, frameAt)
  const current = frameAt(view.now)
  if ('Svg' in ui && current) {
    const pixel = SVG_PIXEL_MINI * scale
    const source = gridToSvg(current.grid, { pixel, backdrop: backdropFor(view.theme, accent) })
    return <ui.Svg source={source} alt={CAST[character].name} {...svgBox(current.grid, pixel)} />
  }
  return <ui.Text color={hex(accent)}>◆</ui.Text>
}
hooks/views.tsx lines 267–300 · Pane
const transcriptRow = (ui: any, message: ServantMessage, index: number, accent: number) => {
  const { Box, Text } = ui
  if (message.role === 'user') {
    if (!message.text) return null
    return (
      <Box key={`row-${index}`} flexDirection="row" columnGap={1}>
        <Text color={hex(CAST.sakura.accent)}>❀</Text>
        <Text dimColor italic wrap="wrap">{clipText(message.text, SUMMONS_CHARACTERS)}</Text>
      </Box>
    )
  }
  return (
    <Box key={`row-${index}`} flexDirection="column">
      {message.text ? (
        <Box flexDirection="row" columnGap={1}>
          <Text color={hex(accent)}>●</Text>
          <Box flexShrink={1} minWidth={0}>
            <ui.Markdown text={clipText(message.text, MESSAGE_CHARACTERS)} />
          </Box>
        </Box>
      ) : null}
      {message.toolUses.map((use, k) => {
        const doing = describeTool(use.tool, use.input)
        const outcome = use.isError ? '✗' : use.text !== undefined || use.result !== undefined ? '✓' : '…'
        return (
          <Box key={`use-${index}-${k}`} flexDirection="row" columnGap={1}>
            <Text color={hex(use.isError ? DARK_ACCENT : accent)}>{outcome}</Text>
            <Text dimColor wrap="truncate-end">{doing.icon} {doing.text}</Text>
          </Box>
        )
      })}
    </Box>
  )
}
hooks/views.tsx lines 214–218 · Pane
const moodPill = (ui: any, mood: HeavensFeelMood, accent: number) => (
  <ui.Text backgroundColor={hex(accent)} color={PILL_TEXT} bold>
    {` ${MOOD_LABEL[mood]} `}
  </ui.Text>
)
Licence text (MIT)
MIT License

Copyright (c) 2026 Yedidya Kfir

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.

What its code calls

drives Claudetool callsremembers

The design, read from code

Drawn from the mod's source at the commit read, not from a run: a list is drawn three times, a condition takes its first branch that draws in the desktop app, and a value only the run time knows is shown as a made-up sample (dotted underline) or left out. Colours and type are this site's.

What its code shows

Read from the source at commit 7792e2110021 on 2026-10-06. The first group decides whether a mod is listed; the rest is for you to weigh. A later commit is not read until the next crawl.

Decides the listing: code you can check
Entry readEvery module hooks/hooks.json names was read.hooks/register.tsx
ParsesEvery file parses as TypeScript or JavaScript.9 files parsed
All its code is in the modEvery import is a file of the mod or the engine's own module; no packages, no require.all its code is in the mod
ReadableNo minified lines, no eval or new Function, no import of a computed path, no encoded blobs.no minified code, no eval, no encoded blobs
Calls in the openNetwork and programs are reached as $.http.fetch and $.process.run in place, never passed around.every call outside goes through $ in the open
For you to weigh before installing
Where it drawsThe terminal, the desktop app, both, or nothing (hooks only: a guard or a prompt rewriter), as its code says. Shown, never a reason to leave a mod out.draws in the terminal and the desktop app, the same in both
Install lineWhether its repository's own .claude-plugin/marketplace.json lists it, so it installs from that marketplace with the lines on its page.listed in its repository's .claude-plugin/marketplace.json: installs from there
Programs on WindowsWhether every program it starts through $.process exists on Windows (tail, date, open, osascript, /usr/… do not).runs no program a Windows PC lacks
NetworkWhether every fetch names its https host in the code.no network
ProgramsWhether every program it starts is named in the code and is not a shell, an interpreter or a network tool.starts no programs
Reads and sendsWhether it both reads files or environment variables and reaches the network.reaches no network
Keys in the sourceWhether the source holds what looks like an API key or a private key.no keys in the source
LicenceAn open licence (MIT, Apache-2.0, BSD, ISC, Unlicense, 0BSD, CC0) with its text lets modscode show its code; otherwise the code is linked.MIT

This is a reading of the code text, not a security review: it does not run the mod, and it cannot see what a program the mod starts does. The check before installing is yours. How mods are chosen

Install it

Check it yourself before you install it. Mods run unsandboxed, with your permissions, and modscode does not vouch for what this code does. Read the code below (or run claude plugin validate . in its folder), weigh what it reaches, and install the commit you read.

Its repository is its marketplace. Add that marketplace (in the terminal with these commands, or in the desktop app's plugin settings) and install the mod from it:

/plugin marketplace add yedidyakfir/heavens-feel
/plugin install heavens-feel@heavens-feel

This installs the marketplace's latest commit, which may not be the one read here (7792e2110021). Compare them before you install.

Ask Claude about it

With the modscode connector added, Claude can read this design, what its code reaches and its code, and build on them. Ask it like this:

Read the modscode design "yedidyakfir-heavens-feel" with its code and make me a pane like it

Search them from Claude: the MCP connector

Similar designs