Repository navigation
Releases
Releases · moonbase2090/lunatui
v0.1.49
Added
- README gallery recordings for
ParagraphandLineGauge, with two newwidget_previewcases (paragraph,line-gauge). - Element pages in
docs/elementsforSpinner,ProgressBar,StatusDot, andBadgewithKbd. - Element pages in
docs/elementsforParagraphwithTextView,Image,BigTextandMarkdownView. - Element pages in
docs/elementsforToastwithToastStack,NotificationCenterwithNotificationLog, andStatusBar. - Element pages in
docs/elementsforGauge,LineGauge,Sparkline,HeatmapandTimeline. - Element pages in
docs/elementsforChart,BarChart,PieChartwithPixelPieChart, andCanvas. - Element pages in
docs/elementsforNodeGraphandMermaidView. - Element pages in
docs/elementsforCodeView,DiffView,LogView,HexViewerandPseudoTerminal. - Element pages in
docs/elementsforLayoutDebug,LightcycleandWidgetList. scripts/check-element-docs.pynow fails when a public widget oflunatui-widgetshas no element page.docs/conventions.mdsection 5 now requires an element page for every public widget and an update to it when the widget's behavior changes.
v0.1.48
Added
- Element pages in
docs/elementsfor the dialogs and floating panels (Dialog,AlertDialog,Popup,Popover,Tooltip,Overlay) and the navigation and scrolling widgets (Accordion,Menu,ScrollView,Scrollbar,SplitTree,Tree). - Element pages in
docs/elementsforBreadcrumbs,List,TableandDataTable, withDataTablemarked as the canonical table for applications.
Changed
- Graphite text (the
graphite-textfeature) now reads the bundled fonts withskrifaand draws glyphs withab_glyph_rasterizer, replacingfontdueand the unmaintainedttf-parserit pulled in (RUSTSEC-2026-0192).cargo denyno longer ignores that advisory. Line metrics, glyph choice and text widths are unchanged; glyph edges on curves can differ by a few coverage levels.BundledText::loadnow takes under a millisecond.
v0.1.47
Added
- An element documentation standard in
docs/elements, with page templates, a checker (scripts/check-element-docs.py) and pilot pages forButton(both crates),TextInputandTabs. - Element pages in
docs/elementsforNumberInput,Slider,SearchBox,SelectandComboBox. - Element pages in
docs/elementsforCheckbox,Switch,Radio,RadioGroupandToggle. - Element pages in
docs/elementsforTagInput,DatePickerand the monthly calendar. - Element pages in
docs/elementsforFieldandForm. - An element page in
docs/elementsforTextArea. - Element pages in
docs/elementsforColorPickerandFilePicker. - Element pages in
docs/elementsforCommandPaletteandKeyHintBar.
Changed
- The website gallery describes each recording in words and keeps the activity monitor readable on narrow screens.
Fixed
- A
Switchfromlunatui-choicenow reports whether it is on to agents, so an agent's snapshot shows its state. - The
ColorPickerState::pointerdocumentation now says what the code does when a drag leaves the square or the hue bar.
v0.1.46
Added
- The
Imagewidget can display decoded images through the Prismattyc native presenter. If the native session is unavailable or fails, the runtime uses the terminal’s existing image fallback.
v0.1.45
Added
DatePicker::actlets an agent select a date withAction::SetValuetext asYYYY-MM-DD, answeringOutcome::Changed,Outcome::Handledwhen it was already selected, andOutcome::Ignoredfor text that is not a real date, a date outside the bounds, a disabled picker and any other action.
Fixed
- The terminal capability probe stops reading once the terminal has answered device attributes, a pixel graphics protocol (kitty, iTerm2 or sixel) and its cell size. Before, only a kitty terminal that also reported its background color ended the probe early, and other pixel terminals waited out the probe budget.
v0.1.44
Added
RadioGroup::actlets an agent choose an option withAction::Select, answeringOutcome::Changed,Outcome::Handledwhen it was already chosen, andOutcome::Ignoredfor a disabled or missing option and for any other action.Select::actlets an agent choose an option by its exact label withAction::SetValuefor the app's choice, answeringOutcome::Changed,Outcome::Handledwhen it was already chosen, andOutcome::Ignoredfor a label that names no option and for any other action. Opening the list stays with the app's layer.TableState::actlets an agent put the table's cursor on a row withAction::SelectorAction::Activate, andTableState::act_headersorts by a column header withAction::Activate, reversing the order when the column is already sorted. A row or column that does not exist, and any other action, giveOutcome::Ignored.- An agent can act on more widgets.
Slider::actandNumberInput::actset a value fromAction::SetValue(clamped, and snapped to the step or rounded to the decimals),Accordion::actopens or closes a section onAction::Toggle,TreeState::actselects a node or opens a branch onAction::SelectandAction::Activate,TagState(new) takes typed text withSetValueand commits it as a tag withActivate, andDateimplementsActfor aYYYY-MM-DDvalue.ActWithlendsActto a closure soRequest::applycan drive state that a widget bounds. Three roles are new,AccessibilityRole::Disclosure(disclosure),TagInput(tag_input) andCalendar(calendar), with their action lists in the snapshot.docs/named-controls.mdhas a table of widgets, roles and actions. A control the widget would not accept, such as text that is not a number or a date that does not exist, isOutcome::Ignoredand changes nothing.
v0.1.43
Added
- An agent can give several steps in one call.
Agent::plan(steps)takesSteps and the app callsAgent::advance(&hits)after each render; the agent checks and queues one step per frame, asAgent::actwould, so a step can name a control an earlier step made appear or enabled. The plan stops at the first failing step, andAgent::plan_status(id)reportsRunning,Waiting(for the application's confirmation),Done,Failed { step, error }orCancelled.Agent::cancel_plan(id)stops it. A second plan while one runs returns the newActError::Busy.
v0.1.42
Added
- An application decides what an agent may do. Mark a control whose action destroys work with
ControlMetadata::destructive(true)orField::destructive(true); the agent snapshot shows it asdestructive. By defaultAgent::actholds a request that would change such a control and returnsActError::NeedsConfirmation(id);Agent::awaiting()lists held requests for the app to put to the person,Agent::confirm(&hits, id)queues one after checking that the same control is still there and enabled, andAgent::decline(id)drops it.Agent::allow(hook)replaces the default with the app's own rule: the hook answersPermission::Allow,Deny(ActError::Denied, nothing queued) orConfirm, and can fall back onPermission::default_for. Focusing a control never needs confirmation.
Changed
- Breaking:
AgentControlhas adestructivefield, andActErrorhasDeniedandNeedsConfirmation. Code that builds anAgentControlwith a struct literal addsdestructive: false; amatchonActErroralready needs a wildcard arm.
v0.1.41
Added
- An agent can subscribe to control changes.
Agent::subscribe(query)returns aSubscriptionfor the controls aControlQuerymatches; each frame,Subscription::observereturns aControlChangefor every control whose value, checked state or states changed, or that appeared or went away, with its previous and currentControlValue. When the application records the change it applied withControlMetadata::changedorField::changed, the change also carries itsChangeReasonandChangeSource, so an agent can tell a keyboard edit from a click or its own action. run()draws in Graphite mode on terminals that can show it. It resolves the application'sModePolicyagainst the probed terminal instead of a cell-only backend: Graphite when the terminal draws pixel images and reports its cell size, Cell otherwise, withLUNATUI_MODEstill overriding. An application draws Graphite by building itsRenderCxfromRenderFrame::partsinRenderFrame::mode; one that only implementsrenderkeeps drawing cells.PixelLayer::cell_pixelsandset_cell_pixelsexpose the cell size images are drawn at, andrun()updates it from the terminal's window-size report on resize. The newactivity_monitor_liveexample draws the activity monitor live this way.- Graphite text can start fast on a tight CPU budget.
UiFont::InterCompactdraws with compact copies of Inter and JetBrains Mono that keep Latin with Latin-1 and Latin Extended-A, punctuation, currency, arrows, mathematical and technical symbols, box drawing, block elements and geometric shapes, and it has no fallback fonts, so any other character draws as the missing-glyph box. The three files it uses parse in under 3 ms on a developer machine, against about 30 ms for full Inter, JetBrains Mono and the Noto Sans fallback that box drawing and block elements reach through.BundledText::loadparses every font file a text can draw with, andBundledText::loadedsays whether that is done, so a program can draw its first frame in cells and load the fonts in a later call.lunatui_fonts::Family::compactreturns the compact files,COMPACT_RANGESlists what they keep, andscripts/subset-fonts.pywrites them. They add about 200 KB. Thegraphite_fontsexample draws a fourth specimen with the compact fonts.
Changed
- In Kitty, an image listed later in a frame now stays above an earlier image at the same depth. Kitty stacks images with the same z-index by image id, so a row image uploaded again with a higher id could cover a badge drawn over it.
PixelLayersends256 × depthplus the image's place in the frame as the z-index, so depth still decides first and negative depths stay under text. Depths must lie inPIXEL_DEPTHS, −8,388,608 to 8,388,607, where that z-index cannot saturate; an image at a depth outside it is refused, and a widget then draws its cells. Depths below −4,194,304 draw under cell backgrounds.
v0.1.40
Added
- Pointer events can carry where they fall inside a cell. The capability probe asks whether the terminal reports the mouse in pixels (mode 1016,
DecModes::sgr_pixel_mouse). When it does and the cell size is known,run()turns the reports on withMouseTracking::SgrPixelsand converts each event withMouseEvent::in_cells, so applications still get cell coordinates, now withMouseEvent::insideholding the pixel inside the cell. The cell size follows the terminal's window-size report on resize, throughterminal_cell_pixels.HitMap::pick_pointreturns the same hit aspick, with where the pointer is inside the region, andSlider::value_at_acrossgives a value that moves smoothly across a cell and equalsvalue_atat a cell's centre. Terminals without mode 1016 or a cell size keep cell reports, and Windows console input stays in cells.