foldkit-form 0.4.3 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -83,7 +83,9 @@ const RenameForm = Page.children.rename
83
83
  ```
84
84
 
85
85
  - `Form.make` takes the name and an `Entity.input`. It resolves a control per
86
- key and throws if it cannot. A view must also supply a renderer for each
86
+ key and throws if it cannot. A form that writes no Entity of its own (a
87
+ sign-up, a search, a login) takes `Form.input(schema)`, an input over an
88
+ Entity defined from that schema: `Form.make('Search', Form.input(SearchInput))`. A view must also supply a renderer for each
87
89
  control kind, including custom kinds.
88
90
  - `Rename.bundle` is an ordinary Bundle. `onOut` is required, so a submit is
89
91
  never dropped by omission.
@@ -368,6 +370,9 @@ const PostForm = Form.make('PostForm', Entity.input(Post, PostInput), {
368
370
  ```
369
371
  - Each edit asks again after `debounce`, and an answer for a draft the key no
370
372
  longer holds is dropped.
373
+ - The ask is the form's Command `PostForm.Check` (named `PostForm.check`), a
374
+ Command definition like any other, so a Scene or Story resolves it with
375
+ `Command.resolve(PostForm.Check, PostForm.Message.Checked({ key, draft, error }))`.
371
376
  - **A submit waits.** Submitted while a check runs, the form sets `submitPending`
372
377
  and sends the value when the last check passes, or nothing if one fails. An
373
378
  edit in between cancels the wait. A filled form (`fill` validates nothing) is