foldkit-mixins-form 0.7.9 → 0.9.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
@@ -15,12 +15,14 @@ what else it does.
15
15
  | Classes, inline style, extra attributes and events | your `Style` / `Behavior` attachments |
16
16
  | The options of a relation picker, the submit button's words | the application, as view inputs |
17
17
 
18
- The optional `foldkit-mixins-form/ui` entry draws Text and Multiline fields
19
- through `foldkit-mixins-ui`'s Input and Textarea adapters. The main entry keeps
20
- the plain-HTML path and does not import that integration.
18
+ The optional `foldkit-mixins-form/ui` entry draws every control through
19
+ `foldkit-mixins-ui`'s components. The main entry keeps the plain-HTML path and
20
+ does not import that integration.
21
21
 
22
22
  It holds no state and adds no Messages. Every event it installs dispatches one
23
- of the form's own Messages (`Changed`, `Blurred`, `Submitted`).
23
+ of the form's own Messages: `Changed`, `Toggled` (a press on a flag or a choice,
24
+ applied to the draft as it lands), `Blurred`, `Searched`, `Submitted`, the row
25
+ Messages, `FollowedIssue` and `AskedForMore`.
24
26
 
25
27
  ## Mental model
26
28
 
@@ -69,12 +71,49 @@ Messages to its reducer; submitting a valid form sends its decoded value to
69
71
 
70
72
  The next example replaces this unstyled `Drawn` with field and form styles.
71
73
 
72
- ## UI-backed fields with a custom layout
74
+ ## A form drawn through `foldkit-mixins-ui`
73
75
 
74
76
  Install `foldkit-mixins-ui` and its `@foldkit/ui` peer to use the optional
75
77
  `foldkit-mixins-form/ui` entry. Import it as `UiForm`.
76
78
 
77
- `UiForm.field({ toMessage, inputStyle, textareaStyle?, draw? })` returns a
79
+ `UiForm.renderers(styles?)` is a renderer for every kind `foldkit-form` ships,
80
+ given to the whole-form view like any other renderers:
81
+
82
+ ```ts
83
+ import { Style } from 'foldkit-mixins'
84
+ import { FormView } from 'foldkit-mixins-form'
85
+ import * as UiForm from 'foldkit-mixins-form/ui'
86
+ import { InputSlots, Recipes, SelectSlots } from 'foldkit-mixins-ui'
87
+
88
+ const UiView = FormView.define(Edit, {
89
+ renderers: UiForm.renderers({
90
+ input: Style.forSlots(InputSlots)(Recipes.Input()),
91
+ select: Style.forSlots(SelectSlots)(Recipes.Select()),
92
+ }),
93
+ })
94
+ ```
95
+
96
+ Each style is optional and names its component: `input` (Text and Number),
97
+ `textarea`, `select` (Select and RelationOne), `checkbox` (Toggle) and
98
+ `checkboxGroup` (Choices and RelationMany). A table with no styles still draws a
99
+ complete form, unstyled.
100
+
101
+ What the table changes is the control, not the field. The label, description,
102
+ checking line and error stay the form view's, and each control keeps the plain
103
+ one's name, id, `aria-invalid`, `aria-required` and `aria-describedby`, so the
104
+ same interaction sends the same Messages either way. Text, Number, Multiline and
105
+ the selects are the plain elements under the component's Slot; a `FieldSlots`
106
+ style for `text`, `number`, `multiline` or `select` no longer reaches them, since
107
+ an element keeps one Slot's class. Toggle, Choices and RelationMany are the
108
+ Checkbox's `role="checkbox"` buttons, which Space presses and their label names;
109
+ a button posts nothing, so each checked one holds a hidden input with the key's
110
+ name, and a form posted without scripts still carries the value it was drawn
111
+ with; unlike the plain checkboxes, those buttons cannot be changed until a script
112
+ runs.
113
+
114
+ ## UI-backed fields with a custom layout
115
+
116
+ `UiForm.field({ toMessage, inputStyle, textareaStyle?, draw?, words? })` returns a
78
117
  `FormView.fields` override for Text and Multiline keys. `toMessage` wraps the
79
118
  form's Changed/Blurred Messages in the caller's Message universe (use an
80
119
  identity function for a whole-form view). Styles target `InputSlots` and
@@ -160,6 +199,7 @@ EditForm.view(model, h, {
160
199
  | `Number` | `input type="text" inputmode="decimal"` | `number` |
161
200
  | `Toggle` | `input type="checkbox"` | `toggle` |
162
201
  | `Select` | `select` of the control's own options, with a blank while nothing is chosen | `select`, `option` |
202
+ | `Choices` | a `role="group"` of checkboxes over the control's own options | `choices`, `choiceLabel`, `choice` |
163
203
  | `RelationOne` | `select` of `options[key]`, with a blank | `select`, `option` |
164
204
  | `RelationMany` | a `role="group"` of checkboxes over `options[key]`, each in a `label` with its words | `choices`, `choiceLabel`, `choice` |
165
205
  | `Nested` | a `fieldset` with a `legend`, a `div` per row holding the nested form's fields, and `button type="button"`s to add and remove a row | `group`, `legend`, `row`, `add`, `remove` |
@@ -168,9 +208,16 @@ A `RelationOne` or `RelationMany` that searches (`Input.search()`) gets an
168
208
  `input type="search"` above it, in the `search` slot, labelled `Search <label>`
169
209
  and naming the picker it controls with `aria-controls`. `words.search` in the
170
210
  view inputs replaces the word. The blank choice of a `select` has no words
171
- unless `words.none` gives it some ("none"). All of the view's words (`submit`,
172
- `submitting`, `checking`, `search`, `none`, `add`, `remove`) are text, with `{label}` and `{position}` as
173
- blanks; see [words in one place](../form/README.md#words-as-text-in-one-place).
211
+ unless `words.none` gives it some ("none"). A picker of the form itself that
212
+ the view inputs' `more` names (`more: { authorId: true }`, which
213
+ `foldkit-crud`'s `Crud.options` gives as `pickers.more(model)`) gets a
214
+ `button type="button"` under it, in the `more` slot, worded by `words.more`
215
+ (default `Show more`) and naming the picker with `aria-controls`; a press sends
216
+ the form's `AskedForMore({ key })`, for the page that owns the list to answer.
217
+ All of the view's words (`submit`,
218
+ `submitting`, `checking`, `search`, `none`, `add`, `remove`, `more`, `summary`,
219
+ `issue`, `inRow`) are text: `add` fills `{label}`, `remove` `{label}` and `{position}`,
220
+ `issue` `{label}` and `{error}`, and `inRow` `{row}` and `{label}`; the others are said as written. See [words in one place](../form/README.md#words-as-text-in-one-place).
174
221
 
175
222
  A chosen value its choices lack stays in sight: after the choices comes
176
223
  `? value`, chosen, in a `select` and in a `RelationMany`'s checkboxes. It is a
@@ -239,7 +286,7 @@ Fields.field(control, formModel, control.key, h, (input, draw) =>
239
286
  ```
240
287
 
241
288
  A override receives the control, its field, id, validity, errors, element
242
- attrs, and the `changed`/`blurred` Messages, so a custom layout reconstructs
289
+ attrs, and the `changed`/`blurred`/`toggled` Messages, so a custom layout reconstructs
243
290
  no form plumbing. A renderer reads the attrs that fit its element — `type` and
244
291
  `placeholder` on a text input, `placeholder` and `rows` on a textarea, and on
245
292
  both, and a number, `autocomplete`, `inputMode`, `enterKeyHint`,
@@ -266,7 +313,23 @@ Around each control, `FieldSlots` also publishes `root`, `label`, `description`,
266
313
  `checking`, `error`, `control` (around a Bundle's own view), and `group` and `affix`, for a
267
314
  renderer that draws text beside its control (a prefix, a unit) with the two
268
315
  together. `FormSlots` publishes `root` (the `form`), `errors` (failures that
269
- belong to no one field), `submit`, and the five slots of a nested key.
316
+ belong to no one field), `summary`, `summaryTitle`, `issues`, `issue` and
317
+ `issueLink` (the fields to fix, below),
318
+ `submit`, and the five slots of a nested key.
319
+
320
+ While any field is invalid, the form draws the fields to fix above its submit
321
+ button, beside `errors`: `words.summary` (default `Check these fields:`), then a
322
+ link to each invalid field in the order the fields are drawn, rows' too, each
323
+ worded by `words.issue` (default `{label}: {error}`); a field of a row is named
324
+ with its row by `words.inRow` (default `{row}, {label}`: `comments 2, body`),
325
+ so two rows' links differ; a row inside a row is named through both
326
+ (`shelves 1, books 2, title`). It sits low in the form,
327
+ so a field turning invalid never moves the fields above it, and it is no live
328
+ region: each field's own error already is. A link's `href` is the control's
329
+ `#id`, so with scripts off it goes there; with them on, a press focuses the
330
+ control itself (a choice group's first box) and goes nowhere, since an
331
+ application takes a link press as a navigation. The press sends the form's
332
+ `FollowedIssue({ id })`, which changes nothing.
270
333
 
271
334
  A Bundle's own view that takes inputs gets them from the view input
272
335
  `controls`, by key: `placed.view(model, h, { controls: { document: inputs } })`.
@@ -286,7 +349,9 @@ same for every row), and `words.add` / `words.remove` word the buttons (defaults
286
349
  A form's own check ([`checks`](../form/README.md)) leaves its key `Validating`
287
350
  until it answers. Meanwhile the control carries `aria-busy`, and under it a line
288
351
  in the `checking` slot, `role="status"`, says so (`words.checking`, default
289
- `Checking…`); the control names that line in `aria-describedby`. Each field's
352
+ `Checking…`); the control names that line in `aria-describedby`. A Bundle
353
+ control's own work (an upload) marks it `aria-busy` with no such line: the
354
+ control says what it is doing itself. Each field's
290
355
  `root` carries `data-validation`, the field's state by Foldkit's own tag
291
356
  (`NotValidated`, `Validating`, `Valid` or `Invalid`), so a stylesheet can mark it
292
357
  without a Style: `[data-validation='Valid'] label::after { content: ' ✓' }`. A
package/dist/index.d.mts CHANGED
@@ -3,7 +3,6 @@ import { Attr, Capability, Event, NamedStyle, Slot, SlotBuilders, SlotView, Slot
3
3
  import * as FieldValidation from "foldkit/fieldValidation";
4
4
  import * as Submodel from "foldkit/submodel";
5
5
  import { Attribute, Html, HtmlBuilder } from "foldkit/html";
6
- //#region src/index.d.ts
7
6
  /** One thing a select or a relation picker offers. */
8
7
  export interface Option {
9
8
  readonly value: string;
@@ -31,6 +30,18 @@ export interface FormViewWords {
31
30
  readonly checking?: string | undefined;
32
31
  /** On the submit button while the form is submitting. Default `Submitting…`. */
33
32
  readonly submitting?: string | undefined;
33
+ /** Above the list of fields to fix. Default `Check these fields:`. */
34
+ readonly summary?: string | undefined;
35
+ /** One field to fix, a link to it. Default `{label}: {error}`. */
36
+ readonly issue?: string | undefined;
37
+ /**
38
+ * A field of a row as the fields to fix name it, so two rows' links differ:
39
+ * `{row}` is the nested key's label, with the row's position when it holds
40
+ * many. Default `{row}, {label}`.
41
+ */
42
+ readonly inRow?: string | undefined;
43
+ /** On the button under a picker whose list has more rows than it shows. Default `Show more`. */
44
+ readonly more?: string | undefined;
34
45
  }
35
46
  /**
36
47
  * What the view needs that the form does not own: the choices of each relation
@@ -38,6 +49,13 @@ export interface FormViewWords {
38
49
  */
39
50
  export interface FormViewInputs<Key extends string = string> {
40
51
  readonly options?: { readonly [K in Key]?: ReadonlyArray<Option>; } | undefined;
52
+ /**
53
+ * The pickers whose list has more rows than `options` holds (`Crud.options`'
54
+ * `more`): each draws a button that sends the form's `AskedForMore`, for the
55
+ * page that owns the list to answer. Relation pickers of the form itself
56
+ * only, and none while locked.
57
+ */
58
+ readonly more?: { readonly [K in Key]?: boolean; } | undefined;
41
59
  /**
42
60
  * The choices of a picker inside a nested key, by its path, the same for every
43
61
  * row: `'author.country'`.
@@ -87,6 +105,10 @@ export interface FieldInput<Key extends string = string> {
87
105
  readonly noneWord?: string | undefined;
88
106
  /** What is said while the key's check runs: the view's `words.checking`. */
89
107
  readonly checkingWord?: string | undefined;
108
+ /** The Message a press of the picker's "more" button sends; none draws no button. */
109
+ readonly more?: unknown;
110
+ /** On that button: the view's `words.more`. */
111
+ readonly moreWord?: string | undefined;
90
112
  /**
91
113
  * Set for a field in a row of a nested key: its Messages, wrapped for the row.
92
114
  * A field of the form itself sends the form's own.
@@ -95,6 +117,7 @@ export interface FieldInput<Key extends string = string> {
95
117
  readonly changed: (value: Draft) => unknown;
96
118
  readonly blurred: unknown;
97
119
  readonly searched: (text: string) => unknown;
120
+ readonly toggled: (choice?: string) => unknown;
98
121
  } | undefined;
99
122
  /**
100
123
  * Set for a key edited by a control backed by a Bundle (`Input.bundle`): the
@@ -159,12 +182,25 @@ export declare const FieldSlots: Slots.Contract<{
159
182
  readonly choiceLabel: Slot.UnnamedSlot<Capability.Capability<"Base", readonly []>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
160
183
  /** Over a relation picker that searches: where the user types to find a choice. */
161
184
  readonly search: Slot.UnnamedSlot<Capability.Capability<"TextInput", readonly [Capability.Capability<"Focusable", readonly [Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>]>]>, readonly [Event.EventToken<"input">], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
185
+ /** Under a relation picker whose list has more rows: asks for them. */
186
+ readonly more: Slot.UnnamedSlot<Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>, readonly [Event.EventToken<"click">], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
162
187
  }>;
163
188
  /** The form around its fields. */
164
189
  export declare const FormSlots: Slots.Contract<{
165
190
  readonly root: Slot.UnnamedSlot<Capability.Capability<"Container", readonly [Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>]>, readonly [Event.EventToken<"submit">], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
166
191
  /** Failures that belong to no one field: a rule that spans keys. */
167
192
  readonly errors: Slot.UnnamedSlot<Capability.Capability<"Base", readonly []>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
193
+ /**
194
+ * The fields to fix, while any is invalid: its words (`summaryTitle`), then a
195
+ * list (`issues`) of `issue`s, each holding an `issueLink` to one field's
196
+ * control. Beside `errors`, above the submit button.
197
+ */
198
+ readonly summary: Slot.UnnamedSlot<Capability.Capability<"Container", readonly [Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>]>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
199
+ readonly summaryTitle: Slot.UnnamedSlot<Capability.Capability<"Base", readonly []>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
200
+ readonly issues: Slot.UnnamedSlot<Capability.Capability<"Collection", readonly [Capability.Capability<"Base", readonly []>]>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
201
+ readonly issue: Slot.UnnamedSlot<Capability.Capability<"Base", readonly []>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
202
+ /** A link to one field's control, which a press focuses. */
203
+ readonly issueLink: Slot.UnnamedSlot<Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>, readonly [Event.EventToken<"click">], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
168
204
  readonly submit: Slot.UnnamedSlot<Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>, readonly [Event.EventToken<"click">], readonly [Attr.AttrToken<"disabled">], readonly Slot.RequirementName[], boolean>;
169
205
  /** A nested key: the group around its rows, its name, each row, and the buttons that add and remove one. */
170
206
  readonly group: Slot.UnnamedSlot<Capability.Capability<"Container", readonly [Capability.Capability<"Interactive", readonly [Capability.Capability<"Base", readonly []>]>]>, readonly Slot.EventName[], readonly Slot.AttributeName[], readonly Slot.RequirementName[], boolean>;
@@ -201,7 +237,17 @@ interface FormLike<Key extends string, Model, Message> {
201
237
  readonly key: Key;
202
238
  readonly text: string;
203
239
  }) => NoInfer<Message>;
240
+ readonly Toggled: (payload: {
241
+ readonly key: Key;
242
+ readonly choice?: string;
243
+ }) => NoInfer<Message>;
204
244
  readonly Submitted: () => NoInfer<Message>;
245
+ readonly FollowedIssue: (payload: {
246
+ readonly id: string;
247
+ }) => NoInfer<Message>;
248
+ readonly AskedForMore: (payload: {
249
+ readonly key: Key;
250
+ }) => NoInfer<Message>;
205
251
  readonly Control: (payload: {
206
252
  readonly key: never;
207
253
  readonly message: unknown;
@@ -228,6 +274,13 @@ export interface RenderContext<Message> {
228
274
  readonly control: Control;
229
275
  readonly draft: Draft;
230
276
  readonly change: (value: Draft) => Message;
277
+ /**
278
+ * A press on a flag (no `choice`) or on one choice of a list, applied to the
279
+ * draft as it stands when it lands: send it for a press, rather than a
280
+ * `change` built from the draft as drawn, which a second press before the
281
+ * next draw would undo.
282
+ */
283
+ readonly toggled: (choice?: string) => Message;
231
284
  readonly blurred: Message;
232
285
  /**
233
286
  * For a control backed by a Bundle: its Model, and the Message carrying one of
@@ -262,6 +315,11 @@ export interface FieldOverrideInput<Key extends string = string, Changed = unkno
262
315
  readonly invalid: boolean;
263
316
  readonly errors: ReadonlyArray<string>;
264
317
  readonly changed: (value: Draft) => Changed;
318
+ /**
319
+ * A press on a flag (no `choice`) or one choice, applied to the draft as it
320
+ * lands: send it for a press, so two before the next draw both count.
321
+ */
322
+ readonly toggled: (choice?: string) => Changed;
265
323
  readonly blurred: Changed;
266
324
  /** What the key's element takes beyond the base field view. */
267
325
  readonly attrs: FieldAttrs;
@@ -405,6 +463,5 @@ export declare const FormView: {
405
463
  readonly canSubmit?: (model: Model) => boolean;
406
464
  }) => Submodel.View<Model, Message, FormViewInputs<Key>>;
407
465
  };
408
- //#endreg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