anomalyco / anomalyco/opencode
TUI: option to configure input cursor style (line/beam instead of block)
Open
@kommander is already working on this.
Since Jul 28, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Description
The prompt textarea in the TUI always renders a blinking block cursor. There is no way to change it to a thin line (beam), underline, or the terminal default.
Current behavior
- No
cursor/cursorStyleoption exists in thetui.jsonschema (checked https://opencode.ai/tui.json) or inopencode.json. - OpenTUI's
EditBufferRenderabledefaults tocursorStyle: { style: "block", blinking: true }and callssetCursorStyleon focus, so it overrides the terminal emulator's own cursor setting while the prompt is focused — configuring the terminal does not help.
Requested behavior
A tui.json option, e.g.:
{
"cursor": { "style": "line", "blinking": true }
}
with values matching OpenTUI's existing CursorStyle type: "block" | "line" | "underline" | "default" (packages/core/src/types.ts in anomalyco/opentui). "default" would leave the terminal's cursor style untouched.
Notes
- The rendering plumbing already exists:
EditBufferRenderableaccepts acursorStyleoption; opencode'spackages/tui/src/component/prompt/index.tsxjust never sets it and no config surface exposes it. - The web app already uses
cursorStyle: "bar"for its xterm instances (packages/app/src/components/terminal.tsx), so the TUI is the outlier.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.