aboutsummaryrefslogtreecommitdiffstats
path: root/tests/browser.mjs
Commit message (Collapse)AuthorAgeFilesLines
* Make the web surface accessible the way the say surface is, checked in ↵eunhhu2026-09-281-1/+44
| | | | | | | | | | | | | Chromium's accessibility tree Lists are listboxes that keep the keyboard focus, the focused row their active descendant, each option with its place in the whole list though only the visible rows are drawn; tables are grids with row indices; tones other than normal and muted are said, not only coloured; keys are named buttons. The page now updates in place instead of rebuilding each list, so the focus a screen reader follows survives every redraw. The browser test reads Chromium's accessibility tree: roles, names, focus, selection and the active descendant moving within the same list.
* Count the open tasks in the todo exampleeunhhu2026-09-261-1/+2
| | | | | | | | The left field said how many tasks there were; it now says how many are still open, "2 of 3", with aup's count(t in tasks where !t.done), which Pure runs as a fold over the list on every surface. The reference model counts the same, and in the browser the field follows a task marked done.
* Add a web surface: the same spec as a pageeunhhu2026-09-261-0/+91
vega web MODULE serves the screen to a browser (127.0.0.1 unless given --listen): one dependency-free page draws the title, fields, lists as listboxes and tables, with tones as colors and the focus highlighted. It asks for the screen as JSON with the rows it can show per list or table, so only those cells are evaluated, scrolled like the TUI around the focus. Keys go as KeyboardEvent.code, which is Pure's key naming already; typed text commits with Enter; a click or the wheel moves the focus through pure_app_point; an event stream tells every open page of each change. Scrolling, key presses and text commits are now shared helpers. The checks drive it against the model (1,200 random steps: title, field, rows, focus, the window of items with badges and tones), check a table's columns and cells, post at random to every example, and in headless Chromium over the DevTools protocol press keys, click a row and type Korean text into the page itself.