facett-form — crate card
Reverse-engineered (from source — verify, don't trust the name)
- One-line pitch: Administrative / CRUD forms as a
Facet— labelled fields with per-field validation, error outlines, dirty-tracking, and JSON copy/paste. - Does: A consumer implements
FormModelfor its record structT;FormView<T>drives labelled fields (text / multiline / number / select-enum / masked YYYY-MM-DD date / checkbox), sections, submit/reset, and dirty-tracking against a baseline snapshot. Per-field validation + red-outline error styling is delegated toegui_form/gardebehind a thinFormUifield-builder seam (backend stays swappable).ValidationReportwrapsGardeReport(ok/from_garde), extractingfield path → messagefor both egui_form outlines and astate_jsonerrors map. Facet-level copy/paste round-trips the whole model as JSON viaFormModel::to_clip/from_clip. - Key deps:
facett-core(Facet, clip, theme),egui,egui_form(validator_garde),garde(derive),serde,serde_json. - Shape: lib; tiny (lib.rs + tests.rs); ships a
form_demoexample. Has a.nornir/design/facett-form.md. - Observed role in the workspace: Re-exported by umbrella
facettasfacett::form; reused by facett-card's edit mode (a card is a bound form over its own fields).
Fill in (one line each — only the human knows these)
- Primary consumer(s):
- Why it exists (vs the obvious alternative):
- Hard constraint (airgap / no-C-deps / no-FFI / pure-Rust / etc.):
- Release cadence & independence (rides a parent? own repo someday?):
- Status (production / prototype / experimental / stubbed):
- Must-NOT-change invariant:
- Biggest known gap or TODO:
- Anything a newcomer would get wrong about it: