SLOPSHOPPER

__MOD__

__DESCRIPTION__

newbandguard
A shopper browsing a rack in a slop shop
Preview · a replayed session in a sandbox
claude · ~/work/app · __MOD__
› fix the failing auth test and add an audit log call ⏺ Read(src/auth.ts) ⎿ Read 6 lines ⏺ Update(src/auth.ts) ⎿ Added 2 lines, removed 1 line ⏺ Bash(bun test) ⎿ 3 pass, 1 fail ● Done. refresh now rejects expired claims and logs an audit event. ✻ Worked for 42s · done 4:20 PM __MOD__: 9 tool calls ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────── › ? for shortcuts

Draws

Band
__MOD__: 9 tool calls
README

__MOD__

한국어 · English

__DESCRIPTION__

<!-- 스크린샷: scripts/shots/__MOD__.shot.tsx 를 만들고 node scripts/shots/render.mjs __MOD__ -->

설치

/plugin install __MOD__ --marketplace speardragon/ray-claude-code-mods

사용법

이 mod가 보여주거나 바꾸는 것, 추가하는 슬래시 명령, 패널이나 밴드의 단축키, 설정에서 읽는 값을 여기에 적어서 설치하는 사람이 무엇을 기대하면 되는지 알 수 있게 하세요.

Source 2 files
hooks/register.tsx 22 lines
1// __MOD__: __DESCRIPTION__
2//   A starting point: a band above the prompt that counts this session's tool calls.
3import { atom, read, update } from 'claude-code'
4import type { Register } from 'claude-code'
5
6// Held by the host, so a hot reload keeps it.
7const count = atom({ plugin: '__MOD__', key: 'count' } as const, 0)
8
9export const register: Register = on => {
10  on('tool.call', async ($, e, next) => {
11    await update($, count, n => n + 1)
12    return next(e)
13  })
14
15  on('ui.render', { component: 'AbovePrompt' }, async ($, e, next) => {
16    const n = await read($, count)
17    if (n === 0) return next(e)
18    const { Text } = $.ui.resolve(e)
19    return <Text dimColor>__MOD__: {n} tool calls</Text>
20  })
21}
22
types/index.d.ts 11 lines
1// The values this mod keeps in $.state, by key. Every key the hooks module names is checked against this.
2export type Count = number
3
4declare module 'claude-code' {
5  interface PluginState {
6    '__MOD__': {
7      count: Count
8    }
9  }
10}
11