@parhelia/core 0.1.12912 → 0.1.12917

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 (247) hide show
  1. package/dist/agents-view/AgentGalleryCard.js +1 -1
  2. package/dist/agents-view/AgentGalleryCard.js.map +1 -1
  3. package/dist/agents-view/AgentsWorkspaceView.js +15 -2
  4. package/dist/agents-view/AgentsWorkspaceView.js.map +1 -1
  5. package/dist/components/MarkdownViewerPopover.d.ts +73 -0
  6. package/dist/components/MarkdownViewerPopover.js +109 -0
  7. package/dist/components/MarkdownViewerPopover.js.map +1 -0
  8. package/dist/components/PageHeader.d.ts +5 -1
  9. package/dist/components/PageHeader.js +2 -2
  10. package/dist/components/PageHeader.js.map +1 -1
  11. package/dist/components/SearchInput.js +1 -1
  12. package/dist/components/ui/UserPicker.js +1 -1
  13. package/dist/components/ui/UserPicker.js.map +1 -1
  14. package/dist/components/ui/select.js +1 -1
  15. package/dist/components/ui/select.js.map +1 -1
  16. package/dist/config/config.js +17 -2
  17. package/dist/config/config.js.map +1 -1
  18. package/dist/config/types/workspace.d.ts +6 -2
  19. package/dist/editor/ConfirmationDialog.d.ts +3 -0
  20. package/dist/editor/ConfirmationDialog.js +5 -1
  21. package/dist/editor/ConfirmationDialog.js.map +1 -1
  22. package/dist/editor/ContentTree.d.ts +7 -1
  23. package/dist/editor/ContentTree.js +13 -1
  24. package/dist/editor/ContentTree.js.map +1 -1
  25. package/dist/editor/ContextMenu.js +6 -2
  26. package/dist/editor/ContextMenu.js.map +1 -1
  27. package/dist/editor/FieldHistory.js +2 -1
  28. package/dist/editor/FieldHistory.js.map +1 -1
  29. package/dist/editor/FieldListField.js +4 -3
  30. package/dist/editor/FieldListField.js.map +1 -1
  31. package/dist/editor/GlobalMenuBar.js +5 -2
  32. package/dist/editor/GlobalMenuBar.js.map +1 -1
  33. package/dist/editor/MobileLayout.js +4 -1
  34. package/dist/editor/MobileLayout.js.map +1 -1
  35. package/dist/editor/ScrollingContentTree.d.ts +2 -1
  36. package/dist/editor/ScrollingContentTree.js +2 -2
  37. package/dist/editor/ScrollingContentTree.js.map +1 -1
  38. package/dist/editor/Titlebar.d.ts +2 -1
  39. package/dist/editor/Titlebar.js +4 -9
  40. package/dist/editor/Titlebar.js.map +1 -1
  41. package/dist/editor/WorkspaceTitleSwitcher.d.ts +2 -1
  42. package/dist/editor/WorkspaceTitleSwitcher.js +4 -3
  43. package/dist/editor/WorkspaceTitleSwitcher.js.map +1 -1
  44. package/dist/editor/ai/AgentProfileSelector.js +3 -3
  45. package/dist/editor/ai/AgentProfileSelector.js.map +1 -1
  46. package/dist/editor/ai/Agents.js +15 -4
  47. package/dist/editor/ai/Agents.js.map +1 -1
  48. package/dist/editor/ai/InlineAiTrigger.js +5 -1
  49. package/dist/editor/ai/InlineAiTrigger.js.map +1 -1
  50. package/dist/editor/ai/agentActivitySummary.js +17 -9
  51. package/dist/editor/ai/agentActivitySummary.js.map +1 -1
  52. package/dist/editor/ai/dialogs/capturePageScreenshot.d.ts +18 -1
  53. package/dist/editor/ai/dialogs/capturePageScreenshot.js +60 -13
  54. package/dist/editor/ai/dialogs/capturePageScreenshot.js.map +1 -1
  55. package/dist/editor/ai/terminal/components/AgentDocumentList.js +6 -3
  56. package/dist/editor/ai/terminal/components/AgentDocumentList.js.map +1 -1
  57. package/dist/editor/ai/terminal/components/AgentFullPromptControls.d.ts +2 -1
  58. package/dist/editor/ai/terminal/components/AgentFullPromptControls.js +9 -6
  59. package/dist/editor/ai/terminal/components/AgentFullPromptControls.js.map +1 -1
  60. package/dist/editor/ai/terminal/components/AgentModeSelector.js +8 -7
  61. package/dist/editor/ai/terminal/components/AgentModeSelector.js.map +1 -1
  62. package/dist/editor/ai/terminal/components/AgentPromptTrayPopovers.js +4 -1
  63. package/dist/editor/ai/terminal/components/AgentPromptTrayPopovers.js.map +1 -1
  64. package/dist/editor/ai/terminal/components/AgentSummaryPromptActions.d.ts +2 -1
  65. package/dist/editor/ai/terminal/components/AgentSummaryPromptActions.js +7 -2
  66. package/dist/editor/ai/terminal/components/AgentSummaryPromptActions.js.map +1 -1
  67. package/dist/editor/ai/terminal/components/AgentTerminalSummaryLayout.d.ts +2 -1
  68. package/dist/editor/ai/terminal/components/AgentTerminalSummaryLayout.js +2 -2
  69. package/dist/editor/ai/terminal/components/AgentTerminalSummaryLayout.js.map +1 -1
  70. package/dist/editor/ai/terminal/components/ContextInfoBar.js +35 -8
  71. package/dist/editor/ai/terminal/components/ContextInfoBar.js.map +1 -1
  72. package/dist/editor/ai/terminal/components/UserMessage.js +4 -4
  73. package/dist/editor/ai/terminal/components/UserMessage.js.map +1 -1
  74. package/dist/editor/ai/terminal/projectTemplateContext.d.ts +11 -0
  75. package/dist/editor/ai/terminal/projectTemplateContext.js +64 -0
  76. package/dist/editor/ai/terminal/projectTemplateContext.js.map +1 -0
  77. package/dist/editor/ai/terminal/useAgentLoadPipeline.js +1 -0
  78. package/dist/editor/ai/terminal/useAgentLoadPipeline.js.map +1 -1
  79. package/dist/editor/ai/terminal/useAgentLoader.d.ts +1 -0
  80. package/dist/editor/ai/terminal/useAgentLoader.js +14 -2
  81. package/dist/editor/ai/terminal/useAgentLoader.js.map +1 -1
  82. package/dist/editor/ai/terminal/useAgentSettingsData.js +1 -0
  83. package/dist/editor/ai/terminal/useAgentSettingsData.js.map +1 -1
  84. package/dist/editor/ai/terminal/useAgentSubmitHandlers.d.ts +1 -0
  85. package/dist/editor/ai/terminal/useAgentSubmitHandlers.js +19 -1
  86. package/dist/editor/ai/terminal/useAgentSubmitHandlers.js.map +1 -1
  87. package/dist/editor/ai/terminal/useAgentTerminalController.js +4 -1
  88. package/dist/editor/ai/terminal/useAgentTerminalController.js.map +1 -1
  89. package/dist/editor/ai/useInlineAiPosition.d.ts +2 -1
  90. package/dist/editor/ai/useInlineAiPosition.js +10 -3
  91. package/dist/editor/ai/useInlineAiPosition.js.map +1 -1
  92. package/dist/editor/bridge/protocol.d.ts +22 -1
  93. package/dist/editor/bridge/protocol.js +3 -1
  94. package/dist/editor/bridge/protocol.js.map +1 -1
  95. package/dist/editor/client/EditorShell.js +45 -22
  96. package/dist/editor/client/EditorShell.js.map +1 -1
  97. package/dist/editor/client/editContext.d.ts +1 -0
  98. package/dist/editor/client/editContext.js.map +1 -1
  99. package/dist/editor/client/pageModelBuilder.d.ts +1 -0
  100. package/dist/editor/client/pageModelBuilder.js +9 -2
  101. package/dist/editor/client/pageModelBuilder.js.map +1 -1
  102. package/dist/editor/client/ui/FullscreenControls.js +1 -1
  103. package/dist/editor/client/ui/FullscreenControls.js.map +1 -1
  104. package/dist/editor/commands/componentCommands.d.ts +1 -0
  105. package/dist/editor/commands/componentCommands.js +139 -2
  106. package/dist/editor/commands/componentCommands.js.map +1 -1
  107. package/dist/editor/content-tree/TreeSettingsMenu.js +1 -1
  108. package/dist/editor/content-tree/TreeSettingsMenu.js.map +1 -1
  109. package/dist/editor/fieldTypeConfiguration.d.ts +2 -0
  110. package/dist/editor/fieldTypeConfiguration.js +7 -0
  111. package/dist/editor/fieldTypeConfiguration.js.map +1 -0
  112. package/dist/editor/menubar/PageSelector.js +8 -1
  113. package/dist/editor/menubar/PageSelector.js.map +1 -1
  114. package/dist/editor/menubar/toolbar-sections/DeviceSwitchToolbar.d.ts +2 -1
  115. package/dist/editor/menubar/toolbar-sections/DeviceSwitchToolbar.js +2 -2
  116. package/dist/editor/menubar/toolbar-sections/DeviceSwitchToolbar.js.map +1 -1
  117. package/dist/editor/page-editor-chrome/BridgeInlineFormatOverlay.js +7 -1
  118. package/dist/editor/page-editor-chrome/BridgeInlineFormatOverlay.js.map +1 -1
  119. package/dist/editor/page-editor-chrome/DragInsertionOverlay.js +53 -19
  120. package/dist/editor/page-editor-chrome/DragInsertionOverlay.js.map +1 -1
  121. package/dist/editor/page-editor-chrome/FrameMenu.js +3 -1
  122. package/dist/editor/page-editor-chrome/FrameMenu.js.map +1 -1
  123. package/dist/editor/page-editor-chrome/PlaceholderDropZone.js +4 -3
  124. package/dist/editor/page-editor-chrome/PlaceholderDropZone.js.map +1 -1
  125. package/dist/editor/page-editor-chrome/bridgeInlineFormatToolbarLayout.d.ts +2 -1
  126. package/dist/editor/page-editor-chrome/bridgeInlineFormatToolbarLayout.js +2 -0
  127. package/dist/editor/page-editor-chrome/bridgeInlineFormatToolbarLayout.js.map +1 -1
  128. package/dist/editor/page-editor-chrome/insertTargetLabel.d.ts +1 -0
  129. package/dist/editor/page-editor-chrome/insertTargetLabel.js +14 -1
  130. package/dist/editor/page-editor-chrome/insertTargetLabel.js.map +1 -1
  131. package/dist/editor/page-editor-chrome/overlay/placeholderZones.js +13 -3
  132. package/dist/editor/page-editor-chrome/overlay/placeholderZones.js.map +1 -1
  133. package/dist/editor/page-editor-chrome/useComponentDragHandle.js +11 -5
  134. package/dist/editor/page-editor-chrome/useComponentDragHandle.js.map +1 -1
  135. package/dist/editor/page-viewer/PageViewer.js +5 -4
  136. package/dist/editor/page-viewer/PageViewer.js.map +1 -1
  137. package/dist/editor/page-viewer/PageViewerFrame.js +53 -3
  138. package/dist/editor/page-viewer/PageViewerFrame.js.map +1 -1
  139. package/dist/editor/page-viewer/bridgeFieldPatch.d.ts +3 -1
  140. package/dist/editor/page-viewer/bridgeFieldPatch.js +24 -1
  141. package/dist/editor/page-viewer/bridgeFieldPatch.js.map +1 -1
  142. package/dist/editor/page-viewer/pageViewContext.d.ts +4 -1
  143. package/dist/editor/page-viewer/pageViewContext.js +4 -1
  144. package/dist/editor/page-viewer/pageViewContext.js.map +1 -1
  145. package/dist/editor/page-viewer/parentBridgeInjection.d.ts +23 -0
  146. package/dist/editor/page-viewer/parentBridgeInjection.js +251 -0
  147. package/dist/editor/page-viewer/parentBridgeInjection.js.map +1 -0
  148. package/dist/editor/page-viewer/renderUrl.js +4 -2
  149. package/dist/editor/page-viewer/renderUrl.js.map +1 -1
  150. package/dist/editor/pageModel.d.ts +1 -0
  151. package/dist/editor/reviews/MultiReviewManager.js +3 -22
  152. package/dist/editor/reviews/MultiReviewManager.js.map +1 -1
  153. package/dist/editor/reviews/openCommentsFeedback.js +2 -0
  154. package/dist/editor/reviews/openCommentsFeedback.js.map +1 -1
  155. package/dist/editor/services/agentService.js +6 -2
  156. package/dist/editor/services/agentService.js.map +1 -1
  157. package/dist/editor/services/editService.d.ts +15 -0
  158. package/dist/editor/services/editService.js +3 -0
  159. package/dist/editor/services/editService.js.map +1 -1
  160. package/dist/editor/settings/SettingsBreadcrumb.js +5 -2
  161. package/dist/editor/settings/SettingsBreadcrumb.js.map +1 -1
  162. package/dist/editor/settings/SettingsHeaderActionsContext.d.ts +4 -0
  163. package/dist/editor/settings/SettingsHeaderActionsContext.js.map +1 -1
  164. package/dist/editor/settings/SettingsTitlebar.d.ts +1 -0
  165. package/dist/editor/settings/SettingsTitlebar.js +18 -0
  166. package/dist/editor/settings/SettingsTitlebar.js.map +1 -0
  167. package/dist/editor/settings/SettingsView.js +64 -18
  168. package/dist/editor/settings/SettingsView.js.map +1 -1
  169. package/dist/editor/settings/panels/ModelsPanel.js +4 -3
  170. package/dist/editor/settings/panels/ModelsPanel.js.map +1 -1
  171. package/dist/editor/settings/panels/ProjectTemplateAgentPanel.d.ts +8 -1
  172. package/dist/editor/settings/panels/ProjectTemplateAgentPanel.js +75 -9
  173. package/dist/editor/settings/panels/ProjectTemplateAgentPanel.js.map +1 -1
  174. package/dist/editor/settings/panels/ProjectTemplateSelectorList.js +1 -1
  175. package/dist/editor/settings/panels/ProjectTemplateSelectorList.js.map +1 -1
  176. package/dist/editor/settings/panels/ProjectTemplatesPanel.js +515 -50
  177. package/dist/editor/settings/panels/ProjectTemplatesPanel.js.map +1 -1
  178. package/dist/editor/settings/panels/ProvidersPanel.js +1 -1
  179. package/dist/editor/settings/panels/ProvidersPanel.js.map +1 -1
  180. package/dist/editor/settings/settingsNavigationStore.d.ts +12 -0
  181. package/dist/editor/settings/settingsNavigationStore.js +32 -0
  182. package/dist/editor/settings/settingsNavigationStore.js.map +1 -0
  183. package/dist/editor/setup-wizard/steps/ProviderStep.js +6 -2
  184. package/dist/editor/setup-wizard/steps/ProviderStep.js.map +1 -1
  185. package/dist/editor/sidebar/ComponentPalette.js +10 -4
  186. package/dist/editor/sidebar/ComponentPalette.js.map +1 -1
  187. package/dist/editor/sidebar/ComponentTree.js +12 -12
  188. package/dist/editor/sidebar/ComponentTree.js.map +1 -1
  189. package/dist/editor/sidebar/ContentTreePanel.js +1 -1
  190. package/dist/editor/sidebar/ContentTreePanel.js.map +1 -1
  191. package/dist/editor/sidebar/SidebarPanel.js +1 -1
  192. package/dist/editor/sidebar/SidebarPanel.js.map +1 -1
  193. package/dist/editor/sidebar/WorkspaceRailMobile.d.ts +0 -1
  194. package/dist/editor/sidebar/WorkspaceRailMobile.js +4 -14
  195. package/dist/editor/sidebar/WorkspaceRailMobile.js.map +1 -1
  196. package/dist/editor/ui/ComponentThumbnailDialog.d.ts +14 -0
  197. package/dist/editor/ui/ComponentThumbnailDialog.js +75 -0
  198. package/dist/editor/ui/ComponentThumbnailDialog.js.map +1 -0
  199. package/dist/editor/ui/PublishRestrictionsDialog.js +77 -9
  200. package/dist/editor/ui/PublishRestrictionsDialog.js.map +1 -1
  201. package/dist/editor/ui/Splitter.d.ts +3 -0
  202. package/dist/editor/ui/Splitter.js +30 -16
  203. package/dist/editor/ui/Splitter.js.map +1 -1
  204. package/dist/editor/utils/itemutils.js +2 -0
  205. package/dist/editor/utils/itemutils.js.map +1 -1
  206. package/dist/editor/views/ItemEditorPane.js +1 -1
  207. package/dist/editor/views/ItemEditorPane.js.map +1 -1
  208. package/dist/index.d.ts +5 -1
  209. package/dist/index.js +3 -1
  210. package/dist/index.js.map +1 -1
  211. package/dist/revision.d.ts +2 -2
  212. package/dist/revision.js +2 -2
  213. package/dist/task-board/TaskBoardWorkspace.js +73 -5
  214. package/dist/task-board/TaskBoardWorkspace.js.map +1 -1
  215. package/dist/task-board/components/CreateProjectDialog.d.ts +0 -1
  216. package/dist/task-board/components/CreateProjectDialog.js +1 -4
  217. package/dist/task-board/components/CreateProjectDialog.js.map +1 -1
  218. package/dist/task-board/components/GoalDialog.d.ts +9 -0
  219. package/dist/task-board/components/GoalDialog.js +149 -0
  220. package/dist/task-board/components/GoalDialog.js.map +1 -0
  221. package/dist/task-board/components/ProjectDashboard.d.ts +10 -0
  222. package/dist/task-board/components/ProjectDashboard.js +3 -3
  223. package/dist/task-board/components/ProjectDashboard.js.map +1 -1
  224. package/dist/task-board/components/ProjectGoalsPanel.d.ts +16 -0
  225. package/dist/task-board/components/ProjectGoalsPanel.js +310 -0
  226. package/dist/task-board/components/ProjectGoalsPanel.js.map +1 -0
  227. package/dist/task-board/components/ProjectPropertiesPanel.js +5 -3
  228. package/dist/task-board/components/ProjectPropertiesPanel.js.map +1 -1
  229. package/dist/task-board/components/TaskAssigneePicker.js +1 -1
  230. package/dist/task-board/components/TaskAssigneePicker.js.map +1 -1
  231. package/dist/task-board/components/TaskAttachmentDropZone.d.ts +1 -0
  232. package/dist/task-board/components/TaskAttachmentDropZone.js +5 -3
  233. package/dist/task-board/components/TaskAttachmentDropZone.js.map +1 -1
  234. package/dist/task-board/components/TaskAttachmentsSection.js +8 -1
  235. package/dist/task-board/components/TaskAttachmentsSection.js.map +1 -1
  236. package/dist/task-board/components/WizardCommunicationCenter.js +1 -10
  237. package/dist/task-board/components/WizardCommunicationCenter.js.map +1 -1
  238. package/dist/task-board/services/goalService.d.ts +65 -0
  239. package/dist/task-board/services/goalService.js +37 -0
  240. package/dist/task-board/services/goalService.js.map +1 -0
  241. package/dist/task-board/types.d.ts +68 -3
  242. package/dist/task-board/views/DependencyGraphView.js +121 -31
  243. package/dist/task-board/views/DependencyGraphView.js.map +1 -1
  244. package/package.json +2 -2
  245. package/dist/editor/sidebar/MobileWorkspacePopover.d.ts +0 -16
  246. package/dist/editor/sidebar/MobileWorkspacePopover.js +0 -35
  247. package/dist/editor/sidebar/MobileWorkspacePopover.js.map +0 -1
@@ -58,19 +58,84 @@ export type ProjectWithPermission = {
58
58
  permission: ProjectPermission;
59
59
  overview?: ProjectOverviewSummary | null;
60
60
  };
61
+ export type GoalStatus = "Open" | "InProgress" | "Achieved" | "Abandoned";
62
+ export type SubgoalStatus = "Pending" | "InProgress" | "Done" | "Failed" | "Skipped";
63
+ /** Arbitrary attached payload (parsed JSON object/array) on a goal or subgoal. */
64
+ export type GoalData = unknown;
65
+ export type GoalCoverage = {
66
+ total: number;
67
+ done: number;
68
+ skipped: number;
69
+ hasMeasurableSubgoals: boolean;
70
+ percent?: number | null;
71
+ };
72
+ export type Subgoal = {
73
+ subgoalId: string;
74
+ goalId: string;
75
+ title: string;
76
+ description?: string | null;
77
+ targetItemId?: string | null;
78
+ targetItemLanguage?: string | null;
79
+ targetItemPath?: string | null;
80
+ status: SubgoalStatus;
81
+ data?: GoalData;
82
+ sortOrder: number;
83
+ createdBy?: string;
84
+ createdByType?: string;
85
+ createdAt: string;
86
+ updatedBy?: string;
87
+ updatedByType?: string;
88
+ updatedAt: string;
89
+ };
90
+ export type Goal = {
91
+ goalId: string;
92
+ projectId: string;
93
+ title: string;
94
+ description?: string | null;
95
+ sourceGoalTemplateId?: string | null;
96
+ sourceGoalTemplateName?: string | null;
97
+ status: GoalStatus;
98
+ data?: GoalData;
99
+ sortOrder: number;
100
+ createdBy?: string;
101
+ createdByType?: string;
102
+ createdAt: string;
103
+ updatedBy?: string;
104
+ updatedByType?: string;
105
+ updatedAt: string;
106
+ subgoals?: Subgoal[] | null;
107
+ coverage?: GoalCoverage | null;
108
+ };
109
+ /** A predefined goal definition (catalog entry) declared by the project's template. */
110
+ export type GoalDefinition = {
111
+ id: string;
112
+ title: string;
113
+ description?: string | null;
114
+ disabled?: boolean;
115
+ sortOrder?: number;
116
+ defaultScopeJson?: string | null;
117
+ dataShape?: string | null;
118
+ };
119
+ export type ProjectGoalsResponse = {
120
+ projectId: string;
121
+ includeDescendants: boolean;
122
+ goals: Goal[];
123
+ catalog: GoalDefinition[];
124
+ /** Effective permission per project id in scope (row-by-row edit gating). */
125
+ permissions: Record<string, ProjectPermission | string>;
126
+ };
61
127
  export type ProjectTemplate = {
62
128
  id: string;
63
129
  name: string;
64
130
  description?: string | null;
65
131
  disabled?: boolean;
66
132
  hideFromCreateDialog?: boolean;
67
- /** When true, new projects from this template open in taskboard wizard mode */
68
- openInWizardMode?: boolean;
69
133
  /** True when stored under /sitecore/system/Parhelia/System/Project Templates */
70
134
  isSystem?: boolean;
71
135
  defaultCostLimit?: number | null;
72
136
  graphLayout?: ProjectTemplateGraphLayout | null;
73
137
  taskTemplates: TaskTemplateSummary[];
138
+ goalTemplates: GoalDefinition[];
74
139
  };
75
140
  export type ProjectTemplateAgentSession = {
76
141
  projectTemplateId: string;
@@ -443,10 +508,10 @@ export type UpsertProjectTemplateRequest = {
443
508
  description?: string | null;
444
509
  disabled: boolean;
445
510
  hideFromCreateDialog: boolean;
446
- openInWizardMode: boolean;
447
511
  defaultCostLimit?: number | null;
448
512
  graphLayout?: ProjectTemplateGraphLayout | null;
449
513
  taskTemplates: TaskTemplateSummary[];
514
+ goalTemplates: GoalDefinition[];
450
515
  };
451
516
  export type DeleteProjectTemplateRequest = {
452
517
  projectTemplateId: string;
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { useCallback, useEffect, useMemo, useRef, useState, } from "react";
3
3
  import { flushSync } from "react-dom";
4
- import { ReactFlow, Controls, MiniMap, useEdgesState, useNodesState, Handle, Position, MarkerType, } from "@xyflow/react";
4
+ import { ReactFlow, Controls, MiniMap, BaseEdge, useEdgesState, useNodesState, Handle, Position, MarkerType, } from "@xyflow/react";
5
5
  import Dagre from "@dagrejs/dagre";
6
6
  import "@xyflow/react/dist/style.css";
7
7
  import { toast } from "sonner";
@@ -95,7 +95,7 @@ function TaskGraphNode({ data }) {
95
95
  const nodeSurfaceClass = data.isSelected
96
96
  ? cn("shadow-lg ring-2", selectedStyle)
97
97
  : hoverStyle;
98
- return (_jsxs("div", { className: cn("group relative cursor-pointer overflow-hidden rounded-lg border bg-white p-3 text-left shadow-sm transition-all hover:shadow-md", nodeSurfaceClass), style: { width: NODE_WIDTH }, "data-testid": `dependency-graph-node-${data.taskId}`, children: [_jsx("div", { className: cn("absolute inset-y-0 left-0 w-1", priorityBarStyle) }), _jsx(Handle, { type: "target", position: Position.Left, id: "left", className: HANDLE_CLASS, "data-testid": `dependency-graph-target-left-${data.taskId}` }), _jsx(Handle, { type: "target", position: Position.Top, id: "top", className: HANDLE_CLASS, "data-testid": `dependency-graph-target-top-${data.taskId}` }), _jsxs("div", { className: "flex flex-col gap-2.5", children: [_jsxs("div", { className: "flex items-start justify-between gap-2", children: [_jsxs("div", { className: "min-w-0", children: [_jsx("div", { className: "text-muted-foreground mb-1 flex items-center gap-1 text-[10px] font-medium tracking-widest", children: _jsx("span", { className: "truncate", children: data.taskKey || data.taskId.slice(0, 8).toUpperCase() }) }), _jsx("div", { className: "line-clamp-2 text-sm leading-snug font-medium", children: data.title })] }), _jsxs("div", { className: "flex shrink-0 items-center gap-1", children: [isDecisionPoint ? (_jsx(GitBranch, { className: "text-highlight-100 h-4 w-4", "aria-label": "Decision Point" })) : null, data.priority === "Critical" ? (_jsx(AlertCircle, { className: "text-feedback-red h-4 w-4", "aria-label": "Critical priority" })) : null, data.onRemoveTask && (_jsx("button", { type: "button", className: "text-neutral-grey-50 hover:bg-neutral-grey-5 hover:text-neutral-grey-50 -mt-px -mr-0.5 shrink-0 rounded p-0.5 transition-colors", "aria-label": "Remove task", "data-testid": `dependency-graph-remove-task-${data.taskId}`, onClick: (event) => {
98
+ return (_jsxs("div", { className: cn("group relative cursor-pointer overflow-visible rounded-lg border bg-white p-3 text-left shadow-sm transition-all hover:shadow-md", nodeSurfaceClass), style: { width: NODE_WIDTH }, "data-testid": `dependency-graph-node-${data.taskId}`, children: [_jsx("div", { className: cn("absolute inset-y-0 left-0 w-1 rounded-l-lg", priorityBarStyle) }), _jsx(Handle, { type: "target", position: Position.Left, id: "left", className: HANDLE_CLASS, "data-testid": `dependency-graph-target-left-${data.taskId}` }), _jsx(Handle, { type: "target", position: Position.Top, id: "top", className: HANDLE_CLASS, "data-testid": `dependency-graph-target-top-${data.taskId}` }), _jsxs("div", { className: "flex flex-col gap-2.5", children: [_jsxs("div", { className: "flex items-start justify-between gap-2", children: [_jsxs("div", { className: "min-w-0", children: [_jsx("div", { className: "text-muted-foreground mb-1 flex items-center gap-1 text-[10px] font-medium tracking-widest", children: _jsx("span", { className: "truncate", children: data.taskKey || data.taskId.slice(0, 8).toUpperCase() }) }), _jsx("div", { className: "line-clamp-2 text-sm leading-snug font-medium", children: data.title })] }), _jsxs("div", { className: "flex shrink-0 items-center gap-1", children: [isDecisionPoint ? (_jsx(GitBranch, { className: "text-highlight-100 h-4 w-4", "aria-label": "Decision Point" })) : null, data.priority === "Critical" ? (_jsx(AlertCircle, { className: "text-feedback-red h-4 w-4", "aria-label": "Critical priority" })) : null, data.onRemoveTask && (_jsx("button", { type: "button", className: "text-neutral-grey-50 hover:bg-neutral-grey-5 hover:text-neutral-grey-50 -mt-px -mr-0.5 shrink-0 rounded p-0.5 transition-colors", "aria-label": "Remove task", "data-testid": `dependency-graph-remove-task-${data.taskId}`, onClick: (event) => {
99
99
  event.stopPropagation();
100
100
  data.onRemoveTask?.(data.taskId);
101
101
  }, children: _jsx(DeleteIcon, { size: "xs" }) }))] })] }), _jsxs("div", { className: "mt-0.5 flex flex-wrap items-center gap-2", children: [isDecisionPoint ? (_jsx(Badge, { variant: "outline", size: "sm", className: "text-2xs border-highlight-100 bg-highlight-10 text-highlight-100", children: "Decision Point" })) : null, data.assigneeDisplayName && (_jsx(TaskAssigneeBadge, { assigneeType: data.assigneeType, label: data.assigneeDisplayName })), executionDisplay ? (_jsxs(Badge, { variant: executionDisplay.variant, size: "sm", className: cn("max-w-full font-bold", executionDisplay.className), title: executionDisplay.needsAttention
@@ -117,8 +117,81 @@ function TaskGraphNode({ data }) {
117
117
  const nodeTypes = {
118
118
  taskNode: TaskGraphNode,
119
119
  };
120
+ function getHierarchyOrthogonalPath({ sourceX, sourceY, targetX, targetY, sourcePosition, targetPosition, }) {
121
+ const sameColumn = Math.abs(sourceX - targetX) < 1;
122
+ const sameRow = Math.abs(sourceY - targetY) < 1;
123
+ if (sameColumn || sameRow) {
124
+ return `M ${sourceX} ${sourceY} L ${targetX} ${targetY}`;
125
+ }
126
+ if (sourcePosition === Position.Bottom && targetPosition === Position.Top) {
127
+ const midY = sourceY + (targetY - sourceY) / 2;
128
+ return `M ${sourceX} ${sourceY} L ${sourceX} ${midY} L ${targetX} ${midY} L ${targetX} ${targetY}`;
129
+ }
130
+ if (sourcePosition === Position.Right && targetPosition === Position.Left) {
131
+ const midX = sourceX + (targetX - sourceX) / 2;
132
+ return `M ${sourceX} ${sourceY} L ${midX} ${sourceY} L ${midX} ${targetY} L ${targetX} ${targetY}`;
133
+ }
134
+ const useHorizontalBend = Math.abs(targetX - sourceX) >= Math.abs(targetY - sourceY);
135
+ if (useHorizontalBend) {
136
+ const midX = sourceX + (targetX - sourceX) / 2;
137
+ return `M ${sourceX} ${sourceY} L ${midX} ${sourceY} L ${midX} ${targetY} L ${targetX} ${targetY}`;
138
+ }
139
+ const midY = sourceY + (targetY - sourceY) / 2;
140
+ return `M ${sourceX} ${sourceY} L ${sourceX} ${midY} L ${targetX} ${midY} L ${targetX} ${targetY}`;
141
+ }
142
+ function HierarchyOrthogonalEdge({ id, sourceX, sourceY, targetX, targetY, sourcePosition, targetPosition, markerEnd, markerStart, style, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, interactionWidth, }) {
143
+ const path = getHierarchyOrthogonalPath({
144
+ sourceX,
145
+ sourceY,
146
+ targetX,
147
+ targetY,
148
+ sourcePosition,
149
+ targetPosition,
150
+ });
151
+ return (_jsx(BaseEdge, { id: id, path: path, markerEnd: markerEnd, markerStart: markerStart, style: style, label: label, labelStyle: labelStyle, labelShowBg: labelShowBg, labelBgStyle: labelBgStyle, labelBgPadding: labelBgPadding, labelBgBorderRadius: labelBgBorderRadius, interactionWidth: interactionWidth }));
152
+ }
153
+ const edgeTypes = {
154
+ hierarchyOrthogonal: HierarchyOrthogonalEdge,
155
+ };
120
156
  const HIERARCHY_CHILD_GAP = 32;
121
157
  const HIERARCHY_SUBTREE_GAP = 80;
158
+ function normalizeGraphNodeSize(size) {
159
+ if (!size ||
160
+ typeof size.width !== "number" ||
161
+ typeof size.height !== "number" ||
162
+ !Number.isFinite(size.width) ||
163
+ !Number.isFinite(size.height) ||
164
+ size.width <= 0 ||
165
+ size.height <= 0) {
166
+ return null;
167
+ }
168
+ return {
169
+ width: Math.max(NODE_WIDTH, size.width),
170
+ height: Math.max(NODE_HEIGHT, size.height),
171
+ };
172
+ }
173
+ function getGraphNodeSize(nodeId, nodeSizeOverrides) {
174
+ return (normalizeGraphNodeSize(nodeSizeOverrides?.get(nodeId)) ?? {
175
+ width: NODE_WIDTH,
176
+ height: NODE_HEIGHT,
177
+ });
178
+ }
179
+ function getMeasuredNodeSizeOverrides(nodes) {
180
+ if (!nodes?.length)
181
+ return undefined;
182
+ const sizes = new Map();
183
+ for (const node of nodes) {
184
+ const measuredNode = node;
185
+ const measuredSize = normalizeGraphNodeSize(measuredNode.measured ?? {
186
+ width: measuredNode.width,
187
+ height: measuredNode.height,
188
+ });
189
+ if (measuredSize) {
190
+ sizes.set(node.id, measuredSize);
191
+ }
192
+ }
193
+ return sizes.size > 0 ? sizes : undefined;
194
+ }
122
195
  function normalizeGraphOrientation(orientation) {
123
196
  return orientation === "vertical" ? "vertical" : "horizontal";
124
197
  }
@@ -137,11 +210,12 @@ function getHierarchyHandles(orientation, autoLayoutStrategy) {
137
210
  }
138
211
  /**
139
212
  * Compound layout for the hierarchy strategy: each parent-child group is
140
- * laid out perpendicular to the selected orientation, and then the resulting subtree
141
- * "super-nodes" are arranged via Dagre using the dependency edges between
142
- * them.
213
+ * laid out perpendicular to the selected orientation, and then the resulting
214
+ * subtree "super-nodes" are arranged via Dagre using the dependency edges
215
+ * between them. Dagre receives root-anchored bounds so the top-level cards in a
216
+ * dependency chain stay aligned even when one of them has a deeper child tree.
143
217
  */
144
- function layoutGraphHierarchy(nodes, edges, orientation) {
218
+ function layoutGraphHierarchy(nodes, edges, orientation, nodeSizeOverrides) {
145
219
  if (nodes.length === 0)
146
220
  return { nodes, edges };
147
221
  const childrenOf = new Map();
@@ -255,12 +329,13 @@ function layoutGraphHierarchy(nodes, edges, orientation) {
255
329
  }
256
330
  }
257
331
  function measureSubtree(nodeId) {
332
+ const nodeSize = getGraphNodeSize(nodeId, nodeSizeOverrides);
258
333
  const children = childrenOf.get(nodeId) ?? [];
259
334
  if (children.length === 0) {
260
335
  return {
261
336
  positions: new Map([[nodeId, { x: 0, y: 0 }]]),
262
- width: NODE_WIDTH,
263
- height: NODE_HEIGHT,
337
+ width: nodeSize.width,
338
+ height: nodeSize.height,
264
339
  };
265
340
  }
266
341
  const childLayouts = children.map((childId) => measureSubtree(childId));
@@ -269,12 +344,12 @@ function layoutGraphHierarchy(nodes, edges, orientation) {
269
344
  const childRowWidth = childLayouts.reduce((sum, child) => sum + child.width, 0) +
270
345
  HIERARCHY_CHILD_GAP * (childLayouts.length - 1);
271
346
  const childRowHeight = Math.max(...childLayouts.map((child) => child.height));
272
- const width = Math.max(NODE_WIDTH, childRowWidth);
273
- const height = NODE_HEIGHT + HIERARCHY_CHILD_GAP + childRowHeight;
274
- positions.set(nodeId, { x: (width - NODE_WIDTH) / 2, y: 0 });
347
+ const width = Math.max(nodeSize.width, childRowWidth);
348
+ const height = nodeSize.height + HIERARCHY_CHILD_GAP + childRowHeight;
349
+ positions.set(nodeId, { x: (width - nodeSize.width) / 2, y: 0 });
275
350
  let childX = (width - childRowWidth) / 2;
276
351
  for (const childLayout of childLayouts) {
277
- addTranslatedPositions(positions, childLayout.positions, childX, NODE_HEIGHT + HIERARCHY_CHILD_GAP);
352
+ addTranslatedPositions(positions, childLayout.positions, childX, nodeSize.height + HIERARCHY_CHILD_GAP);
278
353
  childX += childLayout.width + HIERARCHY_CHILD_GAP;
279
354
  }
280
355
  return {
@@ -286,12 +361,12 @@ function layoutGraphHierarchy(nodes, edges, orientation) {
286
361
  const childColumnWidth = Math.max(...childLayouts.map((child) => child.width));
287
362
  const childColumnHeight = childLayouts.reduce((sum, child) => sum + child.height, 0) +
288
363
  HIERARCHY_CHILD_GAP * (childLayouts.length - 1);
289
- const width = NODE_WIDTH + HIERARCHY_CHILD_GAP + childColumnWidth;
290
- const height = Math.max(NODE_HEIGHT, childColumnHeight);
291
- positions.set(nodeId, { x: 0, y: (height - NODE_HEIGHT) / 2 });
364
+ const width = nodeSize.width + HIERARCHY_CHILD_GAP + childColumnWidth;
365
+ const height = Math.max(nodeSize.height, childColumnHeight);
366
+ positions.set(nodeId, { x: 0, y: (height - nodeSize.height) / 2 });
292
367
  let childY = (height - childColumnHeight) / 2;
293
368
  for (const childLayout of childLayouts) {
294
- addTranslatedPositions(positions, childLayout.positions, NODE_WIDTH + HIERARCHY_CHILD_GAP, childY);
369
+ addTranslatedPositions(positions, childLayout.positions, nodeSize.width + HIERARCHY_CHILD_GAP, childY);
295
370
  childY += childLayout.height + HIERARCHY_CHILD_GAP;
296
371
  }
297
372
  return {
@@ -317,7 +392,14 @@ function layoutGraphHierarchy(nodes, edges, orientation) {
317
392
  ranksep: HIERARCHY_SUBTREE_GAP,
318
393
  });
319
394
  for (const [rootId, data] of subtrees) {
320
- g.setNode(rootId, { width: data.width, height: data.height });
395
+ const rootPosition = data.positions.get(rootId) ?? { x: 0, y: 0 };
396
+ const rootSize = getGraphNodeSize(rootId, nodeSizeOverrides);
397
+ const rootCenterX = rootPosition.x + rootSize.width / 2;
398
+ const rootCenterY = rootPosition.y + rootSize.height / 2;
399
+ g.setNode(rootId, {
400
+ width: Math.max(rootCenterX, data.width - rootCenterX) * 2,
401
+ height: Math.max(rootCenterY, data.height - rootCenterY) * 2,
402
+ });
321
403
  }
322
404
  const addedSuperEdges = new Set();
323
405
  for (const edge of edges) {
@@ -337,8 +419,10 @@ function layoutGraphHierarchy(nodes, edges, orientation) {
337
419
  const finalPositions = new Map();
338
420
  for (const [rootId, data] of subtrees) {
339
421
  const superNode = g.node(rootId);
340
- const offsetX = superNode.x - data.width / 2;
341
- const offsetY = superNode.y - data.height / 2;
422
+ const rootPosition = data.positions.get(rootId) ?? { x: 0, y: 0 };
423
+ const rootSize = getGraphNodeSize(rootId, nodeSizeOverrides);
424
+ const offsetX = superNode.x - rootPosition.x - rootSize.width / 2;
425
+ const offsetY = superNode.y - rootPosition.y - rootSize.height / 2;
342
426
  for (const [nodeId, localPos] of data.positions) {
343
427
  finalPositions.set(nodeId, {
344
428
  x: offsetX + localPos.x,
@@ -354,10 +438,10 @@ function layoutGraphHierarchy(nodes, edges, orientation) {
354
438
  edges,
355
439
  };
356
440
  }
357
- function layoutGraph(nodes, edges, orientation, autoLayoutStrategy) {
441
+ function layoutGraph(nodes, edges, orientation, autoLayoutStrategy, nodeSizeOverrides) {
358
442
  if (autoLayoutStrategy === "hierarchy" &&
359
443
  edges.some((e) => e.data?.relationship === "hierarchy")) {
360
- return layoutGraphHierarchy(nodes, edges, orientation);
444
+ return layoutGraphHierarchy(nodes, edges, orientation, nodeSizeOverrides);
361
445
  }
362
446
  const g = new Dagre.graphlib.Graph().setDefaultEdgeLabel(() => ({}));
363
447
  g.setGraph({
@@ -366,7 +450,7 @@ function layoutGraph(nodes, edges, orientation, autoLayoutStrategy) {
366
450
  ranksep: 60,
367
451
  });
368
452
  for (const node of nodes) {
369
- g.setNode(node.id, { width: NODE_WIDTH, height: NODE_HEIGHT });
453
+ g.setNode(node.id, getGraphNodeSize(node.id, nodeSizeOverrides));
370
454
  }
371
455
  for (const edge of edges) {
372
456
  g.setEdge(edge.source, edge.target);
@@ -374,17 +458,18 @@ function layoutGraph(nodes, edges, orientation, autoLayoutStrategy) {
374
458
  Dagre.layout(g);
375
459
  const layoutedNodes = nodes.map((node) => {
376
460
  const dagNode = g.node(node.id);
461
+ const nodeSize = getGraphNodeSize(node.id, nodeSizeOverrides);
377
462
  return {
378
463
  ...node,
379
464
  position: {
380
- x: dagNode.x - NODE_WIDTH / 2,
381
- y: dagNode.y - NODE_HEIGHT / 2,
465
+ x: dagNode.x - nodeSize.width / 2,
466
+ y: dagNode.y - nodeSize.height / 2,
382
467
  },
383
468
  };
384
469
  });
385
470
  return { nodes: layoutedNodes, edges };
386
471
  }
387
- function buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, blockedTaskIds, orientation, showExecutionStateBadges, autoLayoutStrategy, onSelect, onAddDependentTaskFromNode, onAddChildTaskFromNode, onRemoveTask) {
472
+ function buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, blockedTaskIds, orientation, showExecutionStateBadges, autoLayoutStrategy, onSelect, onAddDependentTaskFromNode, onAddChildTaskFromNode, onRemoveTask, nodeSizeOverrides) {
388
473
  const taskMap = new Map();
389
474
  for (const t of tasks)
390
475
  taskMap.set(t.taskId, t);
@@ -424,6 +509,8 @@ function buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, b
424
509
  const depTargetHandle = dependencyHandles.target;
425
510
  const hierSourceHandle = hierarchyHandles.source;
426
511
  const hierTargetHandle = hierarchyHandles.target;
512
+ const dependencyEdgeType = autoLayoutStrategy === "hierarchy" ? "step" : "smoothstep";
513
+ const hierarchyEdgeType = autoLayoutStrategy === "hierarchy" ? "hierarchyOrthogonal" : "smoothstep";
427
514
  const dependencyEdges = dependencies
428
515
  .filter((dep) => taskMap.has(dep.taskId) &&
429
516
  taskMap.has(dep.dependsOnTaskId) &&
@@ -441,7 +528,7 @@ function buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, b
441
528
  target: dep.taskId,
442
529
  sourceHandle: depSourceHandle,
443
530
  targetHandle: depTargetHandle,
444
- type: "smoothstep",
531
+ type: dependencyEdgeType,
445
532
  animated: false,
446
533
  style: {
447
534
  stroke: isSelected ? "var(--color-neutral-grey-100)" : strokeColor,
@@ -479,7 +566,7 @@ function buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, b
479
566
  target: task.taskId,
480
567
  sourceHandle: hierSourceHandle,
481
568
  targetHandle: hierTargetHandle,
482
- type: "smoothstep",
569
+ type: hierarchyEdgeType,
483
570
  style: {
484
571
  stroke: "var(--color-component-default)",
485
572
  strokeWidth: 1.5,
@@ -497,7 +584,7 @@ function buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, b
497
584
  const edges = [...dependencyEdges, ...hierarchyEdges];
498
585
  if (nodes.length === 0)
499
586
  return { nodes: [], edges: [] };
500
- return layoutGraph(nodes, edges, orientation, autoLayoutStrategy);
587
+ return layoutGraph(nodes, edges, orientation, autoLayoutStrategy, nodeSizeOverrides);
501
588
  }
502
589
  export function buildDependencyGraphLayout(args) {
503
590
  return buildGraph(args.tasks, args.dependencies, null, null, new Set(), args.orientation ?? "horizontal", false, args.autoLayoutStrategy ?? "hierarchy", () => undefined);
@@ -1020,7 +1107,9 @@ export function DependencyGraphView(props) {
1020
1107
  }, []);
1021
1108
  const hasVisibleNodes = initialNodes.length > 0;
1022
1109
  const handleAutoLayout = useCallback(() => {
1023
- const autoLayout = buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, blockedTaskIds, effectiveOrientation, showExecutionStateBadges, autoLayoutStrategy, onSelect, onAddDependentTaskFromNode, onAddChildTaskFromNode, onRemoveTask);
1110
+ const measuredNodeSizes = getMeasuredNodeSizeOverrides(reactFlowRef.current?.getNodes() ??
1111
+ nodesRef.current);
1112
+ const autoLayout = buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, blockedTaskIds, effectiveOrientation, showExecutionStateBadges, autoLayoutStrategy, onSelect, onAddDependentTaskFromNode, onAddChildTaskFromNode, onRemoveTask, measuredNodeSizes);
1024
1113
  beginFittingView();
1025
1114
  flushSync(() => {
1026
1115
  setNodes(autoLayout.nodes);
@@ -1094,7 +1183,8 @@ export function DependencyGraphView(props) {
1094
1183
  tasks,
1095
1184
  ]);
1096
1185
  const handleOrientationChange = useCallback((nextOrientation) => {
1097
- const autoLayout = buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, blockedTaskIds, nextOrientation, showExecutionStateBadges, autoLayoutStrategy, onSelect, onAddDependentTaskFromNode, onAddChildTaskFromNode, onRemoveTask);
1186
+ const measuredNodeSizes = getMeasuredNodeSizeOverrides(reactFlowRef.current?.getNodes() ?? nodesRef.current);
1187
+ const autoLayout = buildGraph(tasks, dependencies, selectedTaskId, selectedDependencyId, blockedTaskIds, nextOrientation, showExecutionStateBadges, autoLayoutStrategy, onSelect, onAddDependentTaskFromNode, onAddChildTaskFromNode, onRemoveTask, measuredNodeSizes);
1098
1188
  // Hide while we relayout-then-fit so the user can't see a paint where
1099
1189
  // the new node positions are still being viewed through the old
1100
1190
  // (orientation-stale) viewport.
@@ -1186,7 +1276,7 @@ export function DependencyGraphView(props) {
1186
1276
  return;
1187
1277
  }
1188
1278
  queueLayoutSave(nodesRef.current, viewport);
1189
- }, nodeTypes: nodeTypes, minZoom: 0.2, maxZoom: 2, proOptions: { hideAttribution: true }, nodesDraggable: canPersistLayout, nodesConnectable: allowDependencyConnect, isValidConnection: isValidConnection, elementsSelectable: true, children: [_jsxs(Controls, { showInteractive: false, showFitView: false, className: "border-border-default! rounded-lg! shadow-md!", children: [_jsx("button", { type: "button", className: "react-flow__controls-button react-flow__controls-fitview border-border-default text-neutral-grey-50 hover:bg-neutral-grey-5 hover:text-neutral-grey-100 flex h-6 w-6 items-center justify-center border-t bg-white transition-colors", title: "Fit view", "aria-label": "Fit view", onClick: (event) => {
1279
+ }, nodeTypes: nodeTypes, edgeTypes: edgeTypes, minZoom: 0.2, maxZoom: 2, proOptions: { hideAttribution: true }, nodesDraggable: canPersistLayout, nodesConnectable: allowDependencyConnect, isValidConnection: isValidConnection, elementsSelectable: true, children: [_jsxs(Controls, { showInteractive: false, showFitView: false, className: "border-border-default! rounded-lg! shadow-md!", children: [_jsx("button", { type: "button", className: "react-flow__controls-button react-flow__controls-fitview border-border-default text-neutral-grey-50 hover:bg-neutral-grey-5 hover:text-neutral-grey-100 flex h-6 w-6 items-center justify-center border-t bg-white transition-colors", title: "Fit view", "aria-label": "Fit view", onClick: (event) => {
1190
1280
  event.stopPropagation();
1191
1281
  reactFlowRef.current?.fitView({ padding: 0.2 });
1192
1282
  }, children: _jsx(SquareSquare, { className: "shrink-0", strokeWidth: 1.75, style: {