CRUD / foldkit-mixins-crud

What is drawn

PartElementSlot
The listdiv with the list's name as its idroot
Loading, failed, or emptyp role="status", aria-busy while loading, or role="alert" for a failurestatus
Asking again after a failurebutton type="button", when onRetry is givenretry
The rowstable, aria-busy while refreshingtable
The header and the bodythead, its tr, and tbodyhead, headRow, body
A column headerth scope="col", with aria-sort when it sortsheadCell
A header that sortsbutton type="button"sort
A rowtr, keyed by rowKey, else the row's id, else its positionrow
A celltdcell
The way into a rowbutton type="button" in the first shown cellopen
The next pagebutton type="button", disabled while refreshingmore

DetailSlots publishes root (the div around everything the detail says, in every state, as a list's root is), list (the dl, aria-busy while refreshing), status, term, value, and retry.

The way into a row is a button, not a click on the tr, so a keyboard reaches it and a screen reader announces it.

Limits

  • One layout each: a table, and a description list. For cards, or a table with grouped headers, draw from list.columns and Display.show yourself; this package is the default, not the only way.
  • A nested value (a relation read through a Selection) is shown as text, its members joined. Draw it specially with cells.
  • No selection of rows, and no inline editing.
  • No pager with page numbers: Remote's pages are cursors, and more appends.