GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Opentui 0.9.0 by simonklee · Pull Request #63989 · anomalyco/opencode

Conversation

@simonklee

@simonklee simonklee commented Nov 14, 2026 •
edited by opencodejr Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Added by the opencode bot (AI-generated).

Public API: @opencode/plugin peer dependencies @opentui/core and @opentui/solid change to >=0.9.4 (plugins must resolve OpenTUI 0.9.4+)

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
opencodejr[bot]
opencodejr Bot reviewed Nov 14, 2026
View reviewed changes

@opencodejr opencodejr Bot left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The upgrade looks sound. I ran a simulated reply with Markdown reasoning, a list, a code fence and a table on the base and with this PR, then expanded the thought. Both screens look the same (screenshots below). Tests pass in packages/tui, packages/latex and the merman markdown test, apart from the dialog-shell-output timeout test, which fails on the base too. tsc -b is clean for tui and latex.

Public API: the plugin API changes in a way that breaks existing renderers.

  • ctx.markdown.registerCodeBlockRenderer(language, render): render is OpenTUI's MarkdownCodeBlockRenderer. Its first argument changes from marked's Tokens.Code (raw, text, lang, …) to OpenTUI's MarkdownCodeBlock (text, lang, info, closed; no raw). A plugin renderer that reads token.raw, or parses the fence itself as the latex renderer used to, has to switch to block.text / block.closed.
  • @opencode/plugin peer dependencies change from @opentui/core/@opentui/solid >=0.8.4 to >=0.9.0, so plugins pinned to 0.8.x will no longer resolve.

A short note for plugin authors in the release notes would help. Nothing else is blocking.

Before

After

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@github-actions github-actions Bot mentioned this pull request Nov 14, 2026
📊 AI CLI 工具社区动态日报 2026-11-15 litang9/big_model_radar#706
Open
@simonklee
simonklee force-pushed the opentui-0.9.0 branch from ab67e72 to d44e053 Compare November 15, 2026 16:59
opencodejr[bot]
opencodejr Bot reviewed Nov 15, 2026
View reviewed changes

@opencodejr opencodejr Bot left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new push is a rebase onto a newer dev. The PR's 25 commits are identical patch for patch, so my earlier review still applies and I have nothing new to add. I didn't get type-check or test results on the rebased head before reporting.

Public API: unchanged since the last review. Plugin code-block renderers registered with ctx.markdown.registerCodeBlockRenderer now receive OpenTUI's MarkdownCodeBlock (text, lang, info, closed) instead of marked's Tokens.Code, so raw is gone. The @opentui/core/@opentui/solid peer dependencies move from >=0.8.4 to >=0.9.0. Both changes break existing plugins.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@opencodejr opencodejr Bot mentioned this pull request Nov 18, 2026
[FEATURE]: TUI plugin renderers for non-code markdown blocks and a per-part slot #64609
Open
1 task done
simonklee added 25 commits November 19, 2026 14:14
@simonklee
refactor(tui): move Markdown onto OpenTUI's native engine API
002ebd5
OpenTUI 0.9 parses Markdown natively and drops marked, coalesced mode
and the renderable's internals. Session links rewrite the parser's
spans with inlineHook (only blocks holding "ses_"), answer clicks with
targetAt and rerun the hook for renamed sessions; scrollback commits
committedBlockCount blocks with the gap above each; mono mode maps
prose through a hook and markers through their text; renderNode is
renderBlock, and LaTeX reads a fence's closed flag.
@simonklee
fix(tui): end each committed Markdown block's row in scrollback
d10fccd
A Markdown answer reaches scrollback one committed block at a time. Each
commit left the terminal on the block's last row, so the next commit's
blank gap row continued that line instead of making a blank row: on the
terminal "# Findings\n\n- stable" read "Findings\n- stable". A commit
of finished blocks now ends its last row; the entry's final commit
keeps the caller's line ending.
@simonklee
test(latex): show a closed fence's source after a rendered formula
a86f630
A fence that rendered a formula and then stopped parsing once its
closing line arrived lost its fallback: OpenTUI handed the renderer a
destroyed default and the fence went blank. OpenTUI keeps the default
now; this pins the sequence with the real renderer.
@simonklee
fix(tui): leave the last Markdown line open for the caller in scrollback
65a5a3a
Each committed Markdown block ended its line, so when an entry finished
with complete(false) and its last block was already written, the line
was ended anyway: a continuation showed "A\n!" instead of "A!". A
committed block is now written once another block follows it; the
last one waits for completion, which ends it as the caller asks.
@simonklee
tui: drop text padding that OpenTUI never painted
cb28f59
Select-dialog titles and the indented Read "Loaded" and execute error
lines set paddingLeft={3} on <text>. OpenTUI took that padding out of
the text's width but never painted it, so titles lined up with their
headers and the tool lines sat 3 cells in, from their parent box.

OpenTUI #2054 (2812326b0) paints text inside its padding. With it, every
select dialog's titles start 3 cells right of their header ("?    Title"
instead of "? Title") and the tool lines are indented 6 cells instead of 3.
Drop the props so the screen keeps today's look on both OpenTUI versions.
On 2812326b0, dialog-open's attention-icon test passes again, and the
headless Drive session's settled screens match those on the pinned 0.8.4.
@simonklee
fix(tui): run tweens and the tab marquee on the animation clock
29030cc
createAnimatable drove every tween from one module-global 16 ms
setInterval, and the tab title marquee scrolled on its own 80 ms
setInterval. Neither shared frames with the renderer's other
animations, and both woke the process on wall-clock timers.

Tweens now hold one 60 fps subscription on the renderer's shared
animation clock while any of them runs, so createAnimatable takes the
renderer from context. The marquee waits on the renderer clock and
scrolls by the clock's tick count at 12.5 fps; its first step lands on
the clock's 80 ms grid, up to one step after the 600 ms delay.
@simonklee
fix(tui): step shimmer and one-cell spinners on the animation clock
16e867b
The shimmer spinner's glyph and the sequenced one-cell spinner each ran
a private setInterval, so they never shared frames with the other
spinners and kept the process waking on their own phase.

Both now tick through onAnimationTick at their old rates (12.5 fps; the
one-cell spinner at 1000 / its step, 30 fps for the work spinners), and
advance by the tick count, so a late frame catches up instead of
dropping steps. Unmounting or turning animations off ends the
subscription.
@simonklee
fix(tui): tick retry provider and Go upsell art on the animation clock
40432cc
RetryProvider's fade held the renderer live with requestLive and a frame
callback, and GoUpsellArt was a live renderable. Both kept the renderer
in its full-rate loop and blocked renderer.idle() while they ran.

RetryProvider now subscribes at 60 fps on the shared clock for the
length of a transition; the clock's first tick measures from the
subscription, so the "fresh" flag that skipped idle time goes. The Go
art sets animationFps to 30, the rate its dialog's live loop ran at, so
it ticks only while drawn and stops on hide or destroy.
@simonklee
fix(tui): tick shimmer and fade text on the animation clock
106c131
ShimmerText was live for its whole life, and FadeInText and
TitleShimmer were live while they animated. Each held the renderer in
its full-rate loop, so renderer.idle() never resolved while one showed,
and they advanced their sweep by the frame's deltaTime in paint.

They now set animationFps to 60, the app's frame rate, and advance
their time in onAnimationTick. They tick only while drawn, stop when
hidden or destroyed, and FadeInText stops when its sweep ends.
TitleShimmer's "fresh" flag goes: the clock's first tick measures from
the subscription.
@simonklee
docs(tui): note that hook-driven animations ignore visibility
201b124
The Solid onAnimationTick hook and createAnimatable's clock are bound to
no node, so a view hidden with visible={false} keeps ticking. Core keeps
a node's draw state private, so binding them needs a Core API; until
then the call sites mount these views under <Show>.
@simonklee
test(tui): check that moved animations advance and settle
f592d81
The frame-rate rows counted frames and tickers, so an animation whose
time stopped still passed: the clock kept requesting frames. Each row
now samples the picture and needs it to change, and the Go art needs
six different pictures in 3 s. A late frame must land the one-cell
spinner and the tab marquee where steady frames do. A renamed title
must stop ticking once its wipe ends, and two tweens must share one
subscription that ends with the last of them.

Each new check fails on the break it targets (frozen shimmer, Go
art, title phase, one-cell spinner and tween; one step per tick in the
one-cell spinner and the marquee; no changed() after a title tick; a
subscription per tween).
@simonklee
chore(tui): bump OpenTUI to 0.9.0
2d007e2
@simonklee
test(tui): wait for the expanded thought's highlight in backfill test
b20a071
The thought body is Markdown in a code block that paints nothing until the tree-sitter worker answers. That answer is not tied to frames, so three quiet frames after the click can pass while the box is still blank. OpenTUI 0.9.0's first highlight in a process lands later than 0.8.4's, and on a loaded runner the test failed every time.

Wait with waitForHighlightedFrame, as the other session tests do.
@simonklee
fix(tui): keep a chip's attachment when undo restores the chip
5751698
Deleting a file, agent or skill chip and undoing it brought the chip back styled, but its part was gone, so the prompt went out with the mention as plain text and no attachment. OpenTUI's undo restores a mark with its id and data, but these chips carried no data and the composer had already dropped the id from its map.

Each chip now stores its part in the mark's data, as pasted text already did, and sync rebinds a restored mark from it. The mini footer does the same.
@simonklee
fix(tui): read a restored web prompt's mention ranges as cells
076297e
The web composer stores mention ranges as string indexes and the TUI stores display cells, and the server keeps either. After a tab or a wide character before a mention, reverting or forking a prompt sent from the web put its chip on the wrong text: in "\t中 @f x" the web range 3..5 marked "中 ".

A restored range that covers its text as string indexes but not as cells is now converted to cells, as the edit buffer's stringIndexToCellOffset() would.
@simonklee
fix(tui): size a pasted attachment's chip in cells
eb74d0f
pasteAttachment ended the chip at the label's string length, but edit buffer offsets count cells. A pasted image that reuses an existing label with wide characters, such as "[图片 1]", got a chip two cells short, and the prompt sent a mention that missed the end of its label. The chip is now measured like pasted text and other mentions.
@simonklee
fix(tui): end the compaction summary's stream when it finishes
7b38676
The compaction summary's Markdown stayed streaming after the compaction completed. A streaming document holds back a last line that can still change kind, such as a possible table row or a heading underline, so a finished summary ending in one never showed it. Streaming now follows the compaction's status, as assistant text already does.
@simonklee
refactor(tui): drop the prompt's timer workarounds around insertText
2783aeb
A plugin append and an inline paste waited a tick to invalidate the prompt's intrinsic size and render again, and the cursor color was set again on a timer after mount. The prompt now grows in the frame that inserts the text, and the cursorColor prop already follows the disabled state, so the timers only delayed the cursor move to the end of an append by a frame. A test checks that both inserts show every line in their first frame.
@simonklee
fix(tui): stop capping the renderer at 30 fps under the Go upsell
7192cea
The Go upsell dialog set the renderer's target and max fps to 30 while its art played. The art now ticks itself at 30 fps on the animation clock, so the cap no longer paced the art; it only slowed every other frame, such as typing and toasts, while the dialog was open, and it overwrote renderer-wide settings.
@simonklee
fix(tui): apply palette replies that arrive after the query
e30b74d
OpenTUI ends a palette query at the DA1 reply. An OSC 4/10/11 reply that arrives later, as over SSH or tmux, revises the renderer's palette and emits a palette event, but the full TUI only read the query's result, so the system theme kept the first, possibly default, colors until the next manual refresh. The theme now applies every palette event, as the mini footer already does; the query's own result goes through the same path.
@simonklee
refactor(tui): read delete positions without moving the cursor
cee6081
Completions found the row and column of a range by moving the cursor to each end and reading it back. Each move fired a cursor-changed event, which reran the prompt's cursor-dependent keymap layers, and in OpenTUI 0.9.0 the cursor setter snaps to the edge of a chip, so a move could read a position other than the one asked for. The positions now come from the edit buffer's offsetToPosition(). deleteRange() already leaves the cursor at the start of the range, as the moves did.
@simonklee
perf(tui): keep the prompt's part lists when a keystroke changes none
e18b287
Every content change rebuilt the prompt's files, agents, skills and pasted lists and assigned them to the store, even with no chips in the prompt, so each keystroke notified every reader of those lists. A list is now replaced only when its parts changed.
@simonklee
perf(tui): lay out the transcript as a list
682f950
The transcript is one column of rows, and while an answer streams only its last row changes. As a flex column, every frame ran Yoga's flex pass over every mounted row. A list lays out only the row that changed and reuses the others' sizes. Transcript rows never grow or shrink, so the layout is the same.
@simonklee
perf(tui): warm the markdown highlighter after the first frame
1c66c55
OpenTUI 0.9.0 draws Markdown prose natively, so answers no longer start the tree-sitter worker. The first thought or code fence then paid the whole cold start (worker, parser init, markdown grammars and queries) on the frame that showed it. The TUI now starts the worker and preloads the markdown and markdown_inline parsers once the first frame is out, and skips the rest if it is closing.

On a loaded machine, the first expanded thought after startup now highlights in 93 ms instead of 184 (median of 10 fresh starts) and the first TypeScript fence in 171 instead of 203, for about 40 ms of worker CPU once. With the worker warm, the backfill test's original quiet-frames wait passes again, also pinned to one busy CPU, so it goes back to that wait.
@simonklee
feat(tui): render reasoning as Markdown when markdown is rendered
e91e685
Reasoning was drawn as highlighted Markdown source in a code view, with markers concealed in rendered mode. With session.markdown set to rendered, thoughts now use OpenTUI's native Markdown, as answers do: tables are grids, headings and lists render, and fences show their code without the markers. None of the reasoning text goes to the highlighter, which re-highlighted the whole thought on every delta. The thought keeps its muted reasoning colours, and it stops streaming when the part completes, so a last line that could still change kind shows once the thought is done.

In source mode nothing changes: the code view and its props are the same. The mini footer follows the same setting for reasoning in scrollback and in the subagent view.
@simonklee
0.9.4
0770309
@simonklee
simonklee force-pushed the opentui-0.9.0 branch from d44e053 to 0770309 Compare November 19, 2026 13:15
opencodejr[bot]
opencodejr Bot reviewed Nov 19, 2026
View reviewed changes

@opencodejr opencodejr Bot left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since my last review there is one new commit, which moves OpenTUI from 0.9.0 to 0.9.4; the other 25 commits are the same, rebased onto a newer dev. I don't have type-check or test results on 0.9.4 yet: the run I started had not finished when I reported.

Public API: the plugin package's @opentui/core/@opentui/solid peer dependencies change from >=0.9.0 to >=0.9.4. Plugins have to resolve OpenTUI 0.9.4 or later. The Markdown code-block renderer change I described earlier is unchanged.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@simonklee
simonklee merged commit 4c5298b into dev Nov 19, 2026
12 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@simonklee
simonklee deleted the opentui-0.9.0 branch November 19, 2026 13:41
@Edo771977 Edo771977 mentioned this pull request Nov 19, 2026
chore: merge upstream/dev into the fork Edo771977/opencode#93
Merged
@BrewTestBot BrewTestBot mentioned this pull request Nov 23, 2026
opencode 2.4.0 Homebrew/homebrew-core#327368
Merged
@amrkmn amrkmn mentioned this pull request Nov 23, 2026
opencode 2.4.0 amrkmn/homebrew-tap#1251
Closed
1 task
@QuaanNguyen QuaanNguyen mentioned this pull request Nov 23, 2026
Check xor against OpenCode v2.2.0 (breaking plugin changes) QuaanNguyen/xor#87
Open
5 tasks
@github-actions github-actions Bot mentioned this pull request Nov 23, 2026
feat: opencode release v2.4.0 sprisa/opencode-server#95
Merged
@opencodejr opencodejr Bot mentioned this pull request Nov 25, 2026
fix(tui): copy text on WSL through Windows interop #66310
Closed
3 tasks done
carsteneu added a commit to carsteneu/opencode that referenced this pull request Nov 26, 2026
@carsteneu
chore(opentui): pin the guard to 0.9.4, the version the merge installs
47007f2
Upstream v2.4.1 bumps the catalog to 0.9.4 (Opentui 0.9.0, anomalyco#63989) and this
fork's own guard still expected 0.8.4, so check:opentui-pin failed on the merged
tree. The guard exists to keep one stock version in one place, not to hold a
particular release; 0.9.4 is what bun.lock resolves and what the TUI the merge
brings is written against.

proof: bun run check:opentui-pin -> openTUI pin check passed
@scottames-github-bot scottames-github-bot Bot mentioned this pull request Nov 27, 2026
chore(deps): update ⬆️ mise-packages scottames/dots#1181
Merged
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@opencodejr opencodejr[bot] opencodejr[bot] left review comments

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@simonklee
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.