Skip to content

Latest commit

 

History

History
168 lines (87 loc) · 9.55 KB

File metadata and controls

168 lines (87 loc) · 9.55 KB

@bomb.sh/tty

0.9.0

Minor Changes

  • #116 31fc1ae Thanks @natemoo-re! - Changes border sides to reserve layout space instead of drawing as an overlay. Each border width is now added to the padding on its side, so content and children are laid out inside the border rather than collapsing behind the border glyphs.

    This is a breaking change for callers who compensated for the old behavior by setting layout.padding equal to the border width — that padding is now additive and double-counts. Remove the workaround:

      {
        border: { color, left: 1, right: 1, top: 1, bottom: 1 },
    -   layout: { padding: { left: 1, right: 1, top: 1, bottom: 1 } },
      }

    A border of 1 with no padding now reserves one cell per bordered side; border of 1 plus padding of 1 reserves two, measured inward from the border edge.

  • #113 6efecfb Thanks @natemoo-re! - Adds a new term.update() method to resize the terminal without reinitializing the WebAssembly module.

    If you previously ran createTerm({ width, height }) on resize events, you should replace that with an explicit term.update({ width, height }) call.

  • #103 b9c10b3 Thanks @cowboyd! - Adds a caret property to text elements that positions the terminal's hardware cursor at a code-point offset within the text, resolved through wrapping and wide-character widths. The cursor shows only while a caret is declared; an offset at or past the content length places it one cell past the last character, giving text inputs a real, movable cursor.

Patch Changes

  • #89 2ebc906 Thanks @natemoo-re! - Shrinks the bundled WASM ~35% (156 kB → 101 kB raw) by compiling out Clay's unused debug-inspector UI.

  • #120 b371922 Thanks @natemoo-re! - Scales the renderer's memory arena to the terminal grid instead of a fixed default, cutting the reservation for an 80×24 grid ~51% (4.85 MB → 2.39 MB) with no change to render performance.

  • #49 d4bc79b Thanks @natemoo-re! - Fixes width measurement for non-printable, control, and surrogate code points, which now measure as one U+FFFD cell to match what the renderer draws (width data regenerated against Unicode 17).

0.8.0

Minor Changes

  • #27 Thanks @cowboyd! - Adds frame-to-frame transitions. Visual properties now interpolate between renders, covering the subset of animations Clay supports today.

  • #96 Thanks @rauhryan! - Adds per-side border support, so each edge of an element can be styled independently.

Patch Changes

  • #85 Thanks @natemoo-re! - Fixes nested clipping so a nested clip restores its parent's region instead of disabling clipping entirely.

0.7.0

Minor Changes

  • #99 Thanks @cowboyd! - Renames the published package to @bomb.sh/tty. The internal clayterm.wasm binary name is unchanged.

  • #93 Thanks @rauhryan! - Adds glyph-cell text backgrounds, so text can carry a per-glyph background color.

  • #94 Thanks @rauhryan! - Adds border-cell backgrounds, so border cells can carry their own background color.

  • #29 Thanks @rauhryan! - Expands the floating parameters on open() to cover more Clay options: expand, attachPoints, pointerCaptureMode, clipTo, and zIndex, exposed as string-literal enums.

  • #42 Thanks @dreyfus92! - Switches alignment properties to string literals instead of numeric magic values.

  • #17 Thanks @cowboyd! - Adds snapshot() to pre-pack a directive subtree into its binary transfer encoding, so unchanged subtrees are not re-encoded every frame.

  • #22 Thanks @cowboyd! - Adds RenderResult.info.get(id) for lazy, computed element bounding-box lookup.

  • #23 Thanks @cowboyd! - Surfaces Clay layout errors per render as errors: ClayError[] on RenderResult.

  • #14 Thanks @cowboyd! - Decouples alternate-buffer switching from clearing. alternateBuffer() accepts { clear }; clear: false uses xterm mode 47 to preserve alt-buffer contents.

  • #35 Thanks @natemoo-re! - Cuts npm install size ~63% (723 kB → 268 kB). Minimum Node is now v22.

  • #50 Thanks @natemoo-re! - Encodes the bundled WASM with brotli + Z85 instead of base64, cutting install size a further ~57% (270 kB → ~115 kB).

Patch Changes

  • #20 Thanks @cowboyd! - Breaking: Renames the numeric Op discriminant to directive and open()'s name argument to id. Element IDs are hashed with a constant seed, so ensuring uniqueness is now the caller's responsibility.

  • #33 Thanks @rauhryan! - Improves packed-string overflow errors. Oversized text and element-id payloads now throw a descriptive RangeError instead of corrupting the buffer.

  • #87 Thanks @natemoo-re! - Leaves the terminal default foreground for uncolored text, so uncolored glyphs no longer emit concrete white — fixing appearance on light-background terminals.

  • #24 Thanks @cowboyd! - Adds the MIT LICENSE file to match the declared license.

0.6.0

Minor Changes

  • #4 Thanks @cowboyd! - Adds a line rendering mode (render(ops, { mode: "line" })) for newline-separated, pipe-friendly output. The row option becomes a 1-based render-time option matching DSR/CPR.

  • #9 Thanks @cowboyd! - Inlines the WASM binary into the generated TypeScript module. This drops the node:fs/promises read and --allow-read, so the module imports from non-file:// URLs.

  • Adds a termcodes module and makes CursorEvent values 1-based to match the terminal's native DSR/CPR format.

Patch Changes

  • #7 Thanks @cowboyd! - Accepts signed int32 colors in the validator, so full-alpha rgba() colors (which serialize to a negative int32) no longer fail validation.

  • Allows cell fill across different initialization types.

0.5.0

Minor Changes

  • Parses DSR cursor-position reports and renames the row-offset render option to top.

0.4.0

Minor Changes

  • Adds a top (row offset) option to createTerm() for region-mode rendering.

  • Adds composable terminal settings that automatically revert when disposed.

0.3.0

Minor Changes

  • Adds pointer events and interactive hover to the Clay render pipeline, including the ability to capture mouse events.

  • Adds progressive Kitty keyboard protocol support, with "0" to reset all progressive enhancements and numpad Enter/Add handling.

0.2.0

Minor Changes

  • Adds a Kitty keyboard protocol (CSI u) input parser.

0.1.3

Patch Changes

  • Preserves the parent background when a text background is set to default.

0.1.2

Patch Changes

  • Fixes WASM memory allocation and adds an ops-buffer overflow check.

0.1.1

Patch Changes

  • Exports the input module from mod.ts.

0.1.0

Minor Changes

  • Adds a terminal input parser.

  • Adds ops validation backed by TypeBox schemas.

0.0.2

Patch Changes

  • Loads the WASM file with node:fs/promises.

0.0.1

Patch Changes

  • Fixes JSR publish by using token auth for scope authorization.

0.0.0

Initial Release

  • Initial release of the terminal rendering backend for Clay, compiled to WebAssembly. render() returns a Uint8Array of terminal output. Thanks @cowboyd!