CRUD / foldkit-mixins-crud

foldkit-mixins-crud

Draws a foldkit-crud list as an accessible table and a detail as a description list, with every element published as a foldkit-mixins Slot. The list decides which rows and columns there are; each column's Display decides what a cell says; this package decides which elements show it; your Style and Behavior attachments decide how it looks.

What it owns

FactOwner
The rows, the pages, whether they are loadingfoldkit-remote, read through Crud.list(...).at
The columns, their labels, and each one's Displayfoldkit-crud
Which element draws them, and the accessibility wiringfoldkit-mixins-crud
What opening a row, sorting, and "more" meanthe application, as Messages it passes in
Classes, inline style, extra attributes and eventsyour Style / Behavior attachments

It holds no state and defines no Messages. A list is not a Bundle, so there is nothing for a click to be sent to but your own update: every button here sends a Message you gave it.

Mental model

Crud.list('Posts', { query, selection })        columns + Displays (no view)
      |
ListView.forMessages<Message>().define(list)    a SlotView over ListSlots
      |   .pipe(Style.attach(...))
Table({ page, onOpen, onMore, sort, words }, h) one call in your view

The view is given the page each time it draws, the same value PostList.page(model) returns. It never reads Remote itself.

Install

sh
pnpm add effect foldkit foldkit-crud foldkit-mixins foldkit-mixins-crud foldkit-remote