@cratis/event-models 0.0.0-stage → 0.105.6

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 (343) hide show
  1. package/README.md +44 -2
  2. package/dist/Board/BoardActions.d.ts +37 -0
  3. package/dist/Board/BoardCanvas.d.ts +6 -0
  4. package/dist/Board/BoardCanvasChrome.d.ts +9 -0
  5. package/dist/Board/BoardCollectionView.d.ts +22 -0
  6. package/dist/Board/BoardCollections.d.ts +17 -0
  7. package/dist/Board/BoardContextValue.d.ts +8 -0
  8. package/dist/Board/BoardEditing.d.ts +22 -0
  9. package/dist/Board/BoardInteraction.d.ts +10 -0
  10. package/dist/Board/BoardInteractionContext.d.ts +3 -0
  11. package/dist/Board/BoardInteractionProvider.d.ts +6 -0
  12. package/dist/Board/BoardNavigation.d.ts +4 -0
  13. package/dist/Board/BoardProvider.d.ts +7 -0
  14. package/dist/Board/BoardReadOnlyContext.d.ts +1 -0
  15. package/dist/Board/BoardSelection.d.ts +5 -0
  16. package/dist/Board/BoardToolbar.d.ts +7 -0
  17. package/dist/Board/EventModelBoard.d.ts +13 -0
  18. package/dist/Board/EventModelBoardEditor.d.ts +16 -0
  19. package/dist/Board/EventModelBoardHandle.d.ts +5 -0
  20. package/dist/Board/HostedEventModelBoard.d.ts +18 -0
  21. package/dist/Board/boardMinimap.d.ts +20 -0
  22. package/dist/Board/index.d.ts +19 -0
  23. package/dist/Board/isLargeBoard.d.ts +4 -0
  24. package/dist/Board/useBoard.d.ts +2 -0
  25. package/dist/Cards/ArtifactCard.d.ts +17 -0
  26. package/dist/Cards/ArtifactCardKind.d.ts +5 -0
  27. package/dist/Cards/Card.d.ts +18 -0
  28. package/dist/Cards/CardAction.d.ts +12 -0
  29. package/dist/Cards/CardActionButton.d.ts +9 -0
  30. package/dist/Cards/CardCorner.d.ts +4 -0
  31. package/dist/Cards/CardNameInput.d.ts +11 -0
  32. package/dist/Cards/CardSurface.d.ts +6 -0
  33. package/dist/Cards/EventTags.d.ts +8 -0
  34. package/dist/Cards/autoFitTitle.d.ts +29 -0
  35. package/dist/Cards/cardColors.d.ts +30 -0
  36. package/dist/Cards/index.d.ts +12 -0
  37. package/dist/Cards/pascalCaseBreak.d.ts +20 -0
  38. package/dist/Cards/useAutoFitTitle.d.ts +21 -0
  39. package/dist/Collections/CollectionGrid.d.ts +28 -0
  40. package/dist/Collections/CollectionGridEditor.d.ts +16 -0
  41. package/dist/Collections/CollectionGridFeature.d.ts +19 -0
  42. package/dist/Collections/CollectionGridFeatureColumn.d.ts +26 -0
  43. package/dist/Collections/CollectionGridFeatureHeaderControls.d.ts +13 -0
  44. package/dist/Collections/CollectionGridModule.d.ts +23 -0
  45. package/dist/Collections/CollectionGridModuleHeaderControls.d.ts +8 -0
  46. package/dist/Collections/CollectionGridSlice.d.ts +19 -0
  47. package/dist/Collections/CollectionGridSliceHeaderControls.d.ts +14 -0
  48. package/dist/Collections/CollectionGridSlots.d.ts +20 -0
  49. package/dist/Collections/CollectionGridTemplate.d.ts +6 -0
  50. package/dist/Collections/CollectionMoveHandle.d.ts +12 -0
  51. package/dist/Collections/CollectionMoved.d.ts +4 -0
  52. package/dist/Collections/CollectionViewport.d.ts +27 -0
  53. package/dist/Collections/collectionGridLayout.d.ts +11 -0
  54. package/dist/Collections/collectionState.d.ts +24 -0
  55. package/dist/Collections/estimateCollectionSize.d.ts +7 -0
  56. package/dist/Collections/index.d.ts +13 -0
  57. package/dist/Collections/useCollectionMove.d.ts +10 -0
  58. package/dist/Collections/useCollectionsArea.d.ts +27 -0
  59. package/dist/Connections/Connectors.d.ts +23 -0
  60. package/dist/Connections/FlowNodeActor.d.ts +13 -0
  61. package/dist/Connections/SliceConnections.d.ts +7 -0
  62. package/dist/Connections/SliceConnectionsContext.d.ts +11 -0
  63. package/dist/Connections/computeSliceConnections.d.ts +23 -0
  64. package/dist/Connections/flowNodeOrder.d.ts +3 -0
  65. package/dist/Connections/index.d.ts +7 -0
  66. package/dist/Connections/useConnectionHighlight.d.ts +7 -0
  67. package/dist/Features/FeatureAddMenu.d.ts +10 -0
  68. package/dist/Features/FeatureColumnFrame.d.ts +10 -0
  69. package/dist/Features/FeatureGridSurface.d.ts +15 -0
  70. package/dist/Features/FeatureHeader.d.ts +21 -0
  71. package/dist/Features/FeatureHeaderAction.d.ts +12 -0
  72. package/dist/Features/FeatureHeaderCell.d.ts +10 -0
  73. package/dist/Features/FeatureHeaderMenu.d.ts +10 -0
  74. package/dist/Features/FeatureHeaderMenuAction.d.ts +14 -0
  75. package/dist/Features/FeatureHeaderSuggestion.d.ts +9 -0
  76. package/dist/Features/FeatureSuggestions.d.ts +4 -0
  77. package/dist/Features/FeaturesArea.d.ts +42 -0
  78. package/dist/Features/FeaturesReordered.d.ts +2 -0
  79. package/dist/Features/featureAreaState.d.ts +27 -0
  80. package/dist/Features/featureDropEdge.d.ts +2 -0
  81. package/dist/Features/featureHeaderMenuItems.d.ts +4 -0
  82. package/dist/Features/index.d.ts +12 -0
  83. package/dist/Features/useFeatureDrag.d.ts +16 -0
  84. package/dist/Features/useFeatureSlotTargets.d.ts +11 -0
  85. package/dist/Geometry/CurveAxis.d.ts +5 -0
  86. package/dist/Geometry/connectionCurve.d.ts +13 -0
  87. package/dist/Geometry/index.d.ts +5 -0
  88. package/dist/Geometry/linkGeometry.d.ts +62 -0
  89. package/dist/Geometry/pillLabelWidth.d.ts +38 -0
  90. package/dist/Geometry/rowLabelWidth.d.ts +1 -0
  91. package/dist/HeaderDragging/HeaderDragGhost.d.ts +6 -0
  92. package/dist/HeaderDragging/HeaderDragStart.d.ts +8 -0
  93. package/dist/HeaderDragging/HeaderDragState.d.ts +8 -0
  94. package/dist/HeaderDragging/createHeaderDragGhost.d.ts +1 -0
  95. package/dist/HeaderDragging/headerDropIndex.d.ts +5 -0
  96. package/dist/HeaderDragging/index.d.ts +8 -0
  97. package/dist/HeaderDragging/reorderedIds.d.ts +2 -0
  98. package/dist/HeaderDragging/useHeaderDragIntent.d.ts +8 -0
  99. package/dist/HeaderDragging/zoomOfAncestor.d.ts +1 -0
  100. package/dist/Headers/CollapseButton.d.ts +6 -0
  101. package/dist/Headers/DetailsToggle.d.ts +5 -0
  102. package/dist/Headers/EditableLabel.d.ts +10 -0
  103. package/dist/Headers/EntityErrorIndicator.d.ts +10 -0
  104. package/dist/Headers/EntityErrorKind.d.ts +6 -0
  105. package/dist/Headers/ErroredEntity.d.ts +17 -0
  106. package/dist/Headers/PillHeader.d.ts +25 -0
  107. package/dist/Headers/index.d.ts +7 -0
  108. package/dist/Icons/CogWheel.d.ts +1 -0
  109. package/dist/Icons/index.d.ts +1 -0
  110. package/dist/Layout/boardMetrics.d.ts +20 -0
  111. package/dist/Layout/index.d.ts +3 -0
  112. package/dist/Layout/sliceLayout.d.ts +14 -0
  113. package/dist/Layout/sliceRows.d.ts +7 -0
  114. package/dist/Links/ModuleCollectionLinks.d.ts +19 -0
  115. package/dist/Links/drawableLinks.d.ts +8 -0
  116. package/dist/Links/index.d.ts +2 -0
  117. package/dist/Links/linkState.d.ts +17 -0
  118. package/dist/Menus/MenuDropdown.d.ts +29 -0
  119. package/dist/Menus/index.d.ts +1 -0
  120. package/dist/Messages/EventModelMessages.d.ts +153 -0
  121. package/dist/Messages/EventModelMessagesContext.d.ts +3 -0
  122. package/dist/Messages/EventModelMessagesProvider.d.ts +7 -0
  123. package/dist/Messages/defaultEventModelMessages.d.ts +2 -0
  124. package/dist/Messages/index.d.ts +4 -0
  125. package/dist/Model/Actor.d.ts +9 -0
  126. package/dist/Model/ActorType.d.ts +5 -0
  127. package/dist/Model/Assignee.d.ts +8 -0
  128. package/dist/Model/AssigneeKind.d.ts +5 -0
  129. package/dist/Model/AutomationTrigger.d.ts +9 -0
  130. package/dist/Model/AutomationTriggerSchedule.d.ts +8 -0
  131. package/dist/Model/AutomationTriggerType.d.ts +6 -0
  132. package/dist/Model/CommandConcurrency.d.ts +9 -0
  133. package/dist/Model/CommandItem.d.ts +13 -0
  134. package/dist/Model/CommandPropertyRules.d.ts +5 -0
  135. package/dist/Model/CommandRule.d.ts +4 -0
  136. package/dist/Model/ConcurrencyBinding.d.ts +5 -0
  137. package/dist/Model/ConcurrencyValueSource.d.ts +5 -0
  138. package/dist/Model/EventConstraint.d.ts +4 -0
  139. package/dist/Model/EventConstraints.d.ts +5 -0
  140. package/dist/Model/EventItem.d.ts +11 -0
  141. package/dist/Model/EventModel.d.ts +11 -0
  142. package/dist/Model/ExternalEventItem.d.ts +6 -0
  143. package/dist/Model/Feature.d.ts +14 -0
  144. package/dist/Model/Module.d.ts +12 -0
  145. package/dist/Model/ModuleCollection.d.ts +10 -0
  146. package/dist/Model/ModuleCollectionLink.d.ts +6 -0
  147. package/dist/Model/PersonaReference.d.ts +5 -0
  148. package/dist/Model/Position.d.ts +4 -0
  149. package/dist/Model/QueryItem.d.ts +7 -0
  150. package/dist/Model/QueryParameter.d.ts +5 -0
  151. package/dist/Model/QueryParameterType.d.ts +8 -0
  152. package/dist/Model/ReadModelItem.d.ts +8 -0
  153. package/dist/Model/ScreenTemplate.d.ts +4 -0
  154. package/dist/Model/Slice.d.ts +31 -0
  155. package/dist/Model/SliceSpecification.d.ts +19 -0
  156. package/dist/Model/SliceStatus.d.ts +9 -0
  157. package/dist/Model/SliceType.d.ts +6 -0
  158. package/dist/Model/SpecificationCommand.d.ts +7 -0
  159. package/dist/Model/SpecificationError.d.ts +7 -0
  160. package/dist/Model/SpecificationErrorRuleKind.d.ts +5 -0
  161. package/dist/Model/SpecificationErrorRuleReference.d.ts +8 -0
  162. package/dist/Model/SpecificationGivenEvent.d.ts +7 -0
  163. package/dist/Model/SpecificationReadModel.d.ts +6 -0
  164. package/dist/Model/SpecificationRunOutcome.d.ts +5 -0
  165. package/dist/Model/SpecificationThenEvent.d.ts +7 -0
  166. package/dist/Model/StickyNote.d.ts +8 -0
  167. package/dist/Model/UserExperienceActor.d.ts +10 -0
  168. package/dist/Model/index.d.ts +43 -0
  169. package/dist/Modules/ModuleColumnFrame.d.ts +11 -0
  170. package/dist/Modules/ModuleDropIndicator.d.ts +1 -0
  171. package/dist/Modules/ModuleHeader.d.ts +20 -0
  172. package/dist/Modules/ModuleHeaderAction.d.ts +14 -0
  173. package/dist/Modules/ModuleHeaderCell.d.ts +7 -0
  174. package/dist/Modules/ModuleHeaderMenu.d.ts +10 -0
  175. package/dist/Modules/ModulePlaceholder.d.ts +6 -0
  176. package/dist/Modules/ModuleSurface.d.ts +15 -0
  177. package/dist/Modules/ModulesArea.d.ts +23 -0
  178. package/dist/Modules/ModulesReordered.d.ts +2 -0
  179. package/dist/Modules/index.d.ts +12 -0
  180. package/dist/Modules/moduleAreaState.d.ts +27 -0
  181. package/dist/Modules/moduleWidth.d.ts +2 -0
  182. package/dist/Modules/persistModuleChange.d.ts +1 -0
  183. package/dist/Modules/useModuleDrag.d.ts +15 -0
  184. package/dist/Pickers/EventReferencePicker.d.ts +10 -0
  185. package/dist/Pickers/PickerPanel.d.ts +16 -0
  186. package/dist/Pickers/index.d.ts +2 -0
  187. package/dist/Pickers/useDismissOnOutsidePointer.d.ts +2 -0
  188. package/dist/Presentation/DetailLevel.d.ts +20 -0
  189. package/dist/Presentation/EventModelPresentation.d.ts +8 -0
  190. package/dist/Presentation/EventModelPresentationContext.d.ts +3 -0
  191. package/dist/Presentation/EventModelPresentationProvider.d.ts +7 -0
  192. package/dist/Presentation/VisualizationMode.d.ts +1 -0
  193. package/dist/Presentation/defaultEventModelPresentation.d.ts +2 -0
  194. package/dist/Presentation/detailsVisibility.d.ts +12 -0
  195. package/dist/Presentation/index.d.ts +7 -0
  196. package/dist/Properties/SchemaTooltipProperties.d.ts +9 -0
  197. package/dist/Properties/TypeBadge.d.ts +10 -0
  198. package/dist/Properties/index.d.ts +3 -0
  199. package/dist/Properties/schemaProperties.d.ts +6 -0
  200. package/dist/Reading/DocumentNode.d.ts +22 -0
  201. package/dist/Reading/InvalidEventModelDocument.d.ts +4 -0
  202. package/dist/Reading/index.d.ts +4 -0
  203. package/dist/Reading/isKnownValue.d.ts +1 -0
  204. package/dist/Reading/readActors.d.ts +4 -0
  205. package/dist/Reading/readBoardItems.d.ts +5 -0
  206. package/dist/Reading/readEventModelDocument.d.ts +2 -0
  207. package/dist/Reading/readJsonSchema.d.ts +2 -0
  208. package/dist/Reading/readModules.d.ts +3 -0
  209. package/dist/Reading/readSlice.d.ts +3 -0
  210. package/dist/Reading/readSliceItems.d.ts +7 -0
  211. package/dist/Reading/readSpecification.d.ts +3 -0
  212. package/dist/References/EventNavigateButton.d.ts +5 -0
  213. package/dist/References/ExternalEventCard.d.ts +14 -0
  214. package/dist/References/index.d.ts +3 -0
  215. package/dist/References/useReferenceHover.d.ts +12 -0
  216. package/dist/RowLabels/ActorRowDragGhost.d.ts +5 -0
  217. package/dist/RowLabels/ActorRowDropIndicator.d.ts +1 -0
  218. package/dist/RowLabels/ActorsReordered.d.ts +3 -0
  219. package/dist/RowLabels/RowLabel.d.ts +19 -0
  220. package/dist/RowLabels/RowLabelAction.d.ts +8 -0
  221. package/dist/RowLabels/RowLabelBadge.d.ts +8 -0
  222. package/dist/RowLabels/RowLabelsColumn.d.ts +20 -0
  223. package/dist/RowLabels/RowLabelsColumnFrame.d.ts +7 -0
  224. package/dist/RowLabels/actorKinds.d.ts +8 -0
  225. package/dist/RowLabels/actorRows.d.ts +4 -0
  226. package/dist/RowLabels/index.d.ts +12 -0
  227. package/dist/RowLabels/rowTypeName.d.ts +3 -0
  228. package/dist/RowLabels/useActorRowDrag.d.ts +30 -0
  229. package/dist/Rows/CellAction.d.ts +8 -0
  230. package/dist/Rows/CellActionButton.d.ts +6 -0
  231. package/dist/Rows/CellCorner.d.ts +7 -0
  232. package/dist/Rows/CellCornerAction.d.ts +7 -0
  233. package/dist/Rows/CellCornerPlacement.d.ts +4 -0
  234. package/dist/Rows/Chat/ChatCell.d.ts +9 -0
  235. package/dist/Rows/Chat/index.d.ts +1 -0
  236. package/dist/Rows/Events/EventCard.d.ts +9 -0
  237. package/dist/Rows/Events/EventReferenceCard.d.ts +7 -0
  238. package/dist/Rows/Events/EventsCell.d.ts +12 -0
  239. package/dist/Rows/Events/SliceEvents.d.ts +11 -0
  240. package/dist/Rows/Events/index.d.ts +5 -0
  241. package/dist/Rows/Events/referenceableEvents.d.ts +2 -0
  242. package/dist/Rows/Interaction/InteractionCard.d.ts +14 -0
  243. package/dist/Rows/Interaction/InteractionCell.d.ts +31 -0
  244. package/dist/Rows/Interaction/InteractionMiniCard.d.ts +4 -0
  245. package/dist/Rows/Interaction/OptionalReadModel.d.ts +6 -0
  246. package/dist/Rows/Interaction/SliceInteraction.d.ts +11 -0
  247. package/dist/Rows/Interaction/index.d.ts +5 -0
  248. package/dist/Rows/RowType.d.ts +7 -0
  249. package/dist/Rows/System/SystemCell.d.ts +12 -0
  250. package/dist/Rows/System/TriggerControl.d.ts +8 -0
  251. package/dist/Rows/System/TriggerKind.d.ts +5 -0
  252. package/dist/Rows/System/index.d.ts +4 -0
  253. package/dist/Rows/System/triggerBadges.d.ts +4 -0
  254. package/dist/Rows/UserExperience/AddPrototypeButton.d.ts +7 -0
  255. package/dist/Rows/UserExperience/PrototypeTemplate.d.ts +6 -0
  256. package/dist/Rows/UserExperience/UiCell.d.ts +17 -0
  257. package/dist/Rows/UserExperience/addPrototypeMenuItems.d.ts +8 -0
  258. package/dist/Rows/UserExperience/index.d.ts +4 -0
  259. package/dist/Rows/eventRowAffordances.d.ts +5 -0
  260. package/dist/Rows/index.d.ts +12 -0
  261. package/dist/SliceDragging/SliceDragGestureVerdict.d.ts +5 -0
  262. package/dist/SliceDragging/SliceDragGhost.d.ts +6 -0
  263. package/dist/SliceDragging/SliceDropIndicator.d.ts +5 -0
  264. package/dist/SliceDragging/SliceDropTarget.d.ts +14 -0
  265. package/dist/SliceDragging/SliceDropVerdict.d.ts +4 -0
  266. package/dist/SliceDragging/SliceMoved.d.ts +2 -0
  267. package/dist/SliceDragging/ValidateSliceDrop.d.ts +3 -0
  268. package/dist/SliceDragging/dropIndicatorClassName.d.ts +1 -0
  269. package/dist/SliceDragging/index.d.ts +14 -0
  270. package/dist/SliceDragging/readSliceDragGesture.d.ts +5 -0
  271. package/dist/SliceDragging/readSlicePress.d.ts +20 -0
  272. package/dist/SliceDragging/sliceMove.d.ts +10 -0
  273. package/dist/SliceDragging/snapshotSlice.d.ts +8 -0
  274. package/dist/SliceDragging/useSliceDrag.d.ts +30 -0
  275. package/dist/SliceDragging/useSliceDragIntent.d.ts +10 -0
  276. package/dist/SliceTypes/SliceTypeIcon.d.ts +5 -0
  277. package/dist/SliceTypes/SliceTypeMenu.d.ts +6 -0
  278. package/dist/SliceTypes/index.d.ts +3 -0
  279. package/dist/SliceTypes/sliceTypeMenuItems.d.ts +7 -0
  280. package/dist/Slices/SliceColumn.d.ts +18 -0
  281. package/dist/Slices/SliceColumnFrame.d.ts +20 -0
  282. package/dist/Slices/SliceContext.d.ts +2 -0
  283. package/dist/Slices/SliceContextValue.d.ts +7 -0
  284. package/dist/Slices/SliceHeader.d.ts +14 -0
  285. package/dist/Slices/SliceHeaderAction.d.ts +10 -0
  286. package/dist/Slices/SliceHeaderSlice.d.ts +2 -0
  287. package/dist/Slices/SliceNames.d.ts +6 -0
  288. package/dist/Slices/SlicePlaceholder.d.ts +15 -0
  289. package/dist/Slices/SliceProvider.d.ts +10 -0
  290. package/dist/Slices/SliceRows.d.ts +28 -0
  291. package/dist/Slices/SlicesArea.d.ts +38 -0
  292. package/dist/Slices/createOptimisticSlice.d.ts +3 -0
  293. package/dist/Slices/index.d.ts +15 -0
  294. package/dist/Slices/resolveSliceReadOnly.d.ts +3 -0
  295. package/dist/Slices/sliceAreaState.d.ts +43 -0
  296. package/dist/Slices/useSlice.d.ts +3 -0
  297. package/dist/Specifications/GivenSection.d.ts +12 -0
  298. package/dist/Specifications/SpecificationAction.d.ts +19 -0
  299. package/dist/Specifications/SpecificationAddPicker.d.ts +11 -0
  300. package/dist/Specifications/SpecificationCollection.d.ts +16 -0
  301. package/dist/Specifications/SpecificationEditing.d.ts +20 -0
  302. package/dist/Specifications/SpecificationErrorCard.d.ts +5 -0
  303. package/dist/Specifications/SpecificationHeader.d.ts +14 -0
  304. package/dist/Specifications/SpecificationItemCard.d.ts +7 -0
  305. package/dist/Specifications/SpecificationItemKind.d.ts +5 -0
  306. package/dist/Specifications/SpecificationItemToOpen.d.ts +14 -0
  307. package/dist/Specifications/SpecificationRow.d.ts +8 -0
  308. package/dist/Specifications/SpecificationRunButton.d.ts +7 -0
  309. package/dist/Specifications/SpecificationRunState.d.ts +23 -0
  310. package/dist/Specifications/SpecificationSection.d.ts +8 -0
  311. package/dist/Specifications/SpecificationStatus.d.ts +14 -0
  312. package/dist/Specifications/ThenSection.d.ts +15 -0
  313. package/dist/Specifications/WhenSection.d.ts +12 -0
  314. package/dist/Specifications/index.d.ts +10 -0
  315. package/dist/Specifications/itemValues.d.ts +7 -0
  316. package/dist/Specifications/ruleErrors.d.ts +8 -0
  317. package/dist/Specifications/specificationCollectionState.d.ts +7 -0
  318. package/dist/Specifications/specificationEvents.d.ts +3 -0
  319. package/dist/Statuses/SliceStatusIcon.d.ts +5 -0
  320. package/dist/Statuses/SliceStatusPicker.d.ts +8 -0
  321. package/dist/Statuses/changeSliceStatus.d.ts +2 -0
  322. package/dist/Statuses/index.d.ts +4 -0
  323. package/dist/Statuses/sliceStatuses.d.ts +6 -0
  324. package/dist/StickyNotes/StickyNoteBounds.d.ts +6 -0
  325. package/dist/StickyNotes/StickyNoteChanges.d.ts +9 -0
  326. package/dist/StickyNotes/StickyNoteHandle.d.ts +4 -0
  327. package/dist/StickyNotes/StickyNoteState.d.ts +16 -0
  328. package/dist/StickyNotes/StickyNotes.d.ts +6 -0
  329. package/dist/StickyNotes/index.d.ts +6 -0
  330. package/dist/StickyNotes/isEditableTarget.d.ts +1 -0
  331. package/dist/Tooltips/AnchoredOverlay.d.ts +27 -0
  332. package/dist/Tooltips/GridTooltip.d.ts +21 -0
  333. package/dist/Tooltips/index.d.ts +2 -0
  334. package/dist/Viewport/index.d.ts +2 -0
  335. package/dist/Viewport/useInViewport.d.ts +3 -0
  336. package/dist/Viewport/viewportFlushScheduler.d.ts +7 -0
  337. package/dist/event-model-document.schema.json +827 -0
  338. package/dist/event-models.css +2 -0
  339. package/dist/index.d.ts +30 -0
  340. package/dist/index.js +7682 -0
  341. package/dist/index.js.map +1 -0
  342. package/dist/theme.css +53 -0
  343. package/package.json +66 -3
@@ -0,0 +1,31 @@
1
+ import type { ReactNode } from 'react';
2
+ import { type CellConnectors } from '../../Connections';
3
+ import { InteractionMiniCard } from './InteractionMiniCard';
4
+ export type InteractionLayout = {
5
+ kind: 'centered';
6
+ cards: ReactNode;
7
+ corners?: ReactNode;
8
+ hasItems: boolean;
9
+ } | {
10
+ kind: 'sideBySide';
11
+ cards: ReactNode;
12
+ readModelOnTop: boolean;
13
+ commandBelow: boolean;
14
+ hasLeftCard: boolean;
15
+ hasRightCard: boolean;
16
+ } | {
17
+ kind: 'split';
18
+ left: ReactNode;
19
+ leftCorner?: ReactNode;
20
+ right: ReactNode;
21
+ rightCorner?: ReactNode;
22
+ hasItems: boolean;
23
+ };
24
+ export interface InteractionCellProps {
25
+ collapsed?: boolean;
26
+ conn: CellConnectors;
27
+ rowHeight: number;
28
+ miniCards: readonly InteractionMiniCard[];
29
+ layout: InteractionLayout;
30
+ }
31
+ export declare const InteractionCell: ({ collapsed, conn, rowHeight, miniCards, layout }: InteractionCellProps) => import("react").JSX.Element;
@@ -0,0 +1,4 @@
1
+ export declare enum InteractionMiniCard {
2
+ command = "command",
3
+ readModel = "readmodel"
4
+ }
@@ -0,0 +1,6 @@
1
+ export interface OptionalReadModelProps {
2
+ label: string;
3
+ defineLabel: string;
4
+ onDefine: (host: DOMRect) => void;
5
+ }
6
+ export declare const OptionalReadModel: ({ label, defineLabel, onDefine }: OptionalReadModelProps) => import("react").JSX.Element;
@@ -0,0 +1,11 @@
1
+ import type { CellConnectors } from '../../Connections';
2
+ import { type EventItem, type Slice } from '../../Model';
3
+ export interface SliceInteractionProps {
4
+ slice: Slice;
5
+ collapsed?: boolean;
6
+ conn: CellConnectors;
7
+ rowHeight: number;
8
+ externalEventOptions?: readonly EventItem[];
9
+ showDetails?: boolean;
10
+ }
11
+ export declare const SliceInteraction: ({ slice, collapsed, conn, rowHeight, externalEventOptions, showDetails }: SliceInteractionProps) => import("react").JSX.Element;
@@ -0,0 +1,5 @@
1
+ export * from './InteractionCard';
2
+ export * from './InteractionCell';
3
+ export * from './InteractionMiniCard';
4
+ export * from './OptionalReadModel';
5
+ export * from './SliceInteraction';
@@ -0,0 +1,7 @@
1
+ export declare enum RowType {
2
+ UI = "ui",
3
+ Chat = "chat",
4
+ System = "system",
5
+ Interaction = "interaction",
6
+ Events = "events"
7
+ }
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { type CellConnectors } from '../../Connections';
3
+ import { type AutomationTriggerType, SliceType } from '../../Model';
4
+ export interface SystemCellProps {
5
+ sliceType: SliceType;
6
+ isSystemSlice: boolean;
7
+ collapsed?: boolean;
8
+ conn: CellConnectors;
9
+ rowHeight: number;
10
+ triggerType?: AutomationTriggerType;
11
+ }
12
+ export declare const SystemCell: ({ sliceType, isSystemSlice, collapsed, conn, rowHeight, triggerType }: SystemCellProps) => React.JSX.Element;
@@ -0,0 +1,8 @@
1
+ import { AutomationTriggerType } from '../../Model';
2
+ import { TriggerKind } from './TriggerKind';
3
+ export interface TriggerControlProps {
4
+ triggerType?: AutomationTriggerType;
5
+ onTriggerKindChosen: (kind: TriggerKind) => void;
6
+ onTriggerOpened: () => void;
7
+ }
8
+ export declare const TriggerControl: ({ triggerType, onTriggerKindChosen, onTriggerOpened }: TriggerControlProps) => import("react").JSX.Element;
@@ -0,0 +1,5 @@
1
+ export declare enum TriggerKind {
2
+ timer = "timer",
3
+ event = "event",
4
+ custom = "custom"
5
+ }
@@ -0,0 +1,4 @@
1
+ export * from './triggerBadges';
2
+ export * from './SystemCell';
3
+ export * from './TriggerControl';
4
+ export * from './TriggerKind';
@@ -0,0 +1,4 @@
1
+ import { AutomationTriggerType } from '../../Model';
2
+ import type { EventModelMessages } from '../../Messages';
3
+ export declare const triggerIcon: (type: AutomationTriggerType) => string | undefined;
4
+ export declare const triggerTitle: (type: AutomationTriggerType, messages: EventModelMessages) => string;
@@ -0,0 +1,7 @@
1
+ import type { PrototypeTemplate } from './PrototypeTemplate';
2
+ export interface AddPrototypeButtonProps {
3
+ templates: readonly PrototypeTemplate[];
4
+ onFromScratch: (host: DOMRect) => void;
5
+ onFromTemplate: (template: PrototypeTemplate, host: DOMRect) => void;
6
+ }
7
+ export declare const AddPrototypeButton: ({ templates, onFromScratch, onFromTemplate }: AddPrototypeButtonProps) => import("react").JSX.Element;
@@ -0,0 +1,6 @@
1
+ import type { Guid } from '@cratis/fundamentals';
2
+ export interface PrototypeTemplate {
3
+ id: Guid;
4
+ name: string;
5
+ onChosen: (sliceId: Guid, actorId: string, host: DOMRect) => void;
6
+ }
@@ -0,0 +1,17 @@
1
+ import React from 'react';
2
+ import { type PrototypeLayout } from '@cratis/scene/Prototypes';
3
+ import type { UIElement, IComponent } from '@cratis/scene';
4
+ import { type CellConnectors } from '../../Connections';
5
+ export interface UiCellProps {
6
+ elements: readonly (UIElement | IComponent)[];
7
+ windowSize?: {
8
+ width: number;
9
+ height: number;
10
+ };
11
+ layout?: PrototypeLayout;
12
+ collapsed?: boolean;
13
+ conn: CellConnectors;
14
+ rowHeight: number;
15
+ actorId: string;
16
+ }
17
+ export declare const UiCell: ({ elements, windowSize, layout, collapsed, conn, rowHeight, actorId }: UiCellProps) => React.JSX.Element;
@@ -0,0 +1,8 @@
1
+ import type { EventModelMessages } from '../../Messages';
2
+ import type { MenuDropdownItem } from '../../Menus';
3
+ import type { PrototypeTemplate } from './PrototypeTemplate';
4
+ export interface AddPrototypeMenuActions {
5
+ onFromScratch: () => void;
6
+ onFromTemplate: (template: PrototypeTemplate) => void;
7
+ }
8
+ export declare const addPrototypeMenuItems: (templates: readonly PrototypeTemplate[], messages: EventModelMessages['prototypes'], actions: AddPrototypeMenuActions) => MenuDropdownItem[];
@@ -0,0 +1,4 @@
1
+ export * from './UiCell';
2
+ export * from './AddPrototypeButton';
3
+ export * from './addPrototypeMenuItems';
4
+ export * from './PrototypeTemplate';
@@ -0,0 +1,5 @@
1
+ import { SliceType } from '../Model';
2
+ export declare const usesEventReferencePicker: (sliceType: SliceType) => boolean;
3
+ export declare const showsAddNewEventButton: (sliceType: SliceType) => boolean;
4
+ export declare const showsEventReferencePlaceholder: (sliceType: SliceType, eventCount: number) => boolean;
5
+ export declare const showsExternalEventPicker: (sliceType: SliceType) => boolean;
@@ -0,0 +1,12 @@
1
+ export * from './RowType';
2
+ export * from './CellAction';
3
+ export * from './CellActionButton';
4
+ export * from './CellCorner';
5
+ export * from './CellCornerAction';
6
+ export * from './CellCornerPlacement';
7
+ export * from './eventRowAffordances';
8
+ export * from './System';
9
+ export * from './UserExperience';
10
+ export * from './Chat';
11
+ export * from './Events';
12
+ export * from './Interaction';
@@ -0,0 +1,5 @@
1
+ export declare enum SliceDragGestureVerdict {
2
+ pending = "pending",
3
+ commit = "commit",
4
+ abandon = "abandon"
5
+ }
@@ -0,0 +1,6 @@
1
+ import type { SliceDragState } from './useSliceDrag';
2
+ export interface SliceDragGhostProps {
3
+ drag?: SliceDragState;
4
+ headerHeight: number;
5
+ }
6
+ export declare const SliceDragGhost: ({ drag, headerHeight }: SliceDragGhostProps) => import("react").ReactPortal | undefined;
@@ -0,0 +1,5 @@
1
+ export interface SliceDropIndicatorProps {
2
+ isValid: boolean;
3
+ marginLeft: number;
4
+ }
5
+ export declare const SliceDropIndicator: ({ isValid, marginLeft }: SliceDropIndicatorProps) => import("react").JSX.Element;
@@ -0,0 +1,14 @@
1
+ import React from 'react';
2
+ import type { Guid } from '@cratis/fundamentals';
3
+ export interface SliceDropTargetProps {
4
+ moduleId: Guid;
5
+ featureId: Guid;
6
+ active?: boolean;
7
+ busy?: boolean;
8
+ acceptsReorder?: boolean;
9
+ acceptsMove?: boolean;
10
+ style?: React.CSSProperties;
11
+ className?: string;
12
+ children?: React.ReactNode;
13
+ }
14
+ export declare const SliceDropTarget: ({ moduleId, featureId, active, busy, acceptsReorder, acceptsMove, style, className, children }: SliceDropTargetProps) => React.JSX.Element;
@@ -0,0 +1,4 @@
1
+ export interface SliceDropVerdict {
2
+ isValid: boolean;
3
+ reason?: string;
4
+ }
@@ -0,0 +1,2 @@
1
+ import type { Guid } from '@cratis/fundamentals';
2
+ export type SliceMoved = (sliceId: Guid, fromFeatureId: Guid, toFeatureId: Guid, index: number) => void;
@@ -0,0 +1,3 @@
1
+ import type { Guid } from '@cratis/fundamentals';
2
+ import type { SliceDropVerdict } from './SliceDropVerdict';
3
+ export type ValidateSliceDrop = (sliceId: Guid, targetFeatureId: Guid, index: number) => SliceDropVerdict | undefined;
@@ -0,0 +1 @@
1
+ export declare const dropIndicatorClassName: (isValid: boolean) => "event-modeling-grid-slice-drop-indicator" | "event-modeling-grid-slice-drop-indicator event-modeling-grid-slice-drop-indicator--invalid";
@@ -0,0 +1,14 @@
1
+ export * from './dropIndicatorClassName';
2
+ export * from './readSliceDragGesture';
3
+ export * from './readSlicePress';
4
+ export * from './SliceDragGestureVerdict';
5
+ export * from './SliceDragGhost';
6
+ export * from './snapshotSlice';
7
+ export * from './SliceDropIndicator';
8
+ export * from './SliceDropTarget';
9
+ export * from './SliceDropVerdict';
10
+ export * from './sliceMove';
11
+ export * from './SliceMoved';
12
+ export * from './useSliceDrag';
13
+ export * from './useSliceDragIntent';
14
+ export * from './ValidateSliceDrop';
@@ -0,0 +1,5 @@
1
+ import { SliceDragGestureVerdict } from './SliceDragGestureVerdict';
2
+ export declare const DRAG_THRESHOLD = 4;
3
+ export declare const TOUCH_LONG_PRESS_MS = 450;
4
+ export declare const TOUCH_LONG_PRESS_TOLERANCE = 10;
5
+ export declare function readSliceDragGesture(pointerType: string, deltaX: number, deltaY: number): SliceDragGestureVerdict;
@@ -0,0 +1,20 @@
1
+ export declare const INTERACTIVE_SELECTOR = "input, textarea, select, button, a, [role=\"button\"], [contenteditable=\"true\"], .p-dropdown, .p-checkbox";
2
+ export interface PressedElement {
3
+ closest(selectors: string): unknown;
4
+ }
5
+ export interface SlicePressEvent {
6
+ target: PressedElement | null;
7
+ clientX: number;
8
+ clientY: number;
9
+ pointerId: number;
10
+ pointerType: string;
11
+ elementTop: number;
12
+ }
13
+ export interface SlicePress {
14
+ startX: number;
15
+ startY: number;
16
+ grabOffsetY: number;
17
+ pointerId: number;
18
+ pointerType: string;
19
+ }
20
+ export declare function readSlicePress(event: SlicePressEvent, disabled: boolean): SlicePress | null;
@@ -0,0 +1,10 @@
1
+ import type { Guid } from '@cratis/fundamentals';
2
+ export interface SliceDropPosition {
3
+ featureId: Guid;
4
+ targetFeatureId: Guid;
5
+ sourceIndex: number;
6
+ dropIndex: number;
7
+ }
8
+ export declare const sliceMove: (position: SliceDropPosition) => {
9
+ index: number;
10
+ } | undefined;
@@ -0,0 +1,8 @@
1
+ export declare const HIT_TEST_ATTRIBUTES: string[];
2
+ export interface GhostNode {
3
+ removeAttribute(name: string): void;
4
+ setAttribute(name: string, value: string): void;
5
+ readonly children: ArrayLike<GhostNode>;
6
+ }
7
+ export declare function prepareGhost(node: GhostNode): void;
8
+ export declare function createSliceDragGhost(element: HTMLElement): HTMLElement | null;
@@ -0,0 +1,30 @@
1
+ import { Guid } from '@cratis/fundamentals';
2
+ import type { SliceMoved } from './SliceMoved';
3
+ import type { ValidateSliceDrop } from './ValidateSliceDrop';
4
+ export interface DraggableFeature {
5
+ id: Guid;
6
+ slices: ReadonlyArray<{
7
+ id: Guid;
8
+ }>;
9
+ }
10
+ export interface SliceDragState {
11
+ sliceId: Guid;
12
+ moduleId: Guid;
13
+ featureId: Guid;
14
+ targetFeatureId: Guid;
15
+ sourceIndex: number;
16
+ ghostLabel: string;
17
+ ghostWidth: number;
18
+ ghost: HTMLElement | null;
19
+ currentX: number;
20
+ currentY: number;
21
+ dropIndex: number;
22
+ headerY: number;
23
+ zoom: number;
24
+ isValid: boolean;
25
+ invalidReason?: string;
26
+ }
27
+ export declare function useSliceDrag(feature: DraggableFeature, moduleId: Guid, onSliceMoved?: SliceMoved, validateSliceDrop?: ValidateSliceDrop): {
28
+ sliceDrag: SliceDragState | undefined;
29
+ handleSliceDragStart: ((sliceId: Guid, sliceName: string, clientX: number, clientY: number, columnWidth: number, headerY: number, zoom: number, ghost?: HTMLElement | null) => void) | undefined;
30
+ };
@@ -0,0 +1,10 @@
1
+ import type React from 'react';
2
+ import { Guid } from '@cratis/fundamentals';
3
+ export type SliceDragStartHandler = (sliceId: Guid, sliceName: string, clientX: number, clientY: number, columnWidth: number, headerY: number, zoom: number, ghost: HTMLElement | null) => void;
4
+ export interface SliceDragIntentHandlers {
5
+ onPointerDown: (event: React.PointerEvent<HTMLDivElement>) => void;
6
+ onPointerMove: (event: React.PointerEvent<HTMLDivElement>) => void;
7
+ onPointerUp: () => void;
8
+ onContextMenu: (event: React.MouseEvent<HTMLDivElement>) => void;
9
+ }
10
+ export declare function useSliceDragIntent(sliceId: Guid | undefined, sliceName: string, columnWidth: number, disabled: boolean, onSliceDragStart?: SliceDragStartHandler): SliceDragIntentHandlers;
@@ -0,0 +1,5 @@
1
+ import { SliceType } from '../Model';
2
+ export interface SliceTypeIconProps {
3
+ type: SliceType;
4
+ }
5
+ export declare const SliceTypeIcon: ({ type }: SliceTypeIconProps) => import("react").JSX.Element;
@@ -0,0 +1,6 @@
1
+ import type { SliceType } from '../Model';
2
+ export interface SliceTypeMenuProps {
3
+ onSelect: (type: SliceType) => void;
4
+ disabled?: boolean;
5
+ }
6
+ export declare const SliceTypeMenu: ({ onSelect, disabled }: SliceTypeMenuProps) => import("react").JSX.Element;
@@ -0,0 +1,3 @@
1
+ export * from './SliceTypeIcon';
2
+ export * from './SliceTypeMenu';
3
+ export * from './sliceTypeMenuItems';
@@ -0,0 +1,7 @@
1
+ import { SliceType } from '../Model';
2
+ import type { EventModelMessages } from '../Messages';
3
+ import type { MenuDropdownItem } from '../Menus';
4
+ export declare const sliceTypes: readonly SliceType[];
5
+ export declare const sliceTypeLabel: (type: SliceType, messages: EventModelMessages) => string;
6
+ export declare const sliceTypeDescription: (type: SliceType, messages: EventModelMessages) => string;
7
+ export declare const sliceTypeMenuItems: (messages: EventModelMessages, onSelect: (type: SliceType) => void) => MenuDropdownItem[];
@@ -0,0 +1,18 @@
1
+ import { type ReactNode } from 'react';
2
+ import type { Guid } from '@cratis/fundamentals';
3
+ import type { SliceHeaderSlice } from './SliceHeaderSlice';
4
+ import type { SliceDragStartHandler } from '../SliceDragging';
5
+ export interface SliceColumnProps {
6
+ featureId: Guid;
7
+ slice: SliceHeaderSlice;
8
+ eventCount: number;
9
+ collapsed: boolean;
10
+ isDragging?: boolean;
11
+ onSliceDragStart?: SliceDragStartHandler;
12
+ header?: ReactNode;
13
+ headerHeight?: number;
14
+ body: ReactNode | ((inView: boolean) => ReactNode);
15
+ specifications?: ReactNode | ((inView: boolean, width: number) => ReactNode);
16
+ collapsedWidth: number;
17
+ }
18
+ export declare const SliceColumn: ({ featureId, slice, eventCount, collapsed, isDragging, onSliceDragStart, header, headerHeight, body, specifications, collapsedWidth }: SliceColumnProps) => import("react").JSX.Element;
@@ -0,0 +1,20 @@
1
+ import React from 'react';
2
+ import type { Guid } from '@cratis/fundamentals';
3
+ import type { SliceStatus } from '../Model';
4
+ import { type SliceDragStartHandler } from '../SliceDragging';
5
+ export interface SliceColumnFrameProps {
6
+ featureId: Guid;
7
+ name: string;
8
+ status: SliceStatus;
9
+ width: number;
10
+ collapsed: boolean;
11
+ isDragging?: boolean;
12
+ onDragStart?: SliceDragStartHandler;
13
+ ref?: React.Ref<HTMLDivElement>;
14
+ onMouseEnter?: () => void;
15
+ onMouseLeave?: () => void;
16
+ onFocusCapture?: (event: React.FocusEvent<HTMLDivElement>) => void;
17
+ onBlurCapture?: (event: React.FocusEvent<HTMLDivElement>) => void;
18
+ children?: React.ReactNode;
19
+ }
20
+ export declare const SliceColumnFrame: ({ featureId, name, status, width, collapsed, isDragging, onDragStart, ref, onMouseEnter, onMouseLeave, onFocusCapture, onBlurCapture, children, }: SliceColumnFrameProps) => React.JSX.Element;
@@ -0,0 +1,2 @@
1
+ import type { SliceContextValue } from './SliceContextValue';
2
+ export declare const SliceContext: import("react").Context<SliceContextValue | undefined>;
@@ -0,0 +1,7 @@
1
+ import type { Guid } from '@cratis/fundamentals';
2
+ import type { SliceType } from '../Model';
3
+ export interface SliceContextValue {
4
+ readOnly: boolean;
5
+ sliceId?: Guid;
6
+ sliceType?: SliceType;
7
+ }
@@ -0,0 +1,14 @@
1
+ import React from 'react';
2
+ import type { SliceStatus } from '../Model';
3
+ import type { SliceHeaderSlice } from './SliceHeaderSlice';
4
+ export interface SliceHeaderProps {
5
+ slice: SliceHeaderSlice;
6
+ height: number;
7
+ collapsed: boolean;
8
+ selectableStatuses?: readonly SliceStatus[];
9
+ unselectableStatusReason?: string;
10
+ error?: string;
11
+ leading?: React.ReactNode;
12
+ trailing?: React.ReactNode;
13
+ }
14
+ export declare const SliceHeader: ({ slice, height, collapsed, selectableStatuses, unselectableStatusReason, error, leading, trailing, }: SliceHeaderProps) => React.JSX.Element;
@@ -0,0 +1,10 @@
1
+ import type { ReactNode } from 'react';
2
+ import type { Guid } from '@cratis/fundamentals';
3
+ import type { SliceHeaderSlice } from './SliceHeaderSlice';
4
+ export interface SliceHeaderAction {
5
+ icon: ReactNode;
6
+ tooltip: string;
7
+ when?: (slice: SliceHeaderSlice) => boolean;
8
+ disabled?: boolean;
9
+ onActivate: (sliceId: Guid, host: DOMRect) => void;
10
+ }
@@ -0,0 +1,2 @@
1
+ import type { Slice } from '../Model';
2
+ export type SliceHeaderSlice = Pick<Slice, 'id' | 'name' | 'sliceType' | 'status'>;
@@ -0,0 +1,6 @@
1
+ export interface SliceNames {
2
+ name?: string;
3
+ commandName?: string;
4
+ eventName?: string;
5
+ readModelName?: string;
6
+ }
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ import { SliceType } from '../Model';
3
+ import { RowType } from '../Rows/RowType';
4
+ export interface SlicePlaceholderSlice {
5
+ sliceType: SliceType;
6
+ hasCommand: boolean;
7
+ hasReadModel: boolean;
8
+ eventCount: number;
9
+ }
10
+ export interface SlicePlaceholderProps {
11
+ slice: SlicePlaceholderSlice;
12
+ contentRows: readonly RowType[];
13
+ rowHeights: Readonly<Record<RowType, number>>;
14
+ }
15
+ export declare const SlicePlaceholder: React.FC<SlicePlaceholderProps>;
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ import type { Guid } from '@cratis/fundamentals';
3
+ import type { SliceStatus, SliceType } from '../Model';
4
+ export interface SliceProviderProps {
5
+ sliceId: Guid;
6
+ sliceType: SliceType;
7
+ status: SliceStatus;
8
+ children?: React.ReactNode;
9
+ }
10
+ export declare const SliceProvider: ({ sliceId, sliceType, status, children }: SliceProviderProps) => React.JSX.Element;
@@ -0,0 +1,28 @@
1
+ import { type ReactNode } from 'react';
2
+ import type { ActorType, SliceType } from '../Model';
3
+ import { type CellConnectors } from '../Connections';
4
+ import { RowType } from '../Rows/RowType';
5
+ export interface SliceRowCell<TActor> {
6
+ rowType: RowType;
7
+ conn: CellConnectors;
8
+ rowHeight: number;
9
+ actor?: TActor;
10
+ }
11
+ export interface SliceRowsProps<TActor extends {
12
+ id: {
13
+ toString(): string;
14
+ };
15
+ actorType: ActorType;
16
+ }> {
17
+ sliceType: SliceType;
18
+ contentRows: readonly RowType[];
19
+ rowHeights: Readonly<Record<RowType, number>>;
20
+ actors: readonly TActor[];
21
+ renderCell: (cell: SliceRowCell<TActor>) => ReactNode;
22
+ }
23
+ export declare const SliceRows: <TActor extends {
24
+ id: {
25
+ toString(): string;
26
+ };
27
+ actorType: ActorType;
28
+ }>({ sliceType, contentRows, rowHeights, actors, renderCell }: SliceRowsProps<TActor>) => import("react").JSX.Element;
@@ -0,0 +1,38 @@
1
+ import { type ReactNode, type Ref } from 'react';
2
+ import type { Guid } from '@cratis/fundamentals';
3
+ import { useSliceDrag, type ValidateSliceDrop } from '../SliceDragging';
4
+ import type { Slice, SliceType } from '../Model';
5
+ import type { SliceNames } from './SliceNames';
6
+ import { type SliceAreaItem } from './sliceAreaState';
7
+ export interface SlicesAreaHandle<T extends SliceAreaItem> {
8
+ addSlice: (sliceType: SliceType, afterSliceId?: Guid, names?: SliceNames) => void;
9
+ updateSlices: (update: (previous: T[]) => T[]) => void;
10
+ addProjectedSlice: (slice: T, afterSliceId?: Guid) => void;
11
+ moveIn: (slice: T, index: number) => void;
12
+ completeMoveIn: (id: Guid, succeeded: boolean) => void;
13
+ moveOut: (id: Guid) => boolean;
14
+ completeMoveOut: (id: Guid, succeeded: boolean) => void;
15
+ }
16
+ export interface SlicesAreaProps<T extends SliceAreaItem> {
17
+ initialSlices: T[];
18
+ ref?: Ref<SlicesAreaHandle<T>>;
19
+ moduleId: Guid;
20
+ featureId: Guid;
21
+ featureCollapsed: boolean;
22
+ hideEmptyPlaceholder?: boolean;
23
+ onSlicesChanged?: (slices: T[]) => void;
24
+ createSlice: (slice: Slice) => T;
25
+ onAddSlice?: (slice: T, afterSliceId?: Guid) => Promise<Guid | undefined>;
26
+ onReorderSlices?: (sliceIds: Guid[]) => Promise<boolean>;
27
+ onMoveSlice?: (slice: T, targetFeatureId: Guid, targetIndex: number) => Promise<boolean>;
28
+ validateSliceDrop?: ValidateSliceDrop;
29
+ renderSlice: (slice: T, options: {
30
+ collapsed: boolean;
31
+ sliceCollapsed: boolean;
32
+ isDragging: boolean;
33
+ onSliceDragStart: ReturnType<typeof useSliceDrag>['handleSliceDragStart'];
34
+ addSlice: SlicesAreaHandle<T>['addSlice'];
35
+ updateSlices: SlicesAreaHandle<T>['updateSlices'];
36
+ }) => ReactNode;
37
+ }
38
+ export declare function SlicesArea<T extends SliceAreaItem>({ ref, initialSlices, moduleId, featureId, featureCollapsed, hideEmptyPlaceholder, onSlicesChanged, createSlice, onAddSlice, onReorderSlices, onMoveSlice, validateSliceDrop, renderSlice, }: SlicesAreaProps<T>): import("react").JSX.Element | null;
@@ -0,0 +1,3 @@
1
+ import { SliceType, type Slice } from '../Model';
2
+ import type { SliceNames } from './SliceNames';
3
+ export declare const createOptimisticSlice: (sliceType: SliceType, names?: SliceNames) => Slice;
@@ -0,0 +1,15 @@
1
+ export * from './resolveSliceReadOnly';
2
+ export * from './SliceContextValue';
3
+ export * from './SliceProvider';
4
+ export * from './useSlice';
5
+ export * from './SliceHeader';
6
+ export * from './SliceHeaderAction';
7
+ export * from './SliceHeaderSlice';
8
+ export * from './SliceColumn';
9
+ export * from './SlicesArea';
10
+ export * from './SliceNames';
11
+ export * from './createOptimisticSlice';
12
+ export * from './sliceAreaState';
13
+ export * from './SliceColumnFrame';
14
+ export * from './SliceRows';
15
+ export * from './SlicePlaceholder';
@@ -0,0 +1,3 @@
1
+ import { SliceStatus } from '../Model';
2
+ import { type DetailLevel } from '../Presentation';
3
+ export declare const resolveSliceReadOnly: (boardReadOnly: boolean, detailLevel: DetailLevel, status: SliceStatus) => boolean;