Repository navigation
Releases: justrach/nanoui
Release list
nanoui 0.4.0
Highlights
ui.motion, after gpui-motion. Say where a box should be every frame; motion takes it there.- Springs are solved exactly and keep their speed when retargeted. Tweens have twelve easings and cubic-bezier.
presentkeeps a box drawn while it leaves toexit.hoverandpressare targets too.staggerdelays a list's items. Layout animation glides boxes the layout moves (scrolling isn't a move).- Keyframes loop or yoyo, and
numbereases a figure. - State lives in the Context by box: no animation objects. Frames are drawn only while something moves, and the system's Reduce motion jumps to the end.
nanoui.kit, components after GPUI Kit:- buttons in its variants and sizes, with icons, loading and tooltips
- tags, badges, avatars, alerts, skeletons, spinners, progress bars and rings
- tooltips, popovers, menus, dialogs, sheets and toasts, placed where they fit and closed by Escape or a click elsewhere
- tabs whose marker slides, breadcrumbs, pagination, accordions
- radio groups, selects, number inputs and fields
- Liquid Glass in motion. Glass buttons, tabs, menus and toasts in the kit. Interactive glass swells and lights up under a press, as iOS 26's does.
- Scale, layers and fixed boxes.
Style.scaledraws a box about its center (both renderers).Style.layerdraws over lower layers, unclipped, and takes clicks first.Style.fixedplaces a box from the window's corner. Context.statekeeps a widget's small state between frames.- Menu bar extras. Trays take clicks and show pixels. Popover windows are frameless panels that hide when they lose focus.
zig build reelrenders a 30-second video of all of it: six mock apps, drawn offscreen by nanoui.
The gallery has new Motion and Kit pages, and its Glass page now moves.
nanoterm 0.1.22, nanomon 0.1.6 and nanostudio 0.1.0 are built on these changes.
Full Changelog: v0.3.0...v0.4.0
nanoui 0.3.0
Highlights
- Emacs and Vim keys for text fields —
textField'skeysoption: readline's ^A ^E ^K ^U ^W ^Y and ⌥B ⌥F ⌥D with a kill buffer, or Vim's insert and normal modes (motions,d/c,x,p,j/kthrough the app's history) with a block caret. - Option and Control on keys — key events carry Alt and Ctrl, and Option-held keys are offered as shortcuts.
- Pictures drawn tinted — a monochrome mark in one color — and at one pixel per point.
- Rows as tall as their wrapped text beside a fixed-size box.
nanoterm 0.1.6–0.1.13 were built on these changes.
Full Changelog: v0.2.0...v0.3.0
nanoui 0.2.0
Liquid Glass
.glass(.{}) fills a box with Liquid Glass, the material of macOS 26 and later, in place of a background. Whatever was painted under the box shows through it: frosted, bent near its edges as through the rim of a lens, and lit along a hairline rim. That includes content scrolling under a toolbar placed over it.
.glass(.{ .tint = th.accent })makes a prominent button, and.style = .clearbarely frosts what's behind, for glass over photos and video.- Drawing: the Metal renderer averages and blurs what was drawn under each pane, then shades it. The CPU renderer computes the same pixels, so glass looks the same on Linux and Windows, and a test checks the two agree.
- Origin: ported from mygo's glass plugin and its measurements of AppKit's
NSGlassEffectView. - Demo: the gallery has a Glass page.
Closes #1.
Versions and releases
- One version: it lives in
build.zig.zon, the code reads it asnanoui.version, andsh tools/version.shsets or checks it. - Release workflow: pushing a
v*tag checks the version, runs the tests, and opens the release. - CI: tests every push on macOS (Metal and the CPU renderer) and on Linux.
Builds for older macOS
A build for -Dtarget=aarch64-macos.13.0 now finds Xcode's SDK, so apps can ship for macOS 13 and later. A native build requires the macOS it was built on.
Add it to a project with:
zig fetch --save git+https://github.com/justrach/nanoui#v0.2.0nanoui 0.1.0
The first versioned release of nanoui: desktop apps in Zig 0.17, drawn on the GPU.
- Native UI in GPUI's manner, drawn with Metal and CoreText on macOS. Linux (GTK 3) and Windows (Win32) use nanoui's own TrueType text and CPU renderer, which is tested against Metal.
- The toolkit: flexbox layout, GPUI-style element chains, a virtualized list, rich and selectable text, controls, text fields with IME support, pictures, shadows, and rounded clips.
- Web pages in the system webview (macOS), with typed Zig to TypeScript IPC and a generated client.
- Headless testing with
ui.Testerand the--nanoui-*flags. nanoui.Updater: apps shipped as signed bundles update themselves from their GitHub releases (macOS).
Add it to a project with:
zig fetch --save git+https://github.com/justrach/nanoui#v0.1.0