@rebasepro/admin 0.5.0 → 0.6.1

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 (348) hide show
  1. package/README.md +7 -3
  2. package/dist/CollectionEditorDialog-HNXGxXdO.js +3549 -0
  3. package/dist/CollectionEditorDialog-HNXGxXdO.js.map +1 -0
  4. package/dist/CollectionsStudioView-B1mN33GB.js +170 -0
  5. package/dist/CollectionsStudioView-B1mN33GB.js.map +1 -0
  6. package/dist/PropertyEditView-C2wp8kQ9.js +3660 -0
  7. package/dist/PropertyEditView-C2wp8kQ9.js.map +1 -0
  8. package/dist/collection_editor/ConfigControllerProvider.d.ts +2 -2
  9. package/dist/collection_editor/ui/AddKanbanColumnAction.d.ts +2 -1
  10. package/dist/collection_editor/ui/CollectionViewHeaderAction.d.ts +2 -1
  11. package/dist/collection_editor/ui/EditorCollectionAction.d.ts +1 -1
  12. package/dist/collection_editor/ui/EditorCollectionActionStart.d.ts +1 -1
  13. package/dist/collection_editor/ui/EditorEntityAction.d.ts +1 -1
  14. package/dist/collection_editor/ui/HomePageEditorCollectionAction.d.ts +1 -1
  15. package/dist/collection_editor/ui/KanbanSetupAction.d.ts +2 -1
  16. package/dist/collection_editor/ui/MissingReferenceWidget.d.ts +1 -1
  17. package/dist/collection_editor/ui/NewCollectionButton.d.ts +1 -1
  18. package/dist/collection_editor/ui/NewCollectionCard.d.ts +1 -1
  19. package/dist/collection_editor/ui/PropertyAddColumnComponent.d.ts +1 -1
  20. package/dist/collection_editor/ui/collection_editor/AICollectionGeneratorPopover.d.ts +1 -1
  21. package/dist/collection_editor/ui/collection_editor/AIModifiedPathsContext.d.ts +1 -1
  22. package/dist/collection_editor/ui/collection_editor/CollectionDetailsForm.d.ts +2 -1
  23. package/dist/collection_editor/ui/collection_editor/CollectionEditorDialog.d.ts +2 -2
  24. package/dist/collection_editor/ui/collection_editor/CollectionEditorWelcomeView.d.ts +2 -2
  25. package/dist/collection_editor/ui/collection_editor/CollectionJsonImportDialog.d.ts +2 -1
  26. package/dist/collection_editor/ui/collection_editor/CollectionPropertiesEditorForm.d.ts +1 -1
  27. package/dist/collection_editor/ui/collection_editor/CollectionRLSTab.d.ts +2 -1
  28. package/dist/collection_editor/ui/collection_editor/CollectionRelationsTab.d.ts +2 -1
  29. package/dist/collection_editor/ui/collection_editor/CollectionStudioView.d.ts +2 -1
  30. package/dist/collection_editor/ui/collection_editor/CollectionYupValidation.d.ts +1 -9
  31. package/dist/collection_editor/ui/collection_editor/CollectionsStudioView.d.ts +2 -1
  32. package/dist/collection_editor/ui/collection_editor/DisplaySettingsForm.d.ts +2 -1
  33. package/dist/collection_editor/ui/collection_editor/EntityActionsEditTab.d.ts +2 -1
  34. package/dist/collection_editor/ui/collection_editor/EntityActionsSelectDialog.d.ts +2 -1
  35. package/dist/collection_editor/ui/collection_editor/EntityCustomViewsSelectDialog.d.ts +2 -1
  36. package/dist/collection_editor/ui/collection_editor/EnumForm.d.ts +2 -1
  37. package/dist/collection_editor/ui/collection_editor/GeneralSettingsForm.d.ts +2 -1
  38. package/dist/collection_editor/ui/collection_editor/GetCodeDialog.d.ts +2 -1
  39. package/dist/collection_editor/ui/collection_editor/KanbanConfigSection.d.ts +2 -1
  40. package/dist/collection_editor/ui/collection_editor/LayoutModeSwitch.d.ts +1 -1
  41. package/dist/collection_editor/ui/collection_editor/PropertyEditView.d.ts +4 -4
  42. package/dist/collection_editor/ui/collection_editor/PropertyFieldPreview.d.ts +2 -2
  43. package/dist/collection_editor/ui/collection_editor/PropertyTree.d.ts +2 -2
  44. package/dist/collection_editor/ui/collection_editor/SubcollectionsEditTab.d.ts +2 -1
  45. package/dist/collection_editor/ui/collection_editor/SwitchControl.d.ts +2 -1
  46. package/dist/collection_editor/ui/collection_editor/ViewModeSwitch.d.ts +1 -1
  47. package/dist/collection_editor/ui/collection_editor/import/CollectionEditorImportDataPreview.d.ts +1 -1
  48. package/dist/collection_editor/ui/collection_editor/import/CollectionEditorImportMapping.d.ts +3 -2
  49. package/dist/collection_editor/ui/collection_editor/properties/BlockPropertyField.d.ts +2 -1
  50. package/dist/collection_editor/ui/collection_editor/properties/BooleanPropertyField.d.ts +2 -1
  51. package/dist/collection_editor/ui/collection_editor/properties/DateTimePropertyField.d.ts +2 -1
  52. package/dist/collection_editor/ui/collection_editor/properties/EnumPropertyField.d.ts +2 -1
  53. package/dist/collection_editor/ui/collection_editor/properties/KeyValuePropertyField.d.ts +2 -1
  54. package/dist/collection_editor/ui/collection_editor/properties/MapPropertyField.d.ts +2 -1
  55. package/dist/collection_editor/ui/collection_editor/properties/MarkdownPropertyField.d.ts +2 -1
  56. package/dist/collection_editor/ui/collection_editor/properties/NumberPropertyField.d.ts +2 -1
  57. package/dist/collection_editor/ui/collection_editor/properties/ReferencePropertyField.d.ts +3 -2
  58. package/dist/collection_editor/ui/collection_editor/properties/RelationPropertyField.d.ts +2 -1
  59. package/dist/collection_editor/ui/collection_editor/properties/RepeatPropertyField.d.ts +2 -1
  60. package/dist/collection_editor/ui/collection_editor/properties/StoragePropertyField.d.ts +2 -1
  61. package/dist/collection_editor/ui/collection_editor/properties/StringPropertyField.d.ts +2 -1
  62. package/dist/collection_editor/ui/collection_editor/properties/UrlPropertyField.d.ts +2 -1
  63. package/dist/collection_editor/ui/collection_editor/properties/VectorPropertyField.d.ts +2 -1
  64. package/dist/collection_editor/ui/collection_editor/properties/advanced/AdvancedPropertyValidation.d.ts +2 -1
  65. package/dist/collection_editor/ui/collection_editor/properties/conditions/ConditionsEditor.d.ts +2 -1
  66. package/dist/collection_editor/ui/collection_editor/properties/conditions/ConditionsPanel.d.ts +1 -1
  67. package/dist/collection_editor/ui/collection_editor/properties/conditions/EnumConditionsEditor.d.ts +2 -1
  68. package/dist/collection_editor/ui/collection_editor/properties/validation/ArrayPropertyValidation.d.ts +2 -1
  69. package/dist/collection_editor/ui/collection_editor/properties/validation/GeneralPropertyValidation.d.ts +2 -1
  70. package/dist/collection_editor/ui/collection_editor/properties/validation/NumberPropertyValidation.d.ts +2 -1
  71. package/dist/collection_editor/ui/collection_editor/properties/validation/StringPropertyValidation.d.ts +2 -1
  72. package/dist/collection_editor/ui/collection_editor/properties/validation/ValidationPanel.d.ts +1 -1
  73. package/dist/collection_editor_ui.js +4 -11
  74. package/dist/components/ArrayContainer.d.ts +3 -3
  75. package/dist/components/ClearFilterSortButton.d.ts +1 -1
  76. package/dist/components/CollectionEditorDialogs.d.ts +2 -1
  77. package/dist/components/CollectionPanel.d.ts +2 -27
  78. package/dist/components/DefaultAppBar.d.ts +1 -1
  79. package/dist/components/DefaultDrawer.d.ts +4 -4
  80. package/dist/components/DeleteEntityDialog.d.ts +2 -1
  81. package/dist/components/DrawerNavigationGroup.d.ts +1 -1
  82. package/dist/components/DrawerNavigationItem.d.ts +1 -1
  83. package/dist/components/EntityCollectionTable/EntityCollectionRowActions.d.ts +1 -1
  84. package/dist/components/EntityCollectionTable/EntityCollectionTable.d.ts +2 -1
  85. package/dist/components/EntityCollectionTable/fields/TableMultipleRelationField.d.ts +3 -3
  86. package/dist/components/EntityCollectionTable/fields/TableReferenceField.d.ts +3 -3
  87. package/dist/components/EntityCollectionTable/fields/TableRelationField.d.ts +3 -3
  88. package/dist/components/EntityCollectionTable/fields/TableRelationSelectorField.d.ts +2 -1
  89. package/dist/components/EntityCollectionTable/fields/TableStorageUpload.d.ts +2 -2
  90. package/dist/components/EntityCollectionTable/fields/VirtualTableDateField.d.ts +1 -1
  91. package/dist/components/EntityCollectionTable/fields/VirtualTableInput.d.ts +2 -1
  92. package/dist/components/EntityCollectionTable/fields/VirtualTableNumberInput.d.ts +2 -1
  93. package/dist/components/EntityCollectionTable/fields/VirtualTableSelect.d.ts +1 -1
  94. package/dist/components/EntityCollectionTable/fields/VirtualTableSwitch.d.ts +2 -1
  95. package/dist/components/EntityCollectionTable/fields/VirtualTableUserSelect.d.ts +1 -1
  96. package/dist/components/EntityCollectionTable/internal/CollectionTableToolbar.d.ts +1 -1
  97. package/dist/components/EntityCollectionTable/internal/EntityTableCellActions.d.ts +1 -1
  98. package/dist/components/EntityCollectionTable/internal/popup_field/PopupFormField.d.ts +4 -3
  99. package/dist/components/EntityCollectionView/Board.d.ts +2 -1
  100. package/dist/components/EntityCollectionView/BoardColumnTitle.d.ts +1 -1
  101. package/dist/components/EntityCollectionView/BoardSortableList.d.ts +1 -1
  102. package/dist/components/EntityCollectionView/EntityBoardCard.d.ts +1 -1
  103. package/dist/components/EntityCollectionView/EntityCard.d.ts +2 -1
  104. package/dist/components/EntityCollectionView/EntityCollectionBoardView.d.ts +1 -1
  105. package/dist/components/EntityCollectionView/EntityCollectionCardView.d.ts +1 -1
  106. package/dist/components/EntityCollectionView/EntityCollectionListView.d.ts +1 -1
  107. package/dist/components/EntityCollectionView/EntityCollectionView.d.ts +0 -24
  108. package/dist/components/EntityCollectionView/EntityCollectionViewActions.d.ts +1 -1
  109. package/dist/components/EntityCollectionView/EntityCollectionViewStartActions.d.ts +2 -1
  110. package/dist/components/EntityCollectionView/FilterPresetsButton.d.ts +2 -1
  111. package/dist/components/EntityCollectionView/FiltersDialog.d.ts +2 -1
  112. package/dist/components/EntityCollectionView/SplitListView.d.ts +1 -1
  113. package/dist/components/EntityCollectionView/ViewModeToggle.d.ts +2 -1
  114. package/dist/components/EntityDetailView.d.ts +1 -1
  115. package/dist/components/EntityEditView.d.ts +2 -2
  116. package/dist/components/EntityEditViewFormActions.d.ts +2 -1
  117. package/dist/components/EntityJsonPreview.d.ts +2 -1
  118. package/dist/components/EntityPreview.d.ts +3 -3
  119. package/dist/components/EntitySidePanel.d.ts +2 -1
  120. package/dist/components/EntityView.d.ts +2 -1
  121. package/dist/components/FieldCaption.d.ts +1 -1
  122. package/dist/components/HomePage/ContentHomePage.d.ts +1 -1
  123. package/dist/components/HomePage/FavouritesView.d.ts +1 -1
  124. package/dist/components/HomePage/HomePageDnD.d.ts +4 -4
  125. package/dist/components/HomePage/NavigationCard.d.ts +1 -1
  126. package/dist/components/HomePage/NavigationCardBinding.d.ts +2 -1
  127. package/dist/components/HomePage/NavigationGroup.d.ts +2 -2
  128. package/dist/components/HomePage/RenameGroupDialog.d.ts +2 -1
  129. package/dist/components/HomePage/SmallNavigationCard.d.ts +1 -1
  130. package/dist/components/PropertyCollectionView.d.ts +2 -1
  131. package/dist/components/PropertyIdCopyTooltip.d.ts +2 -2
  132. package/dist/components/RebaseAuthGate.d.ts +1 -1
  133. package/dist/components/RebaseLayout.d.ts +1 -1
  134. package/dist/components/RebaseNavigation.d.ts +1 -1
  135. package/dist/components/RebaseRouteDefs.d.ts +1 -1
  136. package/dist/components/RebaseShell.d.ts +1 -1
  137. package/dist/components/ReferenceTable/EntitySelectionTable.d.ts +1 -1
  138. package/dist/components/ReferenceWidget.d.ts +2 -1
  139. package/dist/components/SearchIconsView.d.ts +2 -1
  140. package/dist/components/SelectableTable/SelectableTable.d.ts +2 -2
  141. package/dist/components/SelectableTable/filters/BooleanFilterField.d.ts +2 -1
  142. package/dist/components/SelectableTable/filters/DateTimeFilterField.d.ts +2 -1
  143. package/dist/components/SelectableTable/filters/ReferenceFilterField.d.ts +2 -1
  144. package/dist/components/SelectableTable/filters/RelationFilterField.d.ts +2 -1
  145. package/dist/components/SelectableTable/filters/StringNumberFilterField.d.ts +2 -1
  146. package/dist/components/SideDialogs.d.ts +1 -1
  147. package/dist/components/SideEntityProvider.d.ts +1 -1
  148. package/dist/components/admin/CreationResultDialog.d.ts +2 -1
  149. package/dist/components/app/AppBar.d.ts +1 -1
  150. package/dist/components/app/Drawer.d.ts +1 -1
  151. package/dist/components/common/default_entity_actions.d.ts +2 -1
  152. package/dist/components/history/EntityHistoryEntry.d.ts +1 -1
  153. package/dist/components/history/EntityHistoryView.d.ts +1 -1
  154. package/dist/components/history/LastEditedByFormAction.d.ts +2 -1
  155. package/dist/components/history/LastEditedByIndicator.d.ts +2 -1
  156. package/dist/components/history/UserChip.d.ts +1 -1
  157. package/dist/data_export/export/BasicExportAction.d.ts +2 -1
  158. package/dist/data_export/export/ExportCollectionAction.d.ts +1 -1
  159. package/dist/data_import/components/DataNewPropertiesMapping.d.ts +1 -1
  160. package/dist/data_import/components/ImportFileUpload.d.ts +1 -1
  161. package/dist/data_import/components/ImportNewPropertyFieldPreview.d.ts +2 -1
  162. package/dist/data_import/components/ImportSaveInProgress.d.ts +1 -1
  163. package/dist/data_import/import/ImportCollectionAction.d.ts +4 -3
  164. package/dist/editor/components/SlashCommandMenu.d.ts +2 -1
  165. package/dist/editor/editor.d.ts +10 -4
  166. package/dist/editor/selectors/color-selector.d.ts +1 -1
  167. package/dist/editor/selectors/link-selector.d.ts +1 -1
  168. package/dist/editor/selectors/node-selector.d.ts +1 -1
  169. package/dist/editor/selectors/text-buttons.d.ts +1 -1
  170. package/dist/editor.js +2623 -3574
  171. package/dist/editor.js.map +1 -1
  172. package/dist/form/EntityForm.d.ts +2 -1
  173. package/dist/form/EntityFormActions.d.ts +2 -1
  174. package/dist/form/components/FieldHelperText.d.ts +1 -1
  175. package/dist/form/components/FormEntry.d.ts +1 -1
  176. package/dist/form/components/FormLayout.d.ts +1 -1
  177. package/dist/form/components/LabelWithIconAndTooltip.d.ts +1 -1
  178. package/dist/form/components/LocalChangesMenu.d.ts +2 -1
  179. package/dist/form/components/StorageItemPreview.d.ts +2 -1
  180. package/dist/form/components/StorageUploadProgress.d.ts +2 -1
  181. package/dist/form/field_bindings/ArrayCustomShapedFieldBinding.d.ts +2 -1
  182. package/dist/form/field_bindings/ArrayOfReferencesFieldBinding.d.ts +2 -1
  183. package/dist/form/field_bindings/BlockFieldBinding.d.ts +2 -1
  184. package/dist/form/field_bindings/DateTimeFieldBinding.d.ts +2 -1
  185. package/dist/form/field_bindings/KeyValueFieldBinding.d.ts +2 -1
  186. package/dist/form/field_bindings/MapFieldBinding.d.ts +2 -1
  187. package/dist/form/field_bindings/MarkdownEditorFieldBinding.d.ts +4 -3
  188. package/dist/form/field_bindings/MultiSelectFieldBinding.d.ts +2 -1
  189. package/dist/form/field_bindings/MultipleRelationFieldBinding.d.ts +2 -1
  190. package/dist/form/field_bindings/ReadOnlyFieldBinding.d.ts +2 -1
  191. package/dist/form/field_bindings/ReferenceAsStringFieldBinding.d.ts +2 -1
  192. package/dist/form/field_bindings/ReferenceFieldBinding.d.ts +2 -1
  193. package/dist/form/field_bindings/RelationFieldBinding.d.ts +2 -1
  194. package/dist/form/field_bindings/RepeatFieldBinding.d.ts +2 -1
  195. package/dist/form/field_bindings/SelectFieldBinding.d.ts +2 -1
  196. package/dist/form/field_bindings/StorageUploadFieldBinding.d.ts +3 -2
  197. package/dist/form/field_bindings/SwitchFieldBinding.d.ts +2 -1
  198. package/dist/form/field_bindings/TextFieldBinding.d.ts +2 -1
  199. package/dist/form/field_bindings/UserSelectFieldBinding.d.ts +2 -1
  200. package/dist/form/field_bindings/VectorFieldBinding.d.ts +2 -1
  201. package/dist/history-BO6VT85a.js +311 -0
  202. package/dist/history-BO6VT85a.js.map +1 -0
  203. package/dist/hooks/navigation/useBuildNavigationStateController.d.ts +0 -2
  204. package/dist/hooks/navigation/useNavigationResolution.d.ts +5 -6
  205. package/dist/hooks/navigation/useResolvedCollections.d.ts +0 -2
  206. package/dist/hooks/useBreadcrumbsController.d.ts +2 -32
  207. package/dist/index.d.ts +1 -1
  208. package/dist/index.js +2 -3393
  209. package/dist/markdown-CklalUUk.js +526 -0
  210. package/dist/markdown-CklalUUk.js.map +1 -0
  211. package/dist/preview/components/ArrayEnumPreview.d.ts +2 -1
  212. package/dist/preview/components/EmptyValue.d.ts +2 -1
  213. package/dist/preview/components/EnumValuesChip.d.ts +1 -1
  214. package/dist/preview/components/ImagePreview.d.ts +2 -1
  215. package/dist/preview/components/ReferencePreview.d.ts +2 -1
  216. package/dist/preview/components/RelationPreview.d.ts +2 -1
  217. package/dist/preview/components/StorageThumbnail.d.ts +1 -1
  218. package/dist/preview/components/UserPreview.d.ts +6 -3
  219. package/dist/preview/property_previews/ArrayOfMapsPreview.d.ts +2 -1
  220. package/dist/preview/property_previews/ArrayOfReferencesPreview.d.ts +1 -1
  221. package/dist/preview/property_previews/ArrayOfRelationsPreview.d.ts +1 -1
  222. package/dist/preview/property_previews/ArrayOfStorageComponentsPreview.d.ts +2 -1
  223. package/dist/preview/property_previews/ArrayOfStringsPreview.d.ts +2 -1
  224. package/dist/preview/property_previews/ArrayOneOfPreview.d.ts +2 -1
  225. package/dist/preview/property_previews/ArrayPropertyEnumPreview.d.ts +1 -1
  226. package/dist/preview/property_previews/ArrayPropertyPreview.d.ts +2 -1
  227. package/dist/preview/property_previews/MapPropertyPreview.d.ts +3 -2
  228. package/dist/preview/property_previews/SkeletonPropertyComponent.d.ts +5 -4
  229. package/dist/rolldown-runtime-D7D4PA-g.js +13 -0
  230. package/dist/routes/RebaseRoute.d.ts +1 -1
  231. package/dist/src-BYniefVu.js +24011 -0
  232. package/dist/src-BYniefVu.js.map +1 -0
  233. package/dist/types/components/PropertyPreviewProps.d.ts +4 -0
  234. package/dist/types/components/formex.d.ts +1 -40
  235. package/dist/types/fields.d.ts +9 -1
  236. package/dist/util/navigation_utils.d.ts +2 -1
  237. package/dist/util/previews.d.ts +5 -0
  238. package/dist/util/property_utils.d.ts +1 -1
  239. package/package.json +29 -26
  240. package/src/collection_editor/ConfigControllerProvider.tsx +10 -7
  241. package/src/collection_editor/ui/AddKanbanColumnAction.tsx +2 -0
  242. package/src/collection_editor/ui/CollectionViewHeaderAction.tsx +2 -1
  243. package/src/collection_editor/ui/EditorCollectionAction.tsx +2 -1
  244. package/src/collection_editor/ui/EditorCollectionActionStart.tsx +2 -1
  245. package/src/collection_editor/ui/EditorEntityAction.tsx +2 -1
  246. package/src/collection_editor/ui/KanbanSetupAction.tsx +2 -1
  247. package/src/collection_editor/ui/MissingReferenceWidget.tsx +2 -1
  248. package/src/collection_editor/ui/PropertyAddColumnComponent.tsx +2 -1
  249. package/src/collection_editor/ui/collection_editor/CollectionDetailsForm.tsx +2 -3
  250. package/src/collection_editor/ui/collection_editor/CollectionEditorDialog.tsx +0 -1
  251. package/src/collection_editor/ui/collection_editor/CollectionPropertiesEditorForm.tsx +8 -4
  252. package/src/collection_editor/ui/collection_editor/DisplaySettingsForm.tsx +2 -1
  253. package/src/collection_editor/ui/collection_editor/PropertyEditView.tsx +1 -1
  254. package/src/collection_editor/ui/collection_editor/properties/RelationPropertyField.tsx +5 -2
  255. package/src/collection_editor/useLocalCollectionsConfigController.tsx +7 -2
  256. package/src/collection_editor/validateCollectionJson.ts +2 -2
  257. package/src/components/ArrayContainer.tsx +5 -5
  258. package/src/components/CollectionPanel.tsx +51 -25
  259. package/src/components/DefaultAppBar.tsx +1 -2
  260. package/src/components/DefaultDrawer.tsx +3 -2
  261. package/src/components/DrawerNavigationGroup.tsx +3 -2
  262. package/src/components/DrawerNavigationItem.tsx +4 -4
  263. package/src/components/EntityCollectionTable/fields/TableReferenceField.tsx +30 -9
  264. package/src/components/EntityCollectionTable/internal/EntityTableCell.tsx +1 -1
  265. package/src/components/EntityCollectionTable/internal/popup_field/PopupFormField.tsx +1 -0
  266. package/src/components/EntityCollectionView/Board.tsx +10 -8
  267. package/src/components/EntityCollectionView/BoardSortableList.tsx +2 -2
  268. package/src/components/EntityCollectionView/EntityCollectionBoardView.tsx +6 -2
  269. package/src/components/EntityCollectionView/EntityCollectionCardView.tsx +14 -4
  270. package/src/components/EntityCollectionView/EntityCollectionListView.tsx +48 -26
  271. package/src/components/EntityCollectionView/EntityCollectionView.tsx +146 -73
  272. package/src/components/EntityCollectionView/EntityCollectionViewActions.tsx +2 -1
  273. package/src/components/EntityCollectionView/EntityCollectionViewStartActions.tsx +3 -2
  274. package/src/components/EntityCollectionView/FilterPresetsButton.tsx +4 -2
  275. package/src/components/EntityCollectionView/ViewModeToggle.tsx +0 -1
  276. package/src/components/EntityCollectionView/useBoardDataController.tsx +17 -15
  277. package/src/components/EntityCollectionView/useEntityPreviewSlots.ts +29 -19
  278. package/src/components/EntityDetailView.tsx +66 -30
  279. package/src/components/EntityEditView.tsx +70 -32
  280. package/src/components/EntitySidePanel.tsx +6 -3
  281. package/src/components/HomePage/ContentHomePage.tsx +3 -3
  282. package/src/components/HomePage/NavigationCard.tsx +9 -15
  283. package/src/components/HomePage/NavigationCardBinding.tsx +1 -1
  284. package/src/components/HomePage/NavigationGroup.tsx +1 -1
  285. package/src/components/HomePage/SmallNavigationCard.tsx +1 -5
  286. package/src/components/RebaseLayout.tsx +5 -2
  287. package/src/components/RebaseNavigation.tsx +1 -4
  288. package/src/components/RebaseRouteDefs.tsx +5 -3
  289. package/src/components/SearchIconsView.tsx +1 -1
  290. package/src/components/SelectableTable/SelectableTable.tsx +2 -3
  291. package/src/components/SelectableTable/SelectionStore.ts +9 -3
  292. package/src/components/SelectableTable/filters/StringNumberFilterField.tsx +28 -21
  293. package/src/components/UserSelector.tsx +92 -2
  294. package/src/components/common/default_entity_actions.tsx +33 -8
  295. package/src/components/field_configs.tsx +6 -3
  296. package/src/editor/editor.tsx +15 -9
  297. package/src/editor/extensions/Image/index.ts +2 -2
  298. package/src/editor/extensions/Image.ts +2 -2
  299. package/src/editor/extensions/clipboard.ts +2 -2
  300. package/src/editor/markdown-it-plugins.d.ts +24 -0
  301. package/src/editor/markdown.ts +2 -3
  302. package/src/form/EntityForm.tsx +21 -15
  303. package/src/form/field_bindings/MapFieldBinding.tsx +3 -3
  304. package/src/form/field_bindings/MarkdownEditorFieldBinding.tsx +4 -4
  305. package/src/form/field_bindings/StorageUploadFieldBinding.tsx +1 -1
  306. package/src/form/field_bindings/VectorFieldBinding.tsx +3 -3
  307. package/src/form/validation.ts +17 -15
  308. package/src/hooks/navigation/useBuildNavigationStateController.tsx +3 -6
  309. package/src/hooks/navigation/useNavigationResolution.ts +143 -19
  310. package/src/hooks/navigation/useResolvedCollections.ts +4 -6
  311. package/src/hooks/useBreadcrumbsController.tsx +2 -34
  312. package/src/hooks/useBuildSideEntityController.tsx +25 -3
  313. package/src/index.ts +2 -2
  314. package/src/preview/PropertyPreview.tsx +6 -2
  315. package/src/preview/components/ReferencePreview.tsx +64 -13
  316. package/src/preview/components/RelationPreview.tsx +101 -13
  317. package/src/preview/components/UserPreview.tsx +5 -14
  318. package/src/preview/property_previews/ArrayOfMapsPreview.tsx +1 -1
  319. package/src/routes/RebaseRoute.tsx +5 -4
  320. package/src/types/components/PropertyPreviewProps.tsx +5 -0
  321. package/src/types/components/formex.tsx +1 -45
  322. package/src/types/fields.tsx +10 -1
  323. package/src/util/navigation_utils.ts +14 -4
  324. package/src/util/previews.ts +101 -4
  325. package/dist/CollectionEditorDialog-C8E440oK.js +0 -4574
  326. package/dist/CollectionEditorDialog-C8E440oK.js.map +0 -1
  327. package/dist/CollectionsStudioView-Brr_b06v.js +0 -217
  328. package/dist/CollectionsStudioView-Brr_b06v.js.map +0 -1
  329. package/dist/ExportCollectionAction-D3TTYXrq.js +0 -446
  330. package/dist/ExportCollectionAction-D3TTYXrq.js.map +0 -1
  331. package/dist/ImportCollectionAction-Dn7lya6E.js +0 -685
  332. package/dist/ImportCollectionAction-Dn7lya6E.js.map +0 -1
  333. package/dist/PropertyEditView-ChBleIbN.js +0 -8197
  334. package/dist/PropertyEditView-ChBleIbN.js.map +0 -1
  335. package/dist/collection_editor_ui.js.map +0 -1
  336. package/dist/index-D3S9x_RP.js +0 -462
  337. package/dist/index-D3S9x_RP.js.map +0 -1
  338. package/dist/index-D9RNzm01.js +0 -12
  339. package/dist/index-D9RNzm01.js.map +0 -1
  340. package/dist/index-DrrT332R.js +0 -8
  341. package/dist/index-DrrT332R.js.map +0 -1
  342. package/dist/index.js.map +0 -1
  343. package/dist/markdown-DD2JDU1X.js +0 -618
  344. package/dist/markdown-DD2JDU1X.js.map +0 -1
  345. package/dist/useEntityHistory-UVsSclfZ.js +0 -123
  346. package/dist/useEntityHistory-UVsSclfZ.js.map +0 -1
  347. package/dist/util-COYYD8zr.js +0 -30474
  348. package/dist/util-COYYD8zr.js.map +0 -1
@@ -31,7 +31,7 @@ import { EntityFormActions } from "./EntityFormActions";
31
31
  import type { EntityFormActionsProps } from "../types/components/EntityFormActionsProps";
32
32
  import { LocalChangesMenu } from "./components/LocalChangesMenu";
33
33
 
34
- import { getEntityTitlePropertyKey } from "../util/previews";
34
+ import { getEntityTitlePropertyKey, resolveTitleToString } from "../util/previews";
35
35
  import { getValueInPath, isObject, mergeDeep } from "@rebasepro/utils";
36
36
  import { useCollectionRegistryController, useSideEntityController, useCMSContext } from "../index";
37
37
 
@@ -249,11 +249,19 @@ export function EntityForm<M extends Record<string, unknown>>({
249
249
 
250
250
  return save(values)
251
251
  ?.then((savedEntity) => {
252
- formexController.resetForm({
253
- values: savedEntity?.values || values,
254
- submitCount: 0,
255
- touched: {}
256
- });
252
+ if (savedEntity) {
253
+ formexController.resetForm({
254
+ values: savedEntity.values || values,
255
+ submitCount: 0,
256
+ touched: {}
257
+ });
258
+ if (!autoSave) {
259
+ snackbarController.open({
260
+ type: "success",
261
+ message: `${collection.singularName ?? collection.name}: ${t("saved_correctly")}`
262
+ });
263
+ }
264
+ }
257
265
  })
258
266
  .finally(() => {
259
267
  formexController.setSubmitting(false);
@@ -372,11 +380,6 @@ export function EntityForm<M extends Record<string, unknown>>({
372
380
 
373
381
  clearDirtyCache();
374
382
  onValuesModified?.(false, updatedEntity.values);
375
- if (!autoSave)
376
- snackbarController.open({
377
- type: "success",
378
- message: `${collection.singularName ?? collection.name}: ${t("saved_correctly")}`
379
- });
380
383
  onEntityChange?.(updatedEntity);
381
384
  updateStatus("existing");
382
385
  setEntityId(updatedEntity.id);
@@ -502,6 +505,7 @@ export function EntityForm<M extends Record<string, unknown>>({
502
505
  entityId: entityId as string,
503
506
  path,
504
507
  save,
508
+ submit: formex.handleSubmit,
505
509
  formex,
506
510
  entity,
507
511
  savingError,
@@ -520,7 +524,8 @@ export function EntityForm<M extends Record<string, unknown>>({
520
524
 
521
525
  const formActionProps: PluginFormActionProps = {
522
526
  entityId,
523
- parentCollectionSlugs, parentEntityIds,
527
+ parentCollectionSlugs,
528
+ parentEntityIds,
524
529
  path: path,
525
530
  status,
526
531
  collection: collection as EntityCollection,
@@ -534,9 +539,10 @@ export function EntityForm<M extends Record<string, unknown>>({
534
539
  const pluginFormAfter = useSlot("form.after", formActionProps);
535
540
 
536
541
  const titlePropertyKey = getEntityTitlePropertyKey(collection, customizationController.propertyConfigs);
537
- const title = (formex.values && titlePropertyKey ? getValueInPath(formex.values, titlePropertyKey) as React.ReactNode : undefined)
538
- ?? collection.singularName
539
- ?? collection.name;
542
+ const rawTitle = formex.values && titlePropertyKey ? getValueInPath(formex.values, titlePropertyKey) : undefined;
543
+ const title = rawTitle !== undefined && rawTitle !== null
544
+ ? resolveTitleToString(rawTitle)
545
+ : (collection.singularName ?? collection.name);
540
546
 
541
547
  useEffect(() => {
542
548
  if (!autoSave) {
@@ -38,7 +38,7 @@ export function MapFieldBinding({
38
38
  const { t } = useTranslation();
39
39
 
40
40
  if (!property.properties) {
41
- throw Error(`You need to specify a 'properties' prop (or specify a custom field) in your map property ${propertyKey}`);
41
+ throw Error(`You need to specify a 'properties' prop (or specify a custom field) in your map property '${propertyKey}'${property.name ? ` ("${property.name}")` : ""}`);
42
42
  }
43
43
 
44
44
  const mapProperties = property.properties;
@@ -82,7 +82,6 @@ export function MapFieldBinding({
82
82
  </div>
83
83
 
84
84
 
85
-
86
85
  </>
87
86
  ;
88
87
 
@@ -92,7 +91,8 @@ export function MapFieldBinding({
92
91
  {!minimalistView && <ExpandablePanel initiallyExpanded={expanded}
93
92
  onExpandedChange={(expanded: boolean) => {
94
93
  onPropertyChange?.({
95
- ui: { ...property.ui, expanded }
94
+ ui: { ...property.ui,
95
+ expanded }
96
96
  });
97
97
  }}
98
98
  className={property.ui?.widthPercentage !== undefined ? "mt-8" : undefined}
@@ -13,13 +13,13 @@ import {
13
13
  Skeleton,
14
14
  XIcon
15
15
  } from "@rebasepro/ui";
16
- import type { RebaseEditorProps } from "../../editor";
16
+ import type { RichTextEditorProps } from "../../editor";
17
17
  import { resolveStorageFilenameString, resolveStoragePathString } from "@rebasepro/common";
18
18
  import { randomString } from "@rebasepro/utils";
19
19
 
20
20
  // Lazy-load ProseMirror editor + markdown parser/serializer (~300KB)
21
21
  // Only fetched when a markdown field is actually rendered.
22
- const RebaseEditor = lazy(() => import("../../editor").then(m => ({ default: m.RebaseEditor })));
22
+ const RichTextEditor = lazy(() => import("../../editor").then(m => ({ default: m.RichTextEditor })));
23
23
  const loadMarkdownUtils = () => import("../../editor/markdown");
24
24
  let _markdownUtils: Awaited<ReturnType<typeof loadMarkdownUtils>> | null = null;
25
25
  const getMarkdownUtils = async () => {
@@ -29,7 +29,7 @@ const getMarkdownUtils = async () => {
29
29
 
30
30
  interface MarkdownEditorFieldProps {
31
31
  highlight?: { from: number, to: number };
32
- editorProps?: Partial<RebaseEditorProps>
32
+ editorProps?: Partial<RichTextEditorProps>
33
33
  }
34
34
 
35
35
  /**
@@ -173,7 +173,7 @@ export function MarkdownEditorFieldBinding({
173
173
  }, [entityId, entityValues, path, property, propertyKey, storage]);
174
174
 
175
175
  const editor = <Suspense fallback={<Skeleton height={200} className="w-full rounded-md"/>}>
176
- <RebaseEditor
176
+ <RichTextEditor
177
177
  content={value}
178
178
  onMarkdownContentChange={onContentChange}
179
179
  version={context.formex.version + fieldVersion}
@@ -481,7 +481,7 @@ export function StorageUpload({
481
481
  onDragStart={handleDragStart}
482
482
  onDragEnd={handleDragEnd}
483
483
  >
484
- <SortableContext items={value.map(v => v.id)} strategy={horizontalListSortingStrategy}>
484
+ <SortableContext items={(value ?? []).map(v => v.id)} strategy={horizontalListSortingStrategy}>
485
485
  <FileDropComponent {...fileDropProps}/>
486
486
  </SortableContext>
487
487
  </DndContext>
@@ -41,8 +41,8 @@ export function VectorFieldBinding({
41
41
  };
42
42
 
43
43
  // Extract array value from the custom { __type: "Vector", value: number[] } wrapper
44
- const arrayValue = isVectorObject(value)
45
- ? value.value
44
+ const arrayValue = isVectorObject(value)
45
+ ? value.value
46
46
  : (Array.isArray(value) ? value : []);
47
47
 
48
48
  const [textValue, setTextValue] = useState(() => arrayValue.join(", "));
@@ -108,7 +108,7 @@ export function VectorFieldBinding({
108
108
  <div className="flex items-center justify-between flex-wrap gap-2">
109
109
  <div className="flex items-center gap-2.5">
110
110
  {/* Status Dot */}
111
- <div className={`w-2.5 h-2.5 rounded-full ${isPopulated ? 'bg-emerald-500 animate-pulse' : 'bg-surface-300 dark:bg-surface-600'}`} />
111
+ <div className={`w-2.5 h-2.5 rounded-full ${isPopulated ? "bg-emerald-500 animate-pulse" : "bg-surface-300 dark:bg-surface-600"}`} />
112
112
  <span className="text-sm font-semibold text-text-primary dark:text-text-primary-dark">
113
113
  {isPopulated ? `${arrayValue.length} Dimensions` : "Empty Vector"}
114
114
  </span>
@@ -229,7 +229,7 @@ function getZodNumberSchema({
229
229
  const n = Number(val);
230
230
  return isNaN(n) ? val : n; // pass through non-numeric to let refine catch it
231
231
  },
232
- z.number({ invalid_type_error: "Must be a number" }).nullable()
232
+ z.number({ error: "Must be a number" }).nullable()
233
233
  );
234
234
 
235
235
  const isRequired = validation?.required || property.isId === true || property.isId === "manual";
@@ -446,17 +446,19 @@ function getZodArraySchema({
446
446
  });
447
447
  arraySchema = z.array(
448
448
  z.any().superRefine(async (object, ctx) => {
449
- // Find the matching schema from zodProperties based on the path
450
- const parentPath = ctx.path.slice(0, -1).join(".");
451
- const index = ctx.path[ctx.path.length - 1];
452
- const key = parentPath ? `${parentPath}[${index}]` : `${name}[${index}]`;
453
- const zodProperty = getValueInPath(zodProperties, key) as ZodTypeAny | undefined;
454
- if (zodProperty) {
455
- const result = await zodProperty.safeParseAsync(object);
456
- if (!result.success) {
457
- result.error.issues.forEach((issue) => {
458
- ctx.addIssue(issue);
459
- });
449
+ // In Zod v4, ctx.path is not available in superRefine.
450
+ // Instead, iterate all zodProperties and validate against each.
451
+ for (const [key, zodProperty] of Object.entries(zodProperties)) {
452
+ if (zodProperty) {
453
+ const result = await (zodProperty as ZodTypeAny).safeParseAsync(object);
454
+ if (!result.success) {
455
+ result.error.issues.forEach((issue) => {
456
+ ctx.addIssue({
457
+ code: "custom",
458
+ message: issue.message
459
+ });
460
+ });
461
+ }
460
462
  }
461
463
  }
462
464
  })
@@ -537,21 +539,21 @@ function getZodVectorSchema({
537
539
  },
538
540
  z.array(z.number()).nullable().optional()
539
541
  );
540
-
542
+
541
543
  if (property.dimensions) {
542
544
  schema = schema.refine(
543
545
  (val: unknown) => val === null || val === undefined || (Array.isArray(val) && val.length === property.dimensions),
544
546
  { message: `${property.name ?? "Vector"} must have exactly ${property.dimensions} dimensions` }
545
547
  );
546
548
  }
547
-
549
+
548
550
  if (property.validation?.required) {
549
551
  schema = schema.refine(
550
552
  (val: unknown) => val !== null && val !== undefined && Array.isArray(val) && val.length > 0,
551
553
  { message: property.validation?.requiredMessage ?? "Required" }
552
554
  );
553
555
  }
554
-
556
+
555
557
  return schema;
556
558
  }
557
559
 
@@ -5,7 +5,6 @@ import { AuthController, RebaseData, CollectionRegistryController, User } from "
5
5
  import type { EntityCollectionsBuilder, AppViewsBuilder, EffectiveRoleController } from "@rebasepro/types";
6
6
  import { CollectionRegistry } from "@rebasepro/common";
7
7
 
8
- import { UserManagementDelegate } from "@rebasepro/types";
9
8
 
10
9
  import { useResolvedCollections } from "./useResolvedCollections";
11
10
  import { useResolvedViews } from "./useResolvedViews";
@@ -25,7 +24,7 @@ export type BuildNavigationStateProps<EC extends EntityCollection, USER extends
25
24
  urlController: UrlController;
26
25
  adminMode?: "content" | "studio" | "settings";
27
26
  effectiveRoleController?: EffectiveRoleController;
28
- userManagement?: UserManagementDelegate<USER>;
27
+
29
28
  };
30
29
 
31
30
  /**
@@ -55,8 +54,7 @@ export function useBuildNavigationStateController<EC extends EntityCollection, U
55
54
  collectionRegistryController,
56
55
  urlController,
57
56
  adminMode = "content",
58
- effectiveRoleController,
59
- userManagement
57
+ effectiveRoleController
60
58
  } = props;
61
59
 
62
60
  const {
@@ -70,8 +68,7 @@ export function useBuildNavigationStateController<EC extends EntityCollection, U
70
68
  data,
71
69
  plugins,
72
70
  disabled,
73
- collectionRegistryController,
74
- userManagement
71
+ collectionRegistryController
75
72
  });
76
73
 
77
74
  const {
@@ -1,36 +1,157 @@
1
- import type { AppView, AppViewsBuilder, EntityCollection, FirebaseCollection, RebasePlugin } from "@rebasepro/types";
2
- import { AuthController, DataDriver, User, RebaseData } from "@rebasepro/types";
3
- import type { EntityCollectionsBuilder } from "@rebasepro/types";
1
+ import type {
2
+ AppView,
3
+ AppViewsBuilder,
4
+ AuthCollectionConfig,
5
+ EntityAction,
6
+ EntityCollection,
7
+ EntityCollectionsBuilder,
8
+ RebaseContext,
9
+ RebasePlugin,
10
+ UserCreationResult
11
+ } from "@rebasepro/types";
12
+ import { type AuthController, type User, type RebaseData } from "@rebasepro/types";
4
13
  import { canReadCollection } from "@rebasepro/common";
14
+ import { resetPasswordAction } from "../../components/common/default_entity_actions";
15
+ import { CreationResultDialog } from "../../components/admin/CreationResultDialog";
16
+ import React from "react";
5
17
 
6
- export function filterOutNotAllowedCollections(resolvedCollections: EntityCollection[], authController: AuthController<User>): EntityCollection[] {
18
+ /**
19
+ * Check whether a `RebaseCallContext` is actually the full frontend
20
+ * `RebaseContext` (which carries `dialogsController`).
21
+ */
22
+ function isRebaseContext(ctx: unknown): ctx is RebaseContext {
23
+ return typeof ctx === "object" && ctx !== null && "dialogsController" in ctx;
24
+ }
25
+
26
+ export function filterOutNotAllowedCollections(resolvedCollections: EntityCollection[], authController: AuthController): EntityCollection[] {
7
27
  return resolvedCollections
8
28
  .filter((c) => canReadCollection(c, authController))
9
29
  .map((c) => {
10
- if (!("subcollections" in c) || !c.subcollections) return c;
30
+ if (!c.childCollections) return c;
11
31
  return {
12
32
  ...c,
13
- subcollections: () => filterOutNotAllowedCollections((c as FirebaseCollection).subcollections?.() ?? [], authController)
14
- } as FirebaseCollection;
33
+ childCollections: () => filterOutNotAllowedCollections(c.childCollections!() ?? [], authController)
34
+ };
15
35
  });
16
36
  }
17
37
 
18
- export function applyPluginModifyCollection(resolvedCollections: EntityCollection[], modifyCollection: (collection: EntityCollection) => EntityCollection) {
19
- return resolvedCollections.map((collection: EntityCollection): EntityCollection => {
38
+ export function applyPluginModifyCollection(resolvedCollections: EntityCollection[], modifyCollection: (collection: EntityCollection) => EntityCollection): EntityCollection[] {
39
+ return resolvedCollections.map((collection): EntityCollection => {
20
40
  const modifiedCollection = modifyCollection(collection);
21
- if ("subcollections" in modifiedCollection && modifiedCollection.subcollections) {
41
+ if (modifiedCollection.childCollections) {
22
42
  return {
23
43
  ...modifiedCollection,
24
- subcollections: () => applyPluginModifyCollection((modifiedCollection as FirebaseCollection).subcollections?.() ?? [], modifyCollection)
25
- } as FirebaseCollection;
44
+ childCollections: () => applyPluginModifyCollection(modifiedCollection.childCollections!() ?? [], modifyCollection)
45
+ };
26
46
  }
27
47
  return modifiedCollection;
28
48
  });
29
49
  }
30
50
 
31
- export async function resolveCollections<U extends User, EC extends EntityCollection>(
32
- collections: undefined | EC[] | EntityCollectionsBuilder<EC>,
33
- authController: AuthController<U>,
51
+ /**
52
+ * Auto-inject auth-specific entity actions and callbacks for collections
53
+ * with `auth: true` or `auth: { enabled: true }`.
54
+ *
55
+ * Injections:
56
+ * 1. **resetPasswordAction** — adds the entity action unless explicitly disabled
57
+ * 2. **afterSave callback** — shows the `CreationResultDialog` when a new user
58
+ * is created with `invitationSent` or `temporaryPassword` in the response
59
+ *
60
+ * Skips injection if the collection already has the action/callback present.
61
+ */
62
+ function injectAuthCollectionConfig(collections: EntityCollection[]): EntityCollection[] {
63
+ return collections.map((collection) => {
64
+ const authProp = collection.auth;
65
+ if (!authProp) return collection;
66
+
67
+ const isAuth = authProp === true || (typeof authProp === "object" && authProp.enabled === true);
68
+ if (!isAuth) return collection;
69
+
70
+ const authConfig: AuthCollectionConfig | undefined = typeof authProp === "object" ? authProp : undefined;
71
+
72
+ let result = collection;
73
+
74
+ // ─── Entity Action injection (resetPassword) ─────────────────────
75
+ const resetPref = authConfig?.actions?.resetPassword;
76
+ let actionToInject: EntityAction | undefined;
77
+
78
+ if (resetPref === false) {
79
+ actionToInject = undefined;
80
+ } else if (typeof resetPref === "object") {
81
+ actionToInject = resetPref;
82
+ } else {
83
+ actionToInject = resetPasswordAction;
84
+ }
85
+
86
+ if (actionToInject) {
87
+ const injectedAction = actionToInject;
88
+ const existing = result.entityActions ?? [];
89
+ const alreadyHas = existing.some(
90
+ (a) => a.key != null && a.key === injectedAction.key
91
+ );
92
+ if (!alreadyHas) {
93
+ result = {
94
+ ...result,
95
+ entityActions: [...existing, injectedAction]
96
+ };
97
+ }
98
+ }
99
+
100
+ // ─── afterSave callback (creation result dialog) ─────────────────
101
+ const existingAfterSave = result.callbacks?.afterSave;
102
+ result = {
103
+ ...result,
104
+ callbacks: {
105
+ ...result.callbacks,
106
+ afterSave: async (props) => {
107
+ await existingAfterSave?.(props);
108
+
109
+ const { values, status, context } = props;
110
+ if (status !== "new" && status !== "copy") return;
111
+
112
+ const hasCreationInfo = values.invitationSent !== undefined || values.temporaryPassword !== undefined;
113
+ if (!hasCreationInfo || !isRebaseContext(context) || !context.dialogsController) return;
114
+
115
+ const { dialogsController } = context;
116
+
117
+ const creationResult: UserCreationResult = {
118
+ user: {
119
+ uid: String(props.entityId),
120
+ email: typeof values.email === "string" ? values.email : "",
121
+ displayName: typeof values.displayName === "string" ? values.displayName : "",
122
+ roles: Array.isArray(values.roles) ? values.roles as string[] : [],
123
+ photoURL: typeof values.photoURL === "string"
124
+ ? values.photoURL
125
+ : typeof values.photoUrl === "string"
126
+ ? values.photoUrl
127
+ : null,
128
+ providerId: "password",
129
+ isAnonymous: false
130
+ },
131
+ invitationSent: !!values.invitationSent,
132
+ temporaryPassword: typeof values.temporaryPassword === "string" ? values.temporaryPassword : undefined
133
+ };
134
+
135
+ const { closeDialog } = dialogsController.open({
136
+ key: "user_creation_result",
137
+ Component: () => (
138
+ React.createElement(CreationResultDialog, {
139
+ result: creationResult,
140
+ onClose: () => closeDialog()
141
+ })
142
+ )
143
+ });
144
+ }
145
+ }
146
+ };
147
+
148
+ return result;
149
+ });
150
+ }
151
+
152
+ export async function resolveCollections(
153
+ collections: undefined | EntityCollection[] | EntityCollectionsBuilder,
154
+ authController: AuthController,
34
155
  data: RebaseData,
35
156
  plugins: RebasePlugin[] | undefined
36
157
  ): Promise<EntityCollection[]> {
@@ -52,21 +173,24 @@ export async function resolveCollections<U extends User, EC extends EntityCollec
52
173
  }
53
174
 
54
175
  if (plugin.hooks?.injectCollections) {
55
- resolvedCollections = plugin.hooks.injectCollections(resolvedCollections ?? []);
176
+ resolvedCollections = plugin.hooks.injectCollections(resolvedCollections);
56
177
  }
57
178
  }
58
179
  }
59
180
 
181
+ // Auto-inject auth entity actions and callbacks (resetPassword, creation dialog, etc.)
182
+ resolvedCollections = injectAuthCollectionConfig(resolvedCollections);
183
+
60
184
  resolvedCollections = filterOutNotAllowedCollections(resolvedCollections, authController);
61
185
  return resolvedCollections;
62
186
  }
63
187
 
64
- export async function resolveAppViews<U extends User>(
188
+ export async function resolveAppViews(
65
189
  baseViews: AppView[] | AppViewsBuilder | undefined,
66
- authController: AuthController<U>,
190
+ authController: AuthController,
67
191
  data: RebaseData,
68
192
  plugins?: RebasePlugin[]
69
- ) {
193
+ ): Promise<AppView[]> {
70
194
  let resolvedViews: AppView[] = [];
71
195
  if (typeof baseViews === "function") {
72
196
  resolvedViews = await baseViews({
@@ -4,7 +4,7 @@ import { useCallback, useEffect, useRef, useState, useMemo } from "react";
4
4
  import { AuthController, CollectionRegistryController, RebaseData, User } from "@rebasepro/types";
5
5
  import type { EntityCollectionsBuilder } from "@rebasepro/types";
6
6
  import { CollectionRegistry } from "@rebasepro/common";
7
- import { UserManagementDelegate } from "@rebasepro/types";
7
+
8
8
 
9
9
  import { resolveCollections } from "./useNavigationResolution";
10
10
  import { areCollectionListsEqual } from "./utils";
@@ -16,7 +16,7 @@ export type UseResolvedCollectionsProps<EC extends EntityCollection, USER extend
16
16
  plugins?: RebasePlugin[];
17
17
  disabled?: boolean;
18
18
  collectionRegistryController: CollectionRegistryController<EC> & { collectionRegistryRef: React.MutableRefObject<CollectionRegistry> };
19
- userManagement?: UserManagementDelegate<USER>;
19
+
20
20
  };
21
21
 
22
22
  export type UseResolvedCollectionsResult = {
@@ -47,8 +47,7 @@ export function useResolvedCollections<EC extends EntityCollection, USER extends
47
47
  data,
48
48
  plugins,
49
49
  disabled,
50
- collectionRegistryController,
51
- userManagement
50
+ collectionRegistryController
52
51
  } = props;
53
52
 
54
53
  const [loading, setLoading] = useState(true);
@@ -70,8 +69,7 @@ export function useResolvedCollections<EC extends EntityCollection, USER extends
70
69
  authControllerRef.current = authController;
71
70
  const pluginsRef = useRef(plugins);
72
71
  pluginsRef.current = plugins;
73
- const userManagementRef = useRef(userManagement);
74
- userManagementRef.current = userManagement;
72
+
75
73
 
76
74
  // Ref for resolved collections change detection
77
75
  const resolvedCollectionsRef = useRef<EntityCollection[]>([]);
@@ -1,40 +1,8 @@
1
1
  import { useContext } from "react";
2
2
  import { BreadcrumbContext } from "../contexts/BreacrumbsContext";
3
+ import { BreadcrumbEntry, BreadcrumbsController } from "@rebasepro/types";
3
4
 
4
- /**
5
- * @group Hooks and utilities
6
- */
7
- export interface BreadcrumbsController {
8
- breadcrumbs: BreadcrumbEntry[];
9
- set: (props: {
10
- breadcrumbs: BreadcrumbEntry[];
11
- }) => void;
12
- /**
13
- * Update the count for a specific breadcrumb by ID.
14
- */
15
- updateCount: (id: string, count: number | null | undefined) => void;
16
- }
17
-
18
-
19
- /**
20
- * @group Hooks and utilities
21
- */
22
- export interface BreadcrumbEntry {
23
- title: string;
24
- url: string;
25
- /**
26
- * Optional entity count for collection breadcrumbs.
27
- * - undefined: not applicable (e.g., entity breadcrumb, custom view)
28
- * - null: loading
29
- * - number: loaded count
30
- */
31
- count?: number | null;
32
- /**
33
- * Unique identifier for this breadcrumb (e.g., collection path).
34
- * Used to update count without replacing entire breadcrumb array.
35
- */
36
- id?: string;
37
- }
5
+ export type { BreadcrumbEntry, BreadcrumbsController };
38
6
 
39
7
 
40
8
  /**
@@ -11,11 +11,33 @@ import {
11
11
  } from "@rebasepro/common";
12
12
  import { resolvedSelectedEntityView } from "../util/resolutions";
13
13
  import { ADDITIONAL_TAB_WIDTH, CONTAINER_FULL_WIDTH, FORM_CONTAINER_WIDTH } from "@rebasepro/core";
14
- import { useCustomizationController, useLargeLayout } from "@rebasepro/core";
14
+ import { useCustomizationController, useLargeLayout, useComponentOverride, CollectionComponentOverrideProvider } from "@rebasepro/core";
15
15
  import { JSON_TAB_VALUE, HISTORY_TAB_VALUE } from "../components/EntityEditView";
16
16
  import React from "react";
17
17
  import { EntitySidePanel } from "../components/EntitySidePanel";
18
18
 
19
+ /**
20
+ * Thin wrapper that resolves the Entity.SidePanel component override.
21
+ * Because the JSX is created inside `propsToSidePanel` (a plain function,
22
+ * not a React component), we need this wrapper so the hook is called at the
23
+ * top level of a React component per the Rules of Hooks.
24
+ */
25
+ function ResolvedEntitySidePanelInner(props: EntitySidePanelProps) {
26
+ const Resolved = useComponentOverride("Entity.SidePanel", EntitySidePanel);
27
+ return <Resolved {...props}/>;
28
+ }
29
+
30
+ function ResolvedEntitySidePanel(props: EntitySidePanelProps) {
31
+ if (props.collection?.components) {
32
+ return (
33
+ <CollectionComponentOverrideProvider overrides={props.collection.components}>
34
+ <ResolvedEntitySidePanelInner {...props}/>
35
+ </CollectionComponentOverrideProvider>
36
+ );
37
+ }
38
+ return <ResolvedEntitySidePanelInner {...props}/>;
39
+ }
40
+
19
41
  const NEW_URL_HASH = "new_side";
20
42
  const SIDE_URL_HASH = "side";
21
43
 
@@ -188,7 +210,7 @@ width: newWidth };
188
210
  sideDialogsController.open(
189
211
  propsToSidePanel({
190
212
  ...props,
191
- selectedTab: props.selectedTab ?? defaultSelectedView,
213
+ selectedTab: props.selectedTab ?? defaultSelectedView
192
214
  },
193
215
  urlController.buildUrlCollectionPath,
194
216
  urlController.resolveDatabasePathsFrom,
@@ -317,7 +339,7 @@ const propsToSidePanel = (props: EntitySidePanelProps,
317
339
  const entityViewWidth = getEntityViewWidth(props, smallLayout, customizationController);
318
340
  return {
319
341
  key: `${props.path}/${props.entityId}`,
320
- component: <EntitySidePanel {...resolvedPanelProps}/>,
342
+ component: <ResolvedEntitySidePanel {...resolvedPanelProps}/>,
321
343
  urlPath: urlPath,
322
344
  parentUrlPath: parentUrlPath,
323
345
  width: entityViewWidth,
package/src/index.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  // CMS-specific types take priority over base types when names conflict
2
2
  export * from "./types";
3
- // Editor types only — the full ProseMirror editor is a heavy import (~300 KB)
3
+ // Editor types only — the full ProseMirror editor (RichTextEditor) is a heavy import (~300 KB)
4
4
  // and is available as a separate entry point: @rebasepro/admin/editor
5
- export type { RebaseEditorProps, JSONContent, EditorAIController } from "./editor";
5
+ export type { RichTextEditorProps, RichTextEditorTextSize, RebaseEditorProps, RebaseEditorTextSize, JSONContent, EditorAIController } from "./editor";
6
6
  export * from "./form";
7
7
  export * from "./preview";
8
8
  export * from "./routes";