@columnus/sdk 0.0.0-stage → 0.3.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 (386) hide show
  1. package/dist/blocknote-editor-547WFBXP.js +7 -0
  2. package/dist/blocknote-editor-547WFBXP.js.map +1 -0
  3. package/dist/blocknote-editor-YZEFMXLC.css +47 -0
  4. package/dist/blocknote-editor-YZEFMXLC.css.map +1 -0
  5. package/dist/blocknote-preview-6WRENQZD.css +47 -0
  6. package/dist/blocknote-preview-6WRENQZD.css.map +1 -0
  7. package/dist/blocknote-preview-CTMNUSYX.js +7 -0
  8. package/dist/blocknote-preview-CTMNUSYX.js.map +1 -0
  9. package/dist/chunk-5IPH2A64.js +23337 -0
  10. package/dist/chunk-5IPH2A64.js.map +1 -0
  11. package/dist/chunk-BQCD5MEV.js +225 -0
  12. package/dist/chunk-BQCD5MEV.js.map +1 -0
  13. package/dist/chunk-BXTTCBIK.js +11 -0
  14. package/dist/chunk-BXTTCBIK.js.map +1 -0
  15. package/dist/chunk-ICKWVUW7.js +134 -0
  16. package/dist/chunk-ICKWVUW7.js.map +1 -0
  17. package/dist/chunk-IMYSQX2X.js +58 -0
  18. package/dist/chunk-IMYSQX2X.js.map +1 -0
  19. package/dist/chunk-JYSABU33.js +494 -0
  20. package/dist/chunk-JYSABU33.js.map +1 -0
  21. package/dist/chunk-PX6F3LHL.js +37 -0
  22. package/dist/chunk-PX6F3LHL.js.map +1 -0
  23. package/dist/chunk-QPQRNIKG.js +142 -0
  24. package/dist/chunk-QPQRNIKG.js.map +1 -0
  25. package/dist/chunk-SKE2RDD2.js +4217 -0
  26. package/dist/chunk-SKE2RDD2.js.map +1 -0
  27. package/dist/chunk-XWMTXQF3.js +18727 -0
  28. package/dist/chunk-XWMTXQF3.js.map +1 -0
  29. package/dist/chunk-ZTWPGA37.js +68 -0
  30. package/dist/chunk-ZTWPGA37.js.map +1 -0
  31. package/dist/cms/builder/diff-view.js +70 -0
  32. package/dist/cms/builder/diff-view.js.map +1 -0
  33. package/dist/cms/builder/panel.js +1316 -0
  34. package/dist/cms/builder/panel.js.map +1 -0
  35. package/dist/cms/convex/index.css +47 -0
  36. package/dist/cms/convex/index.css.map +1 -0
  37. package/dist/cms/convex/index.js +370 -0
  38. package/dist/cms/convex/index.js.map +1 -0
  39. package/dist/cms/index.css +47 -0
  40. package/dist/cms/index.css.map +1 -0
  41. package/dist/cms/index.js +9 -0
  42. package/dist/cms/index.js.map +1 -0
  43. package/dist/cms/server/index.js +5 -0
  44. package/dist/cms/server/index.js.map +1 -0
  45. package/dist/cms/tables/tables-dialog.css +47 -0
  46. package/dist/cms/tables/tables-dialog.css.map +1 -0
  47. package/dist/cms/tables/tables-dialog.js +590 -0
  48. package/dist/cms/tables/tables-dialog.js.map +1 -0
  49. package/dist/cms/tailwind.css +4 -0
  50. package/dist/editor-543ARQ6S.js +427 -0
  51. package/dist/editor-543ARQ6S.js.map +1 -0
  52. package/dist/editor-54UG7BSP.css +47 -0
  53. package/dist/editor-54UG7BSP.css.map +1 -0
  54. package/dist/mcp-cli.js +61218 -0
  55. package/dist/primitives.css +143 -0
  56. package/dist/rich-text-editor/blocknote-preview-studio.css +54 -0
  57. package/dist/richtext.css +4 -0
  58. package/dist/types/cms/src/adapters/default-richtext.d.ts +24 -0
  59. package/dist/types/cms/src/adapters/projected-fields-adapter.d.ts +22 -0
  60. package/dist/types/cms/src/adapters/table-rows-context.d.ts +4 -0
  61. package/dist/types/cms/src/adapters/table-rows-richtext.d.ts +8 -0
  62. package/dist/types/cms/src/builder/annotate.d.ts +13 -0
  63. package/dist/types/cms/src/builder/diff-view.d.ts +10 -0
  64. package/dist/types/cms/src/builder/inspect.d.ts +32 -0
  65. package/dist/types/cms/src/builder/panel.d.ts +11 -0
  66. package/dist/types/cms/src/builder/sessions-menu.d.ts +37 -0
  67. package/dist/types/cms/src/builder/sidecar-json.d.ts +2 -0
  68. package/dist/types/cms/src/cache/html-cache.d.ts +12 -0
  69. package/dist/types/cms/src/chrome/changes-view.d.ts +15 -0
  70. package/dist/types/cms/src/chrome/confirm-panel.d.ts +10 -0
  71. package/dist/types/cms/src/chrome/floating-toolbar.d.ts +25 -0
  72. package/dist/types/cms/src/chrome/icons.d.ts +13 -0
  73. package/dist/types/cms/src/chrome/overlay-styles.d.ts +38 -0
  74. package/dist/types/cms/src/chrome/resolve-dialog.d.ts +26 -0
  75. package/dist/types/cms/src/chrome/session-storage.d.ts +3 -0
  76. package/dist/types/cms/src/convex/cms-convex-proposals.d.ts +19 -0
  77. package/dist/types/cms/src/convex/cms-convex-shell.d.ts +8 -0
  78. package/dist/types/cms/src/convex/cms-host-refs.d.ts +15 -0
  79. package/dist/types/cms/src/convex/index.d.ts +7 -0
  80. package/dist/types/cms/src/convex/proposal-refs.d.ts +20 -0
  81. package/dist/types/cms/src/convex/use-cms-display-fields-adapter.d.ts +17 -0
  82. package/dist/types/cms/src/convex/use-cms-display-values.d.ts +12 -0
  83. package/dist/types/cms/src/convex/use-cms-editor-auth.d.ts +12 -0
  84. package/dist/types/cms/src/convex/use-cms-storage-display.d.ts +19 -0
  85. package/dist/types/cms/src/convex/use-cms-storage-fields-adapter.d.ts +63 -0
  86. package/dist/types/cms/src/convex/use-fields-adapter-host.d.ts +4 -0
  87. package/dist/types/cms/src/create/compound-create.d.ts +56 -0
  88. package/dist/types/cms/src/draft/merge-draft.d.ts +31 -0
  89. package/dist/types/cms/src/edit/cms-compound-create.d.ts +12 -0
  90. package/dist/types/cms/src/edit/cms-create-button.d.ts +9 -0
  91. package/dist/types/cms/src/edit/edit-surface.d.ts +16 -0
  92. package/dist/types/cms/src/edit/field-editor-dialog.d.ts +22 -0
  93. package/dist/types/cms/src/edit/inplace-field-editor.d.ts +21 -0
  94. package/dist/types/cms/src/edit/inplace-switch-modal.d.ts +5 -0
  95. package/dist/types/cms/src/edit/insert-row-dialog.d.ts +20 -0
  96. package/dist/types/cms/src/index.d.ts +35 -0
  97. package/dist/types/cms/src/list/build-insert-draft.d.ts +13 -0
  98. package/dist/types/cms/src/manifest-index.d.ts +5 -0
  99. package/dist/types/cms/src/nav/content-ref-integrity.d.ts +18 -0
  100. package/dist/types/cms/src/nav/content-ref.d.ts +6 -0
  101. package/dist/types/cms/src/nav/infer-navigation-table.d.ts +20 -0
  102. package/dist/types/cms/src/nav/slugify-de.d.ts +4 -0
  103. package/dist/types/cms/src/pages/login-page.d.ts +5 -0
  104. package/dist/types/cms/src/profile/propose-gates.d.ts +12 -0
  105. package/dist/types/cms/src/profile/readable-tables.d.ts +13 -0
  106. package/dist/types/cms/src/projection/cms-projection.d.ts +63 -0
  107. package/dist/types/cms/src/proposals/types.d.ts +59 -0
  108. package/dist/types/cms/src/provider/builder-draft.d.ts +14 -0
  109. package/dist/types/cms/src/provider/cms-provider.d.ts +240 -0
  110. package/dist/types/cms/src/rich-doc/cms-rich-doc-view.d.ts +4 -0
  111. package/dist/types/cms/src/server/cookie.d.ts +11 -0
  112. package/dist/types/cms/src/server/index.d.ts +2 -0
  113. package/dist/types/cms/src/server/session.d.ts +53 -0
  114. package/dist/types/cms/src/stamps/attrs.d.ts +17 -0
  115. package/dist/types/cms/src/stamps/related.d.ts +11 -0
  116. package/dist/types/cms/src/stamps/resolve-display.d.ts +41 -0
  117. package/dist/types/cms/src/stamps/row.d.ts +41 -0
  118. package/dist/types/cms/src/stamps/stamp-media-drop.d.ts +23 -0
  119. package/dist/types/cms/src/stamps/stamp.d.ts +44 -0
  120. package/dist/types/cms/src/stamps/storage-display.d.ts +4 -0
  121. package/dist/types/cms/src/stamps/use-cms-projected-field.d.ts +6 -0
  122. package/dist/types/cms/src/stamps/use-cms-projected-table.d.ts +7 -0
  123. package/dist/types/cms/src/stamps/use-cms-related-row.d.ts +2 -0
  124. package/dist/types/cms/src/tables/tables-dialog.d.ts +6 -0
  125. package/dist/types/cms/src/tables/use-cms-grid.d.ts +78 -0
  126. package/dist/types/cms/src/tables/use-draft-commands.d.ts +35 -0
  127. package/dist/types/data-grid/src/components/balanced-preview-columns.d.ts +7 -0
  128. package/dist/types/data-grid/src/components/cell-formula-bar.d.ts +40 -0
  129. package/dist/types/data-grid/src/components/cell-renderer.d.ts +10 -0
  130. package/dist/types/data-grid/src/components/cell-selection.d.ts +72 -0
  131. package/dist/types/data-grid/src/components/column-filter-popover.d.ts +29 -0
  132. package/dist/types/data-grid/src/components/context-menu-selection.d.ts +24 -0
  133. package/dist/types/data-grid/src/components/data-grid-table.d.ts +49 -0
  134. package/dist/types/data-grid/src/components/delete-confirm-copy.d.ts +6 -0
  135. package/dist/types/data-grid/src/components/display-search-scope-notice.d.ts +4 -0
  136. package/dist/types/data-grid/src/components/draft-rows.d.ts +14 -0
  137. package/dist/types/data-grid/src/components/field-condition-editor.d.ts +71 -0
  138. package/dist/types/data-grid/src/components/fill-handle.d.ts +22 -0
  139. package/dist/types/data-grid/src/components/grid-action-bar.d.ts +8 -0
  140. package/dist/types/data-grid/src/components/grid-body-layout.d.ts +27 -0
  141. package/dist/types/data-grid/src/components/grid-body-row.d.ts +83 -0
  142. package/dist/types/data-grid/src/components/grid-editing.d.ts +158 -0
  143. package/dist/types/data-grid/src/components/grid-event-utils.d.ts +10 -0
  144. package/dist/types/data-grid/src/components/grid-filter-search-chips.d.ts +7 -0
  145. package/dist/types/data-grid/src/components/grid-filter-search-context.d.ts +135 -0
  146. package/dist/types/data-grid/src/components/grid-filter-search.d.ts +6 -0
  147. package/dist/types/data-grid/src/components/grid-row-menu.d.ts +23 -0
  148. package/dist/types/data-grid/src/components/grid-seam-island.d.ts +23 -0
  149. package/dist/types/data-grid/src/components/grid-sort-group.d.ts +25 -0
  150. package/dist/types/data-grid/src/components/grid-toolbar.d.ts +54 -0
  151. package/dist/types/data-grid/src/components/index-suggestion-banner.d.ts +11 -0
  152. package/dist/types/data-grid/src/components/inline-edit-draft.d.ts +18 -0
  153. package/dist/types/data-grid/src/components/keyboard-shortcuts-overlay.d.ts +7 -0
  154. package/dist/types/data-grid/src/components/measure-column-auto-width.d.ts +6 -0
  155. package/dist/types/data-grid/src/components/pending-edits.d.ts +25 -0
  156. package/dist/types/data-grid/src/components/perform-grid-row-delete.d.ts +27 -0
  157. package/dist/types/data-grid/src/components/query-plan-banner.d.ts +13 -0
  158. package/dist/types/data-grid/src/components/query-predicate-builder.d.ts +53 -0
  159. package/dist/types/data-grid/src/components/row-detail-dialog.d.ts +17 -0
  160. package/dist/types/data-grid/src/components/row-preview-content.d.ts +21 -0
  161. package/dist/types/data-grid/src/components/row-preview-drawer.d.ts +24 -0
  162. package/dist/types/data-grid/src/components/selection-value-chips.d.ts +12 -0
  163. package/dist/types/data-grid/src/components/selection.d.ts +46 -0
  164. package/dist/types/data-grid/src/components/table-cell-overlays.d.ts +33 -0
  165. package/dist/types/data-grid/src/components/table-color-marker.d.ts +10 -0
  166. package/dist/types/data-grid/src/components/use-column-visibility.d.ts +5 -0
  167. package/dist/types/data-grid/src/components/use-column-widths.d.ts +6 -0
  168. package/dist/types/data-grid/src/components/use-undo-redo.d.ts +46 -0
  169. package/dist/types/data-grid/src/hooks/plan-pending-edits.d.ts +41 -0
  170. package/dist/types/data-grid/src/hooks/use-grid-interactions.d.ts +100 -0
  171. package/dist/types/data-grid/src/hooks/use-grid-pending-state.d.ts +41 -0
  172. package/dist/types/data-grid/src/hooks/use-grid-selection-model.d.ts +28 -0
  173. package/dist/types/data-grid/src/hooks/use-grid-table-layout.d.ts +39 -0
  174. package/dist/types/data-grid/src/hooks/use-true-after-delay.d.ts +10 -0
  175. package/dist/types/data-grid/src/index.d.ts +47 -0
  176. package/dist/types/data-grid/src/lib/column-filter.d.ts +43 -0
  177. package/dist/types/data-grid/src/lib/display-search-scope.d.ts +2 -0
  178. package/dist/types/data-grid/src/lib/format-query-chips.d.ts +28 -0
  179. package/dist/types/data-grid/src/lib/grid-items.d.ts +63 -0
  180. package/dist/types/data-grid/src/lib/persistent-state.d.ts +6 -0
  181. package/dist/types/data-grid/src/lib/query-editor-draft.d.ts +15 -0
  182. package/dist/types/data-grid/src/lib/use-row-preview-collapsed.d.ts +9 -0
  183. package/dist/types/data-grid/src/lib/use-row-preview-title.d.ts +1 -0
  184. package/dist/types/fields/src/components/batch-edit-sheet.d.ts +10 -0
  185. package/dist/types/fields/src/components/cell-editor.d.ts +29 -0
  186. package/dist/types/fields/src/components/date-time-input.d.ts +21 -0
  187. package/dist/types/fields/src/components/date-time-picker-logic.d.ts +13 -0
  188. package/dist/types/fields/src/components/field-input-chrome.d.ts +11 -0
  189. package/dist/types/fields/src/components/field-input-inline.d.ts +30 -0
  190. package/dist/types/fields/src/components/field-input.d.ts +36 -0
  191. package/dist/types/fields/src/components/field-value-view.d.ts +10 -0
  192. package/dist/types/fields/src/components/file-array-cell.d.ts +5 -0
  193. package/dist/types/fields/src/components/file-array-upload-dialog.d.ts +19 -0
  194. package/dist/types/fields/src/components/file-cell.d.ts +5 -0
  195. package/dist/types/fields/src/components/file-input.d.ts +21 -0
  196. package/dist/types/fields/src/components/file-upload-dialog.d.ts +19 -0
  197. package/dist/types/fields/src/components/focus-text-input.d.ts +5 -0
  198. package/dist/types/fields/src/components/id-array-cell.d.ts +9 -0
  199. package/dist/types/fields/src/components/id-array-values.d.ts +1 -0
  200. package/dist/types/fields/src/components/id-cell.d.ts +4 -0
  201. package/dist/types/fields/src/components/id-picker.d.ts +28 -0
  202. package/dist/types/fields/src/components/image-array-cell.d.ts +7 -0
  203. package/dist/types/fields/src/components/image-cell.d.ts +7 -0
  204. package/dist/types/fields/src/components/image-preview-dialog.d.ts +8 -0
  205. package/dist/types/fields/src/components/media-compact-preview.d.ts +17 -0
  206. package/dist/types/fields/src/components/media-library-picker-dialog.d.ts +16 -0
  207. package/dist/types/fields/src/components/multi-id-picker.d.ts +24 -0
  208. package/dist/types/fields/src/components/picker-chrome.d.ts +28 -0
  209. package/dist/types/fields/src/components/picker-density.d.ts +5 -0
  210. package/dist/types/fields/src/components/picker-list-placeholder.d.ts +13 -0
  211. package/dist/types/fields/src/components/picker-menu-keyboard.d.ts +16 -0
  212. package/dist/types/fields/src/components/picker-menu-layout.d.ts +12 -0
  213. package/dist/types/fields/src/components/picker-menu-portal.d.ts +19 -0
  214. package/dist/types/fields/src/components/picker-option-row.d.ts +10 -0
  215. package/dist/types/fields/src/components/picker-overlay.d.ts +35 -0
  216. package/dist/types/fields/src/components/record-link-chip.d.ts +21 -0
  217. package/dist/types/fields/src/components/row-edit-panel.d.ts +36 -0
  218. package/dist/types/fields/src/components/row-editor.d.ts +19 -0
  219. package/dist/types/fields/src/components/row-popover.d.ts +11 -0
  220. package/dist/types/fields/src/components/use-flush-ref.d.ts +3 -0
  221. package/dist/types/fields/src/components/use-picker-combobox.d.ts +86 -0
  222. package/dist/types/fields/src/components/use-picker-highlight-scroll.d.ts +4 -0
  223. package/dist/types/fields/src/components/use-picker-menu-overlay.d.ts +7 -0
  224. package/dist/types/fields/src/fields-data-adapter.d.ts +111 -0
  225. package/dist/types/fields/src/fields-data-provider.d.ts +45 -0
  226. package/dist/types/fields/src/hooks/use-debounced-value.d.ts +1 -0
  227. package/dist/types/fields/src/hooks/use-row-edit-shortcuts.d.ts +15 -0
  228. package/dist/types/fields/src/index.d.ts +38 -0
  229. package/dist/types/fields/src/lib/is-row-doc-dirty.d.ts +2 -0
  230. package/dist/types/fields/src/lib/scroll-to-form-field.d.ts +6 -0
  231. package/dist/types/fields/src/media-library-query.d.ts +34 -0
  232. package/dist/types/fields/src/media-upload-limits.d.ts +18 -0
  233. package/dist/types/fields/src/record-actions-context.d.ts +17 -0
  234. package/dist/types/fields/src/storage-upload.d.ts +21 -0
  235. package/dist/types/primitives/src/components/ui/accordion.d.ts +6 -0
  236. package/dist/types/primitives/src/components/ui/alert-dialog.d.ts +12 -0
  237. package/dist/types/primitives/src/components/ui/badge.d.ts +9 -0
  238. package/dist/types/primitives/src/components/ui/button.d.ts +11 -0
  239. package/dist/types/primitives/src/components/ui/calendar.d.ts +8 -0
  240. package/dist/types/primitives/src/components/ui/card.d.ts +7 -0
  241. package/dist/types/primitives/src/components/ui/checkbox.d.ts +3 -0
  242. package/dist/types/primitives/src/components/ui/dialog.d.ts +15 -0
  243. package/dist/types/primitives/src/components/ui/dropdown-menu.d.ts +10 -0
  244. package/dist/types/primitives/src/components/ui/info-hint.d.ts +37 -0
  245. package/dist/types/primitives/src/components/ui/input.d.ts +2 -0
  246. package/dist/types/primitives/src/components/ui/label.d.ts +3 -0
  247. package/dist/types/primitives/src/components/ui/popover.d.ts +6 -0
  248. package/dist/types/primitives/src/components/ui/save-bar.d.ts +43 -0
  249. package/dist/types/primitives/src/components/ui/select.d.ts +8 -0
  250. package/dist/types/primitives/src/components/ui/separator.d.ts +3 -0
  251. package/dist/types/primitives/src/components/ui/sheet.d.ts +18 -0
  252. package/dist/types/primitives/src/components/ui/sonner.d.ts +1 -0
  253. package/dist/types/primitives/src/components/ui/switch.d.ts +3 -0
  254. package/dist/types/primitives/src/components/ui/table.d.ts +7 -0
  255. package/dist/types/primitives/src/components/ui/tabs.d.ts +6 -0
  256. package/dist/types/primitives/src/components/ui/tooltip.d.ts +6 -0
  257. package/dist/types/primitives/src/index.d.ts +28 -0
  258. package/dist/types/primitives/src/lib/animation-frame-batcher.d.ts +11 -0
  259. package/dist/types/primitives/src/lib/locale-week-start.d.ts +5 -0
  260. package/dist/types/primitives/src/lib/save-bar-logic.d.ts +52 -0
  261. package/dist/types/primitives/src/lib/use-raf-batched-pointer-drag.d.ts +31 -0
  262. package/dist/types/primitives/src/lib/use-save-bar.d.ts +36 -0
  263. package/dist/types/primitives/src/lib/use-unsaved-changes-guard.d.ts +15 -0
  264. package/dist/types/primitives/src/lib/utils.d.ts +6 -0
  265. package/dist/types/richtext/src/editor.d.ts +16 -0
  266. package/dist/types/richtext/src/host-adapter.d.ts +66 -0
  267. package/dist/types/richtext/src/index.d.ts +11 -0
  268. package/dist/types/richtext/src/markdown-editor/editor-styles.d.ts +7 -0
  269. package/dist/types/richtext/src/markdown-editor/markdown-editor-dialog.d.ts +16 -0
  270. package/dist/types/richtext/src/markdown-editor/markdown-editor.d.ts +2 -0
  271. package/dist/types/richtext/src/markdown-editor/markdown-field-input.d.ts +11 -0
  272. package/dist/types/richtext/src/markdown-editor/markdown-field-trigger.d.ts +8 -0
  273. package/dist/types/richtext/src/markdown-editor/markdown-insert-pickers-session.d.ts +5 -0
  274. package/dist/types/richtext/src/markdown-editor/markdown-insert-pickers.d.ts +9 -0
  275. package/dist/types/richtext/src/markdown-editor/markdown-preview.d.ts +7 -0
  276. package/dist/types/richtext/src/markdown-editor/markdown-rich-preview.d.ts +5 -0
  277. package/dist/types/richtext/src/markdown-editor/record-link-picker-session.d.ts +7 -0
  278. package/dist/types/richtext/src/markdown-editor/record-link-picker.d.ts +9 -0
  279. package/dist/types/richtext/src/markdown-editor/record-table-picker.d.ts +21 -0
  280. package/dist/types/richtext/src/markdown-editor/use-markdown-insert-pickers.d.ts +33 -0
  281. package/dist/types/richtext/src/record-table-view.d.ts +17 -0
  282. package/dist/types/richtext/src/rich-doc-view.d.ts +30 -0
  283. package/dist/types/richtext/src/rich-text-editor/blocknote-editor.d.ts +25 -0
  284. package/dist/types/richtext/src/rich-text-editor/blocknote-portaled-dropdown.d.ts +2 -0
  285. package/dist/types/richtext/src/rich-text-editor/blocknote-preview.d.ts +12 -0
  286. package/dist/types/richtext/src/rich-text-editor/record-link-inline.d.ts +15 -0
  287. package/dist/types/richtext/src/rich-text-editor/record-link-rows-context.d.ts +9 -0
  288. package/dist/types/richtext/src/rich-text-editor/record-table-block.d.ts +18 -0
  289. package/dist/types/richtext/src/rich-text-editor/studio-schema.d.ts +283 -0
  290. package/dist/types/richtext/src/rich-text-editor/studio-slash-menu.d.ts +8 -0
  291. package/dist/types/richtext/src/rich-text-editor/use-sync-blocknote-value.d.ts +2 -0
  292. package/dist/types/shared/src/apiProfile.d.ts +164 -0
  293. package/dist/types/shared/src/apiProfileDiscovery.d.ts +88 -0
  294. package/dist/types/shared/src/apiProfileSlug.d.ts +11 -0
  295. package/dist/types/shared/src/apiProfileSources.d.ts +112 -0
  296. package/dist/types/shared/src/apiProfileValidators.d.ts +310 -0
  297. package/dist/types/shared/src/apiToken.d.ts +6 -0
  298. package/dist/types/shared/src/assetFamily.d.ts +38 -0
  299. package/dist/types/shared/src/assetFieldValues.d.ts +21 -0
  300. package/dist/types/shared/src/assetGraph.d.ts +221 -0
  301. package/dist/types/shared/src/assetJobs.d.ts +99 -0
  302. package/dist/types/shared/src/assetSettings.d.ts +147 -0
  303. package/dist/types/shared/src/auditRedact.d.ts +36 -0
  304. package/dist/types/shared/src/betterAuthSession.d.ts +12 -0
  305. package/dist/types/shared/src/bffHost.d.ts +36 -0
  306. package/dist/types/shared/src/bffProtocol.d.ts +563 -0
  307. package/dist/types/shared/src/bffRedact.d.ts +30 -0
  308. package/dist/types/shared/src/ciPreviewEnv.d.ts +21 -0
  309. package/dist/types/shared/src/clipboardTransfer.d.ts +25 -0
  310. package/dist/types/shared/src/convexFacade.d.ts +44 -0
  311. package/dist/types/shared/src/convexSiteUrl.d.ts +73 -0
  312. package/dist/types/shared/src/csv.d.ts +65 -0
  313. package/dist/types/shared/src/dataTransfer.d.ts +21 -0
  314. package/dist/types/shared/src/dateValues.d.ts +21 -0
  315. package/dist/types/shared/src/deployOutput.d.ts +3 -0
  316. package/dist/types/shared/src/displayLabel.d.ts +17 -0
  317. package/dist/types/shared/src/displayTemplateGenerator.d.ts +11 -0
  318. package/dist/types/shared/src/displayTypes.d.ts +10 -0
  319. package/dist/types/shared/src/erdLayout.d.ts +27 -0
  320. package/dist/types/shared/src/facets.d.ts +109 -0
  321. package/dist/types/shared/src/failureMessage.d.ts +5 -0
  322. package/dist/types/shared/src/fieldTypeMeta.d.ts +110 -0
  323. package/dist/types/shared/src/fieldTypeText.d.ts +34 -0
  324. package/dist/types/shared/src/fieldValueEqual.d.ts +10 -0
  325. package/dist/types/shared/src/fieldValueShape.d.ts +24 -0
  326. package/dist/types/shared/src/fieldValueText.d.ts +32 -0
  327. package/dist/types/shared/src/gridQuery.d.ts +103 -0
  328. package/dist/types/shared/src/importMatch.d.ts +80 -0
  329. package/dist/types/shared/src/index.d.ts +78 -0
  330. package/dist/types/shared/src/inferIdentifier.d.ts +18 -0
  331. package/dist/types/shared/src/keyboard.d.ts +16 -0
  332. package/dist/types/shared/src/manifestDeploy.d.ts +31 -0
  333. package/dist/types/shared/src/manifestHash.d.ts +12 -0
  334. package/dist/types/shared/src/mcpOAuth.d.ts +182 -0
  335. package/dist/types/shared/src/postLoginPath.d.ts +21 -0
  336. package/dist/types/shared/src/previewDeployName.d.ts +27 -0
  337. package/dist/types/shared/src/proposalDraftMerge.d.ts +35 -0
  338. package/dist/types/shared/src/proposePolicy.d.ts +17 -0
  339. package/dist/types/shared/src/proposeRateLimit.d.ts +27 -0
  340. package/dist/types/shared/src/queryBetween.d.ts +21 -0
  341. package/dist/types/shared/src/queryConditions.d.ts +46 -0
  342. package/dist/types/shared/src/queryExecution.d.ts +12 -0
  343. package/dist/types/shared/src/queryFieldOps.d.ts +123 -0
  344. package/dist/types/shared/src/queryMerge.d.ts +30 -0
  345. package/dist/types/shared/src/queryPlan.d.ts +86 -0
  346. package/dist/types/shared/src/queryStudio.d.ts +28 -0
  347. package/dist/types/shared/src/queryTypes.d.ts +184 -0
  348. package/dist/types/shared/src/queryValidators.d.ts +233 -0
  349. package/dist/types/shared/src/readApiQuery.d.ts +10 -0
  350. package/dist/types/shared/src/readModelLimits.d.ts +23 -0
  351. package/dist/types/shared/src/recordTableColumns.d.ts +24 -0
  352. package/dist/types/shared/src/recordTablePreload.d.ts +19 -0
  353. package/dist/types/shared/src/refDisplayRequests.d.ts +17 -0
  354. package/dist/types/shared/src/refGraph.d.ts +97 -0
  355. package/dist/types/shared/src/refsRecompute.d.ts +16 -0
  356. package/dist/types/shared/src/richDoc.d.ts +80 -0
  357. package/dist/types/shared/src/rowPatchWire.d.ts +12 -0
  358. package/dist/types/shared/src/rowTrash.d.ts +26 -0
  359. package/dist/types/shared/src/savedView.d.ts +37 -0
  360. package/dist/types/shared/src/schemaGenerator.d.ts +36 -0
  361. package/dist/types/shared/src/schemaShrink.d.ts +82 -0
  362. package/dist/types/shared/src/schemaShrinkValidators.d.ts +72 -0
  363. package/dist/types/shared/src/schemaTypes.d.ts +311 -0
  364. package/dist/types/shared/src/share.d.ts +8 -0
  365. package/dist/types/shared/src/shareApiBridge.d.ts +13 -0
  366. package/dist/types/shared/src/shareGuestPolicy.d.ts +14 -0
  367. package/dist/types/shared/src/shareProposal.d.ts +141 -0
  368. package/dist/types/shared/src/shareProposalDiff.d.ts +13 -0
  369. package/dist/types/shared/src/shareScopes.d.ts +19 -0
  370. package/dist/types/shared/src/shareTokenCrypto.d.ts +9 -0
  371. package/dist/types/shared/src/shareTokens.d.ts +6 -0
  372. package/dist/types/shared/src/shareTypes.d.ts +113 -0
  373. package/dist/types/shared/src/shareWizard.d.ts +23 -0
  374. package/dist/types/shared/src/spaceBundle.d.ts +89 -0
  375. package/dist/types/shared/src/stagedApiAccess.d.ts +104 -0
  376. package/dist/types/shared/src/studioBoot.d.ts +63 -0
  377. package/dist/types/shared/src/syncChannel.d.ts +25 -0
  378. package/dist/types/shared/src/syncClampMembership.d.ts +22 -0
  379. package/dist/types/shared/src/tableSearch.d.ts +52 -0
  380. package/dist/types/shared/src/tenantHosts.d.ts +34 -0
  381. package/dist/types/shared/src/tenantSecretsCrypto.d.ts +31 -0
  382. package/dist/types/shared/src/useDebouncedCommit.d.ts +15 -0
  383. package/dist/types/shared/src/useDebouncedValue.d.ts +1 -0
  384. package/dist/types/shared/src/useModifierHeld.d.ts +2 -0
  385. package/package.json +85 -3
  386. package/README.md +0 -3
@@ -0,0 +1,40 @@
1
+ import { type ReactNode } from "react";
2
+ import { type Field, type Manifest } from "../../../shared/src/index.js";
3
+ import { type CellCoord, type SelectionValueSummary } from "./cell-selection";
4
+ import { type GridEditing } from "./grid-editing";
5
+ export type FormulaBarSelectionSummary = {
6
+ cellCount: number;
7
+ rowMin: number;
8
+ rowMax: number;
9
+ fieldName: string;
10
+ rowIds: readonly string[];
11
+ valueSummary: SelectionValueSummary;
12
+ };
13
+ interface Props {
14
+ focus: CellCoord | null;
15
+ field: Field | null;
16
+ value: unknown;
17
+ orderedIds: readonly string[];
18
+ /** The grid's editing coordinator; commits and the inline-draft mirror go through it. */
19
+ editing: Pick<GridEditing, "formulaBar">;
20
+ onNavigateAfterCommit?: () => void;
21
+ selectionSummary?: FormulaBarSelectionSummary | null;
22
+ /** Set by the table when a cell is double-clicked to focus this bar's editor. */
23
+ focusRequest?: {
24
+ openPicker?: boolean;
25
+ key: number;
26
+ initialChar?: string;
27
+ } | null;
28
+ /** Open the markdown editor dialog for the focused cell. */
29
+ onOpenMarkdownEditor?: () => void;
30
+ manifest?: Manifest;
31
+ canUndo?: boolean;
32
+ canRedo?: boolean;
33
+ onUndo?: () => void;
34
+ onRedo?: () => void;
35
+ /** Show the value without an editor (a cell the host can't edit here). */
36
+ readOnly?: boolean;
37
+ trailing?: ReactNode;
38
+ }
39
+ export declare function CellFormulaBar({ focus, field, value: cellValue, orderedIds, editing, onNavigateAfterCommit, selectionSummary, focusRequest, onOpenMarkdownEditor, manifest, canUndo, canRedo, onUndo, onRedo, readOnly, trailing, }: Props): import("react").JSX.Element;
40
+ export {};
@@ -0,0 +1,10 @@
1
+ import type { FieldType } from "../../../shared/src/index.js";
2
+ type CellRendererSize = "compact" | "preview";
3
+ export declare function CellRenderer({ value, type, size, clamped, }: {
4
+ value: unknown;
5
+ type?: FieldType;
6
+ size?: CellRendererSize;
7
+ /** Grid cells: link lists show at most two lines of chips. */
8
+ clamped?: boolean;
9
+ }): string | number | bigint | boolean | Iterable<import("react").ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<import("react").ReactNode> | null | undefined> | import("react").JSX.Element;
10
+ export {};
@@ -0,0 +1,72 @@
1
+ export type CellCoord = {
2
+ rowId: string;
3
+ fieldName: string;
4
+ };
5
+ /** Active inline edit target; optional seed char when opened via type-to-edit. */
6
+ export type EditingCell = CellCoord & {
7
+ initialChar?: string;
8
+ };
9
+ export type CellSelection = {
10
+ anchor: CellCoord;
11
+ focus: CellCoord;
12
+ };
13
+ export type SelectionBounds = {
14
+ rowMin: number;
15
+ rowMax: number;
16
+ colMin: number;
17
+ colMax: number;
18
+ };
19
+ export declare function selectCell(coord: CellCoord): CellSelection;
20
+ export declare function extendSelection(sel: CellSelection, focus: CellCoord): CellSelection;
21
+ export declare function coordsEqual(a: CellCoord, b: CellCoord): boolean;
22
+ /** Row ids covered by a rectangular cell selection (for toolbar row actions). */
23
+ export declare function rowIdsInBounds(bounds: SelectionBounds, orderedIds: readonly string[]): Set<string>;
24
+ export declare function getSelectionBounds(sel: CellSelection, orderedIds: readonly string[], fieldNames: readonly string[]): SelectionBounds | null;
25
+ export declare function isInSelection(sel: CellSelection, rowId: string, fieldName: string, orderedIds: readonly string[], fieldNames: readonly string[]): boolean;
26
+ export declare function isFocusCell(sel: CellSelection, rowId: string, fieldName: string): boolean;
27
+ export type RangeEdgeFlags = {
28
+ isTop: boolean;
29
+ isBottom: boolean;
30
+ isLeft: boolean;
31
+ isRight: boolean;
32
+ };
33
+ export declare function isIndexInSelectionBounds(bounds: SelectionBounds | null, rowIdx: number, colIdx: number): boolean;
34
+ export declare function selectionEdgeFlagsForIndex(bounds: SelectionBounds | null, rowIdx: number, colIdx: number): RangeEdgeFlags | null;
35
+ export declare function isSingleColumnBounds(bounds: SelectionBounds | null): boolean;
36
+ export declare function selectionEdgeFlags(sel: CellSelection, rowId: string, fieldName: string, orderedIds: readonly string[], fieldNames: readonly string[]): RangeEdgeFlags | null;
37
+ export declare function moveSelection(sel: CellSelection, dRow: number, dCol: number, orderedIds: readonly string[], fieldNames: readonly string[], extend: boolean, options?: {
38
+ wrapRows?: boolean;
39
+ }): CellSelection | null;
40
+ /** Move through cells until one satisfies the caller's navigation policy. */
41
+ export declare function moveSelectionSkipping(selection: CellSelection, dRow: number, dCol: number, orderedIds: readonly string[], fieldNames: readonly string[], canNavigate: (coord: CellCoord) => boolean, options?: {
42
+ wrapRows?: boolean;
43
+ }): CellSelection | null;
44
+ export declare function rowNumberFor(orderedIds: readonly string[], rowId: string): number | null;
45
+ export type SelectionCell = CellCoord & {
46
+ rowIdx: number;
47
+ };
48
+ export declare function isSingleColumnSelection(sel: CellSelection, orderedIds: readonly string[], fieldNames: readonly string[]): boolean;
49
+ export type MultiColumnEditSelection = {
50
+ selectionBounds: SelectionBounds | null;
51
+ singleColumnMultiSelect: boolean;
52
+ multiEditCells: SelectionCell[];
53
+ multiEditFieldName: string | null;
54
+ multiEditRowIds: string[];
55
+ };
56
+ /** Single-column selection spanning multiple rows (batch edit / formula bar). */
57
+ export declare function deriveMultiColumnEditSelection(cellSelection: CellSelection | null, orderedIds: readonly string[], visibleFieldNames: readonly string[]): MultiColumnEditSelection;
58
+ export declare function enumerateSelectionCells(sel: CellSelection, orderedIds: readonly string[], fieldNames: readonly string[]): SelectionCell[];
59
+ export type SelectionValueEntry = {
60
+ key: string;
61
+ label: string;
62
+ count: number;
63
+ value: unknown;
64
+ };
65
+ export type SelectionValueSummary = {
66
+ total: number;
67
+ entries: SelectionValueEntry[];
68
+ homogeneous: boolean;
69
+ };
70
+ export declare function selectionValueSummary(cells: readonly CellCoord[], resolveValue: (cell: CellCoord) => unknown, formatValue: (value: unknown) => string): SelectionValueSummary;
71
+ /** Value distribution for one field across multiple rows (preview panel, etc.). */
72
+ export declare function fieldValueSummaryForRows(rowIds: readonly string[], fieldName: string, resolveValue: (rowId: string, fieldName: string) => unknown, formatValue: (value: unknown) => string): SelectionValueSummary;
@@ -0,0 +1,29 @@
1
+ import { type Field, type GridQuery, type Table } from "../../../shared/src/index.js";
2
+ import { type FieldCounts } from "./field-condition-editor.tsx";
3
+ export type ColumnFiltersConfig = {
4
+ query: GridQuery | null;
5
+ /** Edits keep the query's shape: a plain `Query` comes back as one (method: bivariant). */
6
+ onApply(next: GridQuery | null): void;
7
+ /** Offer reference pickers for `id` / `id[]` columns (default true; guests cannot list tables). */
8
+ refPickers?: boolean;
9
+ /** Offer Sort ascending / descending in the popover (default true). */
10
+ showSort?: boolean;
11
+ /** Offer Group by this field (read-model grids); with a reason, it is disabled. */
12
+ group?: {
13
+ disabledReason?: string;
14
+ };
15
+ /**
16
+ * Row counts for choice fields: `open` names the field whose popover is open (null once it
17
+ * closes), `of` returns its counts once loaded.
18
+ */
19
+ counts?: {
20
+ open(field: string | null): void;
21
+ of(field: string): FieldCounts | undefined;
22
+ };
23
+ };
24
+ /** Memoized: headers re-render with every grid render (scroll, selection); pass a stable `config`. */
25
+ export declare const ColumnFilterButton: import("react").MemoExoticComponent<({ table, field, config, }: {
26
+ table: Table;
27
+ field: Field;
28
+ config: ColumnFiltersConfig;
29
+ }) => import("react").JSX.Element | null>;
@@ -0,0 +1,24 @@
1
+ import { type CellSelection } from "./cell-selection";
2
+ import { type Selection } from "./selection";
3
+ export type ContextMenuSelectionInput = {
4
+ rowId: string;
5
+ fieldName?: string;
6
+ modifiers: {
7
+ shiftKey?: boolean;
8
+ metaKey?: boolean;
9
+ ctrlKey?: boolean;
10
+ };
11
+ isMdUp: boolean;
12
+ cellSelection: CellSelection | null;
13
+ selectedIds: Selection;
14
+ orderedIds: readonly string[];
15
+ visibleFieldNames: readonly string[];
16
+ lastAnchorId: string | null;
17
+ };
18
+ export type ContextMenuSelectionResult = {
19
+ cellSelection: CellSelection | null;
20
+ selectedIds: Selection;
21
+ anchor: string;
22
+ };
23
+ /** Pure policy for row + cell selection when opening the grid row context menu. */
24
+ export declare function resolveContextMenuSelection(input: ContextMenuSelectionInput): ContextMenuSelectionResult;
@@ -0,0 +1,49 @@
1
+ import type { VirtualItem } from "@tanstack/react-virtual";
2
+ import { type Field, type QueryOrder, type Table as TableT } from "../../../shared/src/index.js";
3
+ import { type GridBodyRowController, type GridBodyRowProps } from "./grid-body-row";
4
+ import { type ColumnFiltersConfig } from "./column-filter-popover";
5
+ import { type Selection } from "./selection";
6
+ import { type GridItem } from "../lib/grid-items";
7
+ type ColumnMenuItem = {
8
+ name: string;
9
+ label: string;
10
+ hidden: boolean;
11
+ };
12
+ export type DataGridTableRowController = GridBodyRowController;
13
+ export declare function DataGridTable({ table, assetIdsForGrid, showIdColumn, visibleFields, colWidths, columnMenuItems, dataRows, entryRow, showEntryRow, selectionDisplayRows, items, virtualItems, totalSize, onToggleGroup, onLoadMoreInGroup, onShowRow, loadingFirstPage, startResize, autoSizeColumn, toggleColumn, onRowContextMenu, onCopy, rowController, sortOrders, onCycleSort, columnFilters, onClearFilters, readOnly, isCellEditable, isDraftRow, rowClassName, cellClassName, renderRowActions, }: {
14
+ table: TableT;
15
+ assetIdsForGrid: string[];
16
+ showIdColumn: boolean;
17
+ visibleFields: Field[];
18
+ colWidths: Record<string, number>;
19
+ columnMenuItems: ColumnMenuItem[];
20
+ dataRows: Record<string, unknown>[];
21
+ entryRow: Record<string, unknown>;
22
+ showEntryRow?: boolean;
23
+ selectionDisplayRows: Record<string, unknown>[];
24
+ /** The body's items (rows, group headers, "load more"); omitted: one item per data row. */
25
+ items?: readonly GridItem[];
26
+ virtualItems: VirtualItem[];
27
+ totalSize: number;
28
+ onToggleGroup?: (key: string) => void;
29
+ onLoadMoreInGroup?: (key: string) => void;
30
+ /** A click on a row's repeat (its listing in another group): scroll to the row itself. */
31
+ onShowRow?: (rowIdx: number) => void;
32
+ loadingFirstPage: boolean;
33
+ startResize: (field: string, e: React.PointerEvent<HTMLElement>, fieldMeta?: Field) => void;
34
+ autoSizeColumn?: (field: string, fieldMeta: Field | undefined, table: HTMLElement | null) => void;
35
+ toggleColumn: (name: string) => void;
36
+ onRowContextMenu: (e: React.MouseEvent, row: Record<string, unknown>, fieldName?: string) => Selection;
37
+ onCopy?: () => void;
38
+ rowController: DataGridTableRowController;
39
+ /** Sort keys, highest priority first; headers show their direction (and rank, when several). */
40
+ sortOrders?: readonly QueryOrder[];
41
+ onCycleSort?: (field: string) => void;
42
+ /** Per-column header filter funnels; omitted grids (e.g. CSV import) get none. */
43
+ columnFilters?: ColumnFiltersConfig;
44
+ /** Set while filters are active: an empty result shows "No rows match" with this CTA. */
45
+ onClearFilters?: () => void;
46
+ /** Cells select but never edit: no editors, no fill handle (the trash view). */
47
+ readOnly?: boolean;
48
+ } & Pick<GridBodyRowProps, "isCellEditable" | "isDraftRow" | "rowClassName" | "cellClassName" | "renderRowActions">): import("react").JSX.Element;
49
+ export {};
@@ -0,0 +1,6 @@
1
+ export type DeleteConfirmCopy = {
2
+ title: string;
3
+ description: string;
4
+ confirmLabel: string;
5
+ };
6
+ export declare function deleteConfirmCopy(rows: Record<string, unknown>[]): DeleteConfirmCopy;
@@ -0,0 +1,4 @@
1
+ export declare function DisplaySearchScopeNotice({ canLoadMore, className, }: {
2
+ canLoadMore: boolean;
3
+ className?: string;
4
+ }): import("react").JSX.Element;
@@ -0,0 +1,14 @@
1
+ /** A new draft id; one made from a scoped entry row (`from`) keeps its scope. */
2
+ export declare function createDraftRowId(from?: string): string;
3
+ export declare function isDraftRowId(id: string): boolean;
4
+ export declare function createEntryRowId(): string;
5
+ /**
6
+ * The entry row of one part of the grid, such as a group (plan 098): the same id for the same
7
+ * `scope`, any string. Drafts made from it carry the scope; {@link rowScope} reads it back.
8
+ */
9
+ export declare function scopedEntryRowId(scope: string): string;
10
+ /** The scope of an entry or draft row made by {@link scopedEntryRowId}, else undefined. */
11
+ export declare function rowScope(id: string): string | undefined;
12
+ export declare function isEntryRowId(id: string): boolean;
13
+ /** Client-only rows that are not yet persisted (draft append or pinned entry). */
14
+ export declare function isUnsavedRowId(id: string): boolean;
@@ -0,0 +1,71 @@
1
+ import { type Condition, type Field, type Table } from "../../../shared/src/index.js";
2
+ import { type FacetSort } from "../../../shared/src/facets.js";
3
+ /** One counted value of a field, its label resolved; a date bucket has its exclusive `end`. */
4
+ export type CountedValue = {
5
+ key: unknown;
6
+ label: string;
7
+ count: number;
8
+ end?: number;
9
+ };
10
+ /**
11
+ * A field's counts from the read model: its values (or date buckets; (Empty) is the `null` key),
12
+ * or a number's range. `notEmpty` (and a range's `empty`) count rows with (without) a value.
13
+ */
14
+ export type FieldCounts = {
15
+ values: readonly CountedValue[];
16
+ hasMore?: boolean;
17
+ dim?: boolean;
18
+ sort?: FacetSort;
19
+ notEmpty?: number;
20
+ } | {
21
+ min: unknown;
22
+ max: unknown;
23
+ empty?: number;
24
+ notEmpty?: number;
25
+ };
26
+ export type FieldConditionEditorProps = {
27
+ table: Table;
28
+ field: Field;
29
+ /** The field's condition (`fieldCondition`, plan 103 D5). */
30
+ condition: Condition | undefined;
31
+ /** Replace the field's condition; null clears it. */
32
+ apply: (next: Condition | null) => void;
33
+ counts?: FieldCounts;
34
+ /**
35
+ * The field's values come with counts (the Filters rail on a read model): text lists its values,
36
+ * and keeps that shape while counts load or fail.
37
+ */
38
+ counted?: boolean;
39
+ /** A counted list's value search and "Show more" (they change the counts request). */
40
+ search?: {
41
+ value: string;
42
+ onChange: (text: string) => void;
43
+ };
44
+ onShowMore?: () => void;
45
+ /** Opens the builder: offered for a condition this editor can't show. */
46
+ onEdit?: () => void;
47
+ /** Reference pickers for links without counts (default true; guests cannot list tables). */
48
+ refPickers?: boolean;
49
+ };
50
+ type Kind = "values" | "date" | "number" | "boolean" | "text" | "empty";
51
+ /**
52
+ * The editor a field gets, or null when it has none (no value editor, no emptiness ops). Counted
53
+ * text lists its values; a link neither counted nor with a picker gets only (Empty) / (Not
54
+ * empty). Every other editor offers both below its own rows when the field allows them.
55
+ */
56
+ export declare function fieldConditionKind(field: Field, { counted, refPickers }?: {
57
+ counted?: boolean;
58
+ refPickers?: boolean;
59
+ }): Kind | null;
60
+ /**
61
+ * One field's condition editor (plan 103 D10), in the column header popover and the Filters
62
+ * rail: values (with counts, (Empty), search, "Show more"), dates (buckets, presets, from–to),
63
+ * numbers (min–max, applied as you type), booleans and text. (Empty) beside any selection, text
64
+ * included, is a one-field `or`; Not empty is the field's whole condition: it replaces every other
65
+ * selection, and any other pick replaces it. A condition it can't show exactly is read-only, with
66
+ * Edit.
67
+ */
68
+ export declare function FieldConditionEditor(props: FieldConditionEditorProps): import("react").JSX.Element | null;
69
+ /** How long a number edit waits before it applies. */
70
+ export declare const NUMBER_APPLY_MS = 400;
71
+ export {};
@@ -0,0 +1,22 @@
1
+ export type FillSource = {
2
+ fieldName: string;
3
+ sourceRowMin: number;
4
+ sourceRowMax: number;
5
+ sourceValues: unknown[];
6
+ };
7
+ export type FillDragState = FillSource & {
8
+ toRowIdx: number;
9
+ };
10
+ export type FillCellState = {
11
+ role: "source" | "target";
12
+ isTop: boolean;
13
+ isBottom: boolean;
14
+ previewValue?: unknown;
15
+ };
16
+ export declare function fillStateForCell(fillDrag: FillDragState | null, rowIdx: number, fieldName: string): FillCellState | null;
17
+ export type FillAssignment = {
18
+ rowIdx: number;
19
+ value: unknown;
20
+ };
21
+ export declare function computeFillAssignments(source: FillSource, toRowIdx: number): FillAssignment[];
22
+ export declare function fillPreviewValue(source: FillSource, toRowIdx: number, rowIdx: number): unknown | null;
@@ -0,0 +1,8 @@
1
+ export type GridActionBarProps = {
2
+ selectedCount: number;
3
+ onClearSelection: () => void;
4
+ onDeleteSelected: () => void;
5
+ dirtyCount: number;
6
+ };
7
+ /** Compact selection cluster for the formula bar trailing slot (CSV import). Studio uses GridSeamIsland. */
8
+ export declare function GridActionBar({ selectedCount, onClearSelection, onDeleteSelected, dirtyCount, }: GridActionBarProps): import("react").JSX.Element | null;
@@ -0,0 +1,27 @@
1
+ import type { CSSProperties } from "react";
2
+ import { type Field } from "../../../shared/src/index.js";
3
+ /** Fixed body row height so browse/edit mode and inline editors cannot reflow rows. */
4
+ export declare const BODY_ROW_HEIGHT_PX = 56;
5
+ export declare const BODY_ROW_CLASS = "h-14 max-h-14";
6
+ /** Group header and "load more" rows (plan 098). */
7
+ export declare const GROUP_ROW_HEIGHT_PX = 36;
8
+ export declare const BODY_ROW_CELL_CLASS = "h-14 max-h-14 align-middle";
9
+ export declare const BODY_CELL_CHROME_CLASS = "relative overflow-hidden p-0";
10
+ export declare const BODY_CELL_INNER_CLASS = "absolute inset-0 flex min-w-0 select-none items-center px-3 py-2";
11
+ /** Tighter inset for image thumbnails; centered in the column. */
12
+ export declare const BODY_CELL_IMAGE_INNER_CLASS = "absolute inset-0 flex min-w-0 select-none items-center justify-start px-3 py-1.5";
13
+ /** Minimum column width so header labels render without truncation. */
14
+ export declare function headerLabelMinWidthPx(label: string): number;
15
+ export declare const IMAGE_COLUMN_WIDTH_PX = 120;
16
+ export declare function gridVisibleColumnCount(visibleFieldCount: number, leftoverSpacer: boolean): number;
17
+ export declare function leadColumnWidthStyle(showIdColumn: boolean): CSSProperties;
18
+ /** Text-like columns share leftover; compact types stay at min unless pinned. */
19
+ export declare function isFlexDataColumn(field: Pick<Field, "type">): boolean;
20
+ export declare function minColumnWidthPx(field?: Pick<Field, "type"> & Partial<Pick<Field, "name" | "label" | "optional">>): number;
21
+ export declare function dataColumnWidthPx(field: Pick<Field, "name" | "type">, colWidths: Record<string, number>): number;
22
+ export declare function needsLeftoverSpacer(visibleFields: readonly Pick<Field, "name" | "type">[], colWidths: Record<string, number>): boolean;
23
+ /** Pixel widths for data columns. Unpinned flex types share leftover equally. */
24
+ export declare function allocateDataColumnWidths(containerWidth: number, showIdColumn: boolean, visibleFields: readonly Pick<Field, "name" | "type">[], colWidths: Record<string, number>): Record<string, number>;
25
+ export declare function gridTableMinWidthPx(showIdColumn: boolean, visibleFields: readonly Pick<Field, "name" | "type">[], colWidths: Record<string, number>): number;
26
+ export declare function columnWidthStyle(field: Pick<Field, "name" | "type">, colWidths: Record<string, number>): CSSProperties;
27
+ export declare function toolbarColumnWidthStyle(): CSSProperties;
@@ -0,0 +1,83 @@
1
+ import type { ReactNode } from "react";
2
+ import { type Field, type FieldType } from "../../../shared/src/index.js";
3
+ import { type CellCoord, type EditingCell, type CellSelection, type SelectionBounds } from "./cell-selection";
4
+ import type { FillDragState } from "./fill-handle";
5
+ import type { InlineEditorPort } from "./grid-editing";
6
+ import type { Selection } from "./selection";
7
+ export type GridBodyRowController<Interaction extends GridBodyRowInteraction = GridBodyRowInteraction> = {
8
+ pendingEdits: Map<string, Record<string, unknown>>;
9
+ changedCellsByRow: Map<string, Set<string>>;
10
+ cellSelection: CellSelection | null;
11
+ editingCell: EditingCell | null;
12
+ /** From `useGridEditing`: the inline editor's flush and its live-draft mirror. */
13
+ inlineEditor: InlineEditorPort;
14
+ onCellClick: (e: React.MouseEvent, rowId: string, fieldName: string) => void;
15
+ onCellDoubleClick: (rowId: string, fieldName: string, type: FieldType) => void;
16
+ onCellKeyDown: (e: React.KeyboardEvent, rowId: string, fieldName: string) => void;
17
+ focusCellDom: (rowId: string, fieldName: string) => void;
18
+ onNavigateAfterCommit: (coord: CellCoord, direction: -1 | 1) => void;
19
+ interaction: Interaction;
20
+ };
21
+ type GridBodyRowBaseProps = {
22
+ /** Table name for storage upload authorization in embedded field editors. */
23
+ tableName?: string;
24
+ row: Record<string, unknown>;
25
+ rowIdx: number;
26
+ showIdColumn: boolean;
27
+ visibleFields: Field[];
28
+ colWidths: Record<string, number>;
29
+ isDraftRow?: (rowId: string) => boolean;
30
+ isCellEditable?: (rowId: string, field: Field) => boolean;
31
+ rowClassName?: string;
32
+ cellClassName?: (rowId: string, field: Field) => string | undefined;
33
+ renderCellAdornment?: (row: Record<string, unknown>, field: Field) => ReactNode;
34
+ statusCellTestId?: string;
35
+ renderRowActions?: (row: Record<string, unknown>) => ReactNode;
36
+ /** Leftover spacer before the toolbar so data columns keep stored widths. */
37
+ trailingSpacer?: boolean;
38
+ };
39
+ export type GridBodyRowGuestInteraction = {
40
+ kind: "guest";
41
+ };
42
+ export type GridBodyRowInteraction = GridBodyRowGuestInteraction | GridBodyRowStudioInteraction;
43
+ export type GridBodyRowStudioInteraction = {
44
+ kind: "studio";
45
+ selectedIds: Selection;
46
+ selectionBounds: SelectionBounds | null;
47
+ fillDrag: FillDragState | null;
48
+ selectionDrag: boolean;
49
+ fileDrop: GridBodyRowFileDropCapability;
50
+ rowActions: GridBodyRowActionsCapability;
51
+ onIdClick: (e: React.MouseEvent, row: Record<string, unknown>) => void;
52
+ onRowMouseEnter: (rowIdx: number) => void;
53
+ onCellPointerDown: (e: React.PointerEvent, rowId: string, fieldName: string, type: FieldType) => void;
54
+ onFillHandlePointerDown: (e: React.PointerEvent, fieldName: string, sourceRowMin: number, sourceRowMax: number) => void;
55
+ onToggleSelectAll: () => void;
56
+ selectAllChecked: boolean;
57
+ selectAllIndeterminate: boolean;
58
+ };
59
+ export type GridBodyRowFileDropCapability = {
60
+ kind: "disabled";
61
+ } | {
62
+ kind: "enabled";
63
+ target: CellCoord | null;
64
+ setTarget: (target: CellCoord | null) => void;
65
+ handleDrop: (e: React.DragEvent, rowId: string, fieldName: string, type: FieldType) => void | Promise<void>;
66
+ };
67
+ export type GridBodyRowActionsCapability = {
68
+ kind: "none";
69
+ } | {
70
+ kind: "default";
71
+ onEditRows: (rows: Record<string, unknown>[]) => void;
72
+ askDelete: (rows: Record<string, unknown>[]) => void;
73
+ } | {
74
+ kind: "restore";
75
+ onRestoreRows: (rows: Record<string, unknown>[]) => void;
76
+ };
77
+ export type GridBodyRowProps = GridBodyRowBaseProps & {
78
+ controller: GridBodyRowController;
79
+ /** Studio rows only: a guest row has no context menu. */
80
+ onRowContextMenu?: (e: React.MouseEvent, row: Record<string, unknown>) => void;
81
+ };
82
+ export declare function GridBodyRow({ tableName, row, rowIdx, showIdColumn, visibleFields, colWidths, controller, onRowContextMenu, isDraftRow, isCellEditable, rowClassName, cellClassName, renderCellAdornment, statusCellTestId, renderRowActions, trailingSpacer, }: GridBodyRowProps): import("react").JSX.Element;
83
+ export {};
@@ -0,0 +1,158 @@
1
+ /**
2
+ * Grid editing: the one owner of live cell drafts and how they become pending edits.
3
+ *
4
+ * Two surfaces edit cells. The inline editor (`CellEditor` from `@columnus/fields`) lives in
5
+ * the cell and keeps its own input; the formula bar edits the focused cell, or one field across
6
+ * a selection. A draft is not a pending edit: it becomes one only when its surface commits.
7
+ *
8
+ * The rules live here, so callers never order flushes or capture targets themselves:
9
+ *
10
+ * - A draft lands where it was typed. The formula bar captures its target at the first edit;
11
+ * later focus or selection changes never redirect it, and moving away commits it there.
12
+ * - The inline editor stages through the same pending edits as the formula bar; a grid that
13
+ * refuses some values (`acceptsInlineValue`) refuses them on every inline path.
14
+ * - Inline typing is mirrored into the formula bar through `draftStore`, display only — a
15
+ * keystroke re-renders the bar, not the grid, and the mirror is never committed by the bar.
16
+ * - Starting an inline edit hands off: an uncommitted formula-bar draft commits first.
17
+ * - Commits are explicit: `committed`, `unchanged` (matches what the draft started from), or
18
+ * `rejected` (invalid, except text kinds, which stage and are refused at Save instead).
19
+ * - A commit clears the draft before it reaches pending edits, so blur, Enter, Save, and
20
+ * unmount cannot commit the same draft twice.
21
+ * - `prepareForSave` flushes the inline editor (which reads its input directly, so the last
22
+ * keystroke counts even before React settles), then the formula bar, then the row preview.
23
+ *
24
+ * `@columnus/fields` stays independent of the grid: `CellEditor` is reached only through the
25
+ * flush ref and draft callback in `inlineEditor`.
26
+ */
27
+ import { type MutableRefObject, type RefObject } from "react";
28
+ import { type Field, type FieldType } from "../../../shared/src/index.js";
29
+ import type { CellCoord, EditingCell } from "./cell-selection";
30
+ import { type InlineEditDraftStore } from "./inline-edit-draft";
31
+ import { type GridPendingRefs, useGridPendingState } from "../hooks/use-grid-pending-state";
32
+ export type CommitOutcome = "committed" | "unchanged" | "rejected";
33
+ /** Where a draft lands: one cell, or one field across a set of rows. */
34
+ export type DraftTarget = {
35
+ kind: "cell";
36
+ rowId: string;
37
+ fieldName: string;
38
+ } | {
39
+ kind: "selection";
40
+ fieldName: string;
41
+ rowIds: readonly string[];
42
+ };
43
+ /** Where committed drafts become pending edits: the grid's pending state. */
44
+ export type GridEditPending = Pick<GridPendingRefs, "setCellPending" | "setSelectionPending">;
45
+ type Flush = () => void;
46
+ /**
47
+ * What a grid row hands to `CellEditor`. `commit` stages and closes the editor; `stage` stages
48
+ * while it stays open (reference pickers). Both refuse values `acceptsInlineValue` rejects,
49
+ * leaving the editor open. Focus and navigation afterwards are the row's.
50
+ */
51
+ export type InlineEditorPort = {
52
+ flushRef: MutableRefObject<Flush | null>;
53
+ publishDraft: (cell: CellCoord, draft: {
54
+ value: unknown;
55
+ } | null) => void;
56
+ stage: (rowId: string, field: Field, value: unknown) => CommitOutcome;
57
+ commit: (rowId: string, field: Field, value: unknown) => CommitOutcome;
58
+ cancel: () => void;
59
+ };
60
+ type FormulaSurface = {
61
+ flush: () => CommitOutcome;
62
+ root: () => HTMLElement | null;
63
+ };
64
+ /** What `CellFormulaBar` needs; it goes through `useFormulaBarDraft`. */
65
+ export type FormulaBarPort = {
66
+ draftStore: InlineEditDraftStore;
67
+ commit: (target: DraftTarget, value: unknown) => void;
68
+ register: (surface: FormulaSurface) => () => void;
69
+ };
70
+ /** The row-preview drawer registers its focused field's commit here (`editFlushRef`). */
71
+ export type RowPreviewPort = {
72
+ flushRef: MutableRefObject<Flush | null>;
73
+ flush: Flush;
74
+ };
75
+ export type GridEditing = {
76
+ /** The cell open in the inline editor; render state. */
77
+ editingCell: EditingCell | null;
78
+ /** The same, read synchronously — for event handlers that run before a re-render. */
79
+ isEditingCell: (cell: CellCoord) => boolean;
80
+ /** Open the inline editor on a cell (handing off a formula-bar draft first), or close it. */
81
+ setEditingCell: (cell: EditingCell | null) => void;
82
+ /** Close the inline editor, committing its draft or discarding it. */
83
+ endInlineEdit: (options: {
84
+ commit: boolean;
85
+ }) => void;
86
+ /** Commit every live draft, in order, before pending edits are read for Save. */
87
+ prepareForSave: () => void;
88
+ inlineEditor: InlineEditorPort;
89
+ formulaBar: FormulaBarPort;
90
+ rowPreview: RowPreviewPort;
91
+ };
92
+ export declare function useGridEditing({ gridRef, pending, acceptsInlineValue, }: {
93
+ gridRef: RefObject<HTMLElement | null>;
94
+ pending: GridEditPending;
95
+ /** A grid that refuses some inline values (guest proposals) says so here. */
96
+ acceptsInlineValue?: (rowId: string, field: Field, value: unknown) => boolean;
97
+ }): GridEditing;
98
+ /**
99
+ * A grid's pending edits and the coordinator that feeds them, built together — the one way a
100
+ * grid on `useGridPendingState` gets both. A grid that keeps pending edits of its own (guest
101
+ * proposals) calls `useGridEditing` with an adapter instead.
102
+ */
103
+ export declare function useGridEditState({ gridRef, ...pendingOptions }: Parameters<typeof useGridPendingState>[0] & {
104
+ gridRef: RefObject<HTMLElement | null>;
105
+ }): {
106
+ pending: {
107
+ pendingEdits: import("./pending-edits").PendingMap;
108
+ pendingDispatch: import("react").Dispatch<import("./pending-edits").PendingHistoryAction>;
109
+ pendingEditsRef: RefObject<import("./pending-edits").PendingMap>;
110
+ canUndoPending: boolean;
111
+ canRedoPending: boolean;
112
+ changedCellsByRow: Map<string, Set<string>>;
113
+ pendingChangeCount: number;
114
+ pendingCellCount: number;
115
+ runPendingUpdate: (updater: (prev: import("./pending-edits").PendingMap) => import("./pending-edits").PendingMap) => void;
116
+ setCellPending: (rowId: string, fieldName: string, value: unknown) => void;
117
+ resolveCellValue: (rowId: string, fieldName: string) => unknown;
118
+ unsavedRow: (id: string) => Record<string, unknown>;
119
+ startingRow: (id: string) => Record<string, unknown> | undefined;
120
+ setSelectionPending: (fieldName: string, rowIds: readonly string[], value: unknown) => void;
121
+ setCellsPending: (fieldName: string, cells: readonly {
122
+ rowId: string;
123
+ value: unknown;
124
+ }[]) => void;
125
+ clearAllPending: () => () => void;
126
+ clearSavedEdits: ({ updates, insertedFrom }: Extract<import("..").PendingEditPlan, {
127
+ status: "ready";
128
+ }>) => void;
129
+ getBaseline: (rowId: string, fieldName: string) => unknown;
130
+ };
131
+ editing: GridEditing;
132
+ };
133
+ /** What the formula bar is looking at this render. */
134
+ export type FormulaDraftView = {
135
+ target: DraftTarget | null;
136
+ /** Shown while there is no draft of the bar's own: the cell, inline mirror, or selection value. */
137
+ value: unknown;
138
+ type: FieldType | undefined;
139
+ optional: boolean | undefined;
140
+ };
141
+ /**
142
+ * The formula bar's draft. `edit` starts or continues it; `commit` lands it on the target it
143
+ * was started on and reports where; `apply` commits a chosen value outright (commit-on-change kinds, "apply to
144
+ * all"); `cancel` drops it. Without a draft of its own the bar follows `view.value`.
145
+ */
146
+ export declare function useFormulaBarDraft(port: FormulaBarPort, view: FormulaDraftView): {
147
+ draft: unknown;
148
+ key: string | null;
149
+ edit: (next: unknown) => void;
150
+ commit: () => {
151
+ outcome: CommitOutcome;
152
+ target: DraftTarget | null;
153
+ };
154
+ apply: (next: unknown) => CommitOutcome;
155
+ cancel: () => void;
156
+ rootRef: RefObject<HTMLDivElement | null>;
157
+ };
158
+ export {};
@@ -0,0 +1,10 @@
1
+ /** React synthetic events from portaled children (popovers, dropdowns) bubble to
2
+ * `currentTarget` but their targets live elsewhere in the DOM. Use composedPath()
3
+ * to detect legitimate clicks that restructured between dispatch and handler. */
4
+ export declare function isOwnEvent(e: React.SyntheticEvent): boolean;
5
+ /** Record-link chips open a popover on click; grid pointerdown must not preventDefault. */
6
+ export declare function isRecordLinkChipTarget(target: EventTarget | null, nativeEvent?: Event): boolean;
7
+ /** Buttons and other inline chrome inside a cell should not start selection drags. */
8
+ export declare function isCellChromeTarget(target: EventTarget | null, nativeEvent?: Event): boolean;
9
+ export declare function isRowContextMenuTarget(target: EventTarget | null): boolean;
10
+ export declare function fieldNameFromRowContextTarget(target: HTMLElement, rowId: string): string | undefined;