@mistriwork/kit 1.0.0-rc.11 → 1.0.0-rc.12

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 (970) hide show
  1. package/dist/client/actionGrants.d.ts +21 -0
  2. package/dist/client/actionGrants.js +24 -0
  3. package/dist/client/addressMount.d.ts +67 -0
  4. package/dist/client/addressMount.js +136 -0
  5. package/dist/client/app.d.ts +10 -0
  6. package/dist/client/app.js +976 -0
  7. package/dist/client/boot.d.ts +1 -0
  8. package/dist/client/boot.js +37 -0
  9. package/dist/client/brandLook.css +125 -0
  10. package/dist/client/breakdownBatch.d.ts +34 -0
  11. package/dist/client/breakdownBatch.js +115 -0
  12. package/dist/client/bulkActions.d.ts +66 -0
  13. package/dist/client/bulkActions.js +171 -0
  14. package/dist/client/chart.d.ts +20 -0
  15. package/dist/client/chart.js +80 -0
  16. package/dist/client/clauses.d.ts +121 -0
  17. package/dist/client/clauses.js +276 -0
  18. package/dist/client/columns.d.ts +77 -0
  19. package/dist/client/columns.js +102 -0
  20. package/dist/client/components/Accordion.d.ts +26 -0
  21. package/dist/client/components/Accordion.js +44 -0
  22. package/dist/client/components/ApiOperations.d.ts +3 -0
  23. package/dist/client/components/ApiOperations.js +162 -0
  24. package/dist/client/components/AppColumnMenu.d.ts +66 -0
  25. package/dist/client/components/AppColumnMenu.js +59 -0
  26. package/dist/client/components/AppColumnMenuPopups.d.ts +21 -0
  27. package/dist/client/components/AppColumnMenuPopups.js +92 -0
  28. package/dist/client/components/AppFooter.css +17 -0
  29. package/dist/client/components/AppFooter.d.ts +23 -0
  30. package/dist/client/components/AppFooter.js +12 -0
  31. package/dist/client/components/AppIssues.d.ts +4 -0
  32. package/dist/client/components/AppIssues.js +18 -0
  33. package/dist/client/components/AppList.d.ts +20 -0
  34. package/dist/client/components/AppList.js +696 -0
  35. package/dist/client/components/AttachmentList.d.ts +45 -0
  36. package/dist/client/components/AttachmentList.js +178 -0
  37. package/dist/client/components/BoardList.css +9 -0
  38. package/dist/client/components/Breakdown.d.ts +11 -0
  39. package/dist/client/components/Breakdown.js +157 -0
  40. package/dist/client/components/BreakdownRoom.d.ts +4 -0
  41. package/dist/client/components/BreakdownRoom.js +48 -0
  42. package/dist/client/components/CardsList.d.ts +23 -0
  43. package/dist/client/components/CardsList.js +209 -0
  44. package/dist/client/components/Chart.css +165 -0
  45. package/dist/client/components/Chart.d.ts +194 -0
  46. package/dist/client/components/Chart.js +801 -0
  47. package/dist/client/components/ChartFigure.d.ts +82 -0
  48. package/dist/client/components/ChartFigure.js +102 -0
  49. package/dist/client/components/ChartShapes.css +213 -0
  50. package/dist/client/components/ChartShapes.d.ts +63 -0
  51. package/dist/client/components/ChartShapes.js +393 -0
  52. package/dist/client/components/Checklist.css +16 -0
  53. package/dist/client/components/Composer.d.ts +1 -0
  54. package/dist/client/components/Composer.js +331 -0
  55. package/dist/client/components/Content.d.ts +8 -0
  56. package/dist/client/components/Content.js +170 -0
  57. package/dist/client/components/CountedLabel.d.ts +10 -0
  58. package/dist/client/components/CountedLabel.js +26 -0
  59. package/dist/client/components/Crumbs.d.ts +11 -0
  60. package/dist/client/components/Crumbs.js +142 -0
  61. package/dist/client/components/DashboardList.css +7 -0
  62. package/dist/client/components/DashboardList.d.ts +9 -0
  63. package/dist/client/components/DashboardList.js +46 -0
  64. package/dist/client/components/DashboardNote.d.ts +21 -0
  65. package/dist/client/components/DashboardNote.js +22 -0
  66. package/dist/client/components/DateField.css +6 -0
  67. package/dist/client/components/DateField.d.ts +7 -0
  68. package/dist/client/components/DateField.js +27 -0
  69. package/dist/client/components/DefinedFields.d.ts +50 -0
  70. package/dist/client/components/DefinedFields.js +186 -0
  71. package/dist/client/components/DeleteButton.d.ts +30 -0
  72. package/dist/client/components/DeleteButton.js +198 -0
  73. package/dist/client/components/Diagram.d.ts +7 -0
  74. package/dist/client/components/Diagram.js +320 -0
  75. package/dist/client/components/Dressed.d.ts +31 -0
  76. package/dist/client/components/Dressed.js +138 -0
  77. package/dist/client/components/Dropdown.d.ts +14 -0
  78. package/dist/client/components/Dropdown.js +20 -0
  79. package/dist/client/components/EditLayoutButton.d.ts +13 -0
  80. package/dist/client/components/EditLayoutButton.js +7 -0
  81. package/dist/client/components/Editable.d.ts +47 -0
  82. package/dist/client/components/Editable.js +422 -0
  83. package/dist/client/components/ErrorBoundary.d.ts +40 -0
  84. package/dist/client/components/ErrorBoundary.js +41 -0
  85. package/dist/client/components/Export.d.ts +15 -0
  86. package/dist/client/components/Export.js +151 -0
  87. package/dist/client/components/ExportHold.d.ts +18 -0
  88. package/dist/client/components/ExportHold.js +30 -0
  89. package/dist/client/components/FavoriteStar.d.ts +5 -0
  90. package/dist/client/components/FavoriteStar.js +14 -0
  91. package/dist/client/components/FieldArranger.d.ts +28 -0
  92. package/dist/client/components/FieldArranger.js +82 -0
  93. package/dist/client/components/FilePreview.css +20 -0
  94. package/dist/client/components/FilePreview.d.ts +26 -0
  95. package/dist/client/components/FilePreview.js +170 -0
  96. package/dist/client/components/FilterBoxes.d.ts +76 -0
  97. package/dist/client/components/FilterBoxes.js +294 -0
  98. package/dist/client/components/FilterRail.css +100 -0
  99. package/dist/client/components/FilterRail.d.ts +61 -0
  100. package/dist/client/components/FilterRail.js +559 -0
  101. package/dist/client/components/Gallery.d.ts +11 -0
  102. package/dist/client/components/Gallery.js +53 -0
  103. package/dist/client/components/Grid.d.ts +122 -0
  104. package/dist/client/components/Grid.js +1115 -0
  105. package/dist/client/components/GridCellEditor.d.ts +35 -0
  106. package/dist/client/components/GridCellEditor.js +291 -0
  107. package/dist/client/components/GridSelection.d.ts +16 -0
  108. package/dist/client/components/GridSelection.js +28 -0
  109. package/dist/client/components/HelpPanel.d.ts +5 -0
  110. package/dist/client/components/HelpPanel.js +92 -0
  111. package/dist/client/components/History.d.ts +10 -0
  112. package/dist/client/components/History.js +22 -0
  113. package/dist/client/components/Icon.d.ts +31 -0
  114. package/dist/client/components/Icon.js +20 -0
  115. package/dist/client/components/JsonPreview.d.ts +5 -0
  116. package/dist/client/components/JsonPreview.js +25 -0
  117. package/dist/client/components/JsonValue.d.ts +4 -0
  118. package/dist/client/components/JsonValue.js +3 -0
  119. package/dist/client/components/JsonView.css +109 -0
  120. package/dist/client/components/JsonView.d.ts +3 -0
  121. package/dist/client/components/JsonView.js +118 -0
  122. package/dist/client/components/Landing.d.ts +19 -0
  123. package/dist/client/components/Landing.js +55 -0
  124. package/dist/client/components/LandingSurface.css +177 -0
  125. package/dist/client/components/LandingSurface.d.ts +42 -0
  126. package/dist/client/components/LandingSurface.js +108 -0
  127. package/dist/client/components/LayoutBuilder.d.ts +36 -0
  128. package/dist/client/components/LayoutBuilder.js +104 -0
  129. package/dist/client/components/Lightbox.d.ts +29 -0
  130. package/dist/client/components/Lightbox.js +62 -0
  131. package/dist/client/components/ListEmpty.css +13 -0
  132. package/dist/client/components/ListEmpty.d.ts +10 -0
  133. package/dist/client/components/ListEmpty.js +8 -0
  134. package/dist/client/components/ListFilterBar.css +76 -0
  135. package/dist/client/components/ListFilterBar.d.ts +52 -0
  136. package/dist/client/components/ListFilterBar.js +304 -0
  137. package/dist/client/components/LiveNotices.css +105 -0
  138. package/dist/client/components/LiveNotices.d.ts +26 -0
  139. package/dist/client/components/LiveNotices.js +211 -0
  140. package/dist/client/components/MinorMoneyInput.d.ts +26 -0
  141. package/dist/client/components/MinorMoneyInput.js +50 -0
  142. package/dist/client/components/Modal.css +3 -0
  143. package/dist/client/components/MultiStepForm.css +122 -0
  144. package/dist/client/components/MultiStepForm.d.ts +59 -0
  145. package/dist/client/components/MultiStepForm.js +216 -0
  146. package/dist/client/components/NavGlyph.d.ts +14 -0
  147. package/dist/client/components/NavGlyph.js +27 -0
  148. package/dist/client/components/Nested.d.ts +21 -0
  149. package/dist/client/components/Nested.js +86 -0
  150. package/dist/client/components/NewRecord.d.ts +89 -0
  151. package/dist/client/components/NewRecord.js +897 -0
  152. package/dist/client/components/NewRecordButton.d.ts +13 -0
  153. package/dist/client/components/NewRecordButton.js +28 -0
  154. package/dist/client/components/Notes.css +39 -0
  155. package/dist/client/components/Notes.d.ts +59 -0
  156. package/dist/client/components/Notes.js +96 -0
  157. package/dist/client/components/OverflowMenu.d.ts +3 -0
  158. package/dist/client/components/OverflowMenu.js +60 -0
  159. package/dist/client/components/Page.d.ts +52 -0
  160. package/dist/client/components/Page.js +237 -0
  161. package/dist/client/components/PageCurrent.d.ts +38 -0
  162. package/dist/client/components/PageCurrent.js +27 -0
  163. package/dist/client/components/PageEmptyRun.d.ts +18 -0
  164. package/dist/client/components/PageEmptyRun.js +118 -0
  165. package/dist/client/components/PageFields.d.ts +3 -0
  166. package/dist/client/components/PageFields.js +294 -0
  167. package/dist/client/components/PageFlowDiagram.css +193 -0
  168. package/dist/client/components/PageFlowDiagram.d.ts +95 -0
  169. package/dist/client/components/PageFlowDiagram.js +276 -0
  170. package/dist/client/components/PageFlows.css +27 -0
  171. package/dist/client/components/PageFlows.d.ts +54 -0
  172. package/dist/client/components/PageFlows.js +92 -0
  173. package/dist/client/components/PageGroups.d.ts +43 -0
  174. package/dist/client/components/PageGroups.js +123 -0
  175. package/dist/client/components/PageHead.d.ts +28 -0
  176. package/dist/client/components/PageHead.js +279 -0
  177. package/dist/client/components/PageHeadline.d.ts +23 -0
  178. package/dist/client/components/PageHeadline.js +101 -0
  179. package/dist/client/components/PageHistory.d.ts +62 -0
  180. package/dist/client/components/PageHistory.js +160 -0
  181. package/dist/client/components/PageLayout.d.ts +22 -0
  182. package/dist/client/components/PageLayout.js +13 -0
  183. package/dist/client/components/PageMetrics.d.ts +11 -0
  184. package/dist/client/components/PageMetrics.js +252 -0
  185. package/dist/client/components/PageRelated.d.ts +70 -0
  186. package/dist/client/components/PageRelated.js +667 -0
  187. package/dist/client/components/PageRoom.d.ts +37 -0
  188. package/dist/client/components/PageRoom.js +277 -0
  189. package/dist/client/components/PageSectionBox.d.ts +28 -0
  190. package/dist/client/components/PageSectionBox.js +65 -0
  191. package/dist/client/components/PageSections.d.ts +38 -0
  192. package/dist/client/components/PageSections.js +352 -0
  193. package/dist/client/components/PageSkeleton.css +17 -0
  194. package/dist/client/components/PageSkeleton.d.ts +11 -0
  195. package/dist/client/components/PageSkeleton.js +25 -0
  196. package/dist/client/components/PageTimeline.d.ts +2 -0
  197. package/dist/client/components/PageTimeline.js +273 -0
  198. package/dist/client/components/Palette.d.ts +4 -0
  199. package/dist/client/components/Palette.js +176 -0
  200. package/dist/client/components/Peek.d.ts +1 -0
  201. package/dist/client/components/Peek.js +158 -0
  202. package/dist/client/components/PeekPanel.d.ts +16 -0
  203. package/dist/client/components/PeekPanel.js +120 -0
  204. package/dist/client/components/Picker.d.ts +13 -0
  205. package/dist/client/components/Picker.js +33 -0
  206. package/dist/client/components/Prefs.d.ts +3 -0
  207. package/dist/client/components/Prefs.js +121 -0
  208. package/dist/client/components/PresentationSwitch.d.ts +13 -0
  209. package/dist/client/components/PresentationSwitch.js +10 -0
  210. package/dist/client/components/Prompt.d.ts +35 -0
  211. package/dist/client/components/Prompt.js +114 -0
  212. package/dist/client/components/QrCode.css +11 -0
  213. package/dist/client/components/QrCode.d.ts +4 -0
  214. package/dist/client/components/QrCode.js +57 -0
  215. package/dist/client/components/QueueList.css +122 -0
  216. package/dist/client/components/QuickAdd.css +18 -0
  217. package/dist/client/components/QuickAdd.d.ts +11 -0
  218. package/dist/client/components/QuickAdd.js +53 -0
  219. package/dist/client/components/QuickAddOnDemand.d.ts +4 -0
  220. package/dist/client/components/QuickAddOnDemand.js +10 -0
  221. package/dist/client/components/Record.d.ts +36 -0
  222. package/dist/client/components/Record.js +385 -0
  223. package/dist/client/components/RecordGone.d.ts +7 -0
  224. package/dist/client/components/RecordGone.js +22 -0
  225. package/dist/client/components/RecordPicker.d.ts +59 -0
  226. package/dist/client/components/RecordPicker.js +299 -0
  227. package/dist/client/components/RecordSummaries.d.ts +55 -0
  228. package/dist/client/components/RecordSummaries.js +151 -0
  229. package/dist/client/components/RecordTags.d.ts +6 -0
  230. package/dist/client/components/RecordTags.js +119 -0
  231. package/dist/client/components/RecordTrailNav.d.ts +25 -0
  232. package/dist/client/components/RecordTrailNav.js +110 -0
  233. package/dist/client/components/RichText.d.ts +7 -0
  234. package/dist/client/components/RichText.js +82 -0
  235. package/dist/client/components/RichTextEditor.css +202 -0
  236. package/dist/client/components/RichTextEditor.d.ts +33 -0
  237. package/dist/client/components/RichTextEditor.js +348 -0
  238. package/dist/client/components/RichTextField.d.ts +26 -0
  239. package/dist/client/components/RichTextField.js +71 -0
  240. package/dist/client/components/Rooms.d.ts +35 -0
  241. package/dist/client/components/Rooms.js +276 -0
  242. package/dist/client/components/RowActions.d.ts +8 -0
  243. package/dist/client/components/RowActions.js +49 -0
  244. package/dist/client/components/RowHost.d.ts +110 -0
  245. package/dist/client/components/RowHost.js +212 -0
  246. package/dist/client/components/SavedViews.d.ts +25 -0
  247. package/dist/client/components/SavedViews.js +35 -0
  248. package/dist/client/components/SchemaExport.d.ts +15 -0
  249. package/dist/client/components/SchemaExport.js +42 -0
  250. package/dist/client/components/SectionPeriod.css +14 -0
  251. package/dist/client/components/SectionPeriod.d.ts +7 -0
  252. package/dist/client/components/SectionPeriod.js +14 -0
  253. package/dist/client/components/SetFieldDialog.d.ts +12 -0
  254. package/dist/client/components/SetFieldDialog.js +51 -0
  255. package/dist/client/components/Sidebar.d.ts +34 -0
  256. package/dist/client/components/Sidebar.js +398 -0
  257. package/dist/client/components/Skeleton.d.ts +35 -0
  258. package/dist/client/components/Skeleton.js +49 -0
  259. package/dist/client/components/SortMenu.d.ts +20 -0
  260. package/dist/client/components/SortMenu.js +45 -0
  261. package/dist/client/components/SplitListDetail.css +119 -0
  262. package/dist/client/components/SuggestBox.d.ts +29 -0
  263. package/dist/client/components/SuggestBox.js +60 -0
  264. package/dist/client/components/Summary.d.ts +14 -0
  265. package/dist/client/components/Summary.js +93 -0
  266. package/dist/client/components/TableRoom.d.ts +88 -0
  267. package/dist/client/components/TableRoom.js +246 -0
  268. package/dist/client/components/TableView.d.ts +111 -0
  269. package/dist/client/components/TableView.js +324 -0
  270. package/dist/client/components/ThMenu.d.ts +40 -0
  271. package/dist/client/components/ThMenu.js +163 -0
  272. package/dist/client/components/ThemeLab.d.ts +4 -0
  273. package/dist/client/components/ThemeLab.js +67 -0
  274. package/dist/client/components/TimelineSides.css +23 -0
  275. package/dist/client/components/TimelineSides.d.ts +7 -0
  276. package/dist/client/components/TimelineSides.js +9 -0
  277. package/dist/client/components/Tour.d.ts +12 -0
  278. package/dist/client/components/Tour.js +131 -0
  279. package/dist/client/components/Value.d.ts +38 -0
  280. package/dist/client/components/Value.js +172 -0
  281. package/dist/client/components/WorkPanel.d.ts +9 -0
  282. package/dist/client/components/WorkPanel.js +43 -0
  283. package/dist/client/components/WorkflowStatus.d.ts +6 -0
  284. package/dist/client/components/WorkflowStatus.js +44 -0
  285. package/dist/client/components/WriteConfirm.d.ts +4 -0
  286. package/dist/client/components/WriteConfirm.js +27 -0
  287. package/dist/client/components/appColumnMenuModel.d.ts +46 -0
  288. package/dist/client/components/appColumnMenuModel.js +51 -0
  289. package/dist/client/components/appListModel.d.ts +179 -0
  290. package/dist/client/components/appListModel.js +421 -0
  291. package/dist/client/components/appRooms.d.ts +106 -0
  292. package/dist/client/components/appRooms.js +133 -0
  293. package/dist/client/components/autoChart.d.ts +33 -0
  294. package/dist/client/components/autoChart.js +107 -0
  295. package/dist/client/components/avatarPhotos.d.ts +45 -0
  296. package/dist/client/components/avatarPhotos.js +93 -0
  297. package/dist/client/components/besideDetail.d.ts +1 -0
  298. package/dist/client/components/besideDetail.js +10 -0
  299. package/dist/client/components/boardNew.d.ts +2 -0
  300. package/dist/client/components/boardNew.js +8 -0
  301. package/dist/client/components/cardsModel.d.ts +11 -0
  302. package/dist/client/components/cardsModel.js +24 -0
  303. package/dist/client/components/chromeIcons.d.ts +16 -0
  304. package/dist/client/components/chromeIcons.js +16 -0
  305. package/dist/client/components/columnPresentation.d.ts +8 -0
  306. package/dist/client/components/columnPresentation.js +47 -0
  307. package/dist/client/components/componentSlot.d.ts +31 -0
  308. package/dist/client/components/componentSlot.js +76 -0
  309. package/dist/client/components/composerDraft.d.ts +16 -0
  310. package/dist/client/components/composerDraft.js +16 -0
  311. package/dist/client/components/conditionText.d.ts +14 -0
  312. package/dist/client/components/conditionText.js +45 -0
  313. package/dist/client/components/conditionWords.d.ts +37 -0
  314. package/dist/client/components/conditionWords.js +382 -0
  315. package/dist/client/components/crumbSlot.d.ts +14 -0
  316. package/dist/client/components/crumbSlot.js +49 -0
  317. package/dist/client/components/dashboardModel.d.ts +283 -0
  318. package/dist/client/components/dashboardModel.js +415 -0
  319. package/dist/client/components/dashboardParts.d.ts +9 -0
  320. package/dist/client/components/dashboardParts.js +18 -0
  321. package/dist/client/components/diagramModel.d.ts +83 -0
  322. package/dist/client/components/diagramModel.js +211 -0
  323. package/dist/client/components/dueOpen.d.ts +1 -0
  324. package/dist/client/components/dueOpen.js +23 -0
  325. package/dist/client/components/editInteraction.d.ts +20 -0
  326. package/dist/client/components/editInteraction.js +178 -0
  327. package/dist/client/components/favoriteNav.d.ts +6 -0
  328. package/dist/client/components/favoriteNav.js +31 -0
  329. package/dist/client/components/favorites.d.ts +23 -0
  330. package/dist/client/components/favorites.js +86 -0
  331. package/dist/client/components/filePreviewModel.d.ts +18 -0
  332. package/dist/client/components/filePreviewModel.js +21 -0
  333. package/dist/client/components/filterRailModel.d.ts +93 -0
  334. package/dist/client/components/filterRailModel.js +302 -0
  335. package/dist/client/components/formControlsStyle.d.ts +1 -0
  336. package/dist/client/components/formControlsStyle.js +3 -0
  337. package/dist/client/components/formDefaults.d.ts +17 -0
  338. package/dist/client/components/formDefaults.js +128 -0
  339. package/dist/client/components/gridArrange.d.ts +33 -0
  340. package/dist/client/components/gridArrange.js +62 -0
  341. package/dist/client/components/gridCellModel.d.ts +32 -0
  342. package/dist/client/components/gridCellModel.js +42 -0
  343. package/dist/client/components/gridSizing.d.ts +89 -0
  344. package/dist/client/components/gridSizing.js +295 -0
  345. package/dist/client/components/groupMoves.d.ts +44 -0
  346. package/dist/client/components/groupMoves.js +295 -0
  347. package/dist/client/components/groupOrder.d.ts +43 -0
  348. package/dist/client/components/groupOrder.js +63 -0
  349. package/dist/client/components/inputRenderers.d.ts +48 -0
  350. package/dist/client/components/inputRenderers.js +37 -0
  351. package/dist/client/components/intakeStyle.d.ts +2 -0
  352. package/dist/client/components/intakeStyle.js +6 -0
  353. package/dist/client/components/jsonModel.d.ts +98 -0
  354. package/dist/client/components/jsonModel.js +264 -0
  355. package/dist/client/components/listColumn.d.ts +20 -0
  356. package/dist/client/components/listColumn.js +31 -0
  357. package/dist/client/components/listNavigation.d.ts +16 -0
  358. package/dist/client/components/listNavigation.js +14 -0
  359. package/dist/client/components/mentionRows.d.ts +5 -0
  360. package/dist/client/components/mentionRows.js +62 -0
  361. package/dist/client/components/mount.d.ts +55 -0
  362. package/dist/client/components/mount.js +155 -0
  363. package/dist/client/components/myViews.d.ts +54 -0
  364. package/dist/client/components/myViews.js +82 -0
  365. package/dist/client/components/navCounts.d.ts +84 -0
  366. package/dist/client/components/navCounts.js +194 -0
  367. package/dist/client/components/navigationTree.d.ts +52 -0
  368. package/dist/client/components/navigationTree.js +49 -0
  369. package/dist/client/components/newMenuModel.d.ts +27 -0
  370. package/dist/client/components/newMenuModel.js +58 -0
  371. package/dist/client/components/newRecordModel.d.ts +58 -0
  372. package/dist/client/components/newRecordModel.js +232 -0
  373. package/dist/client/components/onDemand.d.ts +30 -0
  374. package/dist/client/components/onDemand.js +121 -0
  375. package/dist/client/components/optimisticMoves.d.ts +21 -0
  376. package/dist/client/components/optimisticMoves.js +145 -0
  377. package/dist/client/components/pageContext.d.ts +154 -0
  378. package/dist/client/components/pageContext.js +47 -0
  379. package/dist/client/components/pageFieldsRead.d.ts +67 -0
  380. package/dist/client/components/pageFieldsRead.js +55 -0
  381. package/dist/client/components/pageModel.d.ts +203 -0
  382. package/dist/client/components/pageModel.js +67 -0
  383. package/dist/client/components/pageStep.d.ts +31 -0
  384. package/dist/client/components/pageStep.js +15 -0
  385. package/dist/client/components/paletteModel.d.ts +9 -0
  386. package/dist/client/components/paletteModel.js +46 -0
  387. package/dist/client/components/pickerStaleness.d.ts +32 -0
  388. package/dist/client/components/pickerStaleness.js +27 -0
  389. package/dist/client/components/placeOrder.d.ts +47 -0
  390. package/dist/client/components/placeOrder.js +71 -0
  391. package/dist/client/components/pointerDrag.d.ts +54 -0
  392. package/dist/client/components/pointerDrag.js +95 -0
  393. package/dist/client/components/presentationFit.d.ts +19 -0
  394. package/dist/client/components/presentationFit.js +32 -0
  395. package/dist/client/components/recordKeys.d.ts +2 -0
  396. package/dist/client/components/recordKeys.js +8 -0
  397. package/dist/client/components/recordSearch.d.ts +31 -0
  398. package/dist/client/components/recordSearch.js +80 -0
  399. package/dist/client/components/recordSurface.d.ts +86 -0
  400. package/dist/client/components/recordSurface.js +267 -0
  401. package/dist/client/components/rowOpens.d.ts +19 -0
  402. package/dist/client/components/rowOpens.js +25 -0
  403. package/dist/client/components/sidebarModel.d.ts +152 -0
  404. package/dist/client/components/sidebarModel.js +372 -0
  405. package/dist/client/components/suggestModel.d.ts +22 -0
  406. package/dist/client/components/suggestModel.js +49 -0
  407. package/dist/client/components/suggestPart.d.ts +4 -0
  408. package/dist/client/components/suggestPart.js +4 -0
  409. package/dist/client/components/textMeasure.d.ts +2 -0
  410. package/dist/client/components/textMeasure.js +35 -0
  411. package/dist/client/components/unknownIcon.d.ts +8 -0
  412. package/dist/client/components/unknownIcon.js +32 -0
  413. package/dist/client/components/useBulkSelection.d.ts +30 -0
  414. package/dist/client/components/useBulkSelection.js +360 -0
  415. package/dist/client/components/useConditionWords.d.ts +17 -0
  416. package/dist/client/components/useConditionWords.js +104 -0
  417. package/dist/client/components/useGridKeyboard.d.ts +32 -0
  418. package/dist/client/components/useGridKeyboard.js +223 -0
  419. package/dist/client/components/useListOrder.d.ts +94 -0
  420. package/dist/client/components/useListOrder.js +294 -0
  421. package/dist/client/components/useMediaQuery.d.ts +10 -0
  422. package/dist/client/components/useMediaQuery.js +45 -0
  423. package/dist/client/components/useMessageLanguage.d.ts +1 -0
  424. package/dist/client/components/useMessageLanguage.js +6 -0
  425. package/dist/client/components/usePins.d.ts +20 -0
  426. package/dist/client/components/usePins.js +66 -0
  427. package/dist/client/components/usePointerDrag.d.ts +72 -0
  428. package/dist/client/components/usePointerDrag.js +553 -0
  429. package/dist/client/components/useRecordInsert.d.ts +42 -0
  430. package/dist/client/components/useRecordInsert.js +145 -0
  431. package/dist/client/components/useRowWindow.d.ts +35 -0
  432. package/dist/client/components/useRowWindow.js +149 -0
  433. package/dist/client/components/useStickyHead.d.ts +17 -0
  434. package/dist/client/components/useStickyHead.js +65 -0
  435. package/dist/client/components/useTabFold.d.ts +32 -0
  436. package/dist/client/components/useTabFold.js +145 -0
  437. package/dist/client/components/valueModel.d.ts +300 -0
  438. package/dist/client/components/valueModel.js +560 -0
  439. package/dist/client/components/valueRenderers.d.ts +36 -0
  440. package/dist/client/components/valueRenderers.js +13 -0
  441. package/dist/client/components/viewLink.d.ts +27 -0
  442. package/dist/client/components/viewLink.js +79 -0
  443. package/dist/client/components/walk.d.ts +14 -0
  444. package/dist/client/components/walk.js +16 -0
  445. package/dist/client/compose.d.ts +8 -0
  446. package/dist/client/compose.js +163 -0
  447. package/dist/client/composedHook.d.ts +20 -0
  448. package/dist/client/composedHook.js +12 -0
  449. package/dist/client/composedReads.d.ts +26 -0
  450. package/dist/client/composedReads.js +183 -0
  451. package/dist/client/composer.css +499 -0
  452. package/dist/client/composer.d.ts +121 -0
  453. package/dist/client/composer.js +1079 -0
  454. package/dist/client/composerEntry.d.ts +1 -0
  455. package/dist/client/composerEntry.js +58 -0
  456. package/dist/client/composerTab.d.ts +6 -0
  457. package/dist/client/composerTab.js +20 -0
  458. package/dist/client/conditions.d.ts +46 -0
  459. package/dist/client/conditions.js +150 -0
  460. package/dist/client/connectionList.d.ts +11 -0
  461. package/dist/client/connectionList.js +146 -0
  462. package/dist/client/connectionScope.d.ts +6 -0
  463. package/dist/client/connectionScope.js +14 -0
  464. package/dist/client/connectionTransition.d.ts +12 -0
  465. package/dist/client/connectionTransition.js +41 -0
  466. package/dist/client/copy/columnMenu/components/AppColumnMenu.d.ts +4 -0
  467. package/dist/client/copy/columnMenu/components/AppColumnMenu.js +6 -0
  468. package/dist/client/copy/columnMenu/components/AppColumnMenuPopups.d.ts +4 -0
  469. package/dist/client/copy/columnMenu/components/AppColumnMenuPopups.js +6 -0
  470. package/dist/client/copy/columnMenu/components/ThMenu.d.ts +35 -0
  471. package/dist/client/copy/columnMenu/components/ThMenu.js +37 -0
  472. package/dist/client/copy/columnMenu/components/appColumnMenuModel.d.ts +10 -0
  473. package/dist/client/copy/columnMenu/components/appColumnMenuModel.js +12 -0
  474. package/dist/client/copy/dashboards/breakdownBatch.d.ts +3 -0
  475. package/dist/client/copy/dashboards/breakdownBatch.js +5 -0
  476. package/dist/client/copy/dashboards/components/Breakdown.d.ts +32 -0
  477. package/dist/client/copy/dashboards/components/Breakdown.js +25 -0
  478. package/dist/client/copy/dashboards/components/BreakdownRoom.d.ts +3 -0
  479. package/dist/client/copy/dashboards/components/BreakdownRoom.js +5 -0
  480. package/dist/client/copy/dashboards/components/Chart.d.ts +26 -0
  481. package/dist/client/copy/dashboards/components/Chart.js +19 -0
  482. package/dist/client/copy/dashboards/components/ChartShapes.d.ts +16 -0
  483. package/dist/client/copy/dashboards/components/ChartShapes.js +12 -0
  484. package/dist/client/copy/dashboards/components/PageMetrics.d.ts +21 -0
  485. package/dist/client/copy/dashboards/components/PageMetrics.js +20 -0
  486. package/dist/client/copy/dashboards/components/SectionPeriod.d.ts +4 -0
  487. package/dist/client/copy/dashboards/components/SectionPeriod.js +6 -0
  488. package/dist/client/copy/dashboards/components/dashboardModel.d.ts +3 -0
  489. package/dist/client/copy/dashboards/components/dashboardModel.js +5 -0
  490. package/dist/client/copy/es.d.ts +11 -0
  491. package/dist/client/copy/es.js +60 -0
  492. package/dist/client/copy/filters/components/FilterBoxes.d.ts +10 -0
  493. package/dist/client/copy/filters/components/FilterBoxes.js +12 -0
  494. package/dist/client/copy/filters/components/FilterRail.d.ts +16 -0
  495. package/dist/client/copy/filters/components/FilterRail.js +18 -0
  496. package/dist/client/copy/filters/components/ListFilterBar.d.ts +9 -0
  497. package/dist/client/copy/filters/components/ListFilterBar.js +11 -0
  498. package/dist/client/copy/filters/components/conditionWords.d.ts +46 -0
  499. package/dist/client/copy/filters/components/conditionWords.js +95 -0
  500. package/dist/client/copy/filters/components/filterRailModel.d.ts +12 -0
  501. package/dist/client/copy/filters/components/filterRailModel.js +14 -0
  502. package/dist/client/copy/forms/components/DateField.d.ts +13 -0
  503. package/dist/client/copy/forms/components/DateField.js +15 -0
  504. package/dist/client/copy/forms/components/MinorMoneyInput.d.ts +4 -0
  505. package/dist/client/copy/forms/components/MinorMoneyInput.js +6 -0
  506. package/dist/client/copy/forms/components/MultiStepForm.d.ts +10 -0
  507. package/dist/client/copy/forms/components/MultiStepForm.js +12 -0
  508. package/dist/client/copy/forms/components/NewRecord.d.ts +29 -0
  509. package/dist/client/copy/forms/components/NewRecord.js +31 -0
  510. package/dist/client/copy/forms/components/NewRecordButton.d.ts +6 -0
  511. package/dist/client/copy/forms/components/NewRecordButton.js +8 -0
  512. package/dist/client/copy/forms/components/Picker.d.ts +4 -0
  513. package/dist/client/copy/forms/components/Picker.js +6 -0
  514. package/dist/client/copy/forms/components/QuickAdd.d.ts +3 -0
  515. package/dist/client/copy/forms/components/QuickAdd.js +5 -0
  516. package/dist/client/copy/forms/components/RecordPicker.d.ts +6 -0
  517. package/dist/client/copy/forms/components/RecordPicker.js +8 -0
  518. package/dist/client/copy/forms/components/RichTextEditor.d.ts +36 -0
  519. package/dist/client/copy/forms/components/RichTextEditor.js +40 -0
  520. package/dist/client/copy/forms/components/RichTextField.d.ts +3 -0
  521. package/dist/client/copy/forms/components/RichTextField.js +5 -0
  522. package/dist/client/copy/forms/components/SetFieldDialog.d.ts +10 -0
  523. package/dist/client/copy/forms/components/SetFieldDialog.js +9 -0
  524. package/dist/client/copy/forms/components/useRecordInsert.d.ts +7 -0
  525. package/dist/client/copy/forms/components/useRecordInsert.js +9 -0
  526. package/dist/client/copy/help/helpContent.d.ts +71 -0
  527. package/dist/client/copy/help/helpContent.js +73 -0
  528. package/dist/client/copy/lists/bulkActions.d.ts +12 -0
  529. package/dist/client/copy/lists/bulkActions.js +14 -0
  530. package/dist/client/copy/lists/components/AppList.d.ts +28 -0
  531. package/dist/client/copy/lists/components/AppList.js +30 -0
  532. package/dist/client/copy/lists/components/CardsList.d.ts +3 -0
  533. package/dist/client/copy/lists/components/CardsList.js +5 -0
  534. package/dist/client/copy/lists/components/Gallery.d.ts +7 -0
  535. package/dist/client/copy/lists/components/Gallery.js +9 -0
  536. package/dist/client/copy/lists/components/Grid.d.ts +30 -0
  537. package/dist/client/copy/lists/components/Grid.js +29 -0
  538. package/dist/client/copy/lists/components/GridCellEditor.d.ts +5 -0
  539. package/dist/client/copy/lists/components/GridCellEditor.js +7 -0
  540. package/dist/client/copy/lists/components/GridSelection.d.ts +4 -0
  541. package/dist/client/copy/lists/components/GridSelection.js +6 -0
  542. package/dist/client/copy/lists/components/Nested.d.ts +7 -0
  543. package/dist/client/copy/lists/components/Nested.js +9 -0
  544. package/dist/client/copy/lists/components/RowActions.d.ts +1 -0
  545. package/dist/client/copy/lists/components/RowActions.js +3 -0
  546. package/dist/client/copy/lists/components/SavedViews.d.ts +5 -0
  547. package/dist/client/copy/lists/components/SavedViews.js +7 -0
  548. package/dist/client/copy/lists/components/SortMenu.d.ts +5 -0
  549. package/dist/client/copy/lists/components/SortMenu.js +7 -0
  550. package/dist/client/copy/lists/components/TableRoom.d.ts +12 -0
  551. package/dist/client/copy/lists/components/TableRoom.js +14 -0
  552. package/dist/client/copy/lists/components/TableView.d.ts +37 -0
  553. package/dist/client/copy/lists/components/TableView.js +39 -0
  554. package/dist/client/copy/lists/components/appListModel.d.ts +6 -0
  555. package/dist/client/copy/lists/components/appListModel.js +5 -0
  556. package/dist/client/copy/lists/components/myViews.d.ts +4 -0
  557. package/dist/client/copy/lists/components/myViews.js +6 -0
  558. package/dist/client/copy/lists/components/placeOrder.d.ts +4 -0
  559. package/dist/client/copy/lists/components/placeOrder.js +6 -0
  560. package/dist/client/copy/lists/components/useBulkSelection.d.ts +20 -0
  561. package/dist/client/copy/lists/components/useBulkSelection.js +16 -0
  562. package/dist/client/copy/lists/components/useListOrder.d.ts +7 -0
  563. package/dist/client/copy/lists/components/useListOrder.js +9 -0
  564. package/dist/client/copy/public/components/appRooms.d.ts +3 -0
  565. package/dist/client/copy/public/components/appRooms.js +5 -0
  566. package/dist/client/copy/record/components/Actions.d.ts +13 -0
  567. package/dist/client/copy/record/components/Actions.js +15 -0
  568. package/dist/client/copy/record/components/AttachmentList.d.ts +23 -0
  569. package/dist/client/copy/record/components/AttachmentList.js +22 -0
  570. package/dist/client/copy/record/components/DeleteButton.d.ts +22 -0
  571. package/dist/client/copy/record/components/DeleteButton.js +24 -0
  572. package/dist/client/copy/record/components/Dressed.d.ts +5 -0
  573. package/dist/client/copy/record/components/Dressed.js +7 -0
  574. package/dist/client/copy/record/components/EditLayoutButton.d.ts +5 -0
  575. package/dist/client/copy/record/components/EditLayoutButton.js +7 -0
  576. package/dist/client/copy/record/components/Editable.d.ts +25 -0
  577. package/dist/client/copy/record/components/Editable.js +24 -0
  578. package/dist/client/copy/record/components/FieldArranger.d.ts +15 -0
  579. package/dist/client/copy/record/components/FieldArranger.js +17 -0
  580. package/dist/client/copy/record/components/FilePreview.d.ts +13 -0
  581. package/dist/client/copy/record/components/FilePreview.js +15 -0
  582. package/dist/client/copy/record/components/JsonPreview.d.ts +3 -0
  583. package/dist/client/copy/record/components/JsonPreview.js +5 -0
  584. package/dist/client/copy/record/components/JsonView.d.ts +12 -0
  585. package/dist/client/copy/record/components/JsonView.js +14 -0
  586. package/dist/client/copy/record/components/LayoutBuilder.d.ts +23 -0
  587. package/dist/client/copy/record/components/LayoutBuilder.js +25 -0
  588. package/dist/client/copy/record/components/Lightbox.d.ts +5 -0
  589. package/dist/client/copy/record/components/Lightbox.js +7 -0
  590. package/dist/client/copy/record/components/LiveNotices.d.ts +33 -0
  591. package/dist/client/copy/record/components/LiveNotices.js +29 -0
  592. package/dist/client/copy/record/components/PageCurrent.d.ts +1 -0
  593. package/dist/client/copy/record/components/PageCurrent.js +3 -0
  594. package/dist/client/copy/record/components/PageEmptyRun.d.ts +3 -0
  595. package/dist/client/copy/record/components/PageEmptyRun.js +5 -0
  596. package/dist/client/copy/record/components/PageFields.d.ts +5 -0
  597. package/dist/client/copy/record/components/PageFields.js +7 -0
  598. package/dist/client/copy/record/components/PageFlowDiagram.d.ts +33 -0
  599. package/dist/client/copy/record/components/PageFlowDiagram.js +37 -0
  600. package/dist/client/copy/record/components/PageFlows.d.ts +20 -0
  601. package/dist/client/copy/record/components/PageFlows.js +22 -0
  602. package/dist/client/copy/record/components/PageGroups.d.ts +12 -0
  603. package/dist/client/copy/record/components/PageGroups.js +14 -0
  604. package/dist/client/copy/record/components/PageHead.d.ts +8 -0
  605. package/dist/client/copy/record/components/PageHead.js +10 -0
  606. package/dist/client/copy/record/components/PageHistory.d.ts +18 -0
  607. package/dist/client/copy/record/components/PageHistory.js +20 -0
  608. package/dist/client/copy/record/components/PageLayout.d.ts +5 -0
  609. package/dist/client/copy/record/components/PageLayout.js +7 -0
  610. package/dist/client/copy/record/components/PageRelated.d.ts +24 -0
  611. package/dist/client/copy/record/components/PageRelated.js +26 -0
  612. package/dist/client/copy/record/components/PageRoom.d.ts +4 -0
  613. package/dist/client/copy/record/components/PageRoom.js +6 -0
  614. package/dist/client/copy/record/components/PageSectionBox.d.ts +6 -0
  615. package/dist/client/copy/record/components/PageSectionBox.js +10 -0
  616. package/dist/client/copy/record/components/PageTimeline.d.ts +9 -0
  617. package/dist/client/copy/record/components/PageTimeline.js +8 -0
  618. package/dist/client/copy/record/components/Peek.d.ts +3 -0
  619. package/dist/client/copy/record/components/Peek.js +5 -0
  620. package/dist/client/copy/record/components/PeekPanel.d.ts +5 -0
  621. package/dist/client/copy/record/components/PeekPanel.js +7 -0
  622. package/dist/client/copy/record/components/QrCode.d.ts +3 -0
  623. package/dist/client/copy/record/components/QrCode.js +5 -0
  624. package/dist/client/copy/record/components/Record.d.ts +19 -0
  625. package/dist/client/copy/record/components/Record.js +21 -0
  626. package/dist/client/copy/record/components/RecordGone.d.ts +4 -0
  627. package/dist/client/copy/record/components/RecordGone.js +6 -0
  628. package/dist/client/copy/record/components/RecordSummaries.d.ts +1 -0
  629. package/dist/client/copy/record/components/RecordSummaries.js +3 -0
  630. package/dist/client/copy/record/components/RecordTags.d.ts +9 -0
  631. package/dist/client/copy/record/components/RecordTags.js +11 -0
  632. package/dist/client/copy/record/components/RecordTrailNav.d.ts +8 -0
  633. package/dist/client/copy/record/components/RecordTrailNav.js +10 -0
  634. package/dist/client/copy/record/components/RichText.d.ts +4 -0
  635. package/dist/client/copy/record/components/RichText.js +6 -0
  636. package/dist/client/copy/record/components/Value.d.ts +4 -0
  637. package/dist/client/copy/record/components/Value.js +6 -0
  638. package/dist/client/copy/record/components/WorkflowStatus.d.ts +7 -0
  639. package/dist/client/copy/record/components/WorkflowStatus.js +9 -0
  640. package/dist/client/copy/record/components/WriteConfirm.d.ts +11 -0
  641. package/dist/client/copy/record/components/WriteConfirm.js +13 -0
  642. package/dist/client/copy/record/components/groupMoves.d.ts +7 -0
  643. package/dist/client/copy/record/components/groupMoves.js +9 -0
  644. package/dist/client/copy/record/components/jsonModel.d.ts +3 -0
  645. package/dist/client/copy/record/components/jsonModel.js +5 -0
  646. package/dist/client/copy/record/components/pageModel.d.ts +5 -0
  647. package/dist/client/copy/record/components/pageModel.js +7 -0
  648. package/dist/client/copy/record/components/recordSurface.d.ts +6 -0
  649. package/dist/client/copy/record/components/recordSurface.js +8 -0
  650. package/dist/client/copy/record/components/valueModel.d.ts +5 -0
  651. package/dist/client/copy/record/components/valueModel.js +7 -0
  652. package/dist/client/copy/record/fileSource.d.ts +3 -0
  653. package/dist/client/copy/record/fileSource.js +5 -0
  654. package/dist/client/copy/record/insert.d.ts +6 -0
  655. package/dist/client/copy/record/insert.js +8 -0
  656. package/dist/client/copy/record/page.d.ts +4 -0
  657. package/dist/client/copy/record/page.js +6 -0
  658. package/dist/client/copy/record/recordEditValidation.d.ts +4 -0
  659. package/dist/client/copy/record/recordEditValidation.js +6 -0
  660. package/dist/client/copy/record/savedPages.d.ts +4 -0
  661. package/dist/client/copy/record/savedPages.js +6 -0
  662. package/dist/client/copy/record/template.d.ts +9 -0
  663. package/dist/client/copy/record/template.js +11 -0
  664. package/dist/client/copy/record/write.d.ts +30 -0
  665. package/dist/client/copy/record/write.js +26 -0
  666. package/dist/client/copy/shell/app.d.ts +27 -0
  667. package/dist/client/copy/shell/app.js +43 -0
  668. package/dist/client/copy/shell/components/AppIssues.d.ts +10 -0
  669. package/dist/client/copy/shell/components/AppIssues.js +9 -0
  670. package/dist/client/copy/shell/components/Crumbs.d.ts +7 -0
  671. package/dist/client/copy/shell/components/Crumbs.js +17 -0
  672. package/dist/client/copy/shell/components/Dropdown.d.ts +3 -0
  673. package/dist/client/copy/shell/components/Dropdown.js +5 -0
  674. package/dist/client/copy/shell/components/ErrorBoundary.d.ts +4 -0
  675. package/dist/client/copy/shell/components/ErrorBoundary.js +6 -0
  676. package/dist/client/copy/shell/components/FavoriteStar.d.ts +4 -0
  677. package/dist/client/copy/shell/components/FavoriteStar.js +6 -0
  678. package/dist/client/copy/shell/components/MobileNavDrawer.d.ts +4 -0
  679. package/dist/client/copy/shell/components/MobileNavDrawer.js +12 -0
  680. package/dist/client/copy/shell/components/OverflowMenu.d.ts +3 -0
  681. package/dist/client/copy/shell/components/OverflowMenu.js +10 -0
  682. package/dist/client/copy/shell/components/Palette.d.ts +15 -0
  683. package/dist/client/copy/shell/components/Palette.js +18 -0
  684. package/dist/client/copy/shell/components/Prefs.d.ts +4 -0
  685. package/dist/client/copy/shell/components/Prefs.js +11 -0
  686. package/dist/client/copy/shell/components/Prompt.d.ts +1 -0
  687. package/dist/client/copy/shell/components/Prompt.js +3 -0
  688. package/dist/client/copy/shell/components/Rooms.d.ts +6 -0
  689. package/dist/client/copy/shell/components/Rooms.js +8 -0
  690. package/dist/client/copy/shell/components/Sidebar.d.ts +7 -0
  691. package/dist/client/copy/shell/components/Sidebar.js +9 -0
  692. package/dist/client/copy/shell/components/Skeleton.d.ts +5 -0
  693. package/dist/client/copy/shell/components/Skeleton.js +7 -0
  694. package/dist/client/copy/shell/components/TopNav.d.ts +4 -0
  695. package/dist/client/copy/shell/components/TopNav.js +12 -0
  696. package/dist/client/copy/shell/components/Tour.d.ts +4 -0
  697. package/dist/client/copy/shell/components/Tour.js +6 -0
  698. package/dist/client/copy/shell/components/newMenuModel.d.ts +3 -0
  699. package/dist/client/copy/shell/components/newMenuModel.js +5 -0
  700. package/dist/client/copy/shell/components/onDemand.d.ts +3 -0
  701. package/dist/client/copy/shell/components/onDemand.js +5 -0
  702. package/dist/client/copy/shell/components/sidebarModel.d.ts +3 -0
  703. package/dist/client/copy/shell/components/sidebarModel.js +5 -0
  704. package/dist/client/copy/shell/connectionList.d.ts +6 -0
  705. package/dist/client/copy/shell/connectionList.js +8 -0
  706. package/dist/client/copy/shell/core.d.ts +16 -0
  707. package/dist/client/copy/shell/core.js +18 -0
  708. package/dist/client/copy/shell/palette.d.ts +6 -0
  709. package/dist/client/copy/shell/palette.js +8 -0
  710. package/dist/client/copy/shell/prompt.d.ts +1 -0
  711. package/dist/client/copy/shell/prompt.js +3 -0
  712. package/dist/client/copy/shell/requestIdentity.d.ts +9 -0
  713. package/dist/client/copy/shell/requestIdentity.js +11 -0
  714. package/dist/client/copy/shell/resourceRequests.d.ts +4 -0
  715. package/dist/client/copy/shell/resourceRequests.js +6 -0
  716. package/dist/client/copy/shell/sessionIdentity.d.ts +11 -0
  717. package/dist/client/copy/shell/sessionIdentity.js +13 -0
  718. package/dist/client/copy/shell/sessionLifecycle.d.ts +5 -0
  719. package/dist/client/copy/shell/sessionLifecycle.js +7 -0
  720. package/dist/client/copy/shell/startup.d.ts +5 -0
  721. package/dist/client/copy/shell/startup.js +7 -0
  722. package/dist/client/copy/shell/theme.d.ts +5 -0
  723. package/dist/client/copy/shell/theme.js +14 -0
  724. package/dist/client/copy/shell/toast.d.ts +3 -0
  725. package/dist/client/copy/shell/toast.js +5 -0
  726. package/dist/client/copy/shell/updateAttempts.d.ts +6 -0
  727. package/dist/client/copy/shell/updateAttempts.js +8 -0
  728. package/dist/client/copy/shell/visualTheme.d.ts +4 -0
  729. package/dist/client/copy/shell/visualTheme.js +6 -0
  730. package/dist/client/copy/workbench/clauses.d.ts +3 -0
  731. package/dist/client/copy/workbench/clauses.js +5 -0
  732. package/dist/client/copy/workbench/components/ApiOperations.d.ts +21 -0
  733. package/dist/client/copy/workbench/components/ApiOperations.js +23 -0
  734. package/dist/client/copy/workbench/components/Composer.d.ts +105 -0
  735. package/dist/client/copy/workbench/components/Composer.js +92 -0
  736. package/dist/client/copy/workbench/components/Diagram.d.ts +56 -0
  737. package/dist/client/copy/workbench/components/Diagram.js +46 -0
  738. package/dist/client/copy/workbench/components/Export.d.ts +26 -0
  739. package/dist/client/copy/workbench/components/Export.js +25 -0
  740. package/dist/client/copy/workbench/components/HelpPanel.d.ts +10 -0
  741. package/dist/client/copy/workbench/components/HelpPanel.js +12 -0
  742. package/dist/client/copy/workbench/components/History.d.ts +11 -0
  743. package/dist/client/copy/workbench/components/History.js +10 -0
  744. package/dist/client/copy/workbench/components/Landing.d.ts +5 -0
  745. package/dist/client/copy/workbench/components/Landing.js +7 -0
  746. package/dist/client/copy/workbench/components/SchemaExport.d.ts +24 -0
  747. package/dist/client/copy/workbench/components/SchemaExport.js +20 -0
  748. package/dist/client/copy/workbench/components/Summary.d.ts +28 -0
  749. package/dist/client/copy/workbench/components/Summary.js +24 -0
  750. package/dist/client/copy/workbench/components/ThemeLab.d.ts +25 -0
  751. package/dist/client/copy/workbench/components/ThemeLab.js +27 -0
  752. package/dist/client/copy/workbench/components/WorkPanel.d.ts +12 -0
  753. package/dist/client/copy/workbench/components/WorkPanel.js +14 -0
  754. package/dist/client/copy/workbench/composer.d.ts +36 -0
  755. package/dist/client/copy/workbench/composer.js +32 -0
  756. package/dist/client/copy/workbench/composerEntry.d.ts +4 -0
  757. package/dist/client/copy/workbench/composerEntry.js +6 -0
  758. package/dist/client/copy/workbench/export.d.ts +8 -0
  759. package/dist/client/copy/workbench/export.js +7 -0
  760. package/dist/client/copy/workbench/filterbar.d.ts +6 -0
  761. package/dist/client/copy/workbench/filterbar.js +8 -0
  762. package/dist/client/copy/workbench/handoff.d.ts +20 -0
  763. package/dist/client/copy/workbench/handoff.js +19 -0
  764. package/dist/client/copy/workbench/help.d.ts +6 -0
  765. package/dist/client/copy/workbench/help.js +8 -0
  766. package/dist/client/copy/workbench/history.d.ts +3 -0
  767. package/dist/client/copy/workbench/history.js +5 -0
  768. package/dist/client/copy/workbench/schemaexport.d.ts +5 -0
  769. package/dist/client/copy/workbench/schemaexport.js +7 -0
  770. package/dist/client/copy/workbench/tour.d.ts +22 -0
  771. package/dist/client/copy/workbench/tour.js +24 -0
  772. package/dist/client/copy/workbench/views.d.ts +6 -0
  773. package/dist/client/copy/workbench/views.js +8 -0
  774. package/dist/client/core.d.ts +312 -0
  775. package/dist/client/core.js +1067 -0
  776. package/dist/client/customThemes.css +43 -0
  777. package/dist/client/dashboard.d.ts +16 -0
  778. package/dist/client/dashboard.js +35 -0
  779. package/dist/client/deeplink.d.ts +64 -0
  780. package/dist/client/deeplink.js +384 -0
  781. package/dist/client/delete.d.ts +8 -0
  782. package/dist/client/delete.js +35 -0
  783. package/dist/client/density.d.ts +8 -0
  784. package/dist/client/density.js +102 -0
  785. package/dist/client/devtoolsEventClient.d.ts +27 -0
  786. package/dist/client/devtoolsEventClient.js +32 -0
  787. package/dist/client/documents.d.ts +9 -0
  788. package/dist/client/documents.js +23 -0
  789. package/dist/client/dom.d.ts +36 -0
  790. package/dist/client/dom.js +232 -0
  791. package/dist/client/draftRecovery.d.ts +16 -0
  792. package/dist/client/draftRecovery.js +56 -0
  793. package/dist/client/export.d.ts +59 -0
  794. package/dist/client/export.js +217 -0
  795. package/dist/client/features.css +2187 -0
  796. package/dist/client/fieldErrors.d.ts +27 -0
  797. package/dist/client/fieldErrors.js +20 -0
  798. package/dist/client/fileSource.d.ts +10 -0
  799. package/dist/client/fileSource.js +115 -0
  800. package/dist/client/filterbar.d.ts +87 -0
  801. package/dist/client/filterbar.js +168 -0
  802. package/dist/client/firstPaint.d.ts +26 -0
  803. package/dist/client/firstPaint.js +102 -0
  804. package/dist/client/fonts/Barlow-OFL.txt +125 -0
  805. package/dist/client/fonts/IBMPlexMono-OFL.txt +104 -0
  806. package/dist/client/fonts/Inter-OFL.txt +92 -0
  807. package/dist/client/fonts/barlow-400.woff2 +0 -0
  808. package/dist/client/fonts/barlow-600.woff2 +0 -0
  809. package/dist/client/fonts/barlow-semi-condensed-700.woff2 +0 -0
  810. package/dist/client/fonts/ibm-plex-mono-400.woff2 +0 -0
  811. package/dist/client/fonts/ibm-plex-mono-500.woff2 +0 -0
  812. package/dist/client/fonts/inter-latin.woff2 +0 -0
  813. package/dist/client/formControls.css +5 -0
  814. package/dist/client/handoff.d.ts +47 -0
  815. package/dist/client/handoff.js +138 -0
  816. package/dist/client/help.css +151 -0
  817. package/dist/client/help.d.ts +20 -0
  818. package/dist/client/help.js +103 -0
  819. package/dist/client/helpContent.d.ts +95 -0
  820. package/dist/client/helpContent.js +661 -0
  821. package/dist/client/history.d.ts +10 -0
  822. package/dist/client/history.js +181 -0
  823. package/dist/client/historyToken.d.ts +18 -0
  824. package/dist/client/historyToken.js +27 -0
  825. package/dist/client/iconWeight.d.ts +16 -0
  826. package/dist/client/iconWeight.js +44 -0
  827. package/dist/client/index.html +244 -0
  828. package/dist/client/insert.d.ts +50 -0
  829. package/dist/client/insert.js +269 -0
  830. package/dist/client/kit.d.ts +7 -0
  831. package/dist/client/kit.js +1 -0
  832. package/dist/client/layoutDraftRecovery.d.ts +8 -0
  833. package/dist/client/layoutDraftRecovery.js +33 -0
  834. package/dist/client/ledgerLook.css +32 -0
  835. package/dist/client/liveReads.d.ts +23 -0
  836. package/dist/client/liveReads.js +38 -0
  837. package/dist/client/liveState.d.ts +94 -0
  838. package/dist/client/liveState.js +212 -0
  839. package/dist/client/locale.d.ts +141 -0
  840. package/dist/client/locale.js +0 -0
  841. package/dist/client/lumenLook.css +1867 -0
  842. package/dist/client/menu.d.ts +49 -0
  843. package/dist/client/menu.js +131 -0
  844. package/dist/client/menuScope.d.ts +6 -0
  845. package/dist/client/menuScope.js +4 -0
  846. package/dist/client/messages.d.ts +240 -0
  847. package/dist/client/messages.js +370 -0
  848. package/dist/client/motionStill.d.ts +1 -0
  849. package/dist/client/motionStill.js +17 -0
  850. package/dist/client/navigationHold.d.ts +37 -0
  851. package/dist/client/navigationHold.js +503 -0
  852. package/dist/client/nested.d.ts +8 -0
  853. package/dist/client/nested.js +26 -0
  854. package/dist/client/ownWrites.d.ts +33 -0
  855. package/dist/client/ownWrites.js +76 -0
  856. package/dist/client/page.css +4052 -0
  857. package/dist/client/page.d.ts +21 -0
  858. package/dist/client/page.js +187 -0
  859. package/dist/client/pagemarks.d.ts +32 -0
  860. package/dist/client/pagemarks.js +98 -0
  861. package/dist/client/palette.d.ts +35 -0
  862. package/dist/client/palette.js +357 -0
  863. package/dist/client/partsLook.css +1047 -0
  864. package/dist/client/peek.d.ts +11 -0
  865. package/dist/client/peek.js +51 -0
  866. package/dist/client/peekpanel.d.ts +26 -0
  867. package/dist/client/peekpanel.js +121 -0
  868. package/dist/client/pendingWork.d.ts +19 -0
  869. package/dist/client/pendingWork.js +36 -0
  870. package/dist/client/pins.d.ts +24 -0
  871. package/dist/client/pins.js +97 -0
  872. package/dist/client/prefs.d.ts +3 -0
  873. package/dist/client/prefs.js +32 -0
  874. package/dist/client/prompt.d.ts +27 -0
  875. package/dist/client/prompt.js +61 -0
  876. package/dist/client/readGathering.d.ts +4 -0
  877. package/dist/client/readGathering.js +23 -0
  878. package/dist/client/recordCompose.d.ts +11 -0
  879. package/dist/client/recordCompose.js +69 -0
  880. package/dist/client/recordDrafts.d.ts +40 -0
  881. package/dist/client/recordDrafts.js +57 -0
  882. package/dist/client/recordEditValidation.d.ts +12 -0
  883. package/dist/client/recordEditValidation.js +52 -0
  884. package/dist/client/recordIntent.d.ts +6 -0
  885. package/dist/client/recordIntent.js +15 -0
  886. package/dist/client/recordPress.d.ts +12 -0
  887. package/dist/client/recordPress.js +84 -0
  888. package/dist/client/recordSource.d.ts +6 -0
  889. package/dist/client/recordSource.js +15 -0
  890. package/dist/client/recordTrail.d.ts +77 -0
  891. package/dist/client/recordTrail.js +101 -0
  892. package/dist/client/recordWriteRefresh.d.ts +74 -0
  893. package/dist/client/recordWriteRefresh.js +284 -0
  894. package/dist/client/relatedRows.d.ts +4 -0
  895. package/dist/client/relatedRows.js +24 -0
  896. package/dist/client/requestIdentity.d.ts +36 -0
  897. package/dist/client/requestIdentity.js +97 -0
  898. package/dist/client/resourceRequests.d.ts +7 -0
  899. package/dist/client/resourceRequests.js +32 -0
  900. package/dist/client/roleLabels.d.ts +7 -0
  901. package/dist/client/roleLabels.js +24 -0
  902. package/dist/client/rowEditing.d.ts +15 -0
  903. package/dist/client/rowEditing.js +36 -0
  904. package/dist/client/sageLook.css +242 -0
  905. package/dist/client/savedPages.d.ts +15 -0
  906. package/dist/client/savedPages.js +123 -0
  907. package/dist/client/schemaexport.d.ts +14 -0
  908. package/dist/client/schemaexport.js +182 -0
  909. package/dist/client/sessionIdentity.d.ts +39 -0
  910. package/dist/client/sessionIdentity.js +255 -0
  911. package/dist/client/sessionLifecycle.d.ts +33 -0
  912. package/dist/client/sessionLifecycle.js +276 -0
  913. package/dist/client/shellHost.d.ts +70 -0
  914. package/dist/client/shellHost.js +92 -0
  915. package/dist/client/shellMain.d.ts +8 -0
  916. package/dist/client/shellMode.d.ts +433 -0
  917. package/dist/client/shellMode.js +68 -0
  918. package/dist/client/shellStart.d.ts +5 -0
  919. package/dist/client/shellStart.js +54 -0
  920. package/dist/client/shells.d.ts +123 -0
  921. package/dist/client/shells.js +1 -0
  922. package/dist/client/sql.css +139 -0
  923. package/dist/client/startup.d.ts +8 -0
  924. package/dist/client/startup.js +85 -0
  925. package/dist/client/startupHold.d.ts +10 -0
  926. package/dist/client/startupHold.js +73 -0
  927. package/dist/client/structure.css +1296 -0
  928. package/dist/client/style.css +3526 -0
  929. package/dist/client/styleImports.d.ts +3 -0
  930. package/dist/client/surfaces.d.ts +18 -0
  931. package/dist/client/surfaces.js +27 -0
  932. package/dist/client/surfacesLook.css +88 -0
  933. package/dist/client/template.d.ts +75 -0
  934. package/dist/client/template.js +403 -0
  935. package/dist/client/theme.d.ts +14 -0
  936. package/dist/client/theme.js +112 -0
  937. package/dist/client/themeFamilies.css +788 -0
  938. package/dist/client/thmenu.d.ts +12 -0
  939. package/dist/client/thmenu.js +94 -0
  940. package/dist/client/toast.d.ts +7 -0
  941. package/dist/client/toast.js +117 -0
  942. package/dist/client/tour.d.ts +8 -0
  943. package/dist/client/tour.js +176 -0
  944. package/dist/client/transport.d.ts +2 -0
  945. package/dist/client/transport.js +13 -0
  946. package/dist/client/typography.d.ts +4 -0
  947. package/dist/client/typography.js +51 -0
  948. package/dist/client/uiBridge.d.ts +57 -0
  949. package/dist/client/uiBridge.js +30 -0
  950. package/dist/client/updateAttempts.d.ts +46 -0
  951. package/dist/client/updateAttempts.js +131 -0
  952. package/dist/client/url.d.ts +74 -0
  953. package/dist/client/url.js +388 -0
  954. package/dist/client/views.d.ts +19 -0
  955. package/dist/client/views.js +133 -0
  956. package/dist/client/visualTheme.d.ts +62 -0
  957. package/dist/client/visualTheme.js +502 -0
  958. package/dist/client/visualThemes.css +421 -0
  959. package/dist/client/workshopLook.css +126 -0
  960. package/dist/client/write.d.ts +100 -0
  961. package/dist/client/write.js +882 -0
  962. package/dist/client/writePaths.d.ts +16 -0
  963. package/dist/client/writePaths.js +35 -0
  964. package/dist/client/yesNoRule.d.ts +12 -0
  965. package/dist/client/yesNoRule.js +39 -0
  966. package/dist/clientFiles.d.ts +11 -4
  967. package/dist/clientFiles.js +16 -12
  968. package/dist/vite.d.ts +136 -0
  969. package/dist/vite.js +571 -0
  970. package/package.json +130 -3
@@ -0,0 +1,661 @@
1
+ /**
2
+ * What the query-language panel says: the grammar, and examples built from the
3
+ * connected schema. Loaded with the panel (components/HelpPanel.tsx), the first
4
+ * time it opens; help.js, which binds `?` and the menu entries, is all the
5
+ * first page carries.
6
+ */
7
+ import { $, api, columnKind, labelColumn, looksLikeDateColumn, primaryKey, quote, state } from './core.js';
8
+ import { say } from './copy/help/helpContent.js';
9
+ /* Enough rows to see whether a column is categorical — two distinct values out
10
+ of five says `status`, five out of five says `reference` — and few enough
11
+ that the request costs nothing on a table with a million rows in it. */
12
+ const SAMPLE_ROWS = 5;
13
+ /* ---------- schema reading ----------
14
+
15
+ Mirrors of shared/schema.ts, the way core.js already mirrors `labelColumn`.
16
+ The client cannot import the TypeScript directly and there is no build step
17
+ to compile it, so the rule is the one core.js follows: mirror the small
18
+ derived helpers, and never let a mirror decide anything the server has
19
+ already decided. */
20
+ /* Was a third copy of the date test, with the same name pattern and a
21
+ narrower type test: `/char|text|varchar|string/` rather than the shared
22
+ classifier, so a `uuid`, `json`, `enum` or `clob` column named `created_at`
23
+ was a date to the server and to the query bar and not to the examples on
24
+ this page. The classifier is one function; asking it is cheaper than
25
+ keeping a copy honest. */
26
+ const isDate = (column) => looksLikeDateColumn(column);
27
+ const isNumber = (column) => columnKind(column.type) === 'number';
28
+ const isText = (column) => columnKind(column.type) === 'text';
29
+ /**
30
+ * Forward hops worth putting in an example.
31
+ *
32
+ * Two exclusions:
33
+ *
34
+ * - a composite key, whose hop name is its columns joined with `+`. The bar
35
+ * does take `invoice_id+line_no.sku`, but a two-column key is not what
36
+ * somebody meeting the dot for the first time should be reading — the
37
+ * point of the example is that a dot follows a reference, and a `+` in the
38
+ * middle of it is a second thing to explain before the first one lands.
39
+ * - two keys sharing a hop name, which `resolvePath` refuses as ambiguous
40
+ * rather than guessing. Emitting one would be emitting an error.
41
+ */
42
+ function hops(schema, tableId) {
43
+ const forward = schema.foreignKeys.filter((fk) => fk.from.table === tableId && fk.from.columns.length === 1);
44
+ const counts = new Map();
45
+ for (const fk of forward)
46
+ counts.set(fk.from.columns[0], (counts.get(fk.from.columns[0]) ?? 0) + 1);
47
+ const incoming = (id) => schema.foreignKeys.filter((fk) => fk.to.table === id).length;
48
+ return (forward
49
+ .filter((fk) => counts.get(fk.from.columns[0]) === 1)
50
+ .map((fk) => ({ name: fk.from.columns[0], target: fk.to.table }))
51
+ /* Ordered here rather than taken as introspection left it. SQLite's
52
+ `PRAGMA foreign_key_list` hands back the *last* declared key first, so
53
+ the unordered version picked `duplicate_of_id` out of a ticket table
54
+ with nine references on it — a legal walk into "the ticket this one
55
+ duplicates", which is nobody's first question.
56
+
57
+ A self-reference goes last, and otherwise the most-pointed-at table
58
+ wins: the table half the schema references is the one the schema is
59
+ about, and a walk into it is a walk somebody recognises. */
60
+ .sort((a, b) => (a.target === tableId ? 1 : 0) - (b.target === tableId ? 1 : 0) ||
61
+ incoming(b.target) - incoming(a.target) ||
62
+ a.name.localeCompare(b.name)));
63
+ }
64
+ const tableById = (schema, id) => schema.tables.find((t) => t.id === id);
65
+ /* ---------- values ----------
66
+
67
+ Real values, from a handful of real rows. `status = open` teaches more than
68
+ `status = <value>`, and — the part that matters — it is a link that returns
69
+ rows when clicked, because the value came out of the table it filters. */
70
+ /* Words the clause scanner will take as clauses wherever they appear.
71
+ `CLAUSE_RE` runs over the raw text before anything knows about quotes, so a
72
+ status of "order by" would be read as a sort clause and the example would
73
+ fail. Such a value is skipped rather than emitted and hoped for. */
74
+ const RESERVED = /(^|\s)(filter|where|show|select|sort|order|by|limit|and|or|not|is|in|like|contains|startswith|endswith|asc|desc)(\s|$)/i;
75
+ /** Whether a sampled value can be written into a query as a literal. */
76
+ function usable(value) {
77
+ if (value === null || value === undefined || typeof value === 'object')
78
+ return false;
79
+ const text = String(value);
80
+ /* Long values make an unreadable example, and a quote inside one has no
81
+ escape in this grammar — `unquoteValue` strips the outer pair and nothing
82
+ else, so the value would end mid-word. */
83
+ return text !== '' && text.length <= 24 && !/["'\n]/.test(text) && !RESERVED.test(text);
84
+ }
85
+ /* A comma inside a value breaks an `in` list and only an `in` list: the list
86
+ is split on commas before anything looks at the quotes around them. */
87
+ const listSafe = (value) => !value.includes(',');
88
+ /**
89
+ * A sampled value, written the way someone would type it.
90
+ *
91
+ * The one rewrite is a flag: SQLite has no boolean type, so `is_urgent` comes
92
+ * back as 1 and 0, and `is_urgent = 0` is an example that needs the column's
93
+ * storage explained before it teaches anything. The compiler coerces `false`
94
+ * to whatever the column actually holds — that is the whole point of it
95
+ * holding the schema — so the readable form is also the correct one.
96
+ */
97
+ function literal(column, value) {
98
+ const flag = /bool/i.test(column.type ?? '') || /^(is|has)_/i.test(column.name);
99
+ if (flag && /^(0|1|true|false)$/i.test(value))
100
+ return /^(1|true)$/i.test(value) ? 'true' : 'false';
101
+ return quote(value);
102
+ }
103
+ function valuesOf(rows, column) {
104
+ const seen = [];
105
+ for (const row of rows ?? []) {
106
+ const value = row?.[column];
107
+ if (!usable(value))
108
+ continue;
109
+ if (!seen.includes(String(value)))
110
+ seen.push(String(value));
111
+ }
112
+ return seen;
113
+ }
114
+ /** A round number below the smallest value seen, so `>=` cannot miss. */
115
+ function roundDown(n) {
116
+ if (!Number.isFinite(n) || n <= 0)
117
+ return null;
118
+ const magnitude = 10 ** Math.floor(Math.log10(n));
119
+ return Math.floor(n / magnitude) * magnitude;
120
+ }
121
+ /* ---------- choosing what to talk about ---------- */
122
+ /**
123
+ * The table the examples are mostly about.
124
+ *
125
+ * A hub with outgoing references and a readable label column, because that is
126
+ * the table where every part of the language has something to say: it has
127
+ * columns worth filtering, a reference worth walking, and a name worth
128
+ * showing. Picking the first table alphabetically gets you `address` on a
129
+ * schema whose story is `sales_order`.
130
+ *
131
+ * Views rank below tables — a view is someone's saved answer, and the first
132
+ * thing a newcomer should see is the shape of the data.
133
+ */
134
+ function rank(schema, table) {
135
+ const out = Math.min(hops(schema, table.id).length, 3);
136
+ const incoming = Math.min(schema.foreignKeys.filter((fk) => fk.to.table === table.id).length, 6);
137
+ const label = labelColumn(table);
138
+ const named = label && !primaryKey(table).includes(label);
139
+ /* Text that is neither a key nor a foreign key: the columns somebody would
140
+ actually filter on. Without this the winner on the demo schema was
141
+ `invoice_line`, a junction table whose every column is a key — a table
142
+ with plenty of edges and nothing to say about any of them. */
143
+ const readable = table.columns.some((c) => isText(c) && !c.primaryKey && !c.references && !isDate(c));
144
+ return out * 3 + incoming + (named ? 4 : 0) + (readable ? 4 : 0) + (table.columns.some(isDate) ? 2 : 0) - (table.isView ? 8 : 0);
145
+ }
146
+ /**
147
+ * The table an example should be about.
148
+ *
149
+ * @param {{ tables: import('@mistriwork/engine/shared/schema.js').TableMeta[] }} schema
150
+ * @param {(table: import('@mistriwork/engine/shared/schema.js').TableMeta) => number} [extra]
151
+ * An extra score, so a caller can prefer tables that suit its own example —
152
+ * typed because the default takes no arguments and every caller passes one.
153
+ */
154
+ function bestTable(schema, extra = () => 0) {
155
+ let best = null;
156
+ let bestScore = -Infinity;
157
+ for (const table of schema.tables) {
158
+ const score = rank(schema, table) + extra(table);
159
+ // Ties break on the earlier table, so the same schema always produces the
160
+ // same examples — an example that moves between reloads reads as a bug.
161
+ if (score > bestScore) {
162
+ best = table;
163
+ bestScore = score;
164
+ }
165
+ }
166
+ return best;
167
+ }
168
+ /**
169
+ * The deepest readable path out of a table, up to two hops.
170
+ *
171
+ * Two rather than one wherever the graph allows, because one hop is easy to
172
+ * read as a join column and two is unmistakably a walk. The last segment has
173
+ * to be a label — `customer_id.party_id.display_name` is a sentence,
174
+ * `customer_id.party_id.id` is a number nobody asked for.
175
+ */
176
+ function bestPath(schema, tableId) {
177
+ let best = null;
178
+ for (const first of hops(schema, tableId)) {
179
+ const target = tableById(schema, first.target);
180
+ if (!target)
181
+ continue;
182
+ const label = labelColumn(target);
183
+ if (label)
184
+ best = best ?? { path: `${first.name}.${label}`, hops: 1, table: target.id };
185
+ for (const second of hops(schema, target.id)) {
186
+ // A path that returns to where it started says nothing about the graph.
187
+ if (second.target === tableId || second.target === target.id)
188
+ continue;
189
+ const further = tableById(schema, second.target);
190
+ const deep = further && labelColumn(further);
191
+ if (!deep)
192
+ continue;
193
+ const column = further.columns.find((c) => c.name === deep);
194
+ if (column && !isText(column))
195
+ continue;
196
+ return { path: `${first.name}.${second.name}.${deep}`, hops: 2, table: further.id };
197
+ }
198
+ }
199
+ return best;
200
+ }
201
+ /**
202
+ * The table the dot-walk example should start from.
203
+ *
204
+ * The hub if it has a path, because keeping every example on one table means
205
+ * the reader learns one schema rather than five. But a two-hop path is worth
206
+ * changing table for: one hop still reads as a join column, and two is
207
+ * unmistakably a walk.
208
+ */
209
+ function walkFrom(schema, hub) {
210
+ const pathAt = (table) => (table ? bestPath(schema, table.id) : null);
211
+ if (pathAt(hub)?.hops === 2)
212
+ return hub;
213
+ const deep = bestTable(schema, (t) => (bestPath(schema, t.id)?.hops === 2 ? 40 : 0));
214
+ if (pathAt(deep)?.hops === 2)
215
+ return deep;
216
+ if (pathAt(hub))
217
+ return hub;
218
+ const any = bestTable(schema, (t) => (bestPath(schema, t.id) ? 40 : 0));
219
+ return pathAt(any) ? any : null;
220
+ }
221
+ /** The column a filter example should use: the most categorical one there is. */
222
+ function filterColumn(table, rows) {
223
+ /* A numeric foreign key is excluded on purpose. `customer_id = 6` is a
224
+ legal filter and a terrible example: reaching a row by the number in its
225
+ key column is the thing dot-walking exists to replace. A *text* key —
226
+ `currency_code = AUD` — is a code someone can read, and stays. */
227
+ const candidates = table.columns.filter((c) => !c.primaryKey && !isDate(c) && (isText(c) || (isNumber(c) && !c.references)));
228
+ if (!candidates.length)
229
+ return null;
230
+ if (rows?.length) {
231
+ /* Fewest distinct values wins: over five sampled rows `status` shows two
232
+ and `reference` shows five, which is the difference between a filter
233
+ that reads like a question and one that reads like a key lookup.
234
+ Text breaks the tie, because `status = open` says what it means and
235
+ `active = 1` needs the schema open beside it.
236
+
237
+ An unfilled column is charged for every row it has nothing in. A column
238
+ that is null four times out of five has one distinct value and would
239
+ otherwise win outright — which is how `external_ref = EXT-10913`, an
240
+ external system's identifier for one row, came to be the first thing
241
+ the landing page taught. */
242
+ const cost = (c) => c.values.length + (rows.length - c.filled) + (isText(c.column) ? 0 : 2);
243
+ const scored = candidates
244
+ .map((column) => ({
245
+ column,
246
+ values: valuesOf(rows, column.name),
247
+ filled: rows.filter((row) => usable(row?.[column.name])).length,
248
+ }))
249
+ .filter((c) => c.values.length)
250
+ .sort((a, b) => cost(a) - cost(b) || a.values[0].length - b.values[0].length);
251
+ if (scored.length)
252
+ return scored[0];
253
+ }
254
+ const named = candidates.find((c) => /status|state|type|kind|category|code|active|priority/i.test(c.name));
255
+ return { column: named ?? candidates[0], values: [] };
256
+ }
257
+ /** A column that is null somewhere in the sample, so `is empty` finds rows. */
258
+ function nullableColumn(table, rows) {
259
+ const optional = table.columns.filter((c) => !c.primaryKey && c.nullable !== false);
260
+ if (!optional.length)
261
+ return null;
262
+ const empty = optional.find((c) => (rows ?? []).some((row) => row?.[c.name] === null));
263
+ return empty ?? optional[0];
264
+ }
265
+ /**
266
+ * A column that is never null, for the second half of an `and`.
267
+ *
268
+ * The point of that example is the word `and`, so the condition beside it has
269
+ * to be one that cannot change the answer: `is not empty` on a NOT NULL column
270
+ * is true of every row, which leaves the example returning exactly what its
271
+ * first condition returned. Pairing two selective conditions instead gave a
272
+ * demonstration of `and` that came back with nothing in it.
273
+ */
274
+ function requiredColumn(table, rows) {
275
+ const declared = table.columns.filter((c) => c.nullable === false && !c.primaryKey);
276
+ if (declared.length)
277
+ return declared[0];
278
+ return (table.columns.find((c) => !c.primaryKey && (rows ?? []).length && (rows ?? []).every((row) => row?.[c.name] !== null && row?.[c.name] !== undefined)) ?? null);
279
+ }
280
+ const dateColumn = (table) => table.columns.find(isDate);
281
+ /**
282
+ * A date window wide enough to reach the newest row the sample saw.
283
+ *
284
+ * `last 30 days` on a database whose most recent row is a year old is a
285
+ * correct query that returns nothing, and nothing is what a beginner reads as
286
+ * "this feature does not work". The window is widened to the first phrase that
287
+ * covers the data — still a phrase somebody would type, not a computed date.
288
+ */
289
+ const WINDOWS = [
290
+ { label: 'last 30 days', days: 30 },
291
+ { label: 'last 90 days', days: 90 },
292
+ { label: 'last 6 months', days: 183 },
293
+ { label: 'last 12 months', days: 366 },
294
+ { label: 'last 24 months', days: 731 },
295
+ { label: 'last 60 months', days: 1827 },
296
+ ];
297
+ function dateWindowFor(values, now) {
298
+ const newest = (values ?? [])
299
+ .map((value) => new Date(String(value)).getTime())
300
+ .filter((t) => Number.isFinite(t))
301
+ .sort((a, b) => b - a)[0];
302
+ if (newest === undefined)
303
+ return WINDOWS[0].label;
304
+ const age = (now.getTime() - newest) / 86_400_000;
305
+ return (WINDOWS.find((w) => w.days >= age) ?? WINDOWS[WINDOWS.length - 1]).label;
306
+ }
307
+ /* ---------- the generator ---------- */
308
+ /**
309
+ * Every example the panel and the empty state can offer, from a schema and
310
+ * (optionally) a few sampled rows.
311
+ *
312
+ * A pure function of its arguments, which is what makes it testable without a
313
+ * browser: the fixtures in test/help.test.ts include a schema with no foreign
314
+ * keys, which is the shape that would otherwise emit a dot-walk example that
315
+ * errors the moment someone clicked it.
316
+ *
317
+ * Keys are absent rather than empty when the schema cannot support them. A
318
+ * caller that renders whatever it finds degrades on its own.
319
+ *
320
+ * @typedef {{query: string, caption: string}} Example
321
+ * @typedef {{
322
+ * sampleTable: string | null,
323
+ * examples: Record<string, Example>,
324
+ * starters: Array<Example & {key: string}>,
325
+ * }} Examples
326
+ *
327
+ * @param {any} schema
328
+ * @param {Record<string, Array<Record<string, unknown>>>} [samples]
329
+ * @param {Date} [now] injected, so a date window is testable to the day
330
+ * @returns {Examples}
331
+ */
332
+ export function buildExamples(schema, samples = {}, now = new Date()) {
333
+ /** @type {Examples} */
334
+ const out = { sampleTable: null, examples: {}, starters: [] };
335
+ if (!schema?.tables?.length)
336
+ return out;
337
+ const hub = bestTable(schema);
338
+ if (!hub)
339
+ return out;
340
+ out.sampleTable = hub.id;
341
+ const rows = samples[hub.id] ?? [];
342
+ const examples = out.examples;
343
+ const add = (key, query, caption) => {
344
+ examples[key] = { query, caption };
345
+ };
346
+ add('table', hub.id, `every row in ${hub.name}`);
347
+ /* ---- filters ---- */
348
+ const chosen = filterColumn(hub, rows);
349
+ const column = chosen?.column;
350
+ const values = chosen?.values ?? [];
351
+ if (column && values.length) {
352
+ add('filter', `${hub.id} ${column.name} = ${literal(column, values[0])}`, 'a column, an operator, a value');
353
+ if (values.length > 1) {
354
+ add('or', `${hub.id} ${column.name} = ${literal(column, values[0])} or ${column.name} = ${literal(column, values[1])}`, 'either one');
355
+ const list = values.filter(listSafe).slice(0, 2);
356
+ if (list.length > 1) {
357
+ add('in', `${hub.id} ${column.name} in (${list.map((v) => literal(column, v)).join(', ')})`, 'the same thing, shorter');
358
+ }
359
+ }
360
+ }
361
+ else if (column) {
362
+ add('filter', `${hub.id} ${column.name} is not empty`, 'rows where the column is set');
363
+ }
364
+ const label = labelColumn(hub);
365
+ const labelValues = label ? valuesOf(rows, label) : [];
366
+ if (label && labelValues.length) {
367
+ /* Both of these are cut out of a value that is in the table, so both come
368
+ back with rows. A guessed word would not, and a filter that silently
369
+ matches nothing is the exact failure this language was built to avoid.
370
+
371
+ `contains` prefers what the sampled values have in common — `TKT-90`
372
+ out of TKT-9014 and TKT-9060 — because the shared part is the part
373
+ worth searching for. Where they share nothing, the first word of the
374
+ first value is a real word out of the column: `contains Harbour`. */
375
+ const shared = labelValues.length > 1 ? commonPrefix(labelValues).trim() : '';
376
+ const word = shared.length >= 3 ? shared : labelValues[0].split(/\s+/)[0];
377
+ const front = labelValues[0].slice(0, 3).trim();
378
+ if (word && !RESERVED.test(word))
379
+ add('contains', `${hub.id} ${label} contains ${quote(word)}`, 'anywhere in the text');
380
+ if (front.length >= 2 && front !== word && !RESERVED.test(front)) {
381
+ add('startswith', `${hub.id} ${label} startswith ${quote(front)}`, 'at the front of it — endswith too');
382
+ }
383
+ }
384
+ /* A quantity, not a key: `total >= 10000` is a question somebody might ask
385
+ and `customer_id >= 1` is arithmetic on an identifier. */
386
+ const numbers = hub.columns.filter((c) => isNumber(c) && !c.primaryKey && !c.references);
387
+ const number = numbers.find((c) => /total|amount|price|cost|qty|quantity|balance|limit|value/i.test(c.name)) ?? numbers[0];
388
+ /* Rounded down from the smallest value in the sample, so the comparison
389
+ cannot come back empty on the table it was built from. */
390
+ const floor = number ? roundDown(Math.min(...valuesOf(rows, number.name).map(Number).filter(Number.isFinite))) : null;
391
+ if (number && floor !== null)
392
+ add('compare', `${hub.id} ${number.name} >= ${floor}`, 'the ordering operators, on numbers and on dates');
393
+ const optional = nullableColumn(hub, rows);
394
+ if (optional)
395
+ add('empty', `${hub.id} ${optional.name} is empty`, 'nothing recorded — is not empty for the opposite');
396
+ const required = requiredColumn(hub, rows);
397
+ if (column && values.length && required && required.name !== column.name) {
398
+ const first = `${column.name} = ${literal(column, values[0])}`;
399
+ add('and', `${hub.id} ${first} and ${required.name} is not empty`, 'both conditions');
400
+ if (values.length > 1) {
401
+ add('brackets', `${hub.id} (${column.name} = ${literal(column, values[0])} or ${column.name} = ${literal(column, values[1])}) and ${required.name} is not empty`, 'or binds loosest, so brackets change the grouping');
402
+ }
403
+ }
404
+ /* ---- references ---- */
405
+ const walk = walkFrom(schema, hub);
406
+ const path = walk && bestPath(schema, walk.id);
407
+ if (walk && path) {
408
+ const shown = labelColumn(walk) ?? primaryKey(walk)[0] ?? walk.columns[0]?.name;
409
+ const hopped = path.hops === 2 ? say('twoTablesAlong') : say('onTheTableItPoints');
410
+ add('dotwalk', `${walk.id} show ${shown}, ${path.path}`, `a column ${hopped}`);
411
+ add('dotfilter', `${walk.id} ${path.path} is not empty`, 'filtering across the reference');
412
+ }
413
+ /* ---- projection, order, limit, dates ---- */
414
+ /* The columns a person would read a row by, not the first three declared:
415
+ a projection example whose point is `show id, customer_id, quote_id` has
416
+ demonstrated the keyword and taught nothing about the table. */
417
+ const readable = hub.columns.filter((c) => !c.references && (c.name === label || !c.primaryKey));
418
+ const shortlist = [...new Set([label, ...readable.map((c) => c.name)].filter(Boolean))].slice(0, 3);
419
+ if (shortlist.length > 1)
420
+ add('show', `${hub.id} show ${shortlist.join(', ')}`, 'only these columns, in this order');
421
+ const dated = dateColumn(hub) ? hub : schema.tables.find((t) => !t.isView && dateColumn(t));
422
+ const date = dated && dateColumn(dated);
423
+ if (date) {
424
+ add('sort', `${dated.id} sort ${date.name} desc limit 10`, 'the ten most recent');
425
+ // Only the sampled table has values to measure; anywhere else the window
426
+ // is the one people reach for first.
427
+ const phrase = dated.id === hub.id
428
+ ? dateWindowFor(rows.map((row) => row?.[date.name]), now)
429
+ : WINDOWS[0].label;
430
+ add('dates', `${dated.id} ${date.name} = ${phrase}`, 'a window, resolved to two real timestamps');
431
+ }
432
+ else if (label) {
433
+ add('sort', `${hub.id} sort ${label} limit 10`, 'ten rows, in order');
434
+ }
435
+ add('limit', `${hub.id} limit 5`, 'stop after five');
436
+ /* ---- the three for the empty state ----
437
+
438
+ A filter, a walk and an order: the three things the language does that a
439
+ list of tables cannot, in the order someone meets them. Anything the
440
+ schema cannot support is skipped rather than faked, and the bare table
441
+ name backfills — on a database with no foreign keys the landing page
442
+ offers three queries that work rather than two that do and one that
443
+ would have errored on the first click. */
444
+ for (const key of ['filter', 'dotwalk', 'sort', 'table']) {
445
+ if (examples[key] && out.starters.length < 3)
446
+ out.starters.push({ key, ...examples[key] });
447
+ }
448
+ return out;
449
+ }
450
+ function commonPrefix(values) {
451
+ let prefix = values[0];
452
+ for (const value of values.slice(1)) {
453
+ let i = 0;
454
+ while (i < prefix.length && prefix[i] === value[i])
455
+ i++;
456
+ prefix = prefix.slice(0, i);
457
+ }
458
+ return prefix;
459
+ }
460
+ /* ---------- sampled rows ---------- */
461
+ /* Keyed by connection as well as table: the same table name means a different
462
+ table on the next database, and examples built from the last one would be
463
+ quietly wrong. Promises rather than rows, so the panel and the empty state
464
+ opening together make one request. */
465
+ const sampled = new Map();
466
+ function sampleKey(tableId) {
467
+ return `${state.activeConnection ?? state.schema?.label ?? ''} ${tableId}`;
468
+ }
469
+ export function sampleRows(tableId) {
470
+ const key = sampleKey(tableId);
471
+ if (!sampled.has(key)) {
472
+ sampled.set(key, api('/api/run', { q: tableId, limit: SAMPLE_ROWS, count: 'none' })
473
+ .then((data) => data.rows ?? [])
474
+ /* An empty table, a permission error, a connection that dropped: the
475
+ examples fall back to the value-free forms rather than the panel
476
+ failing to open. */
477
+ .catch(() => []));
478
+ }
479
+ return sampled.get(key);
480
+ }
481
+ /* ---------- running an example ---------- */
482
+ /**
483
+ * Put the example in the bar and run it.
484
+ *
485
+ * Through the form rather than by navigating directly, for the reason
486
+ * history.js gives for the same move: the one submit handler in app.js decides
487
+ * what a query means, and a second caller deciding it separately is how the
488
+ * two start to disagree. Leaving the text in the bar is the point — the next
489
+ * thing to do with an example is edit it.
490
+ */
491
+ export function runExample(query) {
492
+ const input = $('query');
493
+ if (!input)
494
+ return;
495
+ input.value = query;
496
+ $('querybar').requestSubmit();
497
+ input.focus();
498
+ input.setSelectionRange(query.length, query.length);
499
+ }
500
+ /* ---------- the empty state ---------- */
501
+ /**
502
+ * Three runnable queries on the landing page.
503
+ *
504
+ * The empty state used to be a sentence and a diagram, which tells you the
505
+ * tool is about relationships and leaves you to guess the grammar. A diagram
506
+ * answers "what is in here"; these answer "what do I type".
507
+ */
508
+ /* ---------- the panel ---------- */
509
+ /**
510
+ * What each section says, and which generated examples belong under it.
511
+ *
512
+ * The grammar lines are fixed text and the examples are not: syntax is the
513
+ * same on every database, and what is worth filtering is not. Anything named
514
+ * here that the schema could not produce simply does not appear, which is why
515
+ * the keys are a list rather than a template with holes in it.
516
+ */
517
+ export const SECTIONS = [
518
+ {
519
+ title: say('startWithATable'),
520
+ note: say('theTableComesFirst'),
521
+ grammar: [['table', say('everyRowInASensible')]],
522
+ keys: ['table'],
523
+ },
524
+ {
525
+ title: say('common.filter'),
526
+ note: say('aConditionStraightAfter'),
527
+ grammar: [
528
+ ['column = value', say('alsoOperators')],
529
+ ['column contains text', say('anywhereInItWhatever')],
530
+ ['column startswith text', say('endswithToo')],
531
+ [say('columnLikeWh'), say('yourOwnWildcardsAny')],
532
+ ['column in (a, b)', say('anyOfThemNotInForNone')],
533
+ ['column between a and b', say('aRangeBothEnds')],
534
+ ['column is empty', say('nullIsNotEmpty')],
535
+ ['column = "two words"', say('quoteAValueWithSpaces')],
536
+ ],
537
+ keys: ['filter', 'contains', 'startswith', 'like', 'compare', 'empty', 'in', 'between'],
538
+ },
539
+ {
540
+ title: say('combine'),
541
+ note: say('andBindsTighterThan'),
542
+ grammar: [
543
+ [say('aAndB'), 'both'],
544
+ [say('aOrB'), 'either'],
545
+ ['(a or b) and c', 'grouped'],
546
+ ],
547
+ keys: ['and', 'or', 'brackets'],
548
+ },
549
+ {
550
+ title: say('walkAReference'),
551
+ note: say('aDotFollowsAForeign'),
552
+ grammar: [
553
+ ['reference.column', say('aColumnOnTheTable')],
554
+ ['reference.reference.column', say('twoTablesAlong')],
555
+ ],
556
+ keys: ['dotwalk', 'dotfilter'],
557
+ absent: say('thisDatabaseHasNoForeign'),
558
+ },
559
+ {
560
+ title: say('showOnlySomeColumns'),
561
+ note: say('showPicksTheColumns'),
562
+ grammar: [[say('showABC'), say('theseColumnsInThisOrder')]],
563
+ keys: ['show'],
564
+ },
565
+ {
566
+ title: say('sortAndLimit'),
567
+ note: say('orderByIsAccepted'),
568
+ grammar: [
569
+ ['sort column', 'ascending'],
570
+ ['sort column desc', 'descending'],
571
+ ['sort a, b desc', say('moreThanOne')],
572
+ ['limit 20', say('atMostThisMany')],
573
+ ],
574
+ keys: ['sort', 'limit'],
575
+ },
576
+ {
577
+ title: say('dates'),
578
+ note: say('aDatePhraseIsAWindow'),
579
+ grammar: [
580
+ ['today', 'yesterday, tomorrow'],
581
+ ['this week', say('lastWeekWeeksStart')],
582
+ ['this month', 'last month, this year, last year'],
583
+ ['this quarter', 'last quarter, next quarter'],
584
+ ['last 30 days', 'last 12 hours, last 6 weeks, last 3 months'],
585
+ ['next 7 days', say('theSameUnitsForwards')],
586
+ ['previous 30 days', say('theWindowJustBefore')],
587
+ ],
588
+ keys: ['dates'],
589
+ absent: say('noTableHereHasADate'),
590
+ },
591
+ {
592
+ /* Not generated from the schema, so no `keys` and nothing to be absent:
593
+ these work on every result in every database. They live here because
594
+ the alternative was a hint line under every table, and a permanent
595
+ instruction is a poor trade for the space it takes from the data. */
596
+ title: say('movingAroundAResult'),
597
+ note: say('tabIntoTheTable'),
598
+ /* `rooms`: where a section's keys apply, so the panel puts it first
599
+ there. `app`: shown in an App's keys-only panel as well. */
600
+ rooms: ['table'],
601
+ app: true,
602
+ grammar: [
603
+ ['↑ ↓ ← →', say('moveOneCell')],
604
+ ['Enter', say('openTheRecordForThatRow')],
605
+ ['Space', say('glanceAtThatRows')],
606
+ ['⌘C', say('copyTheCellUnder')],
607
+ [say('homeEnd'), say('firstAndLastColumn')],
608
+ ['Esc', say('backToTheQuery')],
609
+ ],
610
+ },
611
+ {
612
+ /* A record opened from a list steps through that list: the move a mail
613
+ reader's J and K make, and the arrows beside the record's name. */
614
+ title: say('steppingThroughAList'),
615
+ note: say('aRecordOpenedFromAList'),
616
+ rooms: ['row', 'page'],
617
+ app: true,
618
+ grammar: [
619
+ ['j', say('theNextRecordInTheList')],
620
+ ['k', say('thePreviousRecord')],
621
+ ['← →', say('theSameWithTheArrows')],
622
+ ],
623
+ },
624
+ {
625
+ /* Every shortcut the page itself binds, in the one place someone looks
626
+ for one. They were discoverable only by reading the source or by
627
+ pressing a key and seeing what happened — and `h` for home is the sort
628
+ of thing nobody guesses. A hint line under the header would cost the
629
+ space permanently; a section in the panel that answers "what can I
630
+ press" costs nothing until asked. */
631
+ title: say('keysThePageListens'),
632
+ note: say('singleKeysWorkWhen'),
633
+ grammar: [
634
+ ['h', say('homeTheSchemaYourWork')],
635
+ ['/', say('theQueryBar')],
636
+ ['⌘/', say('theQueryBarAsAPanel')],
637
+ ['t', say('theTableFilterInTheSidebar')],
638
+ ['⌘K', say('theCommandPaletteTables')],
639
+ ['⌘B', say('showOrHideTheTable')],
640
+ ['Backspace', say('backOneStepAlong')],
641
+ ['?', say('thisPanel')],
642
+ ['Esc', say('leaveTheFieldOrClose')],
643
+ ],
644
+ },
645
+ {
646
+ /* The address bar has a grammar of its own, and nothing on screen taught
647
+ it: `~30`, `!diagram` and `@page~root` were sigils you could only learn
648
+ by watching the bar change as you clicked. They are worth writing by
649
+ hand — a hash is a place you can send someone — so they are worth
650
+ documenting where the rest of the language lives. */
651
+ title: say('linksYouCanWrite'),
652
+ note: say('theFirstSegmentIsTheConnection'),
653
+ grammar: [
654
+ ['/erp/customer', say('aTableAnyQuery')],
655
+ ['/erp/customer/~42', say('aRowOfTheTable')],
656
+ ['/erp/customer/~42/~invoice:9', say('anotherTablesRowNames')],
657
+ ['/erp/customer!diagram', say('aTabRowsDdl')],
658
+ ['/erp/@customer~42', say('aPageById')],
659
+ ],
660
+ },
661
+ ];
@@ -0,0 +1,10 @@
1
+ /** The history for the connection in use, newest first. */
2
+ export declare function historyFor(connection?: string): any;
3
+ /**
4
+ * Remember a query that ran.
5
+ *
6
+ * Re-running something moves it to the top instead of adding a second copy:
7
+ * the list is meant to answer "what have I been looking at", and twelve
8
+ * identical rows of `customer` push the query you actually want off the end.
9
+ */
10
+ export declare function recordQuery(text: any): void;