Repository navigation
v0.10.0
One collection of records, shown as a grouped tree, a sortable table or a board, is one component: Records. It replaces Tree. Mermaid diagrams stay readable on phones and in print.
What an author does differently
- Write
<Records {...plan} />with a config object (kit Records): flatdata,idField,fieldswith a kind each,columns, andgroupByfor the tree's levels.views,search,facetsandsortadd the controls; the view, sort, search, filters and open folds go in the URL hash, so<a href="#plan?f.owner=JV">opens a filtered list.linknames a filledVieweach row opens, with previous/next through the rows shown;detailnames a text field each row opens to in place, in the tree, the table and the board alike. - A field with
sum: trueadds subtotals and a total. Records without a value never count as zero: the sum shows what is known plus a question mark,1,372 h + ?(or?when no record has a value), since a missing value may be negative, and screen readers hear how many records it leaves out. - A block inside a
Viewkeeps its state after the view's route:#team?crew?view=table. A view's route ends at its first?, and what follows belongs to what the view holds; client code reads and writes that part withViews.local(el)andViews.setLocal(el, text), which keep the view's trail. Previous and next walk views by their route, so links that carry state (#v/a?panel?x=1) still get them, and follow each link with its state.View'sparamtakes the record id as it is; link to an id with?,#or%in it asencodeURIComponentwrites it (#s/a%3Fb). packchecks the config and fails with the path of each problem (fields.hours.kind) and what to write instead. It also fails on alinkthat names noView, and on a blockidthat is also a View's name, in the page and in each record a filledViewdraws.Treeis gone. Flatten its nesteditemsinto records with the group's name as a field, list those fields ingroupBy, and move a row'stextandrefinto fields named bydetailandrefField. Hand-written.treemarkup still works. Uneven depths and JSX cells have no Records form; write the<details>yourself for those.- New label keys for the block's controls and texts (
kit labelslists them, all starting withrecords).
Mermaid
- Mermaid diagrams stay readable on phones. A flowchart or state diagram too wide for a phone gets a second layout across its direction (left to right becomes top-down), shown below 40rem, so left to right is fine to write. Other diagrams shrink until their smallest text is 10 px, then scroll sideways. Printed, each diagram fits the paper whole, top-down when the left-to-right layout would be too small to read.
- A diagram's width limits are the custom properties
--mermaid-maxand--mermaid-minon itssvg, so one page rule can change them. - A circle node with a short label is about the size of a box node, not a large disc.
- Flowcharts turn back only the edges of a real cycle. An input written after the node it feeds now sits before that node, instead of being looped around it.
check's warning about tiny SVG text names the fix: drop the page rule that squeezes a diagram, or for a hand-built SVG, redraw it about 360 wide or hold it at themin-widthit gives inside a.scrollblock.
check
checkwaits after each load and--dostep until the page has settled instead of a fixed time: fonts loaded, every visible chart drawn, and the timers of up to 1 s the page set have run. A slow island chart is in the shots, and an error a page throws shortly after a click is reported. What is still missing after 10 s is a problem:still waiting after 10 s for charts to be drawn: div#sales.chart.- When Chrome fails to start or stops answering,
checkprints one line naming where it was (the screen, and the--dostep if one was running) and exits 1 with no report, for exampleerror: the load event of file:///…/page.html did not come in 10 s (at dark narrow, view #fix/none). It used to wait forever. - A
checkthat stops with an error, or is ended by Ctrl-C or SIGTERM, leaves--outas it was: the PNGs of a run move there only once it has finished. --tagtakes a name without a path separator;--tag ../xis a usage error, since it would write PNGs outside--out.--timeout <seconds>(default 600) limits the whole run, Chrome's start-up included:error: check passed its 600 s limit at light desktop, view #plan/a, after 324 page(s): raise --timeout for a page with many views or --do steps.- Chrome exits with
checkhowevercheckends, and its profile and temp files are deleted (also on Ctrl-C or SIGTERM, sent once or twice). Before, every run left a profile of up to 150 MB in the temp directory, and with Google Chrome acom.google.Chrome.chrome_chrome_url_fetcher_.*directory, and acheckkilled by a timeout left a Chrome running that used a CPU core. - Chrome no longer downloads components or models while it checks a page.
- On Linux, a
TMPDIRtoo deep for the socket Chrome keeps there (about 50 characters) stopscheckwitherror: Chrome cannot start in a temp directory this deep (…): … set TMPDIR to a shorter one, such as /tmp, instead of Chrome's stack trace.