Skip to content

opencode-latex v0.3.0

Choose a tag to compare

@kriss-spy kriss-spy released this 29 Nov 15:28
· 2 commits to main since this release

Fixes the SIXEL background mismatch (#7) and Unicode cells alignment failure (#9). Includes the OpenCode 2.4 migration that the Windows reporter confirmed resolves #8.

  • SIXEL formulas and cell padding use the enclosing painted background. Cached images refresh after a background change. Scroll container fills are included; Kitty keeps transparent pixels.
  • Unicode cells accept empty alignment cells and &-initial continuation rows. Literal text and public TeX content are preserved. Macro-generated alignment cells work, and \blacksquare renders as ■.
  • Requires OpenCode 2.4.0+ with OpenTUI Core >=0.9.4 <0.10.0.

Install

Version 0.3.0 is now available on npm with the latest tag. Install it through OpenCode:

opencode plugin add opencode-latex@0.3.0

The GitHub tarball remains available for a local install.

For Windows, with Node.js/npm available:

$testDir = Join-Path $env:USERPROFILE "opencode-latex-0.3.0"
New-Item -ItemType Directory -Force $testDir | Out-Null
Invoke-WebRequest "https://github.com/kriss-spy/opencode-latex/releases/download/v0.3.0/opencode-latex-0.3.0.tgz" -OutFile (Join-Path $testDir "opencode-latex-0.3.0.tgz")
tar -xzf (Join-Path $testDir "opencode-latex-0.3.0.tgz") -C $testDir
Set-Location (Join-Path $testDir "package")
npm install

Replace the existing LaTeX entry in opencode.jsonc with the extracted package's absolute path. Preserve other plugins and remove duplicate LaTeX entries. Restart OpenCode.

{
  "plugins": ["C:/Users/YOUR_NAME/opencode-latex-0.3.0/package"]
}

Use your actual path. The attached SHA256SUMS records the package checksum. Core 0.9.9 declares Node.js >=26.4.0 for local npm installs. Node 24 may emit an engine warning; the reporter successfully used it for beta.2. OpenCode renders with its bundled runtime.

Verification

  • Typecheck and all 42 tests pass on Core 0.9.4 / SDK 2.4.0 and Core 0.9.9 / SDK 2.4.2.
  • The extracted release package passes typecheck and all 42 tests after an offline Bun install from the dependency cache.
  • Native SIXEL output replayed into isolated Obsidian 1.14.5 / obsidian-opencode 2.4.1 reproduces the beta.2 mismatch. The fixed output matches the surrounding block in both dark and light screenshot checks.
  • The #8 reporter confirmed beta.2 on Windows 11 / OpenCode 2.4.2 / Windows Terminal. The new #7/#9 changes have not been retested on Windows or macOS. A complete OpenCode 2.4.2 session and real Kitty scrolling were not run for this release.

Verification details and screenshots

Older versions

There were no Git merge conflicts. Core 0.7/0.8 hosts need separate Markdown hook and native image adapters, plus their own test matrix. Widening this package's peer range cannot make it compatible. The historical 0.2.1 source targets OpenCode 2.2.2 / Core 0.7 and does not establish Core 0.8 support.

No extra compatibility code is needed outside this release for the tested Core 0.9.4 and 0.9.9 endpoints. The release includes handling for their different scroll-container representations.