viewkitjs 0.28.0 → 0.30.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 (530) hide show
  1. package/CHANGELOG.md +218 -0
  2. package/MIGRATION.md +181 -11
  3. package/fields/dist/derived.d.ts +2 -1
  4. package/fields/dist/derived.js +9 -3
  5. package/fields/dist/entities.js +41 -3
  6. package/fields/dist/index.d.ts +1 -1
  7. package/fields/dist/index.js +1 -1
  8. package/fields/dist/messages.d.ts +8 -2
  9. package/fields/dist/messages.js +3 -0
  10. package/fields/dist/range.d.ts +6 -0
  11. package/fields/dist/range.js +8 -0
  12. package/fields/dist/registry.js +11 -1
  13. package/fields/dist/spec-changes.js +1 -0
  14. package/fields/dist/types.d.ts +23 -1
  15. package/fields/docs/guides/derived-fields.md +7 -5
  16. package/fields/docs/guides/field-types.md +2 -2
  17. package/fields/docs/guides/the-index.md +1 -1
  18. package/fields/docs/reference/fields.md +3 -1
  19. package/fields/docs/reference/types.md +3 -1
  20. package/fields/skills/viewkit/SKILL.md +1 -1
  21. package/package.json +2 -1
  22. package/postgres/dist/definitions/build.js +29 -5
  23. package/postgres/dist/definitions/label.d.ts +7 -0
  24. package/postgres/dist/definitions/label.js +9 -1
  25. package/postgres/dist/definitions/lookup.js +6 -2
  26. package/postgres/dist/definitions/place.d.ts +6 -3
  27. package/postgres/dist/definitions/rollup.js +5 -1
  28. package/postgres/dist/definitions/storage.d.ts +15 -0
  29. package/postgres/dist/definitions/storage.js +52 -1
  30. package/postgres/dist/definitions/stored.js +21 -0
  31. package/postgres/dist/phone.d.ts +13 -1
  32. package/postgres/dist/phone.js +23 -3
  33. package/postgres/dist/search-indexes.d.ts +6 -1
  34. package/postgres/dist/search-indexes.js +71 -25
  35. package/postgres/dist/search.js +3 -3
  36. package/postgres/docs/guides/definitions.md +22 -5
  37. package/postgres/docs/guides/field-map.md +5 -4
  38. package/postgres/docs/reference/definitions.md +3 -3
  39. package/postgres/docs/reference/postgres.md +1 -1
  40. package/views/dist/cells/cell-format.d.ts +2 -2
  41. package/views/dist/cells/cell-format.js +2 -2
  42. package/views/dist/cells/cell-values.js +9 -12
  43. package/views/dist/contract.d.ts +161 -18
  44. package/views/dist/contract.js +170 -28
  45. package/views/dist/controls/bulk-bar/bulk-bar-of.d.ts +66 -0
  46. package/views/dist/controls/bulk-bar/bulk-bar-of.js +22 -0
  47. package/views/dist/controls/bulk-bar/bulk-bar.d.ts +40 -0
  48. package/views/dist/controls/bulk-bar/bulk-bar.js +278 -0
  49. package/views/dist/controls/bulk-bar/looks.d.ts +10 -0
  50. package/views/dist/controls/bulk-bar/looks.js +14 -0
  51. package/views/dist/controls/bulk-bar/map-selection-bar.d.ts +19 -0
  52. package/views/dist/controls/bulk-bar/map-selection-bar.js +57 -0
  53. package/views/dist/controls/bulk-bar/tokens.d.ts +136 -0
  54. package/views/dist/controls/bulk-bar/tokens.js +36 -0
  55. package/views/dist/controls/bulk-bar/words.d.ts +50 -0
  56. package/views/dist/controls/bulk-bar/words.js +19 -0
  57. package/views/dist/controls/bulk-bar.css +96 -0
  58. package/views/dist/controls/button/button.js +3 -1
  59. package/views/dist/controls/button.css +5 -4
  60. package/views/dist/controls/checkbox/checkbox.js +3 -1
  61. package/views/dist/controls/checkbox.css +1 -1
  62. package/views/dist/controls/choice/tokens.d.ts +79 -0
  63. package/views/dist/controls/choice/tokens.js +22 -0
  64. package/views/dist/controls/choice.css +31 -0
  65. package/views/dist/controls/compound-editor/looks.js +1 -1
  66. package/views/dist/controls/controls.d.ts +8 -0
  67. package/views/dist/controls/controls.js +8 -0
  68. package/views/dist/controls/customize/customize.d.ts +176 -0
  69. package/views/dist/controls/customize/customize.js +348 -0
  70. package/views/dist/controls/customize/glide.d.ts +10 -0
  71. package/views/dist/controls/customize/glide.js +55 -0
  72. package/views/dist/controls/customize/looks.d.ts +13 -0
  73. package/views/dist/controls/customize/looks.js +11 -0
  74. package/views/dist/controls/customize/map-customize-body.d.ts +15 -0
  75. package/views/dist/controls/customize/map-customize-body.js +195 -0
  76. package/views/dist/controls/customize/map-ranges.d.ts +23 -0
  77. package/views/dist/controls/customize/map-ranges.js +41 -0
  78. package/views/dist/controls/customize/rules.d.ts +39 -0
  79. package/views/dist/controls/customize/rules.js +21 -0
  80. package/views/dist/controls/customize/tokens.d.ts +40 -0
  81. package/views/dist/controls/customize/tokens.js +12 -0
  82. package/views/dist/controls/customize/words.d.ts +65 -0
  83. package/views/dist/controls/customize/words.js +42 -0
  84. package/views/dist/controls/customize.css +57 -0
  85. package/views/dist/controls/date-editor/looks.js +1 -1
  86. package/views/dist/controls/filter-editor/block.d.ts +31 -0
  87. package/views/dist/controls/filter-editor/block.js +27 -0
  88. package/views/dist/controls/filter-editor/filter-editor.d.ts +4 -0
  89. package/views/dist/controls/filter-editor/filter-editor.js +86 -43
  90. package/views/dist/controls/filter-editor/how.d.ts +1 -1
  91. package/views/dist/controls/filter-editor/how.js +1 -0
  92. package/views/dist/controls/filter-editor/map-filter-body.d.ts +16 -1
  93. package/views/dist/controls/filter-editor/map-filter-body.js +39 -13
  94. package/views/dist/controls/filter-editor/map-rules.d.ts +27 -11
  95. package/views/dist/controls/filter-editor/map-rules.js +73 -42
  96. package/views/dist/controls/filter-editor/rules.d.ts +42 -5
  97. package/views/dist/controls/filter-editor/rules.js +55 -2
  98. package/views/dist/controls/filter-editor/words.d.ts +15 -0
  99. package/views/dist/controls/filter-editor/words.js +6 -0
  100. package/views/dist/controls/filter-editor.css +18 -0
  101. package/views/dist/controls/index.d.ts +33 -9
  102. package/views/dist/controls/index.js +32 -9
  103. package/views/dist/controls/inline-input/looks.js +1 -1
  104. package/views/dist/controls/input/input.js +10 -4
  105. package/views/dist/controls/internal/phone.d.ts +5 -4
  106. package/views/dist/controls/internal/phone.js +7 -7
  107. package/views/dist/controls/internal/scroll.js +5 -1
  108. package/views/dist/controls/internal/typed-run.d.ts +2 -0
  109. package/views/dist/controls/internal/typed-run.js +5 -0
  110. package/views/dist/controls/menu/map-menu.js +2 -2
  111. package/views/dist/controls/menu-list/menu-list.d.ts +16 -1
  112. package/views/dist/controls/menu-list/menu-list.js +26 -8
  113. package/views/dist/controls/menu-list.css +8 -0
  114. package/views/dist/controls/number-editor/looks.js +1 -1
  115. package/views/dist/controls/option/option.js +3 -1
  116. package/views/dist/controls/option.css +1 -1
  117. package/views/dist/controls/pane/pane.d.ts +4 -0
  118. package/views/dist/controls/pane/pane.js +2 -1
  119. package/views/dist/controls/picker/looks.js +1 -1
  120. package/views/dist/controls/picker/map-picker.d.ts +6 -2
  121. package/views/dist/controls/picker/map-picker.js +4 -2
  122. package/views/dist/controls/picker/picker.d.ts +7 -0
  123. package/views/dist/controls/picker/picker.js +57 -8
  124. package/views/dist/controls/popover/map-popover.d.ts +1 -1
  125. package/views/dist/controls/popover/map-popover.js +2 -2
  126. package/views/dist/controls/popover/popover.js +2 -1
  127. package/views/dist/controls/popover.css +3 -0
  128. package/views/dist/controls/ports-host/map-ports-host.d.ts +7 -0
  129. package/views/dist/controls/ports-host/map-ports-host.js +43 -0
  130. package/views/dist/controls/press/tokens.d.ts +8 -0
  131. package/views/dist/controls/press/tokens.js +4 -0
  132. package/views/dist/controls/press.css +44 -0
  133. package/views/dist/controls/quick-filters/looks.d.ts +11 -0
  134. package/views/dist/controls/quick-filters/looks.js +9 -0
  135. package/views/dist/controls/quick-filters/map-quick-filters-body.d.ts +31 -0
  136. package/views/dist/controls/quick-filters/map-quick-filters-body.js +59 -0
  137. package/views/dist/controls/quick-filters/quick-filters.d.ts +37 -0
  138. package/views/dist/controls/quick-filters/quick-filters.js +89 -0
  139. package/views/dist/controls/quick-filters/reminder.d.ts +18 -0
  140. package/views/dist/controls/quick-filters/reminder.js +41 -0
  141. package/views/dist/controls/quick-filters/rules.d.ts +89 -0
  142. package/views/dist/controls/quick-filters/rules.js +52 -0
  143. package/views/dist/controls/quick-filters/tokens.d.ts +112 -0
  144. package/views/dist/controls/quick-filters/tokens.js +30 -0
  145. package/views/dist/controls/quick-filters/words.d.ts +25 -0
  146. package/views/dist/controls/quick-filters/words.js +13 -0
  147. package/views/dist/controls/quick-filters.css +118 -0
  148. package/views/dist/controls/sheet/bottom-sheet.d.ts +9 -4
  149. package/views/dist/controls/sheet/bottom-sheet.js +4 -4
  150. package/views/dist/controls/sheet/map-sheet.d.ts +4 -1
  151. package/views/dist/controls/sheet/map-sheet.js +19 -6
  152. package/views/dist/controls/sheet/sheet-parts.d.ts +10 -0
  153. package/views/dist/controls/sheet/sheet-parts.js +2 -0
  154. package/views/dist/controls/switch-row/switch-row.d.ts +15 -0
  155. package/views/dist/controls/switch-row/switch-row.js +9 -0
  156. package/views/dist/controls/switch-row/tokens.d.ts +51 -0
  157. package/views/dist/controls/switch-row/tokens.js +15 -0
  158. package/views/dist/controls/switch-row.css +39 -0
  159. package/views/dist/controls/switch.css +1 -1
  160. package/views/dist/controls/tag/tag.js +3 -1
  161. package/views/dist/controls/tag-field/tag-field.d.ts +20 -0
  162. package/views/dist/controls/tag-field/tag-field.js +19 -0
  163. package/views/dist/controls/tag-field/tokens.d.ts +7 -0
  164. package/views/dist/controls/tag-field/tokens.js +4 -0
  165. package/views/dist/controls/tag-field.css +13 -0
  166. package/views/dist/controls/text-editor/looks.js +1 -1
  167. package/views/dist/controls/text-editor/map-text-body.d.ts +1 -1
  168. package/views/dist/controls/text-editor/map-text-body.js +2 -2
  169. package/views/dist/controls/text-editor/text-editor.d.ts +3 -0
  170. package/views/dist/controls/text-editor/text-editor.js +17 -7
  171. package/views/dist/controls/text-editor.css +11 -0
  172. package/views/dist/controls/toast/toast.d.ts +5 -1
  173. package/views/dist/controls/toast/toast.js +5 -3
  174. package/views/dist/controls/tokens.js +18 -0
  175. package/views/dist/controls/toolbar/keys.d.ts +3 -0
  176. package/views/dist/controls/toolbar/keys.js +11 -0
  177. package/views/dist/controls/toolbar/looks.d.ts +10 -0
  178. package/views/dist/controls/toolbar/looks.js +40 -0
  179. package/views/dist/controls/toolbar/tokens.d.ts +28 -0
  180. package/views/dist/controls/toolbar/tokens.js +9 -0
  181. package/views/dist/controls/toolbar/toolbar.d.ts +111 -0
  182. package/views/dist/controls/toolbar/toolbar.js +370 -0
  183. package/views/dist/controls/toolbar/words.d.ts +28 -0
  184. package/views/dist/controls/toolbar/words.js +17 -0
  185. package/views/dist/controls/toolbar-button/looks.d.ts +4 -0
  186. package/views/dist/controls/toolbar-button/looks.js +21 -0
  187. package/views/dist/controls/toolbar-button/tokens.d.ts +103 -0
  188. package/views/dist/controls/toolbar-button/tokens.js +28 -0
  189. package/views/dist/controls/toolbar-button/toolbar-button.d.ts +66 -0
  190. package/views/dist/controls/toolbar-button/toolbar-button.js +51 -0
  191. package/views/dist/controls/toolbar-button.css +75 -0
  192. package/views/dist/controls/toolbar.css +65 -0
  193. package/views/dist/controls/tooltip/map-tooltip.d.ts +1 -1
  194. package/views/dist/controls/tooltip/map-tooltip.js +2 -2
  195. package/views/dist/controls/tooltip/tooltip.d.ts +3 -1
  196. package/views/dist/controls/tooltip/tooltip.js +2 -2
  197. package/views/dist/controls/values-editor/looks.js +1 -1
  198. package/views/dist/controls/values-editor/values.js +6 -2
  199. package/views/dist/controls/views-list/map-views-list-body.d.ts +4 -1
  200. package/views/dist/controls/views-list/map-views-list-body.js +128 -4
  201. package/views/dist/controls/views-list/rules.d.ts +26 -0
  202. package/views/dist/controls/views-list/rules.js +63 -0
  203. package/views/dist/controls/views-list/view-menu.d.ts +84 -0
  204. package/views/dist/controls/views-list/view-menu.js +201 -0
  205. package/views/dist/controls/views-list/views-list.d.ts +8 -1
  206. package/views/dist/controls/views-list/views-list.js +18 -3
  207. package/views/dist/controls/views-list/words.d.ts +54 -0
  208. package/views/dist/controls/views-list/words.js +10 -1
  209. package/views/dist/controls/views-list.css +5 -1
  210. package/views/dist/display/date.js +3 -3
  211. package/views/dist/display/format.d.ts +6 -0
  212. package/views/dist/display/format.js +3 -0
  213. package/views/dist/display/index.d.ts +1 -1
  214. package/views/dist/display/index.js +1 -1
  215. package/views/dist/display/options.d.ts +1 -1
  216. package/views/dist/display/range.d.ts +2 -1
  217. package/views/dist/display/range.js +4 -1
  218. package/views/dist/display/rich-text.js +0 -1
  219. package/views/dist/editors/ChipsEditor.d.ts +4 -5
  220. package/views/dist/editors/ChipsEditor.js +12 -78
  221. package/views/dist/editors/DateEditor.d.ts +12 -16
  222. package/views/dist/editors/DateEditor.js +40 -191
  223. package/views/dist/editors/EditorPanel.d.ts +2 -6
  224. package/views/dist/editors/EditorPanel.js +2 -2
  225. package/views/dist/editors/LocationEditor.d.ts +11 -19
  226. package/views/dist/editors/LocationEditor.js +19 -211
  227. package/views/dist/editors/NameEditor.d.ts +8 -16
  228. package/views/dist/editors/NameEditor.js +11 -100
  229. package/views/dist/editors/NumberEditor.d.ts +14 -21
  230. package/views/dist/editors/NumberEditor.js +22 -49
  231. package/views/dist/editors/RangeEditor.d.ts +9 -33
  232. package/views/dist/editors/RangeEditor.js +12 -97
  233. package/views/dist/editors/RelationEditor.d.ts +6 -9
  234. package/views/dist/editors/RelationEditor.js +11 -30
  235. package/views/dist/editors/RelationSetEditor.d.ts +13 -24
  236. package/views/dist/editors/RelationSetEditor.js +33 -101
  237. package/views/dist/editors/SelectEditor.d.ts +15 -17
  238. package/views/dist/editors/SelectEditor.js +15 -94
  239. package/views/dist/editors/TextEditor.d.ts +23 -26
  240. package/views/dist/editors/TextEditor.js +11 -48
  241. package/views/dist/editors/ValueListEditor.d.ts +14 -23
  242. package/views/dist/editors/ValueListEditor.js +16 -202
  243. package/views/dist/editors/body-panel.d.ts +13 -7
  244. package/views/dist/editors/body-panel.js +3 -7
  245. package/views/dist/editors/edit-cores.d.ts +15 -15
  246. package/views/dist/editors/edit-cores.js +14 -14
  247. package/views/dist/editors/number-body.d.ts +1 -1
  248. package/views/dist/editors/number-step.d.ts +0 -34
  249. package/views/dist/editors/number-step.js +0 -37
  250. package/views/dist/editors/option-add-flow.d.ts +1 -13
  251. package/views/dist/editors/option-add-flow.js +0 -22
  252. package/views/dist/editors/relation-links-body.d.ts +2 -3
  253. package/views/dist/editors/relation-picker.d.ts +13 -3
  254. package/views/dist/editors/relation-source.d.ts +0 -22
  255. package/views/dist/editors/relation-source.js +0 -21
  256. package/views/dist/field-row/FieldRow.js +5 -6
  257. package/views/dist/field-row/FieldRowLane.js +0 -1
  258. package/views/dist/field-row/editors/RowChipsEditor.js +2 -2
  259. package/views/dist/field-row/editors/RowDateEditor.d.ts +2 -2
  260. package/views/dist/field-row/editors/RowDateEditor.js +2 -2
  261. package/views/dist/field-row/editors/RowNameEditor.d.ts +2 -5
  262. package/views/dist/field-row/editors/RowNameEditor.js +7 -12
  263. package/views/dist/field-row/editors/RowNumberEditor.d.ts +1 -1
  264. package/views/dist/field-row/editors/RowNumberEditor.js +4 -4
  265. package/views/dist/field-row/editors/RowPlaceEditor.js +3 -3
  266. package/views/dist/field-row/editors/RowRangeEditor.d.ts +2 -5
  267. package/views/dist/field-row/editors/RowRangeEditor.js +7 -14
  268. package/views/dist/field-row/editors/RowRelationEditor.js +3 -3
  269. package/views/dist/field-row/editors/RowSelectEditor.js +2 -2
  270. package/views/dist/field-row/editors/RowTextEditor.d.ts +1 -1
  271. package/views/dist/field-row/editors/RowTextEditor.js +3 -4
  272. package/views/dist/field-row/editors/RowValueListEditor.js +5 -5
  273. package/views/dist/field-row/field-row-button.d.ts +6 -9
  274. package/views/dist/field-row/field-row-button.js +1 -6
  275. package/views/dist/field-row/field-row-checkbox.d.ts +1 -1
  276. package/views/dist/field-row/row-target.d.ts +0 -7
  277. package/views/dist/field-row/row-target.js +0 -2
  278. package/views/dist/grid/chrome/GridAddColumn.d.ts +2 -1
  279. package/views/dist/grid/chrome/GridAddColumn.js +8 -66
  280. package/views/dist/grid/chrome/GridAggregateMenu.d.ts +5 -7
  281. package/views/dist/grid/chrome/GridAggregateMenu.js +20 -39
  282. package/views/dist/grid/chrome/GridCellEditors.d.ts +2 -2
  283. package/views/dist/grid/chrome/GridCellEditors.js +12 -12
  284. package/views/dist/grid/chrome/GridChipsEditor.js +3 -3
  285. package/views/dist/grid/chrome/GridColumnMenu.d.ts +11 -12
  286. package/views/dist/grid/chrome/GridColumnMenu.js +32 -93
  287. package/views/dist/grid/chrome/GridDateEditor.d.ts +6 -6
  288. package/views/dist/grid/chrome/GridDateEditor.js +3 -3
  289. package/views/dist/grid/chrome/GridGroupMenu.d.ts +4 -6
  290. package/views/dist/grid/chrome/GridGroupMenu.js +21 -62
  291. package/views/dist/grid/chrome/GridHeader.d.ts +1 -2
  292. package/views/dist/grid/chrome/GridHeader.js +3 -2
  293. package/views/dist/grid/chrome/GridLongTextEditor.d.ts +17 -38
  294. package/views/dist/grid/chrome/GridLongTextEditor.js +6 -7
  295. package/views/dist/grid/chrome/GridNameEditor.js +4 -4
  296. package/views/dist/grid/chrome/GridNumberEditor.d.ts +4 -5
  297. package/views/dist/grid/chrome/GridNumberEditor.js +5 -6
  298. package/views/dist/grid/chrome/GridPlaceEditor.d.ts +2 -5
  299. package/views/dist/grid/chrome/GridPlaceEditor.js +5 -5
  300. package/views/dist/grid/chrome/GridRangeEditor.d.ts +6 -12
  301. package/views/dist/grid/chrome/GridRangeEditor.js +7 -15
  302. package/views/dist/grid/chrome/GridRelationEditor.js +5 -5
  303. package/views/dist/grid/chrome/GridRow.js +0 -3
  304. package/views/dist/grid/chrome/GridRowActions.d.ts +1 -1
  305. package/views/dist/grid/chrome/GridRowActions.js +0 -5
  306. package/views/dist/grid/chrome/GridRowCells.js +11 -7
  307. package/views/dist/grid/chrome/GridSelectEditor.js +3 -3
  308. package/views/dist/grid/chrome/GridStructure.js +0 -1
  309. package/views/dist/grid/chrome/GridTable.js +1 -1
  310. package/views/dist/grid/chrome/GridTextEditor.d.ts +5 -7
  311. package/views/dist/grid/chrome/GridTextEditor.js +5 -18
  312. package/views/dist/grid/chrome/GridValueListEditor.js +4 -4
  313. package/views/dist/grid/chrome/grid-body-place.d.ts +2 -3
  314. package/views/dist/grid/chrome/grid-body-place.js +4 -8
  315. package/views/dist/grid/chrome/grid-button.d.ts +7 -10
  316. package/views/dist/grid/chrome/grid-button.js +1 -6
  317. package/views/dist/grid/chrome/grid-cell-classes.js +1 -1
  318. package/views/dist/grid/chrome/grid-column-menu-items.d.ts +4 -4
  319. package/views/dist/grid/chrome/grid-column-menu-items.js +10 -6
  320. package/views/dist/grid/chrome/grid-editor-layer.d.ts +5 -1
  321. package/views/dist/grid/chrome/grid-editor-layer.js +1 -0
  322. package/views/dist/grid/chrome/grid-fitted-box.d.ts +7 -1
  323. package/views/dist/grid/chrome/grid-fitted-box.js +4 -4
  324. package/views/dist/grid/chrome/grid-group-menu-parts.d.ts +5 -9
  325. package/views/dist/grid/chrome/grid-group-menu-parts.js +1 -3
  326. package/views/dist/grid/chrome/grid-hover.js +0 -1
  327. package/views/dist/grid/chrome/grid-menu-focus.d.ts +7 -31
  328. package/views/dist/grid/chrome/grid-menu-focus.js +7 -47
  329. package/views/dist/grid/chrome/grid-styles.d.ts +0 -3
  330. package/views/dist/grid/chrome/grid-styles.js +0 -1
  331. package/views/dist/grid/chrome/grid-table-props.d.ts +6 -10
  332. package/views/dist/grid/chrome/useGridTableInteractionModel.js +2 -4
  333. package/views/dist/grid/core/clipboard-model.js +9 -4
  334. package/views/dist/grid/core/editing-controller.d.ts +2 -1
  335. package/views/dist/grid/core/editing-controller.js +10 -2
  336. package/views/dist/grid/core/refusal-sentence.d.ts +3 -0
  337. package/views/dist/grid/core/refusal-sentence.js +2 -2
  338. package/views/dist/grid/core/write-states.d.ts +3 -1
  339. package/views/dist/grid/core/write-states.js +6 -2
  340. package/views/dist/grid/grid.css +240 -0
  341. package/views/dist/grid/looks.d.ts +5 -1
  342. package/views/dist/grid/looks.js +20 -12
  343. package/views/dist/grid-tokens.d.ts +109 -0
  344. package/views/dist/grid-tokens.js +29 -0
  345. package/views/dist/looks/index.d.ts +5 -0
  346. package/views/dist/looks/index.js +5 -0
  347. package/views/dist/looks/pieces.js +10 -0
  348. package/views/dist/model/body-frame.d.ts +0 -32
  349. package/views/dist/model/body-frame.js +1 -15
  350. package/views/dist/model/column-capabilities.d.ts +2 -0
  351. package/views/dist/model/column-filters.d.ts +2 -1
  352. package/views/dist/model/column-from.js +2 -2
  353. package/views/dist/model/column-inspect.d.ts +5 -5
  354. package/views/dist/model/column-inspect.js +2 -2
  355. package/views/dist/model/relation-filters.d.ts +2 -0
  356. package/views/dist/panels/customize-body.d.ts +1 -10
  357. package/views/dist/panels/customize-body.js +0 -3
  358. package/views/dist/panels/filter/MenuSelect.js +0 -5
  359. package/views/dist/panels/filter/RangeFilterBody.js +0 -1
  360. package/views/dist/panels/filter/details.d.ts +1 -5
  361. package/views/dist/panels/filter/details.js +0 -13
  362. package/views/dist/panels/filter/filter-list.d.ts +0 -1
  363. package/views/dist/panels/filter/filter-list.js +1 -1
  364. package/views/dist/panels/index.d.ts +2 -2
  365. package/views/dist/panels/index.js +2 -2
  366. package/views/dist/panels/labels.d.ts +4 -0
  367. package/views/dist/panels/labels.js +8 -0
  368. package/views/dist/panels/model.d.ts +10 -2
  369. package/views/dist/panels/panel-button.d.ts +10 -12
  370. package/views/dist/panels/panel-button.js +1 -6
  371. package/views/dist/panels/quick/model.d.ts +4 -0
  372. package/views/dist/panels/react/chrome.d.ts +0 -17
  373. package/views/dist/panels/react/chrome.js +0 -8
  374. package/views/dist/panels/react/customize-body.d.ts +14 -12
  375. package/views/dist/panels/react/customize-body.js +93 -19
  376. package/views/dist/panels/react/customize.d.ts +16 -12
  377. package/views/dist/panels/react/customize.js +4 -110
  378. package/views/dist/panels/react/filter/FilterEditor.d.ts +4 -18
  379. package/views/dist/panels/react/filter/FilterEditor.js +6 -330
  380. package/views/dist/panels/react/filter/FilterFieldList.d.ts +1 -1
  381. package/views/dist/panels/react/filter/FilterFieldList.js +27 -51
  382. package/views/dist/panels/react/filter/PhoneFilterEditor.d.ts +1 -11
  383. package/views/dist/panels/react/filter/PhoneFilterEditor.js +8 -144
  384. package/views/dist/panels/react/filter/editor-ctx.d.ts +1 -33
  385. package/views/dist/panels/react/filter/editor-ctx.js +5 -33
  386. package/views/dist/panels/react/filter/filter-body.js +5 -2
  387. package/views/dist/panels/react/filter/filter-part-body.d.ts +3 -6
  388. package/views/dist/panels/react/filter/filter-part-body.js +0 -5
  389. package/views/dist/panels/react/filter/rule-writes.d.ts +1 -26
  390. package/views/dist/panels/react/filter/rule-writes.js +4 -95
  391. package/views/dist/panels/react/order-details.d.ts +1 -26
  392. package/views/dist/panels/react/order-details.js +3 -69
  393. package/views/dist/panels/react/panel-header.js +0 -1
  394. package/views/dist/panels/react/panel-step.d.ts +3 -0
  395. package/views/dist/panels/react/panel-step.js +2 -1
  396. package/views/dist/panels/react/popover.d.ts +4 -7
  397. package/views/dist/panels/react/quick/QuickFiltersPanel.d.ts +2 -4
  398. package/views/dist/panels/react/quick/QuickFiltersPanel.js +16 -136
  399. package/views/dist/panels/react/sort/SortEditor.d.ts +4 -4
  400. package/views/dist/panels/react/sort/SortEditor.js +8 -245
  401. package/views/dist/panels/react/sort/SortFieldList.d.ts +1 -1
  402. package/views/dist/panels/react/sort/SortFieldList.js +11 -25
  403. package/views/dist/panels/react/toolbar/ReadyToolbar.d.ts +13 -3
  404. package/views/dist/panels/react/toolbar/ReadyToolbar.js +10 -3
  405. package/views/dist/panels/react/toolbar/Toolbar.js +1 -1
  406. package/views/dist/panels/react/toolbar/ToolbarAdvancedFilters.js +2 -2
  407. package/views/dist/panels/react/toolbar/ToolbarAsideFilter.js +2 -2
  408. package/views/dist/panels/react/toolbar/ToolbarBarFilter.js +16 -18
  409. package/views/dist/panels/react/toolbar/ToolbarFilterAdd.js +2 -1
  410. package/views/dist/panels/react/toolbar/ToolbarFilters.js +3 -3
  411. package/views/dist/panels/react/toolbar/ToolbarOptions.d.ts +12 -4
  412. package/views/dist/panels/react/toolbar/ToolbarOptions.js +6 -2
  413. package/views/dist/panels/react/toolbar/ToolbarQuickFilters.js +1 -1
  414. package/views/dist/panels/react/toolbar/ToolbarSave.js +0 -4
  415. package/views/dist/panels/react/toolbar/ToolbarSearch.js +0 -1
  416. package/views/dist/panels/react/toolbar/ToolbarSortPill.js +3 -3
  417. package/views/dist/panels/react/view-actions.js +0 -1
  418. package/views/dist/panels/react/views-row/FoldingViewRow.js +2 -5
  419. package/views/dist/panels/react/views-row/ViewCreatePill.js +0 -1
  420. package/views/dist/panels/react/views-row/ViewPicker.js +30 -45
  421. package/views/dist/panels/react/views-row/ViewPickerRow.js +0 -2
  422. package/views/dist/panels/react/views-row/menu-classes.d.ts +0 -4
  423. package/views/dist/panels/react/views-row/menu-classes.js +0 -2
  424. package/views/dist/panels/react.d.ts +5 -12
  425. package/views/dist/panels/react.js +5 -12
  426. package/views/dist/panels/settings/filter-groups.d.ts +3 -0
  427. package/views/dist/panels/settings/filter-groups.js +40 -9
  428. package/views/dist/panels/settings/filters.d.ts +5 -0
  429. package/views/dist/panels/settings/filters.js +12 -6
  430. package/views/dist/panels/views-row/model.d.ts +10 -1
  431. package/views/dist/provider/ViewsProvider.d.ts +2 -46
  432. package/views/dist/provider/ViewsProvider.js +31 -27
  433. package/views/dist/provider/components.d.ts +295 -107
  434. package/views/dist/provider/context.d.ts +7 -21
  435. package/views/dist/provider/missing-slot.d.ts +3 -7
  436. package/views/dist/provider/missing-slot.js +2 -9
  437. package/views/dist/provider/ports.d.ts +18 -6
  438. package/views/dist/provider/ports.js +2 -1
  439. package/views/dist/react.d.ts +2 -3
  440. package/views/dist/react.js +1 -1
  441. package/views/dist/selection/SelectionBar.d.ts +2 -16
  442. package/views/dist/selection/SelectionBar.js +6 -4
  443. package/views/dist/selection/bar-props.d.ts +26 -0
  444. package/views/dist/selection/bar-props.js +1 -0
  445. package/views/dist/selection/index.d.ts +1 -1
  446. package/views/dist/selection/verbs.d.ts +32 -5
  447. package/views/dist/styles.css +694 -191
  448. package/views/dist/styles.unlayered.css +691 -188
  449. package/views/docs/contract.md +133 -130
  450. package/views/docs/controls/bulk-bar.md +41 -0
  451. package/views/docs/controls/choice.md +25 -0
  452. package/views/docs/controls/customize.md +17 -0
  453. package/views/docs/controls/popover.md +2 -0
  454. package/views/docs/controls/press.md +9 -0
  455. package/views/docs/controls/quick-filters.md +35 -0
  456. package/views/docs/controls/radio.md +1 -1
  457. package/views/docs/controls/switch-row.md +18 -0
  458. package/views/docs/controls/tag-field.md +7 -0
  459. package/views/docs/controls/toolbar-button.md +31 -0
  460. package/views/docs/controls/toolbar.md +14 -0
  461. package/views/docs/getting-started.md +222 -2
  462. package/views/docs/guides/atoms.md +2 -2
  463. package/views/docs/guides/cells.md +224 -4
  464. package/views/docs/guides/display.md +3 -3
  465. package/views/docs/guides/editors.md +235 -20
  466. package/views/docs/guides/looks.md +8 -2
  467. package/views/docs/guides/ports.md +7 -7
  468. package/views/docs/guides/selection.md +5 -1
  469. package/views/docs/guides/the-grid.md +15 -17
  470. package/views/docs/guides/the-provider.md +9 -15
  471. package/views/docs/install.md +4 -1
  472. package/views/docs/reference/cells.md +2 -2
  473. package/views/docs/reference/controls.md +215 -21
  474. package/views/docs/reference/display.md +1 -0
  475. package/views/docs/reference/editors-chips.md +2 -2
  476. package/views/docs/reference/editors-date.md +4 -4
  477. package/views/docs/reference/editors-location.md +4 -7
  478. package/views/docs/reference/editors-name.md +3 -5
  479. package/views/docs/reference/editors-number.md +10 -10
  480. package/views/docs/reference/editors-panel.md +3 -3
  481. package/views/docs/reference/editors-range.md +3 -5
  482. package/views/docs/reference/editors-relation.md +4 -4
  483. package/views/docs/reference/editors-select.md +3 -3
  484. package/views/docs/reference/editors-text.md +3 -4
  485. package/views/docs/reference/editors-value-list.md +3 -3
  486. package/views/docs/reference/field-row.md +1 -1
  487. package/views/docs/reference/grid.md +2 -2
  488. package/views/docs/reference/looks.md +25 -11
  489. package/views/docs/reference/panels-react.md +23 -37
  490. package/views/docs/reference/panels.md +8 -6
  491. package/views/docs/reference/react.md +24 -24
  492. package/views/docs/reference/selection.md +4 -2
  493. package/views/docs/reference/views.md +12 -11
  494. package/views/skills/views/SKILL.md +2 -2
  495. package/views/dist/editors/relation-panel.d.ts +0 -69
  496. package/views/dist/editors/relation-panel.js +0 -46
  497. package/views/dist/grid/chrome/GridColumnColorSection.d.ts +0 -13
  498. package/views/dist/grid/chrome/GridColumnColorSection.js +0 -40
  499. package/views/dist/grid/chrome/GridColumnDateSection.d.ts +0 -28
  500. package/views/dist/grid/chrome/GridColumnDateSection.js +0 -23
  501. package/views/dist/grid/chrome/GridColumnDurationSection.d.ts +0 -23
  502. package/views/dist/grid/chrome/GridColumnDurationSection.js +0 -24
  503. package/views/dist/grid/chrome/GridColumnNumberSection.d.ts +0 -29
  504. package/views/dist/grid/chrome/GridColumnNumberSection.js +0 -27
  505. package/views/dist/grid/chrome/GridColumnPercentSection.d.ts +0 -16
  506. package/views/dist/grid/chrome/GridColumnPercentSection.js +0 -16
  507. package/views/dist/grid/chrome/GridColumnSortSection.d.ts +0 -38
  508. package/views/dist/grid/chrome/GridColumnSortSection.js +0 -33
  509. package/views/dist/grid/chrome/GridFlyout.d.ts +0 -44
  510. package/views/dist/grid/chrome/GridFlyout.js +0 -80
  511. package/views/dist/grid/chrome/GridMenuRow.d.ts +0 -15
  512. package/views/dist/grid/chrome/GridMenuRow.js +0 -15
  513. package/views/dist/grid/chrome/grid-menu-search.d.ts +0 -7
  514. package/views/dist/grid/chrome/grid-menu-search.js +0 -7
  515. package/views/dist/panels/react/GroupBucketsList.d.ts +0 -16
  516. package/views/dist/panels/react/GroupBucketsList.js +0 -44
  517. package/views/dist/panels/react/LayoutColumnsList.d.ts +0 -24
  518. package/views/dist/panels/react/LayoutColumnsList.js +0 -101
  519. package/views/dist/panels/react/PopoverColumnDetail.d.ts +0 -11
  520. package/views/dist/panels/react/PopoverColumnDetail.js +0 -24
  521. package/views/dist/panels/react/drag.d.ts +0 -2
  522. package/views/dist/panels/react/drag.js +0 -5
  523. package/views/dist/panels/react/layout-detail.d.ts +0 -4
  524. package/views/dist/panels/react/layout-detail.js +0 -29
  525. package/views/dist/panels/react/root-list.d.ts +0 -6
  526. package/views/dist/panels/react/root-list.js +0 -31
  527. package/views/dist/panels/react/sort/use-sort-drag.d.ts +0 -17
  528. package/views/dist/panels/react/sort/use-sort-drag.js +0 -39
  529. package/views/dist/panels/react/view-footer.d.ts +0 -20
  530. package/views/dist/panels/react/view-footer.js +0 -41
@@ -3,6 +3,8 @@ import type { FieldType } from "viewkitjs/fields";
3
3
  import type { CategoryColor } from "viewkitjs/fields/design/category-colors";
4
4
  import type { StatusSlot } from "viewkitjs/fields/design/status-slots";
5
5
  import type { BucketOrderMode, FILTER_OPERATORS, FilterGroup, FilterRelationRule, FilterRule, SetAsideReason, SortDirection } from "viewkitjs/fields/query";
6
+ import type { ViewsConfirmPort, ViewsToastPort } from "./ports.js";
7
+ import type { SelectionBarProps } from "../selection/bar-props.js";
6
8
  /** Where a floating part attaches: an element, a ref to one, or a point (a context menu). */
7
9
  export type ViewsAnchor = HTMLElement | RefObject<HTMLElement | null> | {
8
10
  x: number;
@@ -20,8 +22,7 @@ export type ViewsButtonProps = {
20
22
  children?: ReactNode;
21
23
  onClick?: (event: React.MouseEvent<HTMLButtonElement>) => void;
22
24
  disabled?: boolean;
23
- /** `secondary` is handed only to the views picker's chip when the provider's `panelButtons` is `button`: a filled
24
- * chip with no border. */
25
+ /** `secondary` is handed only to the views picker's chip: a filled chip with no border. */
25
26
  variant?: "default" | "secondary" | "ghost" | "outline" | "destructive";
26
27
  size?: "default" | "sm" | "icon";
27
28
  type?: "button" | "submit";
@@ -43,18 +44,15 @@ export type ViewsButtonProps = {
43
44
  "aria-disabled"?: boolean;
44
45
  /** The ids of what describes it: why it can't be used, on a button with a reason. Forward it to your element. */
45
46
  "aria-describedby"?: string;
46
- /** A toggle's state: the Columns list's new-line mark, and the quick filters' open field, when the provider's
47
- * `panelButtons` is `button`. */
47
+ /** A toggle's state: the Columns list's new-line mark, and the quick filters' open field. */
48
48
  "aria-pressed"?: boolean;
49
- /** `option` on a view's row in the picker when `panelButtons` is `button`. */
49
+ /** `option` on a view's row in the picker. */
50
50
  role?: "option";
51
51
  /** Whether that row is the current view, with `role` `option`. */
52
52
  "aria-selected"?: boolean;
53
- /** `open` while the list a views-row chip or a view's ⋯ opens is open, `closed` otherwise, when `panelButtons` is
54
- * `button`. */
53
+ /** `open` while the list a views-row chip or a view's ⋯ opens is open, `closed` otherwise. */
55
54
  "data-state"?: "open" | "closed";
56
- /** An actions row a host insets through `[data-vs-row]`: the Options panel's Export when `panelButtons` is
57
- * `button`. Forward it to your element. */
55
+ /** An actions row a host insets through `[data-vs-row]`: the Options panel's Export. Forward it to your element. */
58
56
  "data-vs-row"?: boolean;
59
57
  };
60
58
  export type ViewsPopoverProps = {
@@ -116,9 +114,8 @@ export type ViewsCheckboxProps = {
116
114
  * whose partial state is a live selection. */
117
115
  partialTone?: "muted" | "brand";
118
116
  disabled?: boolean;
119
- /** Shown as it is and not pressable, unlike `disabled`, which greys it: a yes/no cell the grid can't write while
120
- * the provider's `gridCheckboxes` is `checkbox`, or a field row's yes/no it can't write while `fieldRowCheckboxes` is
121
- * `checkbox`. Forward it to your control; absent means false. */
117
+ /** Shown as it is and not pressable, unlike `disabled`, which greys it: a yes/no cell the grid can't write, or a
118
+ * field row's yes/no it can't write. Forward it to your control; absent means false. */
122
119
  readOnly?: boolean;
123
120
  className?: string;
124
121
  tabIndex?: number;
@@ -603,6 +600,10 @@ export type ViewsTextBodyProps = {
603
600
  autoFocus: boolean;
604
601
  /** `phone`: it stands in a sheet; draw no ✕, ✓ or Cancel of your own (the sheet holds them). */
605
602
  form: "computer" | "phone";
603
+ /** Where it stands on a computer: `cell`, a grid cell, whose box it fills and may grow past over the rows below; `row`,
604
+ * a record's field row, in the row's flow, so the row grows with it and nothing that clips the row cuts it. ViewKit's
605
+ * editors always hand it; absent (a page drawing the body alone), `cell`. */
606
+ place?: "cell" | "row";
606
607
  /** In the phone's sheet: tell it you stand on a step of your own (a list of countries, a label's list), and hand
607
608
  * `null` once you are back. The sheet's head shows the step's title, Back in ✕'s place and ✓; Escape calls `onBack`;
608
609
  * a swipe still closes the whole editor, as ✕ does. Absent on a computer. */
@@ -762,6 +763,8 @@ export type ViewsQuickFiltersBodyProps = {
762
763
  key: string;
763
764
  label: string;
764
765
  searchPlaceholder?: string;
766
+ /** Its options as the app hands them (`QuickFilterField`'s): each value's mark is its option's. */
767
+ options?: readonly ViewsPickerItem[];
765
768
  /** Each value: its key as the hold keeps it (an option, an id, "true" or "false", "" for none), its words, how
766
769
  * many rows a press on it shows (absent when the app counts none or counts are hidden), and whether it is held. */
767
770
  values: readonly {
@@ -805,10 +808,14 @@ export type ViewsFilterBodyField = {
805
808
  type: keyof typeof FILTER_OPERATORS;
806
809
  /** A relation's far fields, one level in: a rule on one is a relation rule (any, none or every where …). */
807
810
  far?: readonly ViewsFilterBodyField[];
808
- /** A choice field's values (a status's, a select's, a person's, a record's), each as the Picker draws it, where ViewKit holds
811
+ /** A choice field's values (a status's, a select's, a person's, a record's), or a place's country's names (its `countryCode`
812
+ * part, VK-735), each as the Picker draws it, where ViewKit holds
809
813
  * them as the list opens: your body may list them in the rule's value box. Absent where its values are read on demand, or the
810
814
  * field is no choice: open `ruleValue` there. */
811
815
  options?: readonly ViewsPickerItem[];
816
+ /** Why no rule can be made on it, in words (a column the list can't filter); absent, it can. Draw it greyed, in its place,
817
+ * and never write a rule on it, nor put back a set-aside rule on it: ViewKit refuses a level that holds one. */
818
+ disabled?: string;
812
819
  };
813
820
  /** The filter editor's body, which your app draws (`FilterBody`): what an advanced filter's pill opens on a computer and
814
821
  * Filter opens in the phone's Sheet, in place of ViewKit's own. A panel's body, as every panel's: handed the level it is
@@ -818,7 +825,8 @@ export type ViewsFilterBodyProps = {
818
825
  /** The filter's name ("Advanced filter" on a computer, "Filter" on a phone): a phone's title, and the rules' name to a
819
826
  * screen reader. */
820
827
  label: string;
821
- /** The fields a rule may name, in the person's order, then each relation with its far fields one level in. */
828
+ /** The fields a rule may name, in the person's order, each column the list can't filter among them in its place (its
829
+ * `disabled` saying why: draw it greyed, never name it), then each relation with its far fields one level in. */
822
830
  fields: readonly ViewsFilterBodyField[];
823
831
  /** The level it is open on, its items joined by its `op`: on a computer the advanced filter's own group (`and`, `or`,
824
832
  * or `not` for one that excludes its matches; a top joined by Or as one group of its own), on a phone the whole
@@ -909,9 +917,8 @@ export type ViewsFieldsBodyProps = {
909
917
  /** Done with no pick: what holds the list closes (on a phone, the sheet's body turns back). */
910
918
  onDone: () => void;
911
919
  };
912
- /** A filter rule's part, which your app draws (`FilterPartBody`): what a rule's way and its value open wherever ViewKit
913
- * draws them itself (a filter on the bar, a rule in ViewKit's own filter editor on a computer and on a phone), in place
914
- * of ViewKit's ways menu and value body. Handed the rule as data, it hands back the rule changed; ViewKit checks it,
920
+ /** A filter rule's part, which your app draws (`FilterPartBody`; `CONTROLS.FilterPartBody` is ViewKit's own): what a
921
+ * filter's way and its value on the bar open. Handed the rule as data, it hands back the rule changed; ViewKit checks it,
915
922
  * keeps a rule held until whole, and writes it. Never opened inside `FilterBody`'s `ruleValue`. */
916
923
  export type ViewsFilterPartBodyProps = {
917
924
  /** Which part opened it: `way`, how the rule compares; `value`, what it compares with. */
@@ -980,6 +987,93 @@ export type ViewsViewsListItem = {
980
987
  /** The view's own verbs (Rename, Duplicate, Delete…), as your app gave them: ViewKit's own list offers them on the
981
988
  * view in use. */
982
989
  menu?: ViewsMenuItem[];
990
+ /** Its layout, by `ViewsViewVerbs.layouts`' id. */
991
+ layout?: string;
992
+ /** It holds changes not saved. */
993
+ changed?: boolean;
994
+ /** One of the reader's favorites. */
995
+ favorite?: boolean;
996
+ };
997
+ /** A view as a restore hands it back. */
998
+ export type ViewsViewRecord = {
999
+ id: string;
1000
+ name: string;
1001
+ layout: string;
1002
+ private?: boolean;
1003
+ favorite?: boolean;
1004
+ changed?: boolean;
1005
+ count?: number;
1006
+ };
1007
+ /** A change a view's menu makes, as the axis's `verbs.onChange` takes it: the views list's own `ViewsListChange` but `open` and
1008
+ * `order`, which go to the axis's `onChange` and `onReorder`. Written out here, since the provider reaches nothing in the controls. */
1009
+ export type ViewsViewChange = {
1010
+ kind: "rename";
1011
+ id: string;
1012
+ name: string;
1013
+ } | {
1014
+ kind: "create";
1015
+ layout: string;
1016
+ name: string;
1017
+ columns?: string;
1018
+ from?: string;
1019
+ } | {
1020
+ kind: "duplicate";
1021
+ id: string;
1022
+ } | {
1023
+ kind: "delete";
1024
+ id: string;
1025
+ } | {
1026
+ kind: "restore";
1027
+ view: ViewsViewRecord;
1028
+ at: number;
1029
+ open: boolean;
1030
+ } | {
1031
+ kind: "save";
1032
+ id: string;
1033
+ } | {
1034
+ kind: "reset";
1035
+ id: string;
1036
+ } | {
1037
+ kind: "edit";
1038
+ id: string;
1039
+ } | {
1040
+ kind: "link";
1041
+ id: string;
1042
+ } | {
1043
+ kind: "favorite";
1044
+ id: string;
1045
+ on: boolean;
1046
+ } | {
1047
+ kind: "private";
1048
+ id: string;
1049
+ on: boolean;
1050
+ };
1051
+ /** A layout a new view can take: its glyph by your own icon's name (AppIcon), its name, its one line; `columns` where it asks
1052
+ * which field makes its columns (a board). */
1053
+ export type ViewsViewLayout = {
1054
+ id: string;
1055
+ name: string;
1056
+ icon: string;
1057
+ line: string;
1058
+ columns?: boolean;
1059
+ };
1060
+ /** A view's verbs, handed where your app lets ViewKit draw a view's menu (CONTROLS: Rename, New view, the delete question, Undo). */
1061
+ export type ViewsViewVerbs = {
1062
+ layouts: readonly ViewsViewLayout[];
1063
+ /** What the list holds, in the delete question's line ("deals"). */
1064
+ records: string;
1065
+ /** The fields a board's columns can follow, and the one filled in. */
1066
+ columns?: {
1067
+ fields: readonly {
1068
+ value: string;
1069
+ label: string;
1070
+ }[];
1071
+ value: string;
1072
+ };
1073
+ /** Each change a view's menu makes. ViewKit moves no view itself: open the right one here (the first listed when the open one
1074
+ * is deleted, the view again on a restore with `open`, the new one on a create or a duplicate, whose ids your app makes).
1075
+ * `viewsAfter` (viewkitjs/views/controls) does all of it over your views. */
1076
+ onChange: (change: ViewsViewChange) => void;
983
1077
  };
984
1078
  /** The views list's body, which your app draws (`ViewsListBody`): what the view picker's chip opens on a computer and in
985
1079
  * the phone's Sheet, in place of ViewKit's own list. A panel's body, as every panel's: handed the axis's views as data,
@@ -1007,8 +1101,17 @@ export type ViewsViewsListBodyProps = {
1007
1101
  /** The job is done and what holds it closes. */
1008
1102
  onDone: () => void;
1009
1103
  /** On a phone where the sheet's head doesn't draw it (`sheetActions: "bar"`): its ✕, closing the list, for your
1010
- * body's own head. Absent on a computer, and under `head`, where the sheet holds it. */
1104
+ * body's own head, and Back while the body stands on a step (`onStepChange`). Absent on a computer, and under `head`,
1105
+ * where the sheet holds them. */
1011
1106
  actions?: ViewsSheetActions;
1107
+ /** Handed where the axis hands `verbs`: draw a view's whole menu from them (CONTROLS does), not only `menu`. */
1108
+ verbs?: ViewsViewVerbs;
1109
+ /** On a phone, the body stands on a step of its own (a view's menu, Rename…): its title and Back go to the sheet's head, and
1110
+ * the sheet's Escape goes back a step. Absent on a computer. */
1111
+ onStepChange?: (step: ViewsBodyStep | null) => void;
1112
+ /** While true, a press outside the list and Escape close nothing: the body asks a question outside it (your `confirm` port's
1113
+ * dialog, which stands outside the list's popover), and the list stays when it is answered. On a computer. */
1114
+ onHold?: (holding: boolean) => void;
1012
1115
  };
1013
1116
  /** A field a list can be grouped by, as the group body is handed it (`ViewsGroupBodyProps.dimensions`): the panels'
1014
1117
  * `GroupDimension` (`viewkitjs/views/panels`), written out here, since the provider reaches nothing inside the panels. */
@@ -1189,8 +1292,87 @@ export type ViewsCustomizeColumns = {
1189
1292
  /** Your field editor's rows under the columns (Add field, the archived fields). */
1190
1293
  footer?: ReactNode;
1191
1294
  };
1295
+ /** A list's per-field filter, its time range or a date range, as a Customize body is handed it: its row's words, what it
1296
+ * holds and its screen's content, exactly one of `pick`, `check`, `time`, `dates` and `body`. Each is written through its
1297
+ * own change. */
1298
+ export type ViewsCustomizeField = {
1299
+ key: string;
1300
+ label: string;
1301
+ icon?: ReactNode;
1302
+ /** The heading its row stands under (a filter's section). */
1303
+ section?: string;
1304
+ /** What it holds, in words ("All", "2 selected", "Last 30 days"). */
1305
+ says: string;
1306
+ inForce: boolean;
1307
+ /** Why it can't be opened: its row says so and opens nothing. */
1308
+ disabled?: string;
1309
+ /** Where its row stands: with the filters (after Columns), or after Group (a time range, a date range). */
1310
+ place: "filters" | "after";
1311
+ /** Asked once each time its screen opens (a field's values loading). */
1312
+ onOpen?: () => void;
1313
+ /** One value picked from a few (its All choice first, where the list has one); an option's `mark` stands before its name. */
1314
+ pick?: {
1315
+ value: string;
1316
+ options: readonly {
1317
+ value: string;
1318
+ label: string;
1319
+ mark?: ReactNode;
1320
+ }[];
1321
+ onChange: (value: string) => void;
1322
+ };
1323
+ /** Several values checked. */
1324
+ check?: {
1325
+ value: readonly string[];
1326
+ options: readonly {
1327
+ value: string;
1328
+ label: string;
1329
+ mark?: ReactNode;
1330
+ }[];
1331
+ onChange: (value: readonly string[]) => void;
1332
+ };
1333
+ /** A time range: its presets, and Custom, a range picked on a calendar, where the list offers it. Days are ISO days. */
1334
+ time?: {
1335
+ value: string;
1336
+ options: readonly {
1337
+ value: string;
1338
+ label: string;
1339
+ }[];
1340
+ onChange: (value: string) => void;
1341
+ custom?: {
1342
+ label: string;
1343
+ /** The custom range in words, while it is the one in force. */
1344
+ says?: string;
1345
+ on: boolean;
1346
+ from: string | null;
1347
+ to: string | null;
1348
+ /** A day pressed on its calendar: the range the calendar makes of it, and the day itself. */
1349
+ onPress: (next: {
1350
+ from: string | null;
1351
+ to: string | null;
1352
+ }, day: string | null) => void;
1353
+ };
1354
+ };
1355
+ /** A date range picked on a calendar. Days are ISO days. */
1356
+ dates?: {
1357
+ from: string | null;
1358
+ to: string | null;
1359
+ onChange: (next: {
1360
+ from: string | null;
1361
+ to: string | null;
1362
+ }) => void;
1363
+ };
1364
+ /** Any other kind of filter (text, a number, a date, a relation, or a select that draws its options its own way): ViewKit's
1365
+ * own body for its value. */
1366
+ body?: ReactNode;
1367
+ };
1368
+ /** A list's per-field filters, its time range and its date ranges, as a Customize body is handed them. */
1369
+ export type ViewsCustomizeFields = {
1370
+ /** Behind one Filter row (a list), or each its own row (a dashboard). */
1371
+ folded: boolean;
1372
+ items: readonly ViewsCustomizeField[];
1373
+ };
1192
1374
  /** Customize's body, which your app draws (`CustomizeBody`): what Options opens on a computer and in the phone's Sheet,
1193
- * in place of ViewKit's own Customize, wherever ViewKit draws Customize. A panel's body, as every panel's, holding
1375
+ * wherever ViewKit draws Customize: ViewKit draws none of its own. A panel's body, as every panel's, holding
1194
1376
  * several values: each section is handed as data and written through its own change, and the sort, filter and group
1195
1377
  * are handed as their own slots' bodies are. The view's name, Copy link and Export are your app's to hand it. */
1196
1378
  export type ViewsCustomizeBodyProps = {
@@ -1201,18 +1383,19 @@ export type ViewsCustomizeBodyProps = {
1201
1383
  onPageChange: (page: ViewsCustomizePage) => void;
1202
1384
  /** The layouts and the layout in use's settings, where the list has layouts. */
1203
1385
  layout?: ViewsCustomizeLayout;
1204
- /** The columns, where ViewKit's own Customize shows them. */
1386
+ /** The columns, where the layout in use has a Columns section (`columnsFor`, else the layout's sub-options). */
1205
1387
  columns?: ViewsCustomizeColumns;
1206
- /** The filter as and/or groups, as `FilterBody` is handed it on a phone: the whole filter, 3 levels deep. Where a list's
1207
- * filter is only per-field values (no filter tree), ViewKit draws its own Customize instead of the body. */
1388
+ /** The filter as and/or groups, as `FilterBody` is handed it on a phone: the whole filter, 3 levels deep. */
1208
1389
  filter?: Omit<ViewsFilterBodyProps, "form" | "onDone" | "actions" | "onStepChange">;
1390
+ /** The per-field filters, the time range and the date ranges, where the list hands them. */
1391
+ fields?: ViewsCustomizeFields;
1209
1392
  /** The sort, as `SortBody` is handed it: a list with one sort as one rule, `max` 1. */
1210
1393
  sort?: Omit<ViewsSortBodyProps, "form" | "onDone" | "actions" | "onStepChange">;
1211
1394
  /** The group, as `GroupBody` is handed it. */
1212
1395
  group?: Omit<ViewsGroupBodyProps, "form" | "onDone" | "actions" | "onStepChange">;
1213
1396
  /** The list's own toggles, Show counts among them (read from the view). */
1214
1397
  toggles: readonly ViewsCustomizeToggle[];
1215
- /** On a shared view: how far the reader has drifted from it, and Reset and Set default for everyone. */
1398
+ /** On a shared view: how far the reader has drifted from it, and Reset and Save for everyone. */
1216
1399
  view?: {
1217
1400
  changes: number;
1218
1401
  /** Everyone's view moved after the reader's changes began. */
@@ -1237,29 +1420,23 @@ export type ViewsCustomizeBodyProps = {
1237
1420
  /** On a phone where the sheet's head doesn't draw it (`sheetActions: "bar"`): its ✕, closing it, for your body's own
1238
1421
  * head. Absent on a computer, and under `head`, where the sheet holds it. */
1239
1422
  actions?: ViewsSheetActions;
1423
+ /** The view's name, as the app hands it through the toolbar (`viewName`): draw it, renamed in place, only with `onRename`. */
1424
+ name?: string;
1425
+ /** Renames the view (the toolbar's `onRenameView`): handed only where the app can rename it. */
1426
+ onRename?: (name: string) => void;
1427
+ /** Copy link to view, where the app hands it. */
1428
+ onCopyLink?: () => void;
1429
+ /** Export CSV, where the app hands it. */
1430
+ onExport?: () => void;
1431
+ /** What Export CSV takes, in words ("12 deals"), shown beside it. */
1432
+ exportCount?: string;
1433
+ /** On a phone: the level of its own your body stands on inside a section (the group editor's Group by), or `null` once
1434
+ * it is back, so the sheet's Escape goes back a level instead of closing. */
1435
+ onStepChange?: (step: ViewsBodyStep | null) => void;
1240
1436
  };
1241
1437
  /** Where the editor panel's ✕ and ✓, and a toolbar panel's ✕, stand on a phone: `bar`, the panel's own inside the
1242
1438
  * Sheet; `head`, handed to the Sheet as `actions` for its own head, with none drawn inside. */
1243
1439
  export type ViewsSheetActionsPlace = "bar" | "head";
1244
- /** How the grid opens its own menus (a column's, a footer's figure picker, a group's ⋯, Add column):
1245
- * `popover`, ViewKit's rows in your `Popover`; `menu`, your `Menu`, handed rows as data. The row menu and
1246
- * a command cell's menu always go through your `Menu`. */
1247
- export type ViewsMenuRoute = "popover" | "menu";
1248
- /** Who draws the buttons the grid draws itself (a group's fold and ⋯, "+ Add column", a row's ⋯, the name's actions,
1249
- * an action column's buttons, a pick-list cell's ▾): `own`, ViewKit's, as on 0.5.0; `button`, your `Button`. */
1250
- export type ViewsGridButtons = "own" | "button";
1251
- /** Who draws a yes/no cell's box in the grid (the checkbox style): `own`, ViewKit's tick box in its own button, as
1252
- * on 0.5.0; `checkbox`, your `Checkbox`, the box your rail draws. */
1253
- export type ViewsGridCheckboxes = "own" | "checkbox";
1254
- /** Who draws a field row's own buttons (its edit target, the verb trigger around a value, the lane's ▾, rich text's
1255
- * Show more): `own`, ViewKit's, as on 0.5.0; `button`, your `Button`. */
1256
- export type ViewsFieldRowButtons = "own" | "button";
1257
- /** Who draws the buttons the toolbar's panels, the search's ✕ and the views row draw themselves: `own`, ViewKit's,
1258
- * as on 0.6.0; `button`, your `Button`. */
1259
- export type ViewsPanelButtons = "own" | "button";
1260
- /** Who draws a field row's yes/no box (the checkbox style): `own`, ViewKit's tick box in its own button, as on 0.5.0;
1261
- * `checkbox`, your `Checkbox`, a Tab stop as the row's own switch is. */
1262
- export type ViewsFieldRowCheckboxes = "own" | "checkbox";
1263
1440
  /** Where the selection bar's fixed box sits on one form. `bottom` is a CSS length (default
1264
1441
  * `calc(1rem + env(safe-area-inset-bottom))`), `zIndex` its layer (default 50), and `className` the app's
1265
1442
  * own classes on the box (a hook its CSS reads, a rule that hides the bar). */
@@ -1275,17 +1452,14 @@ export type ViewsSelectionBarSettings = {
1275
1452
  phoneQuery?: string;
1276
1453
  desktop?: ViewsBarPlacement;
1277
1454
  phone?: ViewsBarPlacement;
1278
- /** Who draws the count chip that clears the selection on the desktop: `own` (the default), ViewKit's, as on 0.5.0;
1279
- * `button`, your `Button`. */
1280
- chip?: ViewsSelectionChip;
1281
1455
  };
1282
- /** Who draws the selection bar's count chip (`selectionBar`'s `chip`): `own`, ViewKit's, as on 0.5.0; `button`, your
1283
- * `Button`, handed `outline`, `sm`, its box in `className`, `data-slot`, `aria-label` and `disabled` while busy. */
1284
- export type ViewsSelectionChip = "own" | "button";
1285
- /** A phone sheet. `snap` is a hint: an app whose sheet has no snap points ignores it. */
1456
+ /** A phone sheet. `snap` is a hint: an app whose sheet has no snap points ignores it. The Sheet pads its body; a body
1457
+ * draws no side inset of its own: stand what it holds in your phone's side padding, as `CONTROLS.Sheet` does. */
1286
1458
  export type ViewsSheetProps = {
1287
1459
  open: boolean;
1288
1460
  onOpenChange: ViewsOpenChange;
1461
+ /** Its title. Absent, with `label` alone handed, what it holds heads itself (a toolbar panel, its own title and ✕ in
1462
+ * its body): draw no title or close of your own over it. */
1289
1463
  title?: ReactNode;
1290
1464
  /** The title in words, whenever the title is words: the sheet's accessible name, and the title of
1291
1465
  * a head that takes only text. Absent for a title that is something else (a header with a glyph). */
@@ -1314,17 +1488,27 @@ export type ViewsRowsWaitProps = {
1314
1488
  pending: boolean;
1315
1489
  children: ReactNode;
1316
1490
  };
1491
+ /** What the components map's `PortsHost` is told: which ports the app left out, and where to hand ViewKit's own once they
1492
+ * stand. */
1493
+ export type ViewsPortsHostProps = {
1494
+ toast: boolean;
1495
+ confirm: boolean;
1496
+ onReady: (ports: {
1497
+ toast?: ViewsToastPort;
1498
+ confirm?: ViewsConfirmPort;
1499
+ }) => void;
1500
+ };
1317
1501
  export type ViewsComponents = {
1318
1502
  Button: ComponentType<ViewsButtonProps>;
1319
1503
  Popover: ComponentType<ViewsPopoverProps>;
1320
1504
  Tooltip: ComponentType<ViewsTooltipProps>;
1321
1505
  Checkbox: ComponentType<ViewsCheckboxProps>;
1322
1506
  Menu: ComponentType<ViewsMenuProps>;
1323
- /** Optional: the editors' lists and the popover route's menus draw through it. An app that hands `Picker`
1324
- * and sets `menus: "menu"` needs none. Reached without one, it throws an error naming it. */
1507
+ /** @deprecated Read by nothing: the grid's menus are your `Menu` and every list an editor opens is your `Picker`.
1508
+ * Leave it out; it goes at a later minor. */
1325
1509
  Command?: ViewsCommandParts;
1326
- /** Optional: the date editor draws its month through it. Handed `DateBody`, it is never reached.
1327
- * Reached without one, it throws an error naming it. */
1510
+ /** Optional: the filter's month draws through it (the date editor opens `DateBody`). Reached without one, it throws
1511
+ * an error naming it. */
1328
1512
  Calendar?: ComponentType<ViewsCalendarProps>;
1329
1513
  Collapse: ComponentType<ViewsCollapseProps>;
1330
1514
  Sheet: ComponentType<ViewsSheetProps>;
@@ -1346,71 +1530,75 @@ export type ViewsComponents = {
1346
1530
  /** Optional: every editor's single-line box draws through it. Left out, the provider draws a
1347
1531
  * plain `<input>`. */
1348
1532
  Input?: ComponentType<ViewsInputProps>;
1349
- /** Optional: a whole pick list your app draws. Handed one, the select, several-values, place and relation
1350
- * editors open it, handed their rows as data; left out, they draw from `Command`. */
1351
- Picker?: ComponentType<ViewsPickerProps>;
1352
- /** Optional: a whole links body your app draws. Handed one, the set editor of a relation holding several records
1353
- * whose field declares `links` opens it, handed each link's roles, the lead and the field's roles; left out, it
1354
- * opens `Picker`, else its own list. */
1355
- LinksBody?: ComponentType<ViewsLinksBodyProps>;
1356
- /** Optional: a whole date body your app draws. Handed one, the date editor opens it; left out, it draws
1357
- * its own line, quick days and time around `Calendar`. */
1358
- DateBody?: ComponentType<ViewsDateBodyProps>;
1359
- /** Optional: a whole body for a field made of parts your app draws. Handed one, the name, place and range
1360
- * editors open it; left out, they draw their own boxes. */
1361
- PartsBody?: ComponentType<ViewsPartsBodyProps>;
1362
- /** Optional: a whole body for a field holding several emails, phones, links or domains, which your app draws. Handed
1363
- * one, the value list editor opens it; left out, it draws its own rows. */
1364
- ValuesBody?: ComponentType<ViewsValuesBodyProps>;
1365
- /** Optional: a whole body for a field typed as one string, which your app draws. Handed one, the text editors open
1366
- * it; left out, they draw their own box. */
1367
- TextBody?: ComponentType<ViewsTextBodyProps>;
1368
- /** Optional: a whole body for a number, money or a percent, which your app draws. Handed one, the number editors open
1369
- * it; left out, they draw their own box. */
1370
- NumberBody?: ComponentType<ViewsNumberBodyProps>;
1371
- /** Optional: the sort editor's whole body, which your app draws. Handed one, the sort pill opens it on a computer and
1372
- * in the phone's Sheet, handed the rules as data; left out, it opens ViewKit's own sort editor. */
1373
- SortBody?: ComponentType<ViewsSortBodyProps>;
1374
- /** Optional: the filter editor's whole body, which your app draws. Handed one, an advanced filter's pill opens it on a
1375
- * computer and Filter opens it in the phone's Sheet, handed the level as data; left out, they open ViewKit's own
1376
- * filter editor. */
1377
- FilterBody?: ComponentType<ViewsFilterBodyProps>;
1378
- /** Optional: the field list's whole body, which your app draws. Handed one, every sort and filter field list ViewKit
1379
- * opens opens it, handed the fields as data; left out, ViewKit draws its own list. */
1380
- FieldsBody?: ComponentType<ViewsFieldsBodyProps>;
1381
- /** Optional: a filter rule's way and value, which your app draws. Handed one, a rule's way and value open it on the
1382
- * bar and in ViewKit's own filter editor, handed the rule as data; left out, they open ViewKit's ways menu and value
1383
- * body. */
1384
- FilterPartBody?: ComponentType<ViewsFilterPartBodyProps>;
1533
+ /** Required: a whole pick list your app draws (`CONTROLS.Picker` is ViewKit's own). The select, several-values,
1534
+ * place and relation editors open it, handed their rows as data. */
1535
+ Picker: ComponentType<ViewsPickerProps>;
1536
+ /** Required: a whole links body your app draws (`CONTROLS.LinksBody` is ViewKit's own). The set editor of a relation
1537
+ * holding several records whose field declares `links` opens it, handed each link's roles, the lead and the field's
1538
+ * roles; a relation with no `links` opens `Picker`. */
1539
+ LinksBody: ComponentType<ViewsLinksBodyProps>;
1540
+ /** Required: a whole date body your app draws (`CONTROLS.DateBody` is ViewKit's own). The date editors open it. */
1541
+ DateBody: ComponentType<ViewsDateBodyProps>;
1542
+ /** Required: a whole body for a field made of parts your app draws (`CONTROLS.PartsBody` is ViewKit's own). The name,
1543
+ * place and range editors open it. */
1544
+ PartsBody: ComponentType<ViewsPartsBodyProps>;
1545
+ /** Required: a whole body for a field holding several emails, phones, links or domains, which your app draws
1546
+ * (`CONTROLS.ValuesBody` is ViewKit's own). The value list editors open it. */
1547
+ ValuesBody: ComponentType<ViewsValuesBodyProps>;
1548
+ /** Required: a whole body for a field typed as one string, which your app draws (`CONTROLS.TextBody` is ViewKit's own).
1549
+ * The text editors open it; a text opened only to be read keeps ViewKit's own panel. */
1550
+ TextBody: ComponentType<ViewsTextBodyProps>;
1551
+ /** Required: a whole body for a number, money or a percent, which your app draws (`CONTROLS.NumberBody` is ViewKit's
1552
+ * own). The number editors open it; a number formatted as a duration keeps ViewKit's own box. */
1553
+ NumberBody: ComponentType<ViewsNumberBodyProps>;
1554
+ /** Required: the sort editor's whole body, which your app draws (`CONTROLS.SortBody` is ViewKit's own). The sort pill
1555
+ * opens it on a computer and in the phone's Sheet, handed the rules as data. */
1556
+ SortBody: ComponentType<ViewsSortBodyProps>;
1557
+ /** Required: the filter editor's whole body, which your app draws (`CONTROLS.FilterBody` is ViewKit's own). An
1558
+ * advanced filter's pill opens it on a computer and Filter opens it in the phone's Sheet, handed the level as data. */
1559
+ FilterBody: ComponentType<ViewsFilterBodyProps>;
1560
+ /** Required: the field list's whole body, which your app draws (`CONTROLS.FieldsBody` is ViewKit's own). Every sort
1561
+ * and filter field list ViewKit opens opens it, handed the fields as data. */
1562
+ FieldsBody: ComponentType<ViewsFieldsBodyProps>;
1563
+ /** Required: a filter rule's way and value, which your app draws (`CONTROLS.FilterPartBody` is ViewKit's own). A
1564
+ * filter's way and value on the bar open it, handed the rule as data. */
1565
+ FilterPartBody: ComponentType<ViewsFilterPartBodyProps>;
1385
1566
  /** Optional: wraps a grid's rows. Handed one, a grid that already shows rows keeps them on screen, inert, as its
1386
1567
  * children while new ones load, and hands it `pending`; left out, the grid draws Loading in place of its body. A
1387
1568
  * grid with no rows yet draws Loading either way. Draw it as a block in flow that neither scrolls nor clips. */
1388
1569
  RowsWait?: ComponentType<ViewsRowsWaitProps>;
1389
- /** Optional: the quick filters' whole body, which your app draws. Handed one, the quick filters' button opens it on
1390
- * a computer and in the phone's Sheet, handed the fields, their values and the hold as data; left out, it opens
1391
- * ViewKit's own quick-filters panel. */
1392
- QuickFiltersBody?: ComponentType<ViewsQuickFiltersBodyProps>;
1393
- /** Optional: the views list's whole body, which your app draws. Handed one, the view picker's chip opens it on a
1394
- * computer and in the phone's Sheet, handed the views as data; left out, it opens ViewKit's own list. */
1395
- ViewsListBody?: ComponentType<ViewsViewsListBodyProps>;
1396
- /** Optional: the group editor's whole body, which your app draws. Handed one, Customize's Group opens it on a
1397
- * computer and in the phone's Sheet, handed the group as data; left out, it opens ViewKit's own group pages. */
1570
+ /** Required: the quick filters' whole body, which your app draws (`CONTROLS.QuickFiltersBody` is ViewKit's own). The
1571
+ * quick filters' button opens it on a computer and in the phone's Sheet, handed the fields, their values and the
1572
+ * hold as data. */
1573
+ QuickFiltersBody: ComponentType<ViewsQuickFiltersBodyProps>;
1574
+ /** Required: the views list's whole body, which your app draws (`CONTROLS.ViewsListBody` is ViewKit's own). The view
1575
+ * picker's chip opens it on a computer and in the phone's Sheet, handed the views as data. */
1576
+ ViewsListBody: ComponentType<ViewsViewsListBodyProps>;
1577
+ /** @deprecated Read by nothing: only ViewKit's own Customize opened it, and that Customize is gone. A `CustomizeBody`
1578
+ * holds its own group editor, handed the group as `GroupBody` was (`ViewsCustomizeBodyProps.group`). */
1398
1579
  GroupBody?: ComponentType<ViewsGroupBodyProps>;
1399
- /** Optional: Customize's whole body, which your app draws. Handed one, Options opens it on a computer and in the
1400
- * phone's Sheet, and so does anything else that draws ViewKit's Customize, handed the view's settings as data; left
1401
- * out, it opens ViewKit's own Customize. */
1402
- CustomizeBody?: ComponentType<ViewsCustomizeBodyProps>;
1580
+ /** Required: Customize's whole body, which your app draws (`CONTROLS.CustomizeBody`, or your own). Options opens it on a
1581
+ * computer and in the phone's Sheet, and so does everything else that draws Customize, handed the view's settings as
1582
+ * data. ViewKit draws no Customize of its own. */
1583
+ CustomizeBody: ComponentType<ViewsCustomizeBodyProps>;
1403
1584
  /** Optional: the toolbar's search box, which your app draws. Handed one, the search opens it in place of its own
1404
1585
  * field, on a computer and on a phone; left out, ViewKit draws its own. */
1405
1586
  SearchField?: ComponentType<ViewsSearchFieldProps>;
1587
+ /** Optional: what draws the ports an app leaves out (CONTROLS: ViewKit's Toast and alert dialog). Mounted once by the
1588
+ * provider, after it first renders in the browser, only when the app hands no `toast` or no `confirm`; left out, a
1589
+ * missing `toast` draws nothing and a missing `confirm` is the browser's. */
1590
+ PortsHost?: ComponentType<ViewsPortsHostProps>;
1591
+ /** Optional: the selection bar, which your app draws (CONTROLS: the Outright bulk bar). Handed one, ViewKit's `SelectionBar`
1592
+ * draws it in its own place, in the box that holds it, at every count (zero included, so it can leave), handed its props;
1593
+ * left out, ViewKit draws its own bar, portalled to the screen's foot. */
1594
+ SelectionBar?: ComponentType<ViewsSelectionBarProps>;
1406
1595
  };
1407
- /** The map as the views read it: `Input`, `Command` and `Calendar` always filled, the app's or the
1408
- * package's own; `Picker`, `LinksBody`, `DateBody`, `PartsBody`, `ValuesBody`, `TextBody`, `NumberBody`, `SortBody`, `FilterBody`,
1409
- * `FieldsBody`, `FilterPartBody`, `RowsWait`, `QuickFiltersBody`, `ViewsListBody`, `GroupBody`, `CustomizeBody` and
1410
- * `SearchField` as the app handed them. */
1596
+ /** The selection bar's props, as your `SelectionBar` is handed them: ViewKit's `SelectionBar`'s own. */
1597
+ export type ViewsSelectionBarProps = SelectionBarProps;
1598
+ /** The map as the views read it: `Input` and `Calendar` always filled, the app's or the
1599
+ * package's own; `RowsWait`, `GroupBody`, `SearchField`, `PortsHost` and `SelectionBar` as the app handed them. */
1411
1600
  export type ViewsResolvedComponents = ViewsComponents & {
1412
1601
  Input: ComponentType<ViewsInputProps>;
1413
- Command: ViewsCommandParts;
1414
1602
  Calendar: ComponentType<ViewsCalendarProps>;
1415
1603
  };
1416
1604
  export {};
@@ -2,11 +2,10 @@ import type { FieldConventions } from "viewkitjs/fields";
2
2
  import type { ViewsMessageResolver } from "../contract.js";
3
3
  import type { ViewsAtoms } from "../atoms/types.js";
4
4
  import type { FieldPresentation } from "../display/options.js";
5
- import type { ViewsDatePicks, ViewsFieldRowButtons, ViewsFieldRowCheckboxes, ViewsGridButtons, ViewsGridCheckboxes, ViewsMenuRoute, ViewsPanelButtons, ViewsResolvedComponents, ViewsSelectionBarSettings, ViewsSheetActionsPlace } from "./components.js";
5
+ import type { ViewsDatePicks, ViewsResolvedComponents, ViewsSelectionBarSettings, ViewsSheetActionsPlace } from "./components.js";
6
6
  import type { ViewsIcons } from "./icons.js";
7
7
  import type { ViewsResolvedPorts } from "./ports.js";
8
8
  import type { ViewsEscapeRules } from "../editors/escape-rule.js";
9
- import type { ViewsBodyFrame, ViewsGridBodyPlace } from "../model/body-frame.js";
10
9
  import type { ViewsSeveralValues } from "../display/fit-values.js";
11
10
  import type { ViewsOneValueEditors } from "../model/one-value.js";
12
11
  export type ViewsContextValue = {
@@ -16,6 +15,12 @@ export type ViewsContextValue = {
16
15
  icons: ViewsIcons;
17
16
  /** The app's ports, with `confirm` always a function (the browser's where the app handed none). */
18
17
  ports: ViewsResolvedPorts;
18
+ /** No `confirm` of the app's and no `PortsHost` to draw ViewKit's: `ports.confirm` is the browser's own. A control that can ask
19
+ * in a dialog of its own (a view's menu, VK-823) asks there instead. */
20
+ confirmFallback: boolean;
21
+ /** No `toast` of the app's and no `PortsHost`: `ports.toast` draws nothing. A control that can say it through a Toast of its
22
+ * own standing round it (a view's menu) does so instead. */
23
+ toastFallback: boolean;
19
24
  messages: ViewsMessageResolver;
20
25
  conventions: FieldConventions;
21
26
  /** The app's formatting: given the package's defaults, return the app's. */
@@ -28,27 +33,8 @@ export type ViewsContextValue = {
28
33
  escape?: ViewsEscapeRules;
29
34
  /** Which single types open as the value list holding one (`ViewsProvider`'s `oneValue`); absent, the text box. */
30
35
  oneValue?: ViewsOneValueEditors;
31
- /** The grid says why the app refused an edit it sent (`ViewsProvider`'s `sayRefusals`); absent, it says nothing. */
32
- sayRefusals?: boolean;
33
- /** How the grid opens its own menus (`ViewsProvider`'s `menus`). Absent means `popover`. */
34
- menus?: ViewsMenuRoute;
35
- /** Who draws the buttons the grid draws itself (`ViewsProvider`'s `gridButtons`). Absent means `own`. */
36
- gridButtons?: ViewsGridButtons;
37
36
  /** How a cell of several values draws on one line (`ViewsProvider`'s `severalValues`). Absent means `fit`. */
38
37
  severalValues?: ViewsSeveralValues;
39
- /** Who draws a yes/no cell's box in the grid (`ViewsProvider`'s `gridCheckboxes`). Absent means `own`. */
40
- gridCheckboxes?: ViewsGridCheckboxes;
41
- /** Who draws a field row's own buttons (`ViewsProvider`'s `fieldRowButtons`). Absent means `own`. */
42
- fieldRowButtons?: ViewsFieldRowButtons;
43
- /** Who draws a field row's yes/no box (`ViewsProvider`'s `fieldRowCheckboxes`). Absent means `own`. */
44
- fieldRowCheckboxes?: ViewsFieldRowCheckboxes;
45
- /** Who draws the panels' own buttons (`ViewsProvider`'s `panelButtons`). Absent means `own`. */
46
- panelButtons?: ViewsPanelButtons;
47
- /** Who frames a whole body the app hands (`ViewsProvider`'s `bodyFrame`). Absent means `views`. */
48
- bodyFrame?: ViewsBodyFrame;
49
- /** Where a grid editor opens the popover around a body the app hands (`ViewsProvider`'s `gridBodyPlace`). Absent
50
- * means `under`. */
51
- gridBodyPlace?: ViewsGridBodyPlace;
52
38
  /** Where the selection bar sits (`ViewsProvider`'s `selectionBar`); absent, the package's defaults. */
53
39
  selectionBar?: ViewsSelectionBarSettings;
54
40
  /** The quick days the date editors offer (`ViewsProvider`'s `datePicks`); absent, today, tomorrow and next Monday. */