Composition / API
foldkit-builder
foldkit-builder: the page builder's state, as an ordinary Bundle.
The Builder edits a foldkit-composition Document by Operations. Its Model
holds the page as an undo history (foldkit-primitives/state) whose present
is the Document, with the editor's state beside it (what is selected, the
open panel, the viewport), so an edit and the undo step that records it are
one value, changed in one transition. The Catalog and the Renderer are
vocabulary, not state: the Builder closes over them where it is made, and
they never enter the Model or a placement's args.
Placed as a form key's control (builder.input), the Document is that key's
value: the form validates it, submits it, and a CMS autosaves it, while a
selection or an open panel is not an edit. Placed alone, with
Bundle.withChild, its parent owns the Model instead.
Namespaces
Functions
controlOf | The control a prop is drawn with: the Block's hint, else what its Schema says. |
inputOf | The input an event of a Block runs an action with, as a form, made at the first use and kept. One per Block, event and action, so two events of one node… |
settingsOf | A Block's props as a form, made at the first use and kept: one per Block. |
Values
Announcer | What the editor says to assistive technology: a move, an insert, a refusal. |
ContextValue | A value of the page's context, as the editor previews it. |
Drag | A drag under way: what is dragged, what it is over, and where it would go. |
DragSource | What a drag carries: a node on the page, or a new node of a Block, from the palette. |
DropZone | Where over a node a drop lands: before it, inside it, or after it. |
editWords | |
Layers | The layers panel's keyboard focus and which rows are open: a tree that starts open. |
Message | |
Model | |
Panel | |
Viewport |
Interfaces
BuilderCommand | One thing the editor does, and every way to ask for it. |
CommandKey | A key that runs a command, named as KeyboardEvent.key names it. mod is Ctrl, or ⌘ on a Mac. mod and alt must be as given; shift must be as given only where… |
EditWords | The Builder's own words: what it says to assistive technology of each edit, its commands' labels, and the refusals it makes itself. Words are text; a word… |
InspectedForm | One form the inspector draws for the selected node, and its Model. |
Inspecting | The selected node as the inspector edits it: its Block and its forms. |