Server-side searchable allowed-values
The option palettes (:join-table, :target fields) ride /api/list (and /api/item) as allowed-values and ship the entire target display column to the client on every request. Mechanics (traced 2026-10-19): allowed-values (backend.lisp) → allowed-values-for-field → be-list-column → be-list with limit nil → add-page-clause emits no LIMIT — bounded only by RBAC read scope, never by size. Every page navigation re-sends every option of every palette field.
Consumers today all filter client-side over that one full array:
- M2M
:checkbox-list(CheckboxList.tsx): search box appears
at ≥10 options, case-insensitive substring filter, render cap 100 with "N more — type to narrow"; selected items always visible, never filtered
- The list-view chip picker (same search/cap split)
:target:select: renders =<option>=s for the whole column,
no search at all
- The searchable single-target picker (MVP item) deliberately
reuses the same architecture for v1
So the wire cost is the shared wall: payload grows linearly with the target table and every list fetch pays it, no matter how clever the widget. Fine for demos; wrong for real catalogs.
Direction:
- A searchable, paged column endpoint — e.g.
/api/column?type…&field=…&q=…&limit=…= — with an ILIKE arm in be-list-column (it already takes limit; the palette path just passes nil today). Debounced type-ahead from the frontend.
- Threshold switch: small targets keep the inline palette (no
extra requests); large targets go on-demand. Already-selected record values must still render whatever the palette returned (CheckboxList already renders palette-absent selected values; preserve that contract).
- Caching / ETag: palettes change rarely relative to list pages;
avoid re-querying the column per keystroke.
- Write path unchanged: widgets submit display names;
resolve-reference-id / list-ids resolve to ids at write time. No insert/update changes needed.
Related: "Searchable picker for single-target relations" (MVP — the client-side v1 this defers to), :searchable on M2M list fields (server-side EXISTS search for list filtering, a different engine arm, not palettes).
- Slot
- 13200
- Status
- 10 Open
- Tags
- backend, frontend, perf
- Contributors
- Donnie