modscode / Gallery / github-issues
github-issues
A side pane listing the repository's GitHub issues, with one click to have Claude work on one
What it does
- Draws a pane, toasts in the desktop app
- Adds /issues
- Hooks session.start, turn.complete, ui.close
- Keeps its own state between turns
- Starts processes
Good points
- No network calls
- Written in TypeScript
- Has a desktop-specific branch
- Handles errors
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)
import type { Register } from 'claude-code'
// Drawn like github-issues by Marco Carnevali (pane, status, toast), as modscode read it from the mod's code:
// https://modscode.com/gallery/marcocarnevali-github-issues/
// 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: "Issues" })
on('ui.render', { component: 'Pane', requestId: 'my-pane' }, async ($, e) => {
const { Box, Text, Button, Input } = $.ui.resolve(e)
const typed = '…'
const label = '…'
const repoMeta = '…'
const owner = '…'
const repoMeta2 = '…'
const repoMeta3 = '…'
const repoMeta4 = '…'
const owner2 = '…'
const repoMeta5 = '…'
const repoMeta6 = '…'
const repoMeta7 = '…'
const owner3 = '…'
const repoMeta8 = '…'
const repoMeta9 = '…'
const repoMeta10 = '…'
return (
<Box flexDirection="column">
<Box flexDirection="row" justifyContent="space-between">
<Text bold>
Choose a repository
</Text>
<Button label="Back" plain />
</Box>
<Box marginTop={1}>
<Input placeholder="Filter, or type owner/name" value={`${typed}`} submitLabel="open" />
</Box>
<Box marginTop={1}>
<Box flexDirection="row" columnGap={1} alignItems="center">
<Text color="claude">
⠋
</Text>
<Text dimColor>
Refreshing…
</Text>
</Box>
</Box>
<Box flexDirection="column" marginTop={1}>
<Text dimColor bold>
This session
</Text>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta}
</Text>
</Box>
</Box>
<Box flexDirection="column" marginTop={1}>
<Text dimColor bold>
{owner}
</Text>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta2}
</Text>
</Box>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta3}
</Text>
</Box>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta4}
</Text>
</Box>
</Box>
<Box flexDirection="column" marginTop={1}>
<Text dimColor bold>
{owner2}
</Text>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta5}
</Text>
</Box>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta6}
</Text>
</Box>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta7}
</Text>
</Box>
</Box>
<Box flexDirection="column" marginTop={1}>
<Text dimColor bold>
{owner3}
</Text>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta8}
</Text>
</Box>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta9}
</Text>
</Box>
<Box flexDirection="row" columnGap={2}>
<Button label={`● ${label}`} plain />
<Text dimColor wrap="truncate-end">
{repoMeta10}
</Text>
</Box>
</Box>
<Box marginTop={1}>
<Text dimColor wrap="wrap">
{`Press Enter to open ${typed}.`}
</Text>
</Box>
</Box>
)
})
on('session.start', async ($, e, next) => {
const number = '…'
const session = '…'
const target = '…'
await $.ui.toast(`#${number} is already queued for Claude.`)
await $.ui.toast(`This session works in ${session}, not ${target}. Open Claude Code in ${target}'s folder to hand Claude its issues.`)
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.
github-issues/hooks/register.tsx lines 525–684 · Pane
on('ui.render', { component: 'Pane', requestId: PANE }, async ($, e) => {
const table = $.ui.resolve(e)
const { Box, Button, Link, Markdown, Text } = table
const Input = 'Input' in table ? table.Input : undefined
const Select = 'Select' in table ? table.Select : undefined
// The terminal's table answers Svg with an element that draws nothing, so ask the surface.
const Svg = e.surface !== 'terminal' && 'Svg' in table ? table.Svg : undefined
const now = await $.clock.now()
const busy = (text: string) => (
<Box flexDirection="row" columnGap={1} alignItems="center">
{Svg === undefined ? (
<Text color="claude">{spinnerFrame(now)}</Text>
) : (
<Svg source={SPINNER_SVG} alt="Loading" width={14} height={14} isInteractive />
)}
<Text dimColor>{text}</Text>
</Box>
)
if ((await read($, view)) === 'repos') {
const { here, repos: choices, load: status } = await read($, picker)
const shown = (await read($, page)).repo
const typed = await read($, query)
const sections = byOwner(choices, here, typed)
const isSessionShown = here !== null && matchesQuery(here, typed)
const isEmpty = sections.length === 0 && !isSessionShown
const row = (name: string, label: string) => (
<Box key={`repo:${name}`} flexDirection="row" columnGap={2}>
<Button
key={pickKey(name)}
label={name === shown ? `● ${label}` : label}
plain
onPress={() => void chooseRepo($, name)}
/>
<Text dimColor wrap="truncate-end">
{repoMeta(
choices.find(one => one.name === name),
now,
)}
</Text>
</Box>
)
return (
<Box flexDirection="column">
<Box flexDirection="row" justifyContent="space-between">
<Text bold>Choose a repository</Text>
{shown !== null && <Button key="back" label="Back" plain onPress={() => void backToIssues($)} />}
</Box>
{Input !== undefined && (
<Box marginTop={1}>
<Input
key="repo-filter"
placeholder="Filter, or type owner/name"
value={typed}
submitLabel="open"
onInput={text => void setQuery($, text)}
onSubmit={text => void submitQuery($, text)}
/>
</Box>
)}
{status.kind !== 'ready' && (
<Box marginTop={1}>
{status.kind === 'error' ? (
<Text dimColor wrap="wrap">
{status.message}
</Text>
) : (
busy(choices.length > 0 ? 'Refreshing…' : 'Loading repositories…')
)}
</Box>
)}
{isSessionShown && (
<Box flexDirection="column" marginTop={1}>
<Text dimColor bold>
This session
</Text>
{row(here, here)}
</Box>
)}
{sections.map(section => (
<Box key={`owner:${section.owner}`} flexDirection="column" marginTop={1}>
<Text dimColor bold>
{section.owner}
</Text>
{section.repos.map(choice => row(choice.name, choice.name.slice(section.owner.length + 1)))}
</Box>
))}
{status.kind === 'ready' && isEmpty && (
<Box marginTop={1}>
<Text dimColor wrap="wrap">
{isRepoName(typed.trim())
? `Press Enter to open ${typed.trim()}.`
: typed === ''
? 'No repositories found. Run /issues owner/name.'
: 'No match. Type owner/name and press Enter to open any repository.'}
</Text>
</Box>
)}
</Box>
)
}
const { repo: shown, scope, load: status, issues: list, total, labels, assigned } = await read($, page)
const opened = await read($, open)
const working = await read($, active)
const draft = await read($, searchDraft)
const noun = FILTERS.find(one => one.id === scope.filter)?.noun ?? scope.filter
const counted = `${total > list.length ? `${list.length} of ${total}` : list.length} ${noun}`
const narrowing = [
scope.search === '' ? '' : `matching "${scope.search}"`,
scope.label === '' ? '' : `label ${scope.label}`,
].filter(Boolean)
const labelChoices = labelOptions(labels, list, scope.label)
// A card's inside: the pane's width less its border and padding.
const rule = Math.max(1, e.props.bodyColumns - 4)
const [owner, name] = shown === null ? [null, null] : (shown.split('/') as [string, string])
// Labels are pills in one SVG where the surface draws SVG; on the terminal, dots and names.
// A cell is about 7.5 CSS pixels wide on the surfaces that draw SVG.
const pillsWidth = Math.max(160, Math.min(360, Math.floor(rule * 7.5)))
const chipsOf = (shownLabels: readonly IssueLabel[]) => {
if (Svg === undefined) {
return shownLabels.map(one => (
<Box flexDirection="row">
<Text color={labelDot(one.color)}>●</Text>
<Text>{` ${one.name}`}</Text>
</Box>
))
}
const pills = labelPills(shownLabels, pillsWidth)
return [
<Svg
source={pills.source}
alt={`Labels: ${shownLabels.map(one => one.name).join(', ')}`}
width={pills.width}
height={pills.height}
/>,
]
}
const top = (
<Box flexDirection="column">
<Box flexDirection="row" justifyContent="space-between" columnGap={2}>
<Box flexDirection="row" flexShrink={1}>
{owner === null ? (
<Text bold>No repository</Text>
) : (
<Text dimColor wrap="truncate-end">{`${owner} / `}</Text>
)}
{name !== null && (
<Text bold wrap="truncate-end">
{name}
</Text>
)}
</Box>
<Box flexDirection="row" columnGap={2} flexShrink={0}>
<Button key="switch" label="Switch repo" plain onPress={() => void showRepos($)} />
<Button key="refresh" label="Refresh" plain onPress={() => void rescope($, {})} />Licence text (MIT)
MIT License Copyright (c) 2026 Marco Carnevali 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
runs programsdrives Clauderemembers
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 6ca5bd373602 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 read | Every module hooks/hooks.json names was read.github-issues/hooks/register.tsx |
| Parses | Every file parses as TypeScript or JavaScript.2 files parsed |
| All its code is in the mod | Every import is a file of the mod or the engine's own module; no packages, no require.all its code is in the mod |
| Readable | No 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 open | Network 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 draws | The 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 line | Whether 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 Windows | Whether every program it starts through $.process exists on Windows (tail, date, open, osascript, /usr/… do not).runs no program a Windows PC lacks |
| Network | Whether every fetch names its https host in the code.no network |
| Programs | Whether every program it starts is named in the code and is not a shell, an interpreter or a network tool.github-issues/hooks/register.tsx:133 a program named at run time; github-issues/hooks/register.tsx:148 a program named at run time |
| Reads and sends | Whether it both reads files or environment variables and reaches the network.reaches no network |
| Keys in the source | Whether the source holds what looks like an API key or a private key.no keys in the source |
| Licence | An 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 MarcoCarnevali/claude-code-mods/plugin install github-issues@marco-modsThis installs the marketplace's latest commit, which may not be the one read here (6ca5bd373602). 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 "marcocarnevali-github-issues" with its code and make me a pane like itSearch them from Claude: the MCP connector
Similar designs
-
Ask Claude…agent-discoverbuildbuildbuildRefreshMCP Browse/3Tab / shift+Tab move · Enter presses · ↑↓ scroll · Esc back to the promptBrowse...Audit asks:DeclineAcceptDeclineCancelAudit asks:DeclineAcceptDeclineCancelAudit asks:DeclineAcceptDeclineCancel
-
Ask Claude…Usage▲usage-meterokPlan limitsNo rate-limit windows reported (API key, or a plan without limits).note▲ 42%2h 10m · +14:32%/h this session · full in ~4mnote▲ 42%2h 10m · +14:32%/h this session · full in ~4mnote▲ 42%2h 10m · +14:32%/h this session · full in ~4m⋯This sessionCostUsageTimeUsageTurnsUsageOutputUsageCache readUsageCache writeUsageLow cache hit: long pauses or edits to early context break the cache.Cache hitUsage
-
a1b2c3d's result did not fit in the promptAsk Claude…
-
Ask Claude…Backgrounda1b2c3dok · 2h 10m · exit Follow latest
$ npm testNo output yet.Follow latest -
Ask Claude…Prompt cacheexpired · LowTTL Cache breaks · last hit 0 · ctx 42%extending…This conversationavg hit – · req English · breaks Compact · extended Compact · peak ctx 12.4kPer request · token cost■ read ×0.1■ write□ miss▬▬▬ hit rate▬ break┊ idle near expiry▲ extendedCache breaksnone● Low Extend● Low Extend● Low ExtendBreak sensitivityEnglishHigher counts smaller drops as breaks; applies from the next requestExtensionsnone2h 10m · English · 32h 10m · English · 32h 10m · English · 3SettingsWhen about to expireLowAuto-extend per idle stretch2h 10mToast notificationsDetailsCache TTLautoPrompt cacheBand above the promptOffBreak sensitivityEnglishHigher counts smaller drops as breaks; applies from the next requestLanguageen
-
Ask Claude…clawdifybuild 3build 3build 3Presets layer on top of what you have. Reset first for a clean slate.Empty = Claude Code default · lists are comma-separated · tokens {model} {cwd} {time} {date}buildbuildbuildYours bring back exactly the look you saved. /clawdify delete <name> removes one.buildbuildbuildSave current as my-look savecopy JSONreset allWhile thinking