viewkitjs 0.31.0 → 0.32.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.
Files changed (289) hide show
  1. package/CHANGELOG.md +129 -0
  2. package/MIGRATION.md +40 -6
  3. package/README.md +1 -1
  4. package/fields/dist/query/index.d.ts +2 -0
  5. package/fields/dist/query/index.js +2 -0
  6. package/fields/dist/query/list-request.d.ts +148 -0
  7. package/fields/dist/query/list-request.js +125 -0
  8. package/fields/dist/query/saved-view.d.ts +15 -0
  9. package/fields/dist/query/saved-view.js +11 -0
  10. package/fields/dist/query/settings.d.ts +9 -0
  11. package/fields/dist/query/settings.js +9 -0
  12. package/fields/docs/reference/query.md +66 -0
  13. package/package.json +5 -1
  14. package/postgres/README.md +1 -0
  15. package/postgres/dist/handler.d.ts +53 -0
  16. package/postgres/dist/handler.js +211 -0
  17. package/postgres/dist/ids.d.ts +1 -1
  18. package/postgres/dist/ids.js +19 -1
  19. package/postgres/dist/index.d.ts +1 -0
  20. package/postgres/dist/index.js +1 -0
  21. package/postgres/dist/limits.d.ts +3 -1
  22. package/postgres/dist/limits.js +1 -1
  23. package/postgres/dist/list-fields.d.ts +10 -0
  24. package/postgres/dist/list-fields.js +36 -0
  25. package/postgres/dist/readable.d.ts +4 -0
  26. package/postgres/dist/readable.js +4 -0
  27. package/postgres/dist/refusals.d.ts +9 -2
  28. package/postgres/dist/refusals.js +6 -0
  29. package/postgres/docs/guides/field-map.md +2 -2
  30. package/postgres/docs/guides/list-handler.md +99 -0
  31. package/postgres/docs/index.md +1 -0
  32. package/postgres/docs/reference/postgres.md +11 -3
  33. package/views/README.md +2 -2
  34. package/views/dist/atoms/RowMenu.d.ts +7 -0
  35. package/views/dist/atoms/RowMenu.js +18 -16
  36. package/views/dist/atoms/carried.d.ts +5 -0
  37. package/views/dist/atoms/carried.js +7 -0
  38. package/views/dist/atoms/types.d.ts +3 -0
  39. package/views/dist/contract.d.ts +26 -6
  40. package/views/dist/contract.js +25 -0
  41. package/views/dist/controls/alert-dialog/alert-dialog.js +2 -1
  42. package/views/dist/controls/atoms.d.ts +2 -0
  43. package/views/dist/controls/atoms.js +2 -0
  44. package/views/dist/controls/avatar/avatar.d.ts +3 -3
  45. package/views/dist/controls/avatar/avatar.js +1 -1
  46. package/views/dist/controls/avatar/tokens.d.ts +44 -0
  47. package/views/dist/controls/avatar/tokens.js +11 -0
  48. package/views/dist/controls/avatar.css +22 -5
  49. package/views/dist/controls/choice/tokens.d.ts +0 -4
  50. package/views/dist/controls/choice/tokens.js +0 -1
  51. package/views/dist/controls/choice.css +3 -3
  52. package/views/dist/controls/controls.d.ts +6 -0
  53. package/views/dist/controls/controls.js +10 -2
  54. package/views/dist/controls/customize/map-customize-body.js +1 -1
  55. package/views/dist/controls/field/field.d.ts +19 -4
  56. package/views/dist/controls/field/field.js +63 -5
  57. package/views/dist/controls/field/tokens.d.ts +4 -0
  58. package/views/dist/controls/field/tokens.js +1 -0
  59. package/views/dist/controls/field.css +41 -16
  60. package/views/dist/controls/glyphs/glyphs.d.ts +10 -0
  61. package/views/dist/controls/glyphs/glyphs.js +173 -0
  62. package/views/dist/controls/index.d.ts +2 -1
  63. package/views/dist/controls/index.js +2 -1
  64. package/views/dist/controls/input/input.js +5 -2
  65. package/views/dist/controls/input/tokens.d.ts +4 -0
  66. package/views/dist/controls/input/tokens.js +1 -0
  67. package/views/dist/controls/input.css +31 -3
  68. package/views/dist/controls/internal/icons.js +10 -0
  69. package/views/dist/controls/internal/keep-focus.d.ts +2 -0
  70. package/views/dist/controls/internal/keep-focus.js +17 -0
  71. package/views/dist/controls/internal/watch-frame.d.ts +2 -0
  72. package/views/dist/controls/internal/watch-frame.js +33 -0
  73. package/views/dist/controls/markdown/map-markdown.d.ts +4 -0
  74. package/views/dist/controls/markdown/map-markdown.js +5 -0
  75. package/views/dist/controls/menu/map-menu.js +2 -2
  76. package/views/dist/controls/menu-list/menu-list.d.ts +3 -0
  77. package/views/dist/controls/menu-list/menu-list.js +5 -4
  78. package/views/dist/controls/modal/modal.js +5 -1
  79. package/views/dist/controls/pane/pane.js +2 -1
  80. package/views/dist/controls/phone-header/header-bar.d.ts +5 -1
  81. package/views/dist/controls/phone-header/header-bar.js +2 -2
  82. package/views/dist/controls/phone-header.css +11 -1
  83. package/views/dist/controls/picker/map-picker.js +3 -0
  84. package/views/dist/controls/picker/picker.d.ts +14 -0
  85. package/views/dist/controls/picker/picker.js +30 -10
  86. package/views/dist/controls/picker.css +2 -0
  87. package/views/dist/controls/popover/popover.js +2 -1
  88. package/views/dist/controls/radio/radio.d.ts +5 -3
  89. package/views/dist/controls/radio/radio.js +18 -2
  90. package/views/dist/controls/radio/tokens.d.ts +44 -0
  91. package/views/dist/controls/radio/tokens.js +11 -0
  92. package/views/dist/controls/radio.css +79 -1
  93. package/views/dist/controls/select/select.d.ts +4 -0
  94. package/views/dist/controls/select/select.js +11 -5
  95. package/views/dist/controls/select/tokens.d.ts +8 -0
  96. package/views/dist/controls/select/tokens.js +2 -0
  97. package/views/dist/controls/select.css +17 -0
  98. package/views/dist/controls/setting-row/looks.d.ts +1 -1
  99. package/views/dist/controls/setting-row/looks.js +9 -4
  100. package/views/dist/controls/setting-row/setting-row.d.ts +45 -10
  101. package/views/dist/controls/setting-row/setting-row.js +82 -15
  102. package/views/dist/controls/setting-row/tokens.d.ts +74 -2
  103. package/views/dist/controls/setting-row/tokens.js +19 -1
  104. package/views/dist/controls/setting-row.css +135 -14
  105. package/views/dist/controls/sheet/bottom-sheet.d.ts +10 -2
  106. package/views/dist/controls/sheet/bottom-sheet.js +6 -3
  107. package/views/dist/controls/sheet.css +4 -1
  108. package/views/dist/controls/sort-editor/sort-editor.js +3 -2
  109. package/views/dist/controls/sort-editor.css +8 -2
  110. package/views/dist/controls/switch-row/tokens.d.ts +0 -12
  111. package/views/dist/controls/switch-row/tokens.js +0 -3
  112. package/views/dist/controls/switch-row.css +3 -7
  113. package/views/dist/controls/switch.css +17 -7
  114. package/views/dist/controls/tag/tag.d.ts +3 -1
  115. package/views/dist/controls/tag/tag.js +2 -2
  116. package/views/dist/controls/tag/tokens.d.ts +4 -0
  117. package/views/dist/controls/tag/tokens.js +1 -0
  118. package/views/dist/controls/tag-field/tag-field.d.ts +5 -1
  119. package/views/dist/controls/tag-field/tag-field.js +11 -5
  120. package/views/dist/controls/tag-field/tokens.d.ts +16 -0
  121. package/views/dist/controls/tag-field/tokens.js +4 -0
  122. package/views/dist/controls/tag-field.css +19 -0
  123. package/views/dist/controls/tag.css +2 -0
  124. package/views/dist/controls/toolbar/toolbar.d.ts +15 -3
  125. package/views/dist/controls/toolbar/toolbar.js +22 -15
  126. package/views/dist/controls/toolbar-button/atom-toolbar-button.d.ts +14 -0
  127. package/views/dist/controls/toolbar-button/atom-toolbar-button.js +51 -0
  128. package/views/dist/controls/toolbar-button/toolbar-button.d.ts +1 -1
  129. package/views/dist/controls/toolbar-button/toolbar-button.js +2 -3
  130. package/views/dist/controls/toolbar-button.css +4 -0
  131. package/views/dist/controls/toolbar.css +5 -0
  132. package/views/dist/controls/views-list/map-view-menu.d.ts +3 -0
  133. package/views/dist/controls/views-list/map-view-menu.js +25 -0
  134. package/views/dist/controls/views-list/map-views-list-body.d.ts +28 -1
  135. package/views/dist/controls/views-list/map-views-list-body.js +39 -21
  136. package/views/dist/controls/views-list/rules.d.ts +2 -0
  137. package/views/dist/controls/views-list/view-menu.d.ts +7 -0
  138. package/views/dist/controls/views-list/view-menu.js +28 -24
  139. package/views/dist/controls/views-list/words.d.ts +2 -0
  140. package/views/dist/controls/views-list/words.js +1 -1
  141. package/views/dist/editors/EditorPanel.js +2 -1
  142. package/views/dist/editors/edit-session.js +2 -5
  143. package/views/dist/field-row/FieldRow.d.ts +4 -2
  144. package/views/dist/field-row/FieldRow.js +67 -20
  145. package/views/dist/field-row/FieldRowLane.d.ts +7 -2
  146. package/views/dist/field-row/FieldRowLane.js +4 -3
  147. package/views/dist/field-row/editors/RowEditor.d.ts +12 -0
  148. package/views/dist/field-row/editors/RowEditor.js +31 -1
  149. package/views/dist/field-row/editors/RowValueListEditor.d.ts +5 -1
  150. package/views/dist/field-row/editors/RowValueListEditor.js +4 -1
  151. package/views/dist/field-row/field-row-button.d.ts +5 -0
  152. package/views/dist/field-row/field-row-button.js +2 -0
  153. package/views/dist/fields/binding.d.ts +3 -2
  154. package/views/dist/fields/binding.js +38 -5
  155. package/views/dist/grid/chrome/GridColumnMenu.d.ts +4 -2
  156. package/views/dist/grid/chrome/GridColumnMenu.js +3 -2
  157. package/views/dist/grid/chrome/GridGroupMenu.d.ts +4 -1
  158. package/views/dist/grid/chrome/GridGroupMenu.js +4 -3
  159. package/views/dist/grid/chrome/GridHeader.d.ts +4 -1
  160. package/views/dist/grid/chrome/GridHeader.js +2 -2
  161. package/views/dist/grid/chrome/GridRow.js +6 -5
  162. package/views/dist/grid/chrome/GridRowCells.js +6 -9
  163. package/views/dist/grid/chrome/GridStructure.d.ts +4 -1
  164. package/views/dist/grid/chrome/GridStructure.js +4 -4
  165. package/views/dist/grid/chrome/GridTable.js +5 -2
  166. package/views/dist/grid/chrome/grid-column-menu-items.js +1 -1
  167. package/views/dist/grid/chrome/grid-row-menu-items.d.ts +27 -3
  168. package/views/dist/grid/chrome/grid-row-menu-items.js +92 -6
  169. package/views/dist/grid/chrome/grid-row-props.d.ts +7 -2
  170. package/views/dist/grid/chrome/grid-rows-menu.js +34 -6
  171. package/views/dist/grid/chrome/grid-table-props.d.ts +38 -7
  172. package/views/dist/grid/chrome/useGridBatchApi.d.ts +3 -1
  173. package/views/dist/grid/chrome/useGridBatchApi.js +4 -2
  174. package/views/dist/grid/chrome/useGridKeyboard.d.ts +4 -2
  175. package/views/dist/grid/chrome/useGridKeyboard.js +15 -9
  176. package/views/dist/grid/chrome/useGridPendingReconciliation.js +1 -2
  177. package/views/dist/grid/chrome/useGridTableInteractionModel.d.ts +1 -1
  178. package/views/dist/grid/chrome/useGridTableInteractionModel.js +11 -5
  179. package/views/dist/grid/core/commit-model.d.ts +20 -2
  180. package/views/dist/grid/core/editing-controller.d.ts +18 -0
  181. package/views/dist/grid/core/editing-controller.js +188 -42
  182. package/views/dist/grid/core/editing-model.d.ts +3 -0
  183. package/views/dist/grid/core/editing-model.js +3 -0
  184. package/views/dist/grid/core/save-path.d.ts +24 -0
  185. package/views/dist/grid/core/save-path.js +122 -0
  186. package/views/dist/grid/core/spreadsheet-operations.d.ts +3 -0
  187. package/views/dist/grid/core/spreadsheet-operations.js +23 -0
  188. package/views/dist/grid/index.d.ts +3 -2
  189. package/views/dist/grid/index.js +1 -0
  190. package/views/dist/internal/field-rows.d.ts +26 -0
  191. package/views/dist/internal/field-rows.js +8 -0
  192. package/views/dist/internal/page-close.d.ts +7 -0
  193. package/views/dist/internal/page-close.js +43 -0
  194. package/views/dist/list/browser-views-store.d.ts +10 -0
  195. package/views/dist/list/browser-views-store.js +182 -0
  196. package/views/dist/list/index.d.ts +23 -0
  197. package/views/dist/list/index.js +8 -0
  198. package/views/dist/list/menu.d.ts +31 -0
  199. package/views/dist/list/menu.js +76 -0
  200. package/views/dist/list/parts.d.ts +6 -0
  201. package/views/dist/list/parts.js +59 -0
  202. package/views/dist/list/registry.d.ts +11 -0
  203. package/views/dist/list/registry.js +31 -0
  204. package/views/dist/list/root.d.ts +40 -0
  205. package/views/dist/list/root.js +128 -0
  206. package/views/dist/list/slot.d.ts +14 -0
  207. package/views/dist/list/slot.js +22 -0
  208. package/views/dist/list/source.d.ts +11 -0
  209. package/views/dist/list/source.js +31 -0
  210. package/views/dist/list/store.d.ts +87 -0
  211. package/views/dist/list/store.js +115 -0
  212. package/views/dist/list/toolbar.d.ts +6 -0
  213. package/views/dist/list/toolbar.js +359 -0
  214. package/views/dist/list/views-axis.d.ts +5 -0
  215. package/views/dist/list/views-axis.js +96 -0
  216. package/views/dist/list/views-store.d.ts +41 -0
  217. package/views/dist/list/views-store.js +1 -0
  218. package/views/dist/list/views.d.ts +67 -0
  219. package/views/dist/list/views.js +400 -0
  220. package/views/dist/model/preferences.js +1 -1
  221. package/views/dist/model/prefs-buckets.js +1 -1
  222. package/views/dist/panels/index.d.ts +3 -1
  223. package/views/dist/panels/index.js +1 -0
  224. package/views/dist/panels/react/customize-body.js +1 -0
  225. package/views/dist/panels/react/toolbar/ReadyToolbar.d.ts +41 -4
  226. package/views/dist/panels/react/toolbar/ReadyToolbar.js +6 -326
  227. package/views/dist/panels/react/toolbar/Toolbar.d.ts +9 -1
  228. package/views/dist/panels/react/toolbar/Toolbar.js +34 -23
  229. package/views/dist/panels/react/toolbar/ToolbarButton.js +4 -1
  230. package/views/dist/panels/react/toolbar/ToolbarNew.js +1 -1
  231. package/views/dist/panels/react/toolbar/ToolbarQuickFilters.d.ts +2 -2
  232. package/views/dist/panels/react/toolbar/ToolbarQuickFilters.js +3 -1
  233. package/views/dist/panels/react/toolbar/ToolbarSearch.js +1 -1
  234. package/views/dist/panels/react/toolbar/context.d.ts +10 -2
  235. package/views/dist/panels/react/toolbar/context.js +3 -1
  236. package/views/dist/panels/react/views-row/FoldingViewRow.d.ts +1 -1
  237. package/views/dist/panels/react/views-row/FoldingViewRow.js +15 -4
  238. package/views/dist/panels/react/views-row/PillGroup.d.ts +5 -2
  239. package/views/dist/panels/react/views-row/PillGroup.js +16 -7
  240. package/views/dist/panels/react/views-row/ViewPicker.js +2 -12
  241. package/views/dist/panels/react/views-row/ViewPickerRow.d.ts +4 -2
  242. package/views/dist/panels/react/views-row/ViewPickerRow.js +9 -5
  243. package/views/dist/panels/react.d.ts +2 -2
  244. package/views/dist/panels/toolbar/edit-view.d.ts +7 -1
  245. package/views/dist/panels/toolbar/edit-view.js +14 -0
  246. package/views/dist/panels/toolbar/model.d.ts +5 -0
  247. package/views/dist/panels/toolbar/model.js +7 -3
  248. package/views/dist/panels/view-state.d.ts +5 -3
  249. package/views/dist/panels/views-row/model.d.ts +19 -2
  250. package/views/dist/panels/views-row/model.js +14 -0
  251. package/views/dist/provider/ViewsProvider.d.ts +16 -7
  252. package/views/dist/provider/ViewsProvider.js +23 -5
  253. package/views/dist/provider/components.d.ts +43 -2
  254. package/views/dist/provider/context.d.ts +2 -1
  255. package/views/dist/provider/context.js +1 -1
  256. package/views/dist/provider/ports.d.ts +19 -12
  257. package/views/dist/provider/ports.js +69 -1
  258. package/views/dist/react.d.ts +1 -1
  259. package/views/dist/styles.css +418 -59
  260. package/views/dist/styles.unlayered.css +418 -59
  261. package/views/docs/contract.md +42 -31
  262. package/views/docs/controls/avatar.md +11 -0
  263. package/views/docs/controls/choice.md +0 -1
  264. package/views/docs/controls/field.md +3 -0
  265. package/views/docs/controls/input.md +1 -0
  266. package/views/docs/controls/radio.md +16 -1
  267. package/views/docs/controls/select.md +2 -0
  268. package/views/docs/controls/setting-row.md +18 -0
  269. package/views/docs/controls/switch-row.md +0 -3
  270. package/views/docs/controls/tag-field.md +4 -0
  271. package/views/docs/controls/tag.md +1 -0
  272. package/views/docs/getting-started.md +2 -2
  273. package/views/docs/guides/atoms.md +2 -2
  274. package/views/docs/guides/columns.md +1 -1
  275. package/views/docs/guides/ports.md +1 -1
  276. package/views/docs/guides/the-grid.md +34 -7
  277. package/views/docs/guides/the-provider.md +4 -2
  278. package/views/docs/index.md +1 -0
  279. package/views/docs/reference/controls.md +35 -25
  280. package/views/docs/reference/editors-session.md +1 -1
  281. package/views/docs/reference/field-row.md +9 -1
  282. package/views/docs/reference/grid.md +14 -8
  283. package/views/docs/reference/list.md +227 -0
  284. package/views/docs/reference/looks.md +1 -1
  285. package/views/docs/reference/panels-react.md +17 -12
  286. package/views/docs/reference/panels.md +8 -5
  287. package/views/docs/reference/react.md +11 -9
  288. package/views/docs/reference/views.md +2 -2
  289. package/views/skills/views/SKILL.md +9 -6
@@ -4,8 +4,7 @@ The names the rendering speaks to the engine through, and the names an app hands
4
4
  is public; nothing outside this list is. `src/contract.ts` holds the slots, states, tokens, component
5
5
  names, port names, icon names and message namespaces as typed constants, and `src/contract.test.ts`
6
6
  pins them to this file: a constant this file does not name, and a slot, state or `--vk-*` token this
7
- file names that no constant holds, fail the package's tests. The getters and the ports' methods are
8
- named here only, until the engine that implements them lands. Renaming a name
7
+ file names that no constant holds, fail the package's tests. The ports' methods are named here only. Renaming a name
9
8
  after a second app holds a copy is a codemod across every app, so a rename is a changelog line and a
10
9
  codemod, never a quiet edit.
11
10
 
@@ -155,17 +154,6 @@ pending value, else the row's): nothing, a blank text or an empty list; a value
155
154
  parts are all empty (a money, a range) does not count as empty, and a column with no value of its
156
155
  own (an action column) never is.
157
156
 
158
- ## Getters
159
-
160
- The engine's functions the rendering calls. They return only stable structure — role, ARIA indices,
161
- `data-*` identifiers, geometry — and carry no per-cell handlers; they are pure functions of their
162
- arguments, created once per engine.
163
-
164
- - `getGridProps()`
165
- - `getHeaderProps(colId)`
166
- - `getRowProps(rowKey, index)`
167
- - `getCellProps(rowKey, colId, colIndex)`
168
-
169
157
  ## Row state
170
158
 
171
159
  A row is the grid's own component, handed flat props; no hook hands a row its state, and an app reads none of them.
@@ -323,6 +311,15 @@ or an ancestor, or on one group: to stand the group after a folded one right und
323
311
  no layer. A `margin-top` rule on the slot still works where it wins over the class (outside any layer, or in one
324
312
  after `utilities`).
325
313
 
314
+ **The field row's frame is the app's to declare.** A record's field row (`viewkitjs/views/field-row`) reads
315
+ `--vk-field-row-label-w` for its label column on a desktop (undeclared `calc(var(--spacing)*32)`, what `w-32` drew), `--vk-field-row-gap` for the gap
316
+ between its glyph, label, value and lane (`calc(var(--spacing)*3)`), `--vk-field-row-h` for its least height, its one line standing
317
+ in the middle of it (`auto`), `--vk-field-row-py` for its padding above and below (`calc(var(--spacing)*2.5)`), `--vk-field-row-line-w`
318
+ for the line under every row but the last (`1px`; `0px` draws none), `--vk-field-row-line` for that line's colour
319
+ (`--vk-border`) and `--vk-field-row-label-fg` for its label's colour (`--vk-fg-subtle`). Undeclared, the row draws as
320
+ it always has; declared on a section or any ancestor, every row in it takes them. Inside a Field rows card on a phone the
321
+ row is one of the card's rows, drawn by the card's frame, and none of them apply there.
322
+
326
323
  **Type, lines and timing are the app's to dress, one variable per kind.** Each is optional. Undeclared, every
327
324
  place keeps its own value, the one shown here; declared once, on the grid, a panel or an ancestor, every place of
328
325
  that kind takes it.
@@ -430,7 +427,7 @@ grid's editors and menus use, each in Base UI's shape, and an adapter on Radix a
430
427
  both fill every one.
431
428
 
432
429
  **Defaults for an app that hands none:** `CONTROLS`, from `viewkitjs/views/controls`, holds ViewKit's default controls,
433
- the Outright kit's, on Base UI: its controls (the Button, the Popover, the Sheet, the Input, the Checkbox, the Tooltip, the Menu), the Text editor as its `TextBody`, the Picker as its `Picker` and `FieldsBody`, the Date editor as its `DateBody`, the Date editor's days as its `Calendar`, the Compound editor as its `PartsBody`, the Number editor as its `NumberBody`, the Values editor as its `ValuesBody`, the Links editor as its `LinksBody`, and of the panels the sort editor as its `SortBody`, the views list as its `ViewsListBody`, the filter editor as its `FilterBody` and `FilterPartBody` and the group editor as its `GroupBody`, Customize as its `CustomizeBody`, the quick filters as its `QuickFiltersBody`, the bulk bar as its `SelectionBar`; and of the panels' controls the Collapsible as its `Collapse`; and `PortsHost`, ViewKit's Toast and alert dialog for the `toast` and `confirm` ports an app leaves out. An app spreads it first and its own after
430
+ the Outright kit's, on Base UI: its controls (the Button, the Popover, the Sheet, the Input, the Checkbox, the Tooltip, the Menu), the Text editor as its `TextBody`, the Picker as its `Picker` and `FieldsBody`, the Date editor as its `DateBody`, the Date editor's days as its `Calendar`, the Compound editor as its `PartsBody`, the Number editor as its `NumberBody`, the Values editor as its `ValuesBody`, the Links editor as its `LinksBody`, and of the panels the sort editor as its `SortBody`, the views list as its `ViewsListBody` and a view's menu as its `ViewMenu`, the filter editor as its `FilterBody` and `FilterPartBody` and the group editor as its `GroupBody`, Customize as its `CustomizeBody`, the quick filters as its `QuickFiltersBody`, the bulk bar as its `SelectionBar`; and of the panels' controls the Collapsible as its `Collapse`; and `PortsHost`, ViewKit's Toast and alert dialog for the `toast` and `confirm` ports an app leaves out; and `AppIcon`, ViewKit's own glyphs by name (`CONTROL_ICONS`), and `Markdown`, the stored text as it stands with its line breaks kept. So it fills every required slot, and `components={CONTROLS}` is the one line an app must write; handed as it stands it brings `CONTROL_ATOMS` too, the atoms drawn with those controls, under the app's own `atoms`. An app spreads it first and its own after
434
431
  (`components={{ ...CONTROLS, ...own }}`), so whatever it hands wins. That door alone needs `@base-ui/react`, an optional
435
432
  peer; the provider and every other door import neither library, so an app that hands every control never installs it.
436
433
 
@@ -471,9 +468,11 @@ peer; the provider and every other door import neither library, so an app that h
471
468
 
472
469
  `PortsHost`, optional: what draws the ports an app leaves out, `ViewsPortsHostProps`: `toast` and `confirm` (which of them to draw) and `onReady` (hand it the ports once they stand). The provider mounts it once, after it first renders in the browser, so a server render draws neither, and only when the app hands no `toast` or no `confirm`; an app's own port always wins. Left out, a missing `toast` draws nothing and a missing `confirm` is the browser's. `CONTROLS.PortsHost` reports in ViewKit's Toast (Undo where `success` hands one) and asks in ViewKit's alert dialog, the question held in its own state, so an app's own `AlertDialogHost` never shows it twice; its words are your messages' (`views.panels.toast-undo`, `views.panels.close`, `views.panels.toast-region`, `views.panels.alert-failed`, `views.picker.retry`, `views.picker.cancel`).
473
470
 
471
+ `ViewMenu`, optional: one view's whole menu at an anchor, which your app draws, `ViewsViewMenuProps`; `CONTROLS.ViewMenu` is ViewKit's own (VK-947). A views row's pill (the open one on a click on it again or a right-click, another on a right-click) and a folded view's `⋮` in the "+N" list open it, on a computer, where the axis hands `verbs`; left out, they open the view's `menu` rows through `Menu`, and the row's + calls the axis's `onCreate`, as an axis without `verbs` does. It is handed `open`, `onOpenChange`, `anchor` and `align`, as `Menu` is; the view whose menu it is (`view`; left out, it stands on New view's Modal in place of a menu, as the row's + opens it where the axis grows, and tells `onOpenChange(false)` once the Modal has closed, VK-971), every view of the axis in its order (`views`, as `ViewsListBody` is handed them), the view in use (`value`) and `verbs`; `onDone` (a change opened a view, ended in the Toast, or asked for Customize: what holds it closes) and, in the "+N" list's popover, `onHold` (while it asks your `confirm` port, a press outside and Escape close nothing). `CONTROLS.ViewMenu` draws the views list's view menu (`useViewMenu`), its items reshaped by `verbs.menu`, through your `Menu`: Rename… and Save as new view… in the Modal, Delete asked through the `confirm` port and said through the `toast` port with its `undo`, each change handed to `verbs.onChange`.
472
+
474
473
  `SelectionBar`, optional: the selection bar, which your app draws, `ViewsSelectionBarProps`, the props of ViewKit's `SelectionBar`. Handed one, ViewKit's `SelectionBar`, wherever your `renderBar` calls it, draws yours in its own place, in the box that holds it (a grid's frame), at every count, zero included, so it can leave as it chooses; left out, ViewKit draws its own bar, portalled to the screen's foot, placed by the provider's `selectionBar`. Beside the count, the clear, the verbs, `busy`, `onDelete` and `deleteLabel`, it is handed what ViewKit's own bar doesn't read: `noun` (what a row is, one and many), `deleteLine` (the line under Delete's question), and on each verb `more` (kept off the bar, in More), on an options verb `value` (what every picked row holds, null when every one is empty), `empty` (the empty row's words; a pick of it hands `null`) and `search`, its `options` ViewKit's picker items (a person by `avatarUrl` and `kind`), and a press (`onClick`, `onSelect`, `onDelete`) may hand back a `SelectionDone`, `{ words, undo }`, or a promise of one, which yours shows. `CONTROLS.SelectionBar` is the Outright bulk bar (`BulkBar`): on a computer a surface floating at the foot of the box that holds it, centred, its count (which clears), the verbs as outlined buttons, Delete in More or its own (its option `delete`, `BULK_BAR_LOOKS`), and More, holding what is kept off and what doesn't fit; on a phone, or in a `PhoneHost` screen, the tray, its verbs at 44 with Delete among them, or the pill (its option `phone`); one Tab stop with the arrows; Escape from the box clears; an options verb's values in the Picker (in the one Sheet on a phone); Delete asked first in ViewKit's alert dialog, then called, so your `onDelete` asks nothing of its own; what a press hands back said in its own Toast, just above it, with Undo; a press that throws said as one that didn't go through. It hands the box that holds it the room it takes, which a list that scrolls in it pads its foot by ([its tokens](controls/bulk-bar.md)). The provider's `selectionBar` placement and query are ViewKit's own bar's. Every word is your messages'.
475
474
 
476
- `ViewsListBody`, required: the views list's whole body, which your app draws, `ViewsViewsListBodyProps`; `CONTROLS.ViewsListBody` is ViewKit's own. The view picker's chip opens it: in its popover on a computer and in the Sheet on a phone. The row's pills and its "+N" list stay ViewKit's. It is handed the list's name (`label`), the axis's views in its order (`views`, each its `value`, its words, its `icon`, its `count` (absent while the list's counts are hidden), `private` for one of the reader's own, and `menu`, the view's own verbs as your app gave them), the view in use (`value`), `form`, and, where the axis has them, `onCreate` with its word (`createLabel`; what holds the list closes first, then the axis's own create runs) and `onReorder` with `canDrag`. The body hands back `onViewChange` (a view picked; it closes nothing, so call `onDone` after it, as `CONTROLS.ViewsListBody` closes on a pick), `onReorder` (one whole block, the shared views or the reader's own, in its new order, each once) and `onDone` (what holds it closes). On a phone where the sheet's head doesn't draw it (the provider's `sheetActions` at `bar`), it is handed `actions`, the ✕ (`close`, which closes the list) and, while it stands on a step, Back (`back`); on a computer, and under `head`, it is handed none. On a computer it is handed `onHold`: while the body holds, a press outside the list and Escape close nothing (it asks a question outside the list, your `confirm` port's dialog), so the list stays when the question is answered. On a phone it is handed `onStepChange`: a body standing on a step of its own (a view's menu, Rename) tells it, and the sheet shows the step's title and Back and its Escape goes back a step. Where the axis hands `verbs` (`ViewsViewVerbs`: the `layouts` a new view can take, each its glyph by your `AppIcon`, the `records`' noun, a board's `columns` and `onChange`, which takes every change a view's menu makes, `ViewsViewChange`: rename, create, duplicate, delete, restore, save, reset, edit, link, favorite, private), the body is handed them, and each view its `layout`, `changed` and `favorite`. ViewKit checks each value before it is written: a pick that isn't one of `views`, and an order that isn't one whole block, write nothing. What creating, reordering and a view's verbs mean stays your app's, as the axis says. `CONTROLS.ViewsListBody` is ViewKit's own, the views list: a search over the views (at the Sheet's foot on a phone), each with its glyph, its count and its ⋮ where you hand it a menu, Shared and the reader's own under their headings with a lock on each of the reader's own, a view moved by a drag or ⌥↑ ⌥↓ within its block (never one `canDrag` refuses, nor a view dropped past one), ↓ and ↑ going on from the view in use, and New view where the axis grows. It draws no ✕ of its own: the Sheet's head draws it, and `actions` goes unread but for Back on a step. On a phone a view's ⋯ turns the one Sheet into its menu, with Back, never a sheet on top (VK-823). Handed `verbs`, a view's menu is the Outright kit's (`useViewMenu`): Rename… and New view in the Modal (New view where the axis grows, as without verbs, its create handed to `verbs.onChange`), Edit view, Private view, Save for everyone, Reset and Save as new view, Copy link, Favorite, Duplicate, and Delete, asked on a computer through the `confirm` port (ViewKit's alert dialog where your app hands none and `PortsHost` stands; the menu's own dialog where neither does, never the browser's) and said through the `toast` port's `success` with its `undo`. ViewKit moves no view itself: your `verbs.onChange` opens the right one, the first listed when the open one is deleted, the view again on a restore with `open`, the new one on a create or a duplicate (whose ids your app makes); `viewsAfter`, from `viewkitjs/views/controls`, does all of it over your views; on a phone each a step of the one Sheet, the delete question the Alert in its sheet form. Every word is your messages'.
475
+ `ViewsListBody`, required: the views list's whole body, which your app draws, `ViewsViewsListBodyProps`; `CONTROLS.ViewsListBody` is ViewKit's own. The view picker's chip opens it: in its popover on a computer and in the Sheet on a phone. The row's pills and its "+N" list stay ViewKit's (a view's menu there is `ViewMenu`'s). It is handed the list's name (`label`), the axis's views in its order (`views`, each its `value`, its words, its `icon`, its `count` (absent while the list's counts are hidden), `private` for one of the reader's own, and `menu`, the view's own verbs as your app gave them), the view in use (`value`), `form`, and, where the axis has them, `onCreate` with its word (`createLabel`; what holds the list closes first, then the axis's own create runs) and `onReorder` with `canDrag`. The body hands back `onViewChange` (a view picked; it closes nothing, so call `onDone` after it, as `CONTROLS.ViewsListBody` closes on a pick), `onReorder` (one whole block, the shared views or the reader's own, in its new order, each once) and `onDone` (what holds it closes). On a phone where the sheet's head doesn't draw it (the provider's `sheetActions` at `bar`), it is handed `actions`, the ✕ (`close`, which closes the list) and, while it stands on a step, Back (`back`); on a computer, and under `head`, it is handed none. On a computer it is handed `onHold`: while the body holds, a press outside the list and Escape close nothing (it asks a question outside the list, your `confirm` port's dialog), so the list stays when the question is answered. On a phone it is handed `onStepChange`: a body standing on a step of its own (a view's menu, Rename) tells it, and the sheet shows the step's title and Back and its Escape goes back a step. Where the axis hands `verbs` (`ViewsViewVerbs`: the `layouts` a new view can take, each its glyph by your `AppIcon`, the `records`' noun, a board's `columns` and `onChange`, which takes every change a view's menu makes, `ViewsViewChange`: rename, create, duplicate, delete, restore, save, reset, edit, link, favorite, private), the body is handed them, and each view its `layout`, `changed` and `favorite`. ViewKit checks each value before it is written: a pick that isn't one of `views`, and an order that isn't one whole block, write nothing. What creating, reordering and a view's verbs mean stays your app's, as the axis says. `CONTROLS.ViewsListBody` is ViewKit's own, the views list: a search over the views (at the Sheet's foot on a phone), each with its glyph, its count and its ⋮ where you hand it a menu, Shared and the reader's own under their headings with a lock on each of the reader's own, a view moved by a drag or ⌥↑ ⌥↓ within its block (never one `canDrag` refuses, nor a view dropped past one), ↓ and ↑ going on from the view in use, and New view where the axis grows. It draws no ✕ of its own: the Sheet's head draws it, and `actions` goes unread but for Back on a step. On a phone a view's ⋯ turns the one Sheet into its menu, with Back, never a sheet on top (VK-823). Handed `verbs`, a view's menu is the Outright kit's (`useViewMenu`): Rename… and New view in the Modal (New view where the axis grows, as without verbs, its create handed to `verbs.onChange`), Edit view, Private view, Save for everyone, Reset and Save as new view, Copy link, Favorite, Duplicate, and Delete, asked on a computer through the `confirm` port (ViewKit's alert dialog where your app hands none and `PortsHost` stands; the menu's own dialog where neither does, never the browser's) and said through the `toast` port's `success` with its `undo`. ViewKit moves no view itself: your `verbs.onChange` opens the right one, the first listed when the open one is deleted, the view again on a restore with `open`, the new one on a create or a duplicate (whose ids your app makes); `viewsAfter`, from `viewkitjs/views/controls`, does all of it over your views; on a phone each a step of the one Sheet, the delete question the Alert in its sheet form. Every word is your messages'.
477
476
 
478
477
  `GroupBody`, optional and deprecated: read by nothing. Only ViewKit's own Customize opened it, and that Customize is gone; a `CustomizeBody` holds its group editor inside it, handed the same props as its `group`. A map that names it still compiles; it leaves in a later release. Its props, `ViewsGroupBodyProps`, are what a `CustomizeBody`'s `group` is handed: it is handed the group's name (`label`), the fields the list can be grouped by (`dimensions`, each its `value`, its words, its `orderOptions` with the direction each opens in, its `defaultOrder`, and a date's `granularities` with its `defaultGranularity`), the group as one value (`group`, a `ViewsGroupValue`: the dimension grouped by or `none`, the active dimension's `order` (`mode` and `dir`), its date step (`granularity`), `hideEmpty` while grouped where the list offers it, and `groups` while grouped where the list hands them, in the order the list shows them, each its `key`, its words, `empty`, `hidden`, and its `count` where the list counts it), `manualOrder` (your own order, `manual`, may be picked) and `form`. The body hands back `onGroupChange` (the whole group, every change as it is made) and `onDone` (inside Customize, back to its list). ViewKit makes one write for each change, in this order: a new Group by, order or date step is written alone, the rest of the value (about the old field's groups) set aside; else Hide empty groups; else the groups: the same groups in a new order (your own order), one group shown or hidden, every group hidden, or every group shown. A new Group by keeps the order and step handed with it only where the new field offers them, else takes the field's own. A value that changes two of those at once, names a field the list doesn't offer, names an order or step the field grouped by doesn't offer, or adds or loses a group writes nothing. It is handed no `actions`. It is handed `onStepChange`, on a computer and a phone: hand it a level of your own (`ViewsBodyStep`, its `title` and `onBack`: Group by's fields, an order's choices) while you stand on one, and `null` once you are back; what holds it shows the level's name in its head and its Back calls `onBack`. `CONTROLS.GroupBody`, kept so a map that names it compiles, is ViewKit's own, the group editor: Group by, Order, Direction, a date field's Date step and Hide empty groups, each opening its choices in place; the groups with their Switch, dragged into your own order, Hide all and Show all; Remove grouping; each change one write, Count ordered by each group's `count`, its level told through `onStepChange`.
479
478
 
@@ -506,8 +505,9 @@ carries `keepOpen`, a hint to leave the menu open so several can be ticked in tu
506
505
  item's `children` are a group, its rows drawn in place under the item's label unless it carries `beside`, a hint to open them one level in, its row showing its label and `detail`, and
507
506
  the group's own `onSelect`, `href` and `checked` are ignored, and a group marked `disabled` disables every row under it, at every depth: the provider hands your `Menu` those rows already `disabled`, each one that gives no reason carrying the group's `disabledReason`, so you draw each row by its own flag. Any row may carry `detail`, its current value in words, for its end. An adapter that draws none of the three keeps every row closing and every group in place, and loses nothing it needs. So an adapter needn't guess: a ticked row's `onSelect` fires on every pick, also when it is already ticked (a second pick of the ticked sort flips its direction), so an adapter that draws ticked rows as a radio value still calls it; ticked rows that close, inside a group, are one choice among several (a pick list), and ticked rows with `keepOpen` are separate ticks (checkboxes); a label is always text, so a swatch or a column's mark rides as the row's `icon` beside it. The sheet takes `label`, its title in words whenever the title is words (its accessible name, and the title of a head that takes only text), and, when the provider's `sheetActions` is `head`, `actions`: the editor panel's ✕ (`close`) and ✓ (`done`, absent where the body saves on its pick), or a toolbar panel's ✕ alone (`close`, which closes it), or the sort editor's ✕ (`close`, which takes its rules back to what they were as the sheet opened) and ✓ (`done`), each a `label` and an `onPress`, for your sheet's own head; with `bar`, the default, the panel draws them itself. `AppIcon` is the app's own icon component by the app's own names, for
508
507
  the glyphs a host declares (a row's icon, a binding's icon, an option's icon), drawn on the first paint (rows are measured as they mount); the semantic glyphs the rendering itself
509
- needs are a port, by meaning (below). `Markdown` is the app's markdown renderer, handed the stored text whole; the
510
- package draws rich text through it and parses none.
508
+ needs are a port, by meaning (below); `CONTROLS.AppIcon` draws ViewKit's own glyph of each meaning's name. `Markdown` is the
509
+ app's markdown renderer, handed the stored text whole; the package draws rich text through it and parses none, and
510
+ `CONTROLS.Markdown` draws the text as it stands, its line breaks kept.
511
511
 
512
512
  A popup reports why it closed through `onOpenChange`'s `details.reason`: `trigger-press`,
513
513
  `outside-press`, `escape-key`, `focus-out`, `item-press`, `close-press` (a close button inside it) or
@@ -598,7 +598,7 @@ container: the inset a run of rows sits in, inside a panel or a command list's g
598
598
  a button or, with `interactive={false}`, a static line), `RowContent` (a row's inside, for inside a
599
599
  command list's item, which owns the element and the highlight), `TickBox` (a paint-only tick box), `Avatar` (a person's or a record's picture, `ViewsAvatarProps`: a user's, a relation's and an actor's chip draw it at `size="chip"`, and the name draws it at `size="glyph"`, sized by `--vk-glyph`, when the list's `rowIcon` hands the row's `avatar`; it is handed `label`, whose picture it is, `avatarUrl`, `kind`, the record's kind as the app names it (a relation's `entity`, `user` for a member, an actor's type), and `fallback`, the glyph the chip or the name draws without a picture; the default draws the picture, marked `data-slot="vk-avatar"`, and the fallback when there is none or it fails to load, so an app that hands none sees its chips and names as before; yours draws initials on a tone, a record in its own shape, or the fallback for a kind it doesn't dress),
600
600
  `StatusBadge` (a pill by status slot), `StatusMarker` (an attention badge that opens its reason) and
601
- `Tag` (a category chip, removable, with an optional leading glyph), `CommandMenu` (a `command` cell's verb menu, opened from the trigger the cell drew; the default is the components map's `Menu`), `RowMenu` (the rows' right-click menu, once around each section's rows' container and aimed at the row a press or a right-click came from, its props that row's: Open page, the rows the rendering builds, Delete; the default is the components map's `Menu` at the pointer, opened by a right-click or the row's ⋯ (`data-slot="vk-grid-row-more"`), wrapped in `data-slot="vk-row-menu"`; the grid's row-menu keys send a cell the same right-click, with no press before it, so a `RowMenu` of your own opens on any `contextmenu` and doesn't wait for a press; its Delete asks the `confirm` port with `views.menus.row-delete-confirm` (the browser's own confirm when you hand none), and a delete that rejects says so through the toast port's `error` with `views.menus.row-delete-failed`; a long-press on a phone opens nothing, and with `GridTable`'s `phonePicking` on the grid's own long press picks the row, an `onToggleSelect` that answers the same held press ticking it with the grid's, once) and `RelationLink` (where a relation chip goes, around the chip the display drew; the default goes nowhere), `RelationRoles` (a link's roles, inside its chip after the record's name, on a `many` relation that declares `links`; the default draws their labels in the subtle colour after a middle dot, wrapped in `data-slot="vk-relation-roles"`, and in a narrow cell cuts them, down to nothing, before the name loses a letter), `Loading` (a wait: the list reloading, or more rows arriving; the default is a plain ring) `LoadMore` (how a list asks for its next page; the default watches a sentinel past the last row) and `PlatformMark` (a link's platform, drawn before it, read from its address with the conventions' platforms; the default draws nothing, so a link looks plain, and the package ships no brand art, so an app that wants marks draws its own by the platform's key into `data-slot="vk-platform"`), and the rows the panels (`/panels`) draw with: `ChoiceRow` (picks a value: its label, a second line, a right-hand meta, the check when chosen), `CheckRow` (toggles one of many, a tick box on the left), `RadioRow` (picks one of a set, its mark a check or, with `mark="box"`, a tick box; a disabled row's reason in your `Tooltip`), `DirectionButton` (a sort's direction arrow, named `views.panels.direction`), `MenuRow` (a drill-in row: a glyph, the section, where it stands, a chevron; a disabled row's reason in your `Tooltip`), `ToggleRow` (a boolean flipped in place, with a way back named `views.panels.toggle-reset`; a disabled row's reason in your `Tooltip`) and `PanelSearch` (a panel's text box, a filled well with a magnifier), and `Pill` (one option of a row of pills, the views row's and any tab row's: `active`, a `solid` or `plain` variant, a `default` or `sm` size, a leading glyph, the app's own active and hover classes for a status colour; with `menuOpen` it says it opens a menu, `aria-haspopup="menu"` and `aria-expanded`), and `ToolbarButton` (a toolbar's button, the one every toolbar part draws with: its glyph, its name, its word for a dress that shows words, a count in its corner, which becomes a ✕ badge that clears what it counts when handed `onClear`, a dot that says something is applied with no number, `open`, `changed`, `edge` for the row's outermost button, `disabled`, a `md` or `sm` size, and `popup` when it opens one; and, for the sort (VK-188), its own words shown whatever the dress, with their weight, in `data-slot="vk-toolbar-words"` (`children`: "Sorted by **Amount**"), a count in words after them in `data-slot="vk-toolbar-more"` (`more`: "+1"), an empty place with its edge dashed and `data-empty` (`empty`), and a reason it can't be used, `disabledReason` with `disabled`, in your `Tooltip`, the button then `aria-disabled` and still a Tab stop, a press doing nothing; its own words are then its name, with `more` after them, in place of `label`; and, in a folding toolbar line with no room, `iconAlone`, its words given up for its icon, `data-icon-alone`, which you draw as the icon alone whatever your dress says of words; `aside`, what it names left the list, its edge dashed in the warning's colour, `data-aside`; `foot`, New's + standing alone at a phone list's foot, round, a finger's size, on the brand's ground, `data-foot`; `joined` (`start`, `middle` or `end`), one of buttons joined as one (a filter's field, how it compares, its value, its menu), its corners on the outer side alone, no gap, the shared edge drawn once, `data-joined` with the value; and `waits`, its words saying what it waits for (a filter's value not yet picked), drawn in `--vk-fg-subtlest`, the placeholder's colour, `data-waits`; its own words keep to one line and give way to a holder that caps its width, cut with "…", where an icon button keeps its size; and, told what it is where your own toolbar frame draws it (VK-629), `current` (a view tab, `data-tab`; `true` the open one, `data-current` and `aria-current="true"`), `part` (which of the toolbar's own buttons it stands for, drawn as its `data-slot`: `views-chip` `vk-views-chip`, `views-tab` `vk-views-tab`, `views-more` `vk-views-more`, `views-add` `vk-views-add`, `clear` `vk-toolbar-clear`, `save` `vk-toolbar-save-button`; the default draws the chip and "+N" with a chevron after their words, `data-slot="vk-toolbar-chevron"`, and Save on an edge) and `onContextMenu` (a right-click: a tab's verbs open on it)). Each ships as a default, exported as `DEFAULT_VIEWS_ATOMS`, drawn
601
+ `Tag` (a category chip, removable, with an optional leading glyph), `CommandMenu` (a `command` cell's verb menu, opened from the trigger the cell drew; the default is the components map's `Menu`), `RowMenu` (the rows' right-click menu, once around each section's rows' container and aimed at the row a press or a right-click came from, its props that row's: Open page, the rows the rendering builds, Delete, where the grid's `menus.row` makes the first and last rows of `items` instead (`row-open`, `row-delete`), with one disabled `loading` row while it answers; the default is the components map's `Menu` at the pointer, opened by a right-click or the row's ⋯ (`data-slot="vk-grid-row-more"`), wrapped in `data-slot="vk-row-menu"`; the grid's row-menu keys send a cell the same right-click, with no press before it, so a `RowMenu` of your own opens on any `contextmenu` and doesn't wait for a press; its Delete asks the `confirm` port with `views.menus.row-delete-confirm` (the browser's own confirm when you hand none), and a delete that rejects says so through the toast port's `error` with `views.menus.row-delete-failed`; a long-press on a phone opens nothing, and with `GridTable`'s `phonePicking` on the grid's own long press picks the row, an `onToggleSelect` that answers the same held press ticking it with the grid's, once) and `RelationLink` (where a relation chip goes, around the chip the display drew; the default goes nowhere), `RelationRoles` (a link's roles, inside its chip after the record's name, on a `many` relation that declares `links`; the default draws their labels in the subtle colour after a middle dot, wrapped in `data-slot="vk-relation-roles"`, and in a narrow cell cuts them, down to nothing, before the name loses a letter), `Loading` (a wait: the list reloading, or more rows arriving; the default is a plain ring) `LoadMore` (how a list asks for its next page; the default watches a sentinel past the last row) and `PlatformMark` (a link's platform, drawn before it, read from its address with the conventions' platforms; the default draws nothing, so a link looks plain, and the package ships no brand art, so an app that wants marks draws its own by the platform's key into `data-slot="vk-platform"`), and the rows the panels (`/panels`) draw with: `ChoiceRow` (picks a value: its label, a second line, a right-hand meta, the check when chosen), `CheckRow` (toggles one of many, a tick box on the left), `RadioRow` (picks one of a set, its mark a check or, with `mark="box"`, a tick box; a disabled row's reason in your `Tooltip`), `DirectionButton` (a sort's direction arrow, named `views.panels.direction`), `MenuRow` (a drill-in row: a glyph, the section, where it stands, a chevron; a disabled row's reason in your `Tooltip`), `ToggleRow` (a boolean flipped in place, with a way back named `views.panels.toggle-reset`; a disabled row's reason in your `Tooltip`) and `PanelSearch` (a panel's text box, a filled well with a magnifier), and `Pill` (one option of a row of pills, the views row's and any tab row's: `active`, a `solid` or `plain` variant, a `default` or `sm` size, a leading glyph, the app's own active and hover classes for a status colour; with `menuOpen` it says it opens a menu, `aria-haspopup="menu"` and `aria-expanded`), and `ToolbarButton` (a toolbar's button, the one every toolbar part draws with: its glyph, its name, its word for a dress that shows words, a count in its corner, which becomes a ✕ badge that clears what it counts when handed `onClear`, a dot that says something is applied with no number, `open`, `changed`, `edge` for the row's outermost button, `disabled`, a `md` or `sm` size, and `popup` when it opens one; and, for the sort (VK-188), its own words shown whatever the dress, with their weight, in `data-slot="vk-toolbar-words"` (`children`: "Sorted by **Amount**"), a count in words after them in `data-slot="vk-toolbar-more"` (`more`: "+1"), an empty place with its edge dashed and `data-empty` (`empty`), and a reason it can't be used, `disabledReason` with `disabled`, in your `Tooltip`, the button then `aria-disabled` and still a Tab stop, a press doing nothing; its own words are then its name, with `more` after them, in place of `label`; and, in a folding toolbar line with no room, `iconAlone`, its words given up for its icon, `data-icon-alone`, which you draw as the icon alone whatever your dress says of words; `aside`, what it names left the list, its edge dashed in the warning's colour, `data-aside`; `foot`, New's + standing alone at a phone list's foot, round, a finger's size, on the brand's ground, `data-foot`; `joined` (`start`, `middle` or `end`), one of buttons joined as one (a filter's field, how it compares, its value, its menu), its corners on the outer side alone, no gap, the shared edge drawn once, `data-joined` with the value; and `waits`, its words saying what it waits for (a filter's value not yet picked), drawn in `--vk-fg-subtlest`, the placeholder's colour, `data-waits`; its own words keep to one line and give way to a holder that caps its width, cut with "…", where an icon button keeps its size; and, told what it is where your own toolbar frame draws it (VK-629), `current` (a view tab, `data-tab`; `true` the open one, `data-current` and `aria-current="true"`), `part` (which of the toolbar's own buttons it stands for, drawn as its `data-slot`: `views-chip` `vk-views-chip`, `views-tab` `vk-views-tab`, `views-more` `vk-views-more`, `views-add` `vk-views-add`, `clear` `vk-toolbar-clear`, `save` `vk-toolbar-save-button`; the default draws the chip and "+N" with a chevron after their words, `data-slot="vk-toolbar-chevron"`, and Save on an edge) and `onContextMenu` (a right-click: a tab's verbs open on it)). Each ships as a default, exported as `DEFAULT_VIEWS_ATOMS`, drawn
602
602
  from the app's colours; an app swaps any of them through the provider's `atoms`, and the rest
603
603
  stay the defaults. `SelectionSheet` is the phone's sheet of a selection's verbs, opened by the
604
604
  selection bar's Actions: the default is the components map's `Sheet` holding the atoms' rows, a group's
@@ -764,18 +764,24 @@ a desktop and its `Sheet` on a phone, and marks its parts with these slots:
764
764
 
765
765
  ## Ports
766
766
 
767
- Runtime services the app hands in through the provider, typed in `src/provider/ports.ts`:
767
+ Runtime services the app may hand in through the provider, typed in `src/provider/ports.ts`. Each is optional, and
768
+ `useViews().ports` always carries every one, the app's own or its default; each default reads the browser only when it is
769
+ called, so a server render reaches none:
768
770
 
769
771
  - `toast` — `success(message, { undo })`, `error(message)`, `info(message)`, `warning(message, { description })` (a change the person did not make). `undo`, where handed, takes the act back: offer it as the toast's Undo (an app's toast may ignore it, and then shows no Undo). Optional: an app that hands none sees ViewKit's Toast where the components map hands `PortsHost` (`CONTROLS` does), and nothing elsewhere. `useViews().ports.toast` is always there.
770
- - `haptics` — `selection()`, `impact(style)`, `notification(type)`; an app without a device hands in no-ops.
771
- - `clipboard` — `writeText(text)` resolving to whether it succeeded; `readText()` resolving to the text or `null`.
772
- - `viewPrefs` — `get(key)`, `set(key, value)`, `subscribe(key, listener)`: a per-device store for state a view keeps between visits. No view in this release reads it; the grid's preferences come in through `useGridTablePrefs`, from wherever the host keeps them.
773
- - `confirm` — `confirm({ message, confirmLabel, subject, detail, destructive })` resolving to whether the person said yes; asked before a row's Delete, `subject` being the host's `deleteLabel`, and before a view's delete in `CONTROLS.ViewsListBody` on a computer, `detail` its one line on what follows. Optional: an app that hands none asks in ViewKit's alert dialog where the components map hands `PortsHost` (`CONTROLS` does), and elsewhere gets the browser's own confirm with `message`, and a rejection or a throw counts as no. `useViews().ports.confirm` is always a function.
772
+ - `haptics` — `selection()`, `impact(style)`, `notification(type)`. Absent: haptics that do nothing.
773
+ - `clipboard` — `writeText(text)` resolving to whether it succeeded; `readText()` resolving to the text or `null`. Absent: the browser's own clipboard, `false` and `null` where it refuses.
774
+ - `viewPrefs` — `get(key)`, `set(key, value)`, `subscribe(key, listener)`: a per-device store for state a view keeps between visits. No view in this release reads it; the grid's preferences come in through `useGridTablePrefs`, from wherever the host keeps them. Absent: a store on the browser's `localStorage`, each value as JSON at the package's own `vk:` key, keeping nothing where storage is refused.
775
+ - `confirm` — `confirm({ message, confirmLabel, subject, detail, destructive })` resolving to whether the person said yes; asked before a row's Delete, `subject` being the host's `deleteLabel`, and before a view's delete in `CONTROLS.ViewsListBody` and `CONTROLS.ViewMenu` on a computer, `detail` its one line on what follows. Optional: an app that hands none asks in ViewKit's alert dialog where the components map hands `PortsHost` (`CONTROLS` does), and elsewhere gets the browser's own confirm with `message`, and a rejection or a throw counts as no. `useViews().ports.confirm` is always a function.
776
+
777
+ The provider's `conventions` (the `FieldConventions` every value is read with) are optional too: absent, `en-US` in
778
+ `UTC`, one object, the same on the server and in the browser.
774
779
 
775
780
  ## Icons
776
781
 
777
782
  The glyphs the rendering asks for, by meaning. The app maps each name to a component taking
778
- `className`. Field types: `text` `longText` `number` `percent` `currency` `date` `datetime` `duration`
783
+ `className`, as the provider's `icons`; handed none, the provider draws each meaning through the map's `AppIcon` by its
784
+ name, and `CONTROLS.AppIcon` draws ViewKit's own (`CONTROL_ICONS`, Tabler's as the Outright kit draws them). Field types: `text` `longText` `number` `percent` `currency` `date` `datetime` `duration`
779
785
  `boolean` `select` `status` `multiselect` `relation` `user` `url` `domain` `email` `phone` `location` `name` `actor`
780
786
  `rich_text` `range` `lookup` `rollup` `formula` `computed`. Who did it: `automation` `apiKey` `system` (a member wears `user`). Actions: `add` `edit` `delete` `copy` `cut` `paste` `clear` `hide` `show` `lock`
781
787
  `pin` `wrap` `more` `close` `check` `warning` `drag` `resize` `open` `selectRow`. Navigation and order: `chevronDown`
@@ -828,7 +834,8 @@ and the plain row menu's `views.menus.row-open` ("Open page"), `views.menus.row-
828
834
  "Deselect", as text for a catalog's `select`), `views.menus.row-delete`, `views.menus.row-delete-confirm` (the
829
835
  browser's confirm before a delete: "Delete this row?") and `views.menus.row-delete-failed` (the error toast when the
830
836
  delete the host ran rejects: "Failed to delete the row"), and `views.menus.row-menu` (its name, handed to your `Menu` as
831
- `label`: "Row actions"); a `command` field's verb menu's name: `views.menus.commands` (`{ field }`: "Actions for Stage")
837
+ `label`: "Row actions"), and `views.menus.row-waiting` (the greyed row a row's menu holds while your `menus.row`
838
+ answers: "Loading…"); a `command` field's verb menu's name: `views.menus.commands` (`{ field }`: "Actions for Stage")
832
839
  and `views.menus.commands-unnamed` ("Actions", when its opener hands no field); `views.menus.figure-menu`
833
840
  (`{ field }`: "Calculate Amount", the figure picker's name) and `views.menus.column-menu`
834
841
  (`{ field }`: "Options for Amount", a column menu's name);
@@ -875,7 +882,9 @@ a batch, once, with the first refusal's words when it has any); and the warnings
875
882
  title on a money figure shown in another currency than its record's) and `views.display.as-shown` ("as shown",
876
883
  after that figure under a money editor).
877
884
  A field row's own word is under `views.field-row.*`: `views.field-row.empty` ("Empty", what a row the viewer may
878
- edit draws when it holds nothing, muted; a row they can't edit draws "—").
885
+ edit draws when it holds nothing, muted; a row they can't edit draws "—") and `views.field-row.set` (`{ label }`, "Set" and
886
+ the label, each word lower-cased unless a capital stands inside it: "Set lost reason", "Set VAT number"; what the same row draws in
887
+ a Field rows card on a phone).
879
888
  And the panels' words: the "For you" heading, `views.panels.for-you`; the Group
880
889
  panel's orders, `views.panels.group-order-most` ("Most first"), `views.panels.group-order-fewest`,
881
890
  `views.panels.group-order-newest`, `views.panels.group-order-oldest`, `views.panels.group-order-alphabetical`,
@@ -917,10 +926,12 @@ picker's chip), `views.panels.view-fallback` ("View", the chip with no active vi
917
926
  `views.panels.view-create-row` (`{ label }`, "New view…", the picker's last row) and
918
927
  `views.panels.view-menu` ("View menu", a picker row's `⋮`).
919
928
  The ports' own (`CONTROLS.PortsHost`): `views.panels.toast-undo` ("Undo", a toast's way back) and `views.panels.alert-failed` ("That didn't go through. Nothing changed.", the alert dialog's failure with no words of its own).
920
- A view's menu and what it opens (`CONTROLS.ViewsListBody` where the axis hands `verbs`, and `useViewMenu`): `views.panels.view-rename` ("Rename…") and `views.panels.view-rename-short` ("Rename", a phone's tile), `views.panels.view-edit` ("Edit view…"), `views.panels.view-private-toggle` ("Private view"), `views.panels.view-save-everyone` ("Save for everyone"), `views.panels.view-save-new` ("Save as new view…"), `views.panels.view-copy-link-short` ("Copy link", a phone's tile; a computer's is `views.panels.copy-link`), `views.panels.view-favorite` ("Favorite") and `views.panels.view-unfavorite` ("Unfavorite"), `views.panels.view-duplicate` ("Duplicate view") and `views.panels.view-duplicate-short` ("Duplicate", a phone's tile), `views.panels.view-delete` ("Delete view"), `views.panels.view-keep-one` ("A list keeps one view", why Delete can't be pressed), `views.panels.view-unsaved` ("Unsaved changes") and `views.panels.view-this` ("This view"), a phone's two headings, `views.panels.view-rename-title` ("Rename view"), `views.panels.view-name` ("Name"), `views.panels.view-create-action` ("Create view"), `views.panels.view-delete-title` (`{ name }`, "Delete Q3?"), `views.panels.view-deleted` (`{ name }`, "Q3 was deleted", the toast), `views.panels.view-copy-name` (`{ name }`, "Copy of Q3", a duplicate's name), `views.panels.view-delete-stays` (`{ records }`, "The deals in it stay as they are.") and `views.panels.view-delete-goes` ("The view goes for everyone who uses it."), the delete question's line, and `views.panels.view-columns` (`{ layout }`, "Board columns", the field a board's columns follow).
929
+ A view's menu and what it opens (`CONTROLS.ViewsListBody` where the axis hands `verbs`, `CONTROLS.ViewMenu`, and `useViewMenu`): `views.panels.view-rename` ("Rename…") and `views.panels.view-rename-short` ("Rename", a phone's tile), `views.panels.view-edit` ("Edit view…"), `views.panels.view-private-toggle` ("Private view"), `views.panels.view-save-everyone` ("Save for everyone"), `views.panels.view-save-own` ("Save", a private view's Save, in its menu and Customize's foot), `views.panels.view-save-new` ("Save as new view…"), `views.panels.view-copy-link-short` ("Copy link", a phone's tile; a computer's is `views.panels.copy-link`), `views.panels.view-favorite` ("Favorite") and `views.panels.view-unfavorite` ("Unfavorite"), `views.panels.view-duplicate` ("Duplicate view") and `views.panels.view-duplicate-short` ("Duplicate", a phone's tile), `views.panels.view-delete` ("Delete view"), `views.panels.view-keep-one` ("A list keeps one view", why Delete can't be pressed), `views.panels.view-unsaved` ("Unsaved changes") and `views.panels.view-this` ("This view"), a phone's two headings, `views.panels.view-rename-title` ("Rename view"), `views.panels.view-name` ("Name"), `views.panels.view-create-action` ("Create view"), `views.panels.view-delete-title` (`{ name }`, "Delete Q3?"), `views.panels.view-deleted` (`{ name }`, "Q3 was deleted", the toast), `views.panels.view-copy-name` (`{ name }`, "Copy of Q3", a duplicate's name), `views.panels.view-delete-stays` (`{ records }`, "The deals in it stay as they are.") and `views.panels.view-delete-goes` ("The view goes for everyone who uses it."), the delete question's line, and `views.panels.view-columns` (`{ layout }`, "Board columns", the field a board's columns follow).
921
930
  The toolbar's words: `views.panels.show-counts` ("Show counts", the toolbar's toggle over the views' and the quick filters' counts,
922
931
  writing the view's `showCounts`),
923
- `views.panels.toolbar-more` ("More", ⋯'s name in a folding toolbar line), `views.panels.view-clear` ("Clear") and
932
+ `views.panels.toolbar-more` ("More", ⋯'s name in a folding toolbar line), `views.panels.toolbar-row` ("List tools",
933
+ the name of a toolbar's row, each line a `role="toolbar"` of its own) and `views.panels.toolbar-bar` ("Sort and
934
+ filters", the filter bar's name), `views.panels.view-clear` ("Clear") and
924
935
  `views.panels.view-save` ("Save") (the bar's Clear and Save, and the ready toolbar's Customize foot),
925
936
  `views.panels.toolbar-new` ("New", the New button's name and word), `views.panels.toolbar-options` ("Customize",
926
937
  the Options button's name and word), `views.panels.edit-view` ("Edit view…", the row the ready toolbar puts at the
@@ -957,8 +968,8 @@ rows' and pages' names where the list names none, `views.panels.filter` ("Filter
957
968
  ("Layout"), `views.panels.columns` ("Columns"), `views.panels.column` ("Column") and `views.panels.group`
958
969
  ("Group"), with `views.panels.sort`, `views.panels.group-by`, `views.panels.date-by`,
959
970
  `views.panels.time-scope-label` and `views.panels.date-range-label` above, and the Columns row's value,
960
- `views.panels.columns-shown` (`{ count }`, "3 shown"); its footer on a shared view, `views.panels.view-publish`
961
- ("Save for everyone"), `views.panels.view-reset` ("Reset") and `views.panels.view-stale` ("Everyone's view
971
+ `views.panels.columns-shown` (`{ count }`, "3 shown"); its footer on a saved view, `views.panels.view-publish`
972
+ ("Save for everyone"; `views.panels.view-save-own`, "Save", on the reader's own), `views.panels.view-reset` ("Reset") and `views.panels.view-stale` ("Everyone's view
962
973
  changed since you started."); and its actions, `views.panels.copy-link` ("Copy link to view"),
963
974
  `views.panels.export-csv` ("Export CSV"), `views.panels.share` ("Share"), `views.panels.coming-soon` ("Coming
964
975
  soon", a parked action's hint) and `views.panels.loading` ("Loading", the export's spinner).
@@ -1258,7 +1269,7 @@ opening its panel from its own button over the builder's panels (`ToolbarOptions
1258
1269
  giving it back on the panel's own ✕, `useToolbarPanelState`, `ToolbarPanelState`, `FilterPanelContent`); the sort as up to three rules
1259
1270
  (`ToolbarSortPill`, the sort editor's host `SortEditorHost` with `useSortEditorHost` and `SortEditorOptions`, and `SortFieldList`); the
1260
1271
  and/or groups (`ToolbarAdvancedFilters`, the filter editor's host `FilterEditorHost`, `FilterFieldList` and `FilterValueBody`); and the ready toolbar over a
1261
- list's settings (`ReadyToolbar`, `ReadyToolbarProps`) with a list held in memory (`useListSettingsState`). It is the one door that may reach dnd-kit (`@dnd-kit/core`,
1272
+ list's settings (`ReadyToolbar`, `ReadyToolbarProps`) with a list held in memory (`useListSettingsState`). It is the one door that may reach dnd-kit, with `/list`, whose `ListToolbar` draws its parts (`@dnd-kit/core`,
1262
1273
  `@dnd-kit/sortable`, `@dnd-kit/utilities`), the package's optional peers, which the Columns list, the group
1263
1274
  order, the view pills and the sort editor's rules drag with. It reaches them only through `import()`, started
1264
1275
  as it loads (`loadPanelsDrag`), so the door itself loads in plain Node without them: an app that renders a part that drags installs
@@ -10,6 +10,7 @@ Every name the Avatar's stylesheet (`avatar.css`) reads, each optional: the read
10
10
  | `--vk-fg-on-brand` | colour | `text-brand-inverse` | `hsl(0 0% 100%)` · dark `hsl(210 8% 5%)` |
11
11
  | `--vk-fg-subtle` | colour | `text-subtle` | `hsl(0 0% 35%)` · dark `hsl(258 4% 72%)` |
12
12
  | `--vk-fg-subtlest` | colour | `text-subtlest` | `hsl(210 1% 53.5%)` · dark `hsl(210 3% 53%)` |
13
+ | `--vk-fg-inverse` | colour | `text-inverse` | `hsl(0 0% 100%)` · dark `hsl(210 8% 95%)` |
13
14
  | `--vk-label-amber-fill` | colour | `label-amber-fill` | `hsl(19 72% 92.5%)` · dark `hsl(20 42% 18.5%)` |
14
15
  | `--vk-label-amber-strong` | colour | `label-amber-strong` | `hsl(23 85% 29%)` · dark `hsl(20 90% 76.5%)` |
15
16
  | `--vk-label-blue-fill` | colour | `label-blue-fill` | `hsl(218 100% 94%)` · dark `hsl(219 46% 21%)` |
@@ -24,6 +25,13 @@ Every name the Avatar's stylesheet (`avatar.css`) reads, each optional: the read
24
25
  | `--vk-label-red-strong` | colour | `label-red-strong` | `hsl(0 59% 39%)` · dark `hsl(6 100% 83%)` |
25
26
  | `--vk-label-teal-fill` | colour | `label-teal-fill` | `hsl(196 52% 91.5%)` · dark `hsl(196 32% 17.5%)` |
26
27
  | `--vk-label-teal-strong` | colour | `label-teal-strong` | `hsl(193 82% 26%)` · dark `hsl(196 67% 75.5%)` |
28
+ | `--vk-label-blue` | colour | `label-blue` | `hsl(219 87% 54%)` · dark `hsl(219 87% 59.5%)` |
29
+ | `--vk-label-green` | colour | `label-green` | `hsl(158 98% 26%)` · dark `hsl(158 98% 34%)` |
30
+ | `--vk-label-amber` | colour | `label-amber` | `hsl(25 92% 41%)` |
31
+ | `--vk-label-red` | colour | `label-red` | `hsl(0 81% 58%)` |
32
+ | `--vk-label-purple` | colour | `label-purple` | `hsl(260 100% 64.5%)` · dark `hsl(260 100% 69%)` |
33
+ | `--vk-label-pink` | colour | `label-pink` | `hsl(335 73% 49.5%)` · dark `hsl(335 73% 57.5%)` |
34
+ | `--vk-label-teal` | colour | `label-teal` | `hsl(192 87% 32%)` · dark `hsl(192 87% 40%)` |
27
35
  | `--vk-neutral` | colour | `background-neutral` | `hsl(0 0% 94%)` · dark `hsl(225 7% 11%)` |
28
36
  | `--vk-person-1` | colour | `person-1` | `#d7a77e` |
29
37
  | `--vk-person-2` | colour | `person-2` | `#93b6ce` |
@@ -38,11 +46,14 @@ Every name the Avatar's stylesheet (`avatar.css`) reads, each optional: the read
38
46
  | `--vk-font-size-2xl` | size | `text-2xl` | `24px` |
39
47
  | `--vk-font-size-2xs` | size | `text-2xs` | `10px` |
40
48
  | `--vk-font-size-3xs` | size | `text-3xs` | `8px` |
49
+ | `--vk-font-size-4xl` | size | `text-4xl` | `36px` |
41
50
  | `--vk-font-size-sm` | size | `text-sm` | `14px` |
42
51
  | `--vk-font-size-xl` | size | `text-xl` | `20px` |
43
52
  | `--vk-font-size-xs` | size | `text-xs` | `12px` |
44
53
  | `--vk-font-weight-semibold` | size | `font-weight-semibold` | `600` |
45
54
  | `--vk-radius-2xl` | size | `radius-2xl` | `20px` |
55
+ | `--vk-radius-3xl` | size | `radius-3xl` | `26.67px` |
56
+ | `--vk-radius-4xl` | size | `radius-4xl` | `33.33px` |
46
57
  | `--vk-radius-full` | size | `radius-full` | `9999px` |
47
58
  | `--vk-radius-lg` | size | `radius-lg` | `10px` |
48
59
  | `--vk-radius-md` | size | `radius-md` | `7.5px` |
@@ -12,7 +12,6 @@ Every name the stylesheet of the words beside a choice (`choice.css`) reads, eac
12
12
  | `--vk-fg-subtle` | colour | `text-subtle` | `hsl(0 0% 35%)` · dark `hsl(258 4% 72%)` |
13
13
  | `--vk-ground` | colour | `surface` | `hsl(0 0% 100%)` · dark `hsl(210 6% 7%)` |
14
14
  | `--vk-hovered` | colour | `surface-hovered` | `hsl(0 0% 96.5%)` · dark `hsl(210 4% 9.5%)` |
15
- | `--vk-selected` | colour | `surface-selected` | `hsl(0 0% 94.5%)` · dark `hsl(225 7% 15%)` |
16
15
  | `--vk-border-width` | size | `border-width` | `1px` |
17
16
  | `--vk-font-size-sm` | size | `text-sm` | `14px` |
18
17
  | `--vk-font-size-xs` | size | `text-xs` | `12px` |
@@ -4,6 +4,8 @@ Every name the Field's, the FieldSet's, the separator's and Field rows' styleshe
4
4
 
5
5
  Its options set its variables on the frame that picks them (`data-field-rows-*`), from some of these names: an app that declares the names on each element, rather than once at its root, declares them on those frames too, or a frame's pick falls back to the default.
6
6
 
7
+ A row of Field rows may open with a glyph lane (`o-field-row-glyph`), 20 wide, its glyph centred; a row holding one starts the line above it from the words, after the lane and the gap (a place that sets another gap between a row's parts sets `--field-rows-line-start` with it). A label's one long word breaks inside its column. Nothing new to declare.
8
+
7
9
  | name | kind | the Outright token | default |
8
10
  | ---- | ---- | ------------------ | ------- |
9
11
  | `--vk-border-overlay-card` | colour | `border-overlay-card` | `hsl(220 3% 86%)` · dark `hsl(220 4% 22%)` |
@@ -13,6 +15,7 @@ Its options set its variables on the frame that picks them (`data-field-rows-*`)
13
15
  | `--vk-fg` | colour | `text` | `hsl(210 6% 7%)` · dark `hsl(210 8% 95%)` |
14
16
  | `--vk-fg-disabled` | colour | `text-disabled` | `hsl(210 1% 72%)` · dark `hsl(210 1% 37%)` |
15
17
  | `--vk-fg-subtle` | colour | `text-subtle` | `hsl(0 0% 35%)` · dark `hsl(258 4% 72%)` |
18
+ | `--vk-fg-subtlest` | colour | `text-subtlest` | `hsl(210 1% 53.5%)` · dark `hsl(210 3% 53%)` |
16
19
  | `--vk-font-size-base` | size | `text-base` | `16px` |
17
20
  | `--vk-font-size-sm` | size | `text-sm` | `14px` |
18
21
  | `--vk-font-size-xs` | size | `text-xs` | `12px` |
@@ -19,6 +19,7 @@ Every name the Input's, the InputGroup's and the segments' stylesheet (`input.cs
19
19
  | `--vk-ease-in` | motion | `ease-in` | `cubic-bezier(0.4, 0, 1, 1)` |
20
20
  | `--vk-ease-out` | motion | `ease-out` | `cubic-bezier(0, 0, 0.2, 1)` |
21
21
  | `--vk-fg` | colour | `text` | `hsl(210 6% 7%)` · dark `hsl(210 8% 95%)` |
22
+ | `--vk-fg-brand` | colour | `link` | `hsl(219 87% 54%)` · dark `hsl(219 87% 59.5%)` |
22
23
  | `--vk-fg-disabled` | colour | `text-disabled` | `hsl(210 1% 72%)` · dark `hsl(210 1% 37%)` |
23
24
  | `--vk-fg-subtle` | colour | `text-subtle` | `hsl(0 0% 35%)` · dark `hsl(258 4% 72%)` |
24
25
  | `--vk-fg-subtlest` | colour | `text-subtlest` | `hsl(210 1% 53.5%)` · dark `hsl(210 3% 53%)` |
@@ -10,6 +10,7 @@ The words beside a choice, and a card's edge and ground (`o-choice-*`), are `cho
10
10
  | `--vk-border-danger` | colour | `border-danger` | `hsl(3 87% 68%)` · dark `hsl(1 55% 46.5%)` |
11
11
  | `--vk-border-input` | colour | `border-input` | `hsl(220 3% 86%)` · dark `hsl(220 4% 22%)` |
12
12
  | `--vk-border-input-hovered` | colour | `border-input-hovered` | `hsl(210 1% 82%)` · dark `hsl(210 2% 26.5%)` |
13
+ | `--vk-border-overlay-card` | colour | `border-overlay-card` | `hsl(220 3% 86%)` · dark `hsl(220 4% 22%)` |
13
14
  | `--vk-border-selected` | colour | `border-selected` | `hsl(219 90% 65.5%)` · dark `hsl(219 66% 47%)` |
14
15
  | `--vk-border-subtle` | colour | `border-subtle` | `hsl(0 0% 94%)` · dark `hsl(225 7% 11%)` |
15
16
  | `--vk-border-width` | size | `border-width` | `1px` |
@@ -26,19 +27,29 @@ The words beside a choice, and a card's edge and ground (`o-choice-*`), are `cho
26
27
  | `--vk-fg-inverse` | colour | `text-inverse` | `hsl(0 0% 100%)` · dark `hsl(210 8% 95%)` |
27
28
  | `--vk-fg-on-brand` | colour | `text-brand-inverse` | `hsl(0 0% 100%)` · dark `hsl(210 8% 5%)` |
28
29
  | `--vk-fg-subtle` | colour | `text-subtle` | `hsl(0 0% 35%)` · dark `hsl(258 4% 72%)` |
30
+ | `--vk-fg-subtlest` | colour | `text-subtlest` | `hsl(210 1% 53.5%)` · dark `hsl(210 3% 53%)` |
29
31
  | `--vk-focus-offset` | size | `focus-offset` | `2px` |
30
32
  | `--vk-focus-width` | size | `focus-width` | `2px` |
33
+ | `--vk-font-size-base` | size | `text-base` | `16px` |
31
34
  | `--vk-font-weight-medium` | size | `font-weight-medium` | `500` |
32
35
  | `--vk-font-weight-normal` | size | `font-weight-normal` | `400` |
33
36
  | `--vk-ground` | colour | `surface` | `hsl(0 0% 100%)` · dark `hsl(210 6% 7%)` |
34
37
  | `--vk-hovered` | colour | `surface-hovered` | `hsl(0 0% 96.5%)` · dark `hsl(210 4% 9.5%)` |
35
38
  | `--vk-input` | colour | `background-input` | `hsl(0 0% 100% / 0)` |
39
+ | `--vk-line-height-base` | size | `text-base--line-height` | `1.5` |
40
+ | `--vk-label-amber` | colour | `label-amber` | `hsl(25 92% 41%)` |
36
41
  | `--vk-label-amber-fill` | colour | `label-amber-fill` | `hsl(19 72% 92.5%)` · dark `hsl(20 42% 18.5%)` |
42
+ | `--vk-label-blue` | colour | `label-blue` | `hsl(219 87% 54%)` · dark `hsl(219 87% 59.5%)` |
37
43
  | `--vk-label-blue-fill` | colour | `label-blue-fill` | `hsl(218 100% 94%)` · dark `hsl(219 46% 21%)` |
44
+ | `--vk-label-green` | colour | `label-green` | `hsl(158 98% 26%)` · dark `hsl(158 98% 34%)` |
38
45
  | `--vk-label-green-fill` | colour | `label-green-fill` | `hsl(143 41% 91%)` · dark `hsl(146 27% 16.5%)` |
46
+ | `--vk-label-pink` | colour | `label-pink` | `hsl(335 73% 49.5%)` · dark `hsl(335 73% 57.5%)` |
39
47
  | `--vk-label-pink-fill` | colour | `label-pink-fill` | `hsl(345 100% 94.5%)` · dark `hsl(341 34% 20.5%)` |
48
+ | `--vk-label-purple` | colour | `label-purple` | `hsl(260 100% 64.5%)` · dark `hsl(260 100% 69%)` |
40
49
  | `--vk-label-purple-fill` | colour | `label-purple-fill` | `hsl(249 100% 95.5%)` · dark `hsl(254 34% 23.5%)` |
50
+ | `--vk-label-red` | colour | `label-red` | `hsl(0 81% 58%)` |
41
51
  | `--vk-label-red-fill` | colour | `label-red-fill` | `hsl(6 100% 94%)` · dark `hsl(5 37% 20.5%)` |
52
+ | `--vk-label-teal` | colour | `label-teal` | `hsl(192 87% 32%)` · dark `hsl(192 87% 40%)` |
42
53
  | `--vk-label-teal-fill` | colour | `label-teal-fill` | `hsl(196 52% 91.5%)` · dark `hsl(196 32% 17.5%)` |
43
54
  | `--vk-neutral` | colour | `background-neutral` | `hsl(0 0% 94%)` · dark `hsl(225 7% 11%)` |
44
55
  | `--vk-overlay-card` | colour | `surface-overlay-card` | `hsl(0 0% 94%)` · dark `hsl(225 7% 15%)` |
@@ -50,8 +61,12 @@ The words beside a choice, and a card's edge and ground (`o-choice-*`), are `cho
50
61
 
51
62
  ## A swatch
52
63
 
53
- `<Radio swatch="teal" aria-label="Teal" />`: a 24px dot in one of the label colours (`blue`, `green`, `amber`, `red`, `purple`, `pink`, `teal`, `grey`) in place of the ring, named by its aria-label. Chosen, a thin ring of the ground (`--vk-ground`) and the selected colour just outside it; under the pointer the same ring in `--vk-border-input-hovered`; focus outlines it outside that ring; disabled, `--vk-neutral` with a dashed edge, which the arrows pass by, the chosen one keeping its ring in `--vk-border-input`. In a `row` group, 10 apart.
64
+ `<Radio swatch="teal" aria-label="Teal" />`: a 24px dot in one of the label colours (`blue`, `green`, `amber`, `red`, `purple`, `pink`, `teal`, `grey`) in place of the ring, named by its aria-label. Chosen, a thin ring of the ground (`--vk-ground`) and the selected colour just outside it; under the pointer the same ring in `--vk-border-input-hovered`; focus outlines it outside that ring; disabled, `--vk-neutral` with a dashed edge, which the arrows pass by, the chosen one keeping its ring in `--vk-border-input`. In a `row` group, 10 apart. On a phone each row of swatches is a card of its own, each swatch 28 across in its colour's bold shade (`--vk-label-<colour>`, grey `--vk-fg-subtlest`) where a computer's is the label's pale fill (`--vk-label-<colour>-fill`, grey `--vk-neutral`).
54
65
 
55
66
  ## A picture on a marked card
56
67
 
57
68
  `<Radio mark={<SunIcon />} picture={<YourPicture />} label="Light" />`: what the app draws fills the card's width, 120 tall, framed in `--vk-border-subtle` at `--vk-radius-sm`; the mark and the name stand side by side and centred under it, in `--vk-fg-subtle`, the chosen card's in `--vk-fg`, its name `--vk-font-weight-medium`. A picture makes the card marked with a mark or without. In a `row` group the pictured cards stand one beside another at equal widths, on a phone too.
69
+
70
+ ## Cards on a phone
71
+
72
+ `<Radio card value="everyone" label="Everyone in the workspace" note="Every member and guest." />` in a group: on a phone the cards are iOS's ✓ rows on one card (`--vk-overlay-card`, `--vk-radius-xl`), each row 52 at least, its label in `--vk-font-size-base` and its note in `--vk-fg-subtlest`, a rule in `--vk-border-overlay-card` between each from the words (a place stops it `--field-rows-line-end` short of the right edge, as Field rows' rule); the ring stands at the row's end, bare, and the chosen one shows a ✓ in `--vk-fg-accent`. The ring keeps the keys and the focus.
@@ -5,8 +5,10 @@ Every name the Select's stylesheet (`select.css`) reads, each optional: the read
5
5
  | name | kind | the Outright token | default |
6
6
  | ---- | ---- | ------------------ | ------- |
7
7
  | `--vk-fg-disabled` | colour | `text-disabled` | `hsl(210 1% 72%)` · dark `hsl(210 1% 37%)` |
8
+ | `--vk-fg-subtle` | colour | `text-subtle` | `hsl(0 0% 35%)` · dark `hsl(258 4% 72%)` |
8
9
  | `--vk-fg-subtlest` | colour | `text-subtlest` | `hsl(210 1% 53.5%)` · dark `hsl(210 3% 53%)` |
9
10
  | `--vk-font-size-base` | size | `text-base` | `16px` |
11
+ | `--vk-font-weight-normal` | size | `font-weight-normal` | `400` |
10
12
  | `--vk-spacing` | size | `spacing` | `4px` |
11
13
  | `--vk-duration-fast` | motion | `duration-fast` | `150ms` |
12
14
  | `--vk-ease-out` | motion | `ease-out` | `cubic-bezier(0, 0, 0.2, 1)` |
@@ -10,17 +10,35 @@ Every name the setting row's stylesheet (`setting-row.css`) reads, each optional
10
10
  | `--vk-hovered` | colour | `surface-hovered` | `hsl(0 0% 96.5%)` · dark `hsl(210 4% 9.5%)` |
11
11
  | `--vk-raised` | colour | `surface-raised` | `hsl(0 0% 100%)` · dark `hsl(226 10% 10%)` |
12
12
  | `--vk-danger` | colour | `text-danger` | `hsl(0 81% 58%)` |
13
+ | `--vk-fg` | colour | `text` | `hsl(210 6% 7%)` · dark `hsl(210 8% 95%)` |
13
14
  | `--vk-fg-subtle` | colour | `text-subtle` | `hsl(0 0% 35%)` · dark `hsl(258 4% 72%)` |
14
15
  | `--vk-fg-subtlest` | colour | `text-subtlest` | `hsl(210 1% 53.5%)` · dark `hsl(210 3% 53%)` |
16
+ | `--vk-fg-brand` | colour | `link` | `hsl(219 87% 54%)` · dark `hsl(219 87% 59.5%)` |
17
+ | `--vk-border-brand` | colour | `border-focused` | `hsl(219 90% 65.5%)` · dark `hsl(219 66% 47%)` |
18
+ | `--vk-label-blue` | colour | `label-blue` | `hsl(219 87% 54%)` · dark `hsl(219 87% 59.5%)` |
19
+ | `--vk-label-green` | colour | `label-green` | `hsl(158 98% 26%)` · dark `hsl(158 98% 34%)` |
20
+ | `--vk-label-amber` | colour | `label-amber` | `hsl(25 92% 41%)` |
21
+ | `--vk-label-red` | colour | `label-red` | `hsl(0 81% 58%)` |
22
+ | `--vk-label-purple` | colour | `label-purple` | `hsl(260 100% 64.5%)` · dark `hsl(260 100% 69%)` |
23
+ | `--vk-label-pink` | colour | `label-pink` | `hsl(335 73% 49.5%)` · dark `hsl(335 73% 57.5%)` |
24
+ | `--vk-label-teal` | colour | `label-teal` | `hsl(192 87% 32%)` · dark `hsl(192 87% 40%)` |
25
+ | `--vk-fg-inverse` | colour | `text-inverse` | `hsl(0 0% 100%)` · dark `hsl(210 8% 95%)` |
26
+ | `--vk-neutral` | colour | `background-neutral` | `hsl(0 0% 94%)` · dark `hsl(225 7% 11%)` |
27
+ | `--vk-icon-disclosure` | colour | `icon-disclosure` | `hsl(210 1% 72%)` · dark `hsl(210 1% 37%)` |
15
28
  | `--vk-border-width` | size | `border-width` | `1px` |
16
29
  | `--vk-corner-smoothing` | size | `corner-smoothing` | `0.7` |
17
30
  | `--vk-font-size-sm` | size | `text-sm` | `14px` |
18
31
  | `--vk-font-size-xs` | size | `text-xs` | `12px` |
32
+ | `--vk-focus-width` | size | `focus-width` | `2px` |
33
+ | `--vk-focus-offset` | size | `focus-offset` | `2px` |
19
34
  | `--vk-font-weight-medium` | size | `font-weight-medium` | `500` |
20
35
  | `--vk-line-height-sm` | size | `text-sm--line-height` | `1.4286` |
21
36
  | `--vk-line-height-xs` | size | `text-xs--line-height` | `1.3333` |
22
37
  | `--vk-radius-lg` | size | `radius-lg` | `10px` |
23
38
  | `--vk-radius-md` | size | `radius-md` | `7.5px` |
39
+ | `--vk-radius-sm` | size | `radius-sm` | `5px` |
40
+ | `--vk-radius-full` | size | `radius-full` | `9999px` |
24
41
  | `--vk-spacing` | size | `spacing` | `4px` |
42
+ | `--vk-opacity-off` | size | `opacity-off` | `0.45` |
25
43
  | `--vk-duration-fast` | motion | `duration-fast` | `150ms` |
26
44
  | `--vk-ease-out` | motion | `ease-out` | `cubic-bezier(0, 0, 0.2, 1)` |
@@ -6,7 +6,6 @@ Every name the SwitchRow's and SwitchRows' stylesheet (`switch-row.css`) reads,
6
6
  | ---- | ---- | ------------------ | ------- |
7
7
  | `--vk-border` | colour | `border` | `hsl(220 7% 90%)` · dark `hsl(225 7% 15%)` |
8
8
  | `--vk-border-subtle` | colour | `border-subtle` | `hsl(0 0% 94%)` · dark `hsl(225 7% 11%)` |
9
- | `--vk-hovered` | colour | `surface-hovered` | `hsl(0 0% 96.5%)` · dark `hsl(210 4% 9.5%)` |
10
9
  | `--vk-border-width` | size | `border-width` | `1px` |
11
10
  | `--vk-corner-smoothing` | size | `corner-smoothing` | `0.7` |
12
11
  | `--vk-font-size-sm` | size | `text-sm` | `14px` |
@@ -14,5 +13,3 @@ Every name the SwitchRow's and SwitchRows' stylesheet (`switch-row.css`) reads,
14
13
  | `--vk-line-height-sm` | size | `text-sm--line-height` | `1.4286` |
15
14
  | `--vk-radius-lg` | size | `radius-lg` | `10px` |
16
15
  | `--vk-spacing` | size | `spacing` | `4px` |
17
- | `--vk-duration-fast` | motion | `duration-fast` | `150ms` |
18
- | `--vk-ease-out` | motion | `ease-out` | `cubic-bezier(0, 0, 0.2, 1)` |
@@ -4,4 +4,8 @@ Every name the TagField's stylesheet (`tag-field.css`) reads, each optional: the
4
4
 
5
5
  | name | kind | the Outright token | default |
6
6
  | ---- | ---- | ------------------ | ------- |
7
+ | `--vk-border-width` | size | `border-width` | `1px` |
8
+ | `--vk-font-weight-normal` | size | `font-weight-normal` | `400` |
9
+ | `--vk-neutral` | colour | `background-neutral` | `hsl(0 0% 94%)` · dark `hsl(225 7% 11%)` |
10
+ | `--vk-radius-full` | size | `radius-full` | `9999px` |
7
11
  | `--vk-spacing` | size | `spacing` | `4px` |
@@ -14,6 +14,7 @@ Every name the Tag's stylesheet (`tag.css`) reads, each optional: the ready styl
14
14
  | `--vk-focus-width` | size | `focus-width` | `2px` |
15
15
  | `--vk-font-size-xs` | size | `text-xs` | `12px` |
16
16
  | `--vk-font-weight-medium` | size | `font-weight-medium` | `500` |
17
+ | `--vk-font-weight-normal` | size | `font-weight-normal` | `400` |
17
18
  | `--vk-radius-md` | size | `radius-md` | `7.5px` |
18
19
  | `--vk-radius-xs` | size | `radius-xs` | `2.5px` |
19
20
  | `--vk-spacing` | size | `spacing` | `4px` |
@@ -8,7 +8,7 @@ This page takes you from install to a grid of records drawn with your own primit
8
8
  pnpm add viewkitjs zod
9
9
  ```
10
10
 
11
- `react` and `react-dom` 19 are optional peers that the views part needs and you already have, and `zod` `^4.1.12` is a peer of the package. The dnd-kit packages are optional peers too, for the panels' parts that drag (the views row's pills, the sort's rules, the Columns list, the group order), which the door loads with `import()` as it loads: install them if your app renders one. The drawn panels' door (`viewkitjs/views/panels/react`) itself loads without them. The package is ESM only and runs on Node 20 or later.
11
+ `react` and `react-dom` 19 are optional peers that the views part needs and you already have, and `zod` `^4.1.12` is a peer of the package. The dnd-kit packages are optional peers too, for the panels' parts that drag (the views row's pills, the sort's rules, the Columns list, the group order), which the door loads with `import()` as it loads: install them if your app renders one. The drawn panels' door (`viewkitjs/views/panels/react`) and the list's (`viewkitjs/views/list`) load without them. The package is ESM only and runs on Node 20 or later.
12
12
 
13
13
  The rendering's look is one stylesheet: `@import "viewkitjs/views/styles.css";` draws it with no Tailwind, the Outright look by default, and one block mapping the `--vk-*` colours onto your theme makes it your app's. [Install](install.md) has both, and the `@source` line that lets your own Tailwind compile it instead.
14
14
 
@@ -64,7 +64,7 @@ const DEAL_BINDINGS = bindFields<Deal, typeof DEAL_FIELDS>(DEAL_FIELDS, {
64
64
  });
65
65
  ```
66
66
 
67
- `bindFields` checks every binding when the module loads: a `write` on a field that can't be changed, or a writable money field whose currency comes from the row with no `unit`, throws `FieldBindingError` at startup. The [columns guide](guides/columns.md) has the rest.
67
+ A field you leave out binds by its key: it reads `row[key]` and writes `{ [key]: value }`. `bindFields` checks every binding when the module loads: a `write` on a field that can't be changed, or a writable money field whose currency comes from the row with no `unit`, throws `FieldBindingError` at startup. The [columns guide](guides/columns.md) has the rest.
68
68
 
69
69
  ## Make the columns
70
70
 
@@ -202,7 +202,7 @@ A `command` field offers verbs instead of an editor: moving a deal to Lost asks
202
202
 
203
203
  ## The row's menu
204
204
 
205
- `RowMenu` wraps a section's rows: the grid mounts it once around each section's rows' container, never around each row, and aims it at the row a press or a right-click came from. Its props are that row's, set in the same event your menu opens on; `children` is the rows' container, which takes the props and `ref` your trigger hands it (a `Slot`, `asChild`) and passes them to its element; a right-click on no row arrives already prevented and opens nothing. The rendering builds its `items` (the clicked cell's clipboard rows, Select, your verbs for the row), and the menu adds an Open page row before them when the row has a page (`openHref`, opened in a new tab) and a Delete row after them when the row can be deleted (`onDelete`). Its props are `ViewsRowMenuProps`; each item is a `ViewsRowMenuItem`, a rule (`{ separator: true }`) or a labelled row with its `onClick`, optional `icon`, `destructive`, `disabled` with its `disabledReason` (the grid's own Cut, Paste and Clear carry one whenever they are disabled), and a `shortcut` hint the menu draws but never binds. The default names your `Menu` "Row actions" (`views.menus.row-menu`).
205
+ `RowMenu` wraps a section's rows: the grid mounts it once around each section's rows' container, never around each row, and aims it at the row a press or a right-click came from. Its props are that row's, set in the same event your menu opens on; `children` is the rows' container, which takes the props and `ref` your trigger hands it (a `Slot`, `asChild`) and passes them to its element; a right-click on no row arrives already prevented and opens nothing. The rendering builds its `items` (the clicked cell's clipboard rows, Select, your verbs for the row), and the menu adds an Open page row before them when the row has a page (`openHref`, opened in a new tab) and a Delete row after them when the row can be deleted (`onDelete`). Its props are `ViewsRowMenuProps`; each item is a `ViewsRowMenuItem`, a rule (`{ separator: true }`) or a labelled row with its `onClick`, optional `icon`, `destructive`, `disabled` with its `disabledReason` (the grid's own Cut, Paste and Clear carry one whenever they are disabled), and a `shortcut` hint the menu draws but never binds. The default names your `Menu` "Row actions" (`views.menus.row-menu`). Where the grid has `menus.row`, Open page and Delete come as rows of `items` (`row-open`, `row-delete`, which the grid's Delete asks the confirm port for, as yours would), and `openHref` and `onDelete` are left out; while `menus.row` answers, `items` is one disabled row with the `loading` glyph, "Loading…" (`views.menus.row-waiting`). The grid asks `menus.row` on the row's right-click (its ⋯'s, the menu key's), so a `RowMenu` of yours that opens any other way meets that waiting row.
206
206
 
207
207
  The default opens your `Menu` at the pointer on a right-click, or from the row's ⋯ (`data-slot="vk-grid-row-more"`). On a touch screen a long-press opens nothing: the ⋯ is the way in there. Its Delete asks first, through the `confirm` port, with the message `views.menus.row-delete-confirm` and the row's `deleteLabel` as the `subject`; an app that hands no `confirm` gets the browser's own where your components map holds no `PortsHost`, ViewKit's alert dialog where it does (`CONTROLS`), and a confirm that rejects or throws counts as no. A delete that then rejects leaves the row where it was and says so through the toast port's `error`, with `views.menus.row-delete-failed`. [Ports](ports.md) covers `confirm` and the toast.
208
208
 
@@ -214,7 +214,7 @@ Swap it for a menu of your own, or for a long-press that selects: `onToggleSelec
214
214
 
215
215
  ## Handing them in
216
216
 
217
- The provider's `atoms` takes any of them, each over the default of its name; the rest stay the defaults. Declare the object at module level: a new object each render re-renders every view.
217
+ The provider's `atoms` takes any of them, each over the default of its name; the rest stay the defaults. Handed `components={CONTROLS}` as it stands, the provider lays them over `CONTROL_ATOMS` (the Tag, the StatusBadge, the CellMore and the ToolbarButton drawn with ViewKit's controls) instead; a map spread from `CONTROLS` brings none, so an app that spreads it hands `atoms={{ ...CONTROL_ATOMS, ...own }}` for them. Declare the object at module level: a new object each render re-renders every view.
218
218
 
219
219
  ```tsx
220
220
  import type { ReactNode } from "react";
@@ -86,7 +86,7 @@ const deal: Deal = {
86
86
 
87
87
  ## A binding: how a field reads and writes on your row
88
88
 
89
- `bindFields(registry, specs)` binds every field of a registry at once, and refuses a registry with a field left unbound; `bindField(field, spec)` binds one. A spec says:
89
+ `bindFields(registry, specs)` binds every field of a registry at once; `bindField(field, spec)` binds one. A field you give no spec binds by its key: it reads `row[key]`, and, where anyone may write it, writes `{ [key]: value }` (a number, a percent or an amount writes the number its editor commits, as decimal text under `storage: "decimal"`), so you write specs only for the fields that differ, and `bindFields(registry)` with none binds them all. A field the key can't bind still throws `FieldBindingError`, naming why: a writable relation needs its candidates, a writable amount whose currency is the row's its `unit`, a ratio formula its `ratio` readers, and a writable datetime its `write`, since its editor commits a local time that only your time zone turns into an instant. A spec says:
90
90
 
91
91
  - `read(row)`: the value a surface draws. A relation reads its resolved `{ id, label }`.
92
92
  - `editRead(row)`: the stored value, when it differs from the one drawn: a relation's id, or a raw value behind a fallback. An editor opens on it.
@@ -1,6 +1,6 @@
1
1
  # Ports
2
2
 
3
- A port is a runtime service your app hands the provider: the narrowest surface the rendering needs, named for what it does, so your own toast library, haptics, clipboard helper, storage and dialog each map onto it in a few lines. There are five: `toast`, `haptics`, `clipboard`, `viewPrefs` and `confirm`; `toast` and `confirm` are optional, and an app that spreads `CONTROLS` and hands neither reports in ViewKit's Toast and asks in ViewKit's alert dialog (`CONTROLS.PortsHost`). This page covers what calls each and when, the do-nothing ports to start with, and a port over each of your services.
3
+ A port is a runtime service your app hands the provider: the narrowest surface the rendering needs, named for what it does, so your own toast library, haptics, clipboard helper, storage and dialog each map onto it in a few lines. There are five: `toast`, `haptics`, `clipboard`, `viewPrefs` and `confirm`, and every one is optional (VK-198). Left out, `haptics` do nothing, `clipboard` is the browser's own, `viewPrefs` keeps each value on the browser's `localStorage` at the package's `vk:` key, and an app that spreads `CONTROLS` reports in ViewKit's Toast and asks in ViewKit's alert dialog (`CONTROLS.PortsHost`); each default reads the browser only when it is called, never while the server renders. Hand only the ones your app does its own way. This page covers what calls each and when, the do-nothing ports to start with, and a port over each of your services.
4
4
 
5
5
  ## Start with nothing
6
6