@vertesia/ui 1.0.0 → 1.1.0-dev.20260427.060440Z

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 (293) hide show
  1. package/lib/esm/core/components/ComboBox.js +23 -24
  2. package/lib/esm/core/components/ComboBox.js.map +1 -1
  3. package/lib/esm/core/components/FormItem.js +2 -2
  4. package/lib/esm/core/components/FormItem.js.map +1 -1
  5. package/lib/esm/core/components/SidePanel.js +1 -1
  6. package/lib/esm/core/components/SidePanel.js.map +1 -1
  7. package/lib/esm/core/components/shadcn/collaspible.js +3 -4
  8. package/lib/esm/core/components/shadcn/collaspible.js.map +1 -1
  9. package/lib/esm/core/components/shadcn/dropdown.js +37 -12
  10. package/lib/esm/core/components/shadcn/dropdown.js.map +1 -1
  11. package/lib/esm/core/components/shadcn/filters/comboBox/DateCombobox.js +6 -6
  12. package/lib/esm/core/components/shadcn/filters/comboBox/DateCombobox.js.map +1 -1
  13. package/lib/esm/core/components/shadcn/filters/filterBar.js +5 -3
  14. package/lib/esm/core/components/shadcn/filters/filterBar.js.map +1 -1
  15. package/lib/esm/core/components/shadcn/radioGroup.js +1 -2
  16. package/lib/esm/core/components/shadcn/radioGroup.js.map +1 -1
  17. package/lib/esm/core/components/shadcn/switch.js +0 -1
  18. package/lib/esm/core/components/shadcn/switch.js.map +1 -1
  19. package/lib/esm/core/components/shadcn/tabs.js +2 -2
  20. package/lib/esm/core/components/shadcn/tabs.js.map +1 -1
  21. package/lib/esm/core/components/shadcn/tooltip.js +17 -1
  22. package/lib/esm/core/components/shadcn/tooltip.js.map +1 -1
  23. package/lib/esm/core/hooks/PortalContainerProvider.js +9 -3
  24. package/lib/esm/core/hooks/PortalContainerProvider.js.map +1 -1
  25. package/lib/esm/env/index.js +5 -8
  26. package/lib/esm/env/index.js.map +1 -1
  27. package/lib/esm/features/agent/chat/AgentRightPanel.js +21 -11
  28. package/lib/esm/features/agent/chat/AgentRightPanel.js.map +1 -1
  29. package/lib/esm/features/agent/chat/AskUserWidget.js +2 -6
  30. package/lib/esm/features/agent/chat/AskUserWidget.js.map +1 -1
  31. package/lib/esm/features/agent/chat/DocumentPanel.js +8 -5
  32. package/lib/esm/features/agent/chat/DocumentPanel.js.map +1 -1
  33. package/lib/esm/features/agent/chat/DocumentTabBar.js +5 -13
  34. package/lib/esm/features/agent/chat/DocumentTabBar.js.map +1 -1
  35. package/lib/esm/features/agent/chat/ModernAgentConversation.js +57 -26
  36. package/lib/esm/features/agent/chat/ModernAgentConversation.js.map +1 -1
  37. package/lib/esm/features/agent/chat/ModernAgentOutput/AllMessagesMixed.js +20 -16
  38. package/lib/esm/features/agent/chat/ModernAgentOutput/AllMessagesMixed.js.map +1 -1
  39. package/lib/esm/features/agent/chat/ModernAgentOutput/Header.js +56 -45
  40. package/lib/esm/features/agent/chat/ModernAgentOutput/Header.js.map +1 -1
  41. package/lib/esm/features/agent/chat/ModernAgentOutput/MessageItem.js +1 -1
  42. package/lib/esm/features/agent/chat/ModernAgentOutput/MessageItem.js.map +1 -1
  43. package/lib/esm/features/agent/chat/SlidingThinkingIndicator.js +3 -9
  44. package/lib/esm/features/agent/chat/SlidingThinkingIndicator.js.map +1 -1
  45. package/lib/esm/features/agent/chat/hooks/useAgentStream.js +9 -5
  46. package/lib/esm/features/agent/chat/hooks/useAgentStream.js.map +1 -1
  47. package/lib/esm/features/agent/chat/hooks/useDocumentPanel.js +4 -0
  48. package/lib/esm/features/agent/chat/hooks/useDocumentPanel.js.map +1 -1
  49. package/lib/esm/features/facets/AgentRunnerFacetsNav.js +1 -1
  50. package/lib/esm/features/facets/AgentRunnerFacetsNav.js.map +1 -1
  51. package/lib/esm/features/facets/DocumentsFacetsNav.js +3 -2
  52. package/lib/esm/features/facets/DocumentsFacetsNav.js.map +1 -1
  53. package/lib/esm/features/facets/RunsFacetsNav.js +8 -1
  54. package/lib/esm/features/facets/RunsFacetsNav.js.map +1 -1
  55. package/lib/esm/features/facets/WorkflowExecutionsFacetsNav.js +1 -1
  56. package/lib/esm/features/facets/WorkflowExecutionsFacetsNav.js.map +1 -1
  57. package/lib/esm/features/facets/index.js +1 -0
  58. package/lib/esm/features/facets/index.js.map +1 -1
  59. package/lib/esm/features/facets/utils/VInteractionFacet.js +5 -5
  60. package/lib/esm/features/facets/utils/VInteractionFacet.js.map +1 -1
  61. package/lib/esm/features/index.js +1 -0
  62. package/lib/esm/features/index.js.map +1 -1
  63. package/lib/esm/features/oauth/OAuthProviderConnectButton.js +85 -0
  64. package/lib/esm/features/oauth/OAuthProviderConnectButton.js.map +1 -0
  65. package/lib/esm/features/oauth/RemoteMcpConnectionButton.js +119 -0
  66. package/lib/esm/features/oauth/RemoteMcpConnectionButton.js.map +1 -0
  67. package/lib/esm/features/oauth/index.js +4 -0
  68. package/lib/esm/features/oauth/index.js.map +1 -0
  69. package/lib/esm/features/oauth/useOAuthPopup.js +89 -0
  70. package/lib/esm/features/oauth/useOAuthPopup.js.map +1 -0
  71. package/lib/esm/features/store/collections/BrowseCollectionView.js.map +1 -1
  72. package/lib/esm/features/store/collections/EditCollectionView.js +9 -2
  73. package/lib/esm/features/store/collections/EditCollectionView.js.map +1 -1
  74. package/lib/esm/features/store/objects/components/ContentOverview.js +19 -7
  75. package/lib/esm/features/store/objects/components/ContentOverview.js.map +1 -1
  76. package/lib/esm/features/store/objects/components/useContentPanelHooks.js +35 -15
  77. package/lib/esm/features/store/objects/components/useContentPanelHooks.js.map +1 -1
  78. package/lib/esm/features/store/objects/selection/ObjectsActionContext.js +3 -3
  79. package/lib/esm/features/store/objects/selection/ObjectsActionContext.js.map +1 -1
  80. package/lib/esm/features/store/objects/selection/SelectionActions.js +4 -3
  81. package/lib/esm/features/store/objects/selection/SelectionActions.js.map +1 -1
  82. package/lib/esm/features/store/objects/selection/actions/ExportPropertiesAction.js +11 -3
  83. package/lib/esm/features/store/objects/selection/actions/ExportPropertiesAction.js.map +1 -1
  84. package/lib/esm/features/store/objects/upload/DocumentUploadModal.js +1 -5
  85. package/lib/esm/features/store/objects/upload/DocumentUploadModal.js.map +1 -1
  86. package/lib/esm/features/user/UserInfo.js +33 -10
  87. package/lib/esm/features/user/UserInfo.js.map +1 -1
  88. package/lib/esm/i18n/locales/ar.json +81 -98
  89. package/lib/esm/i18n/locales/de.json +44 -73
  90. package/lib/esm/i18n/locales/en.json +31 -61
  91. package/lib/esm/i18n/locales/es.json +55 -79
  92. package/lib/esm/i18n/locales/fr.json +55 -81
  93. package/lib/esm/i18n/locales/it.json +55 -79
  94. package/lib/esm/i18n/locales/ja.json +46 -75
  95. package/lib/esm/i18n/locales/ko.json +44 -73
  96. package/lib/esm/i18n/locales/pt.json +55 -79
  97. package/lib/esm/i18n/locales/ru.json +58 -81
  98. package/lib/esm/i18n/locales/tr.json +46 -75
  99. package/lib/esm/i18n/locales/zh-TW.json +46 -75
  100. package/lib/esm/i18n/locales/zh.json +46 -75
  101. package/lib/esm/session/UserSession.js +2 -4
  102. package/lib/esm/session/UserSession.js.map +1 -1
  103. package/lib/esm/session/UserSessionProvider.js +22 -17
  104. package/lib/esm/session/UserSessionProvider.js.map +1 -1
  105. package/lib/esm/session/auth/composable.js +20 -2
  106. package/lib/esm/session/auth/composable.js.map +1 -1
  107. package/lib/esm/session/auth/domainRouting.js +7 -0
  108. package/lib/esm/session/auth/domainRouting.js.map +1 -0
  109. package/lib/esm/shell/login/InviteAcceptModal.js +1 -0
  110. package/lib/esm/shell/login/InviteAcceptModal.js.map +1 -1
  111. package/lib/esm/widgets/form/Form.js +2 -2
  112. package/lib/esm/widgets/form/Form.js.map +1 -1
  113. package/lib/esm/widgets/markdown/MarkdownRenderer.js +2 -1
  114. package/lib/esm/widgets/markdown/MarkdownRenderer.js.map +1 -1
  115. package/lib/esm/widgets/markdown/preprocessMathDelimiters.js +226 -0
  116. package/lib/esm/widgets/markdown/preprocessMathDelimiters.js.map +1 -0
  117. package/lib/esm/widgets/monacoEditor/MonacoEditor.js +40 -5
  118. package/lib/esm/widgets/monacoEditor/MonacoEditor.js.map +1 -1
  119. package/lib/esm/widgets/monacoEditor/foldingProviders.js +132 -0
  120. package/lib/esm/widgets/monacoEditor/foldingProviders.js.map +1 -0
  121. package/lib/tsconfig.tsbuildinfo +1 -1
  122. package/lib/types/core/components/ComboBox.d.ts +12 -2
  123. package/lib/types/core/components/ComboBox.d.ts.map +1 -1
  124. package/lib/types/core/components/FormItem.d.ts +5 -2
  125. package/lib/types/core/components/FormItem.d.ts.map +1 -1
  126. package/lib/types/core/components/SidePanel.d.ts.map +1 -1
  127. package/lib/types/core/components/shadcn/badge.d.ts +2 -2
  128. package/lib/types/core/components/shadcn/collaspible.d.ts +3 -3
  129. package/lib/types/core/components/shadcn/collaspible.d.ts.map +1 -1
  130. package/lib/types/core/components/shadcn/dropdown.d.ts +11 -3
  131. package/lib/types/core/components/shadcn/dropdown.d.ts.map +1 -1
  132. package/lib/types/core/components/shadcn/filters/filterBar.d.ts +2 -1
  133. package/lib/types/core/components/shadcn/filters/filterBar.d.ts.map +1 -1
  134. package/lib/types/core/components/shadcn/input.d.ts +1 -1
  135. package/lib/types/core/components/shadcn/radioGroup.d.ts.map +1 -1
  136. package/lib/types/core/components/shadcn/switch.d.ts.map +1 -1
  137. package/lib/types/core/components/shadcn/tabs.d.ts +4 -2
  138. package/lib/types/core/components/shadcn/tabs.d.ts.map +1 -1
  139. package/lib/types/core/components/shadcn/text.d.ts +1 -1
  140. package/lib/types/core/components/shadcn/tooltip.d.ts +1 -1
  141. package/lib/types/core/components/shadcn/tooltip.d.ts.map +1 -1
  142. package/lib/types/core/hooks/PortalContainerProvider.d.ts +1 -0
  143. package/lib/types/core/hooks/PortalContainerProvider.d.ts.map +1 -1
  144. package/lib/types/env/index.d.ts +2 -2
  145. package/lib/types/env/index.d.ts.map +1 -1
  146. package/lib/types/features/agent/chat/AgentChart.d.ts +1 -1
  147. package/lib/types/features/agent/chat/AgentChart.d.ts.map +1 -1
  148. package/lib/types/features/agent/chat/AgentRightPanel.d.ts +7 -2
  149. package/lib/types/features/agent/chat/AgentRightPanel.d.ts.map +1 -1
  150. package/lib/types/features/agent/chat/DocumentPanel.d.ts +2 -2
  151. package/lib/types/features/agent/chat/DocumentPanel.d.ts.map +1 -1
  152. package/lib/types/features/agent/chat/DocumentTabBar.d.ts +1 -2
  153. package/lib/types/features/agent/chat/DocumentTabBar.d.ts.map +1 -1
  154. package/lib/types/features/agent/chat/ModernAgentConversation.d.ts +5 -3
  155. package/lib/types/features/agent/chat/ModernAgentConversation.d.ts.map +1 -1
  156. package/lib/types/features/agent/chat/ModernAgentOutput/AllMessagesMixed.d.ts +4 -2
  157. package/lib/types/features/agent/chat/ModernAgentOutput/AllMessagesMixed.d.ts.map +1 -1
  158. package/lib/types/features/agent/chat/ModernAgentOutput/Header.d.ts +4 -4
  159. package/lib/types/features/agent/chat/ModernAgentOutput/Header.d.ts.map +1 -1
  160. package/lib/types/features/agent/chat/ModernAgentOutput/MessageItem.d.ts.map +1 -1
  161. package/lib/types/features/agent/chat/VegaLiteChart.d.ts +1 -1
  162. package/lib/types/features/agent/chat/VegaLiteChart.d.ts.map +1 -1
  163. package/lib/types/features/agent/chat/hooks/useAgentStream.d.ts +4 -2
  164. package/lib/types/features/agent/chat/hooks/useAgentStream.d.ts.map +1 -1
  165. package/lib/types/features/agent/chat/hooks/useDocumentPanel.d.ts +1 -0
  166. package/lib/types/features/agent/chat/hooks/useDocumentPanel.d.ts.map +1 -1
  167. package/lib/types/features/facets/DocumentsFacetsNav.d.ts.map +1 -1
  168. package/lib/types/features/facets/RunsFacetsNav.d.ts.map +1 -1
  169. package/lib/types/features/facets/index.d.ts +1 -0
  170. package/lib/types/features/facets/index.d.ts.map +1 -1
  171. package/lib/types/features/index.d.ts +1 -0
  172. package/lib/types/features/index.d.ts.map +1 -1
  173. package/lib/types/features/oauth/OAuthProviderConnectButton.d.ts +11 -0
  174. package/lib/types/features/oauth/OAuthProviderConnectButton.d.ts.map +1 -0
  175. package/lib/types/features/oauth/RemoteMcpConnectionButton.d.ts +25 -0
  176. package/lib/types/features/oauth/RemoteMcpConnectionButton.d.ts.map +1 -0
  177. package/lib/types/features/oauth/index.d.ts +4 -0
  178. package/lib/types/features/oauth/index.d.ts.map +1 -0
  179. package/lib/types/features/oauth/useOAuthPopup.d.ts +12 -0
  180. package/lib/types/features/oauth/useOAuthPopup.d.ts.map +1 -0
  181. package/lib/types/features/store/collections/BrowseCollectionView.d.ts.map +1 -1
  182. package/lib/types/features/store/collections/EditCollectionView.d.ts.map +1 -1
  183. package/lib/types/features/store/objects/components/useContentPanelHooks.d.ts.map +1 -1
  184. package/lib/types/features/store/objects/selection/ObjectsActionContext.d.ts +3 -3
  185. package/lib/types/features/store/objects/selection/ObjectsActionContext.d.ts.map +1 -1
  186. package/lib/types/features/store/objects/selection/ObjectsActionSpec.d.ts +2 -1
  187. package/lib/types/features/store/objects/selection/ObjectsActionSpec.d.ts.map +1 -1
  188. package/lib/types/features/store/objects/selection/SelectionActions.d.ts +3 -3
  189. package/lib/types/features/store/objects/selection/SelectionActions.d.ts.map +1 -1
  190. package/lib/types/features/store/objects/selection/actions/ExportPropertiesAction.d.ts.map +1 -1
  191. package/lib/types/features/user/UserInfo.d.ts +2 -1
  192. package/lib/types/features/user/UserInfo.d.ts.map +1 -1
  193. package/lib/types/session/UserSession.d.ts.map +1 -1
  194. package/lib/types/session/UserSessionProvider.d.ts +0 -1
  195. package/lib/types/session/UserSessionProvider.d.ts.map +1 -1
  196. package/lib/types/session/auth/composable.d.ts +4 -0
  197. package/lib/types/session/auth/composable.d.ts.map +1 -1
  198. package/lib/types/session/auth/domainRouting.d.ts +8 -0
  199. package/lib/types/session/auth/domainRouting.d.ts.map +1 -0
  200. package/lib/types/shell/login/InviteAcceptModal.d.ts.map +1 -1
  201. package/lib/types/widgets/markdown/MarkdownRenderer.d.ts.map +1 -1
  202. package/lib/types/widgets/markdown/preprocessMathDelimiters.d.ts +24 -0
  203. package/lib/types/widgets/markdown/preprocessMathDelimiters.d.ts.map +1 -0
  204. package/lib/types/widgets/monacoEditor/MonacoEditor.d.ts +2 -1
  205. package/lib/types/widgets/monacoEditor/MonacoEditor.d.ts.map +1 -1
  206. package/lib/types/widgets/monacoEditor/foldingProviders.d.ts +2 -0
  207. package/lib/types/widgets/monacoEditor/foldingProviders.d.ts.map +1 -0
  208. package/lib/vertesia-ui-core.js +1 -1
  209. package/lib/vertesia-ui-core.js.map +1 -1
  210. package/lib/vertesia-ui-env.js +1 -1
  211. package/lib/vertesia-ui-env.js.map +1 -1
  212. package/lib/vertesia-ui-features.js +1 -1
  213. package/lib/vertesia-ui-features.js.map +1 -1
  214. package/lib/vertesia-ui-i18n.js +1 -1
  215. package/lib/vertesia-ui-i18n.js.map +1 -1
  216. package/lib/vertesia-ui-layout.js +1 -1
  217. package/lib/vertesia-ui-layout.js.map +1 -1
  218. package/lib/vertesia-ui-session.js +1 -1
  219. package/lib/vertesia-ui-session.js.map +1 -1
  220. package/lib/vertesia-ui-shell.js +1 -1
  221. package/lib/vertesia-ui-shell.js.map +1 -1
  222. package/lib/vertesia-ui-widgets.js +1 -1
  223. package/lib/vertesia-ui-widgets.js.map +1 -1
  224. package/package.json +15 -15
  225. package/src/core/components/ComboBox.tsx +66 -29
  226. package/src/core/components/FormItem.tsx +9 -6
  227. package/src/core/components/SidePanel.tsx +5 -3
  228. package/src/core/components/shadcn/collaspible.tsx +5 -7
  229. package/src/core/components/shadcn/dropdown.tsx +68 -13
  230. package/src/core/components/shadcn/filters/comboBox/DateCombobox.tsx +6 -6
  231. package/src/core/components/shadcn/filters/filterBar.tsx +5 -3
  232. package/src/core/components/shadcn/radioGroup.tsx +1 -3
  233. package/src/core/components/shadcn/switch.tsx +0 -2
  234. package/src/core/components/shadcn/tabs.tsx +15 -2
  235. package/src/core/components/shadcn/tooltip.tsx +20 -3
  236. package/src/core/hooks/PortalContainerProvider.tsx +11 -3
  237. package/src/env/index.ts +7 -10
  238. package/src/features/agent/chat/AgentRightPanel.tsx +43 -23
  239. package/src/features/agent/chat/DocumentPanel.tsx +21 -19
  240. package/src/features/agent/chat/DocumentTabBar.tsx +21 -32
  241. package/src/features/agent/chat/ModernAgentConversation.tsx +72 -27
  242. package/src/features/agent/chat/ModernAgentOutput/AllMessagesMixed.tsx +21 -9
  243. package/src/features/agent/chat/ModernAgentOutput/Header.tsx +136 -115
  244. package/src/features/agent/chat/ModernAgentOutput/MessageItem.tsx +0 -3
  245. package/src/features/agent/chat/hooks/useAgentStream.ts +13 -7
  246. package/src/features/agent/chat/hooks/useDocumentPanel.ts +8 -0
  247. package/src/features/facets/AgentRunnerFacetsNav.tsx +1 -1
  248. package/src/features/facets/DocumentsFacetsNav.tsx +3 -1
  249. package/src/features/facets/RunsFacetsNav.tsx +9 -1
  250. package/src/features/facets/WorkflowExecutionsFacetsNav.tsx +1 -1
  251. package/src/features/facets/index.ts +1 -0
  252. package/src/features/facets/utils/VInteractionFacet.tsx +12 -12
  253. package/src/features/index.ts +1 -0
  254. package/src/features/oauth/OAuthProviderConnectButton.tsx +125 -0
  255. package/src/features/oauth/RemoteMcpConnectionButton.tsx +274 -0
  256. package/src/features/oauth/index.ts +3 -0
  257. package/src/features/oauth/useOAuthPopup.ts +125 -0
  258. package/src/features/store/collections/BrowseCollectionView.tsx +3 -3
  259. package/src/features/store/collections/EditCollectionView.tsx +10 -1
  260. package/src/features/store/objects/components/ContentOverview.tsx +108 -87
  261. package/src/features/store/objects/components/useContentPanelHooks.ts +50 -15
  262. package/src/features/store/objects/selection/ObjectsActionContext.tsx +5 -5
  263. package/src/features/store/objects/selection/ObjectsActionSpec.ts +2 -1
  264. package/src/features/store/objects/selection/SelectionActions.tsx +6 -5
  265. package/src/features/store/objects/selection/actions/ExportPropertiesAction.tsx +12 -3
  266. package/src/features/user/UserInfo.tsx +82 -10
  267. package/src/i18n/locales/ar.json +81 -98
  268. package/src/i18n/locales/de.json +44 -73
  269. package/src/i18n/locales/en.json +31 -61
  270. package/src/i18n/locales/es.json +55 -79
  271. package/src/i18n/locales/fr.json +55 -81
  272. package/src/i18n/locales/it.json +55 -79
  273. package/src/i18n/locales/ja.json +46 -75
  274. package/src/i18n/locales/ko.json +44 -73
  275. package/src/i18n/locales/pt.json +55 -79
  276. package/src/i18n/locales/ru.json +58 -81
  277. package/src/i18n/locales/tr.json +46 -75
  278. package/src/i18n/locales/zh-TW.json +46 -75
  279. package/src/i18n/locales/zh.json +46 -75
  280. package/src/session/UserSession.ts +2 -5
  281. package/src/session/UserSessionProvider.tsx +23 -18
  282. package/src/session/auth/auth-flow.md +1 -1
  283. package/src/session/auth/composable.ts +21 -2
  284. package/src/session/auth/domainRouting.test.ts +26 -0
  285. package/src/session/auth/domainRouting.ts +13 -0
  286. package/src/shell/login/InviteAcceptModal.tsx +1 -0
  287. package/src/widgets/form/Form.tsx +2 -2
  288. package/src/widgets/markdown/MarkdownRenderer.tsx +2 -1
  289. package/src/widgets/markdown/markdown.css +12 -0
  290. package/src/widgets/markdown/preprocessMathDelimiters.test.ts +87 -0
  291. package/src/widgets/markdown/preprocessMathDelimiters.ts +229 -0
  292. package/src/widgets/monacoEditor/MonacoEditor.tsx +47 -4
  293. package/src/widgets/monacoEditor/foldingProviders.ts +122 -0
@@ -14,8 +14,8 @@ type TooltipContentProps = React.ComponentPropsWithoutRef<typeof TooltipPrimitiv
14
14
  side?: "top" | "right" | "bottom" | "left"
15
15
  };
16
16
 
17
- const TooltipContent: React.ForwardRefExoticComponent<TooltipContentProps & React.RefAttributes<React.ElementRef<typeof TooltipPrimitive.Content>>> = React.forwardRef<
18
- React.ElementRef<typeof TooltipPrimitive.Content>,
17
+ const TooltipContent: React.ForwardRefExoticComponent<TooltipContentProps & React.RefAttributes<React.ComponentRef<typeof TooltipPrimitive.Content>>> = React.forwardRef<
18
+ React.ComponentRef<typeof TooltipPrimitive.Content>,
19
19
  React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Content> & {
20
20
  side?: "top" | "right" | "bottom" | "left"
21
21
  }
@@ -49,9 +49,26 @@ interface TooltipPopoverProps {
49
49
  asChild?: boolean;
50
50
  }
51
51
  export function VTooltip({ description, children, size = 'sm', placement = 'top', className, asChild }: TooltipPopoverProps) {
52
+ const [open, setOpen] = React.useState(false);
53
+ const suppressRef = React.useRef(false);
54
+
55
+ React.useEffect(() => {
56
+ const suppress = () => {
57
+ setOpen(false);
58
+ suppressRef.current = true;
59
+ requestAnimationFrame(() => { suppressRef.current = false; });
60
+ };
61
+ window.addEventListener('blur', suppress);
62
+ document.addEventListener('visibilitychange', suppress);
63
+ return () => {
64
+ window.removeEventListener('blur', suppress);
65
+ document.removeEventListener('visibilitychange', suppress);
66
+ };
67
+ }, []);
68
+
52
69
  return (
53
70
  <TooltipProvider delayDuration={0}>
54
- <Tooltip>
71
+ <Tooltip open={open} onOpenChange={(v) => { if (!suppressRef.current) setOpen(v); }}>
55
72
  <TooltipTrigger className="cursor-pointer" asChild={asChild}>
56
73
  {children}
57
74
  </TooltipTrigger>
@@ -1,6 +1,6 @@
1
1
  import React from "react";
2
2
 
3
- const PortalContainerContext = React.createContext<HTMLElement | undefined>(undefined);
3
+ export const PortalContainerContext = React.createContext<HTMLElement | undefined>(undefined);
4
4
 
5
5
  function findOrCreatePortalContainer(root: ShadowRoot | Document, id = "plugin-portal-container") {
6
6
  // Determine the actual parent element to search and append to
@@ -26,10 +26,18 @@ export function PortalContainerProvider({
26
26
  children: React.ReactNode;
27
27
  id?: string;
28
28
  }) {
29
+ const inherited = React.useContext(PortalContainerContext);
29
30
  const ref = React.useRef<HTMLDivElement>(null);
30
- const [container, setContainer] = React.useState<HTMLElement | null | undefined>(undefined);
31
+ const [container, setContainer] = React.useState<HTMLElement | null | undefined>(
32
+ inherited || undefined
33
+ );
31
34
 
32
35
  React.useEffect(() => {
36
+ // If a parent already provides a portal container, inherit it
37
+ if (inherited) {
38
+ setContainer(inherited);
39
+ return;
40
+ }
33
41
  if (ref.current) {
34
42
  const root = ref.current.getRootNode();
35
43
  if (root instanceof ShadowRoot || root instanceof Document) {
@@ -39,7 +47,7 @@ export function PortalContainerProvider({
39
47
  setContainer(null);
40
48
  }
41
49
  }
42
- }, [id]);
50
+ }, [id, inherited]);
43
51
 
44
52
  // If container not discovered yet → render hidden marker only
45
53
  if (container === undefined) {
package/src/env/index.ts CHANGED
@@ -6,6 +6,7 @@ import { AuthTokenPayload } from "@vertesia/common";
6
6
  export interface EnvProps {
7
7
  name: string; // the app name
8
8
  version: string,
9
+ commitTimestamp?: string, // ISO timestamp of the deployed commit
9
10
  sdkVersion?: string, // the @vertesia/ui package version
10
11
  isLocalDev: boolean,
11
12
  isDocker: boolean,
@@ -56,6 +57,10 @@ export class VertesiaEnvironment implements Readonly<EnvProps> {
56
57
  return this.prop("version");
57
58
  }
58
59
 
60
+ get commitTimestamp() {
61
+ return this._props?.commitTimestamp;
62
+ }
63
+
59
64
  get sdkVersion() {
60
65
  return this._props?.sdkVersion;
61
66
  }
@@ -69,19 +74,11 @@ export class VertesiaEnvironment implements Readonly<EnvProps> {
69
74
  }
70
75
 
71
76
  get isProd() {
72
- return this.type === "production";
73
- }
74
-
75
- get isStable() {
76
- return this.type === "production" || this.type === "preview" || this.type === "disaster-recovery";
77
+ return this.type === "production" || this.type === "preview";
77
78
  }
78
79
 
79
80
  get isDev() {
80
- return !this.isStable;
81
- }
82
-
83
- get isPreview() {
84
- return this.type === "preview";
81
+ return !this.isProd;
85
82
  }
86
83
 
87
84
  get isLocalDev() {
@@ -30,7 +30,7 @@ export interface WorkstreamInfo {
30
30
  elapsed_ms: number;
31
31
  deadline_ms: number;
32
32
  remaining_ms: number;
33
- status: 'running' | 'canceling';
33
+ status: 'running' | 'canceling' | 'completed' | 'canceled';
34
34
  phase?: string;
35
35
  child_workflow_id?: string;
36
36
  child_workflow_run_id?: string;
@@ -124,7 +124,7 @@ interface WorkstreamsTabProps {
124
124
  runId?: string;
125
125
  }
126
126
 
127
- function WorkstreamsTab({ workstreams }: WorkstreamsTabProps) {
127
+ function WorkstreamsTab({ workstreams, messages: _messages }: WorkstreamsTabProps) {
128
128
  const { t } = useUITranslation();
129
129
  const { client } = useUserSession();
130
130
  const toast = useToast();
@@ -155,12 +155,21 @@ function WorkstreamsTab({ workstreams }: WorkstreamsTabProps) {
155
155
  return (
156
156
  <div className="p-3 space-y-2">
157
157
  {workstreams.map((ws) => {
158
+ const isActive = ws.status === 'running' || ws.status === 'canceling';
158
159
  const elapsed = Math.round(ws.elapsed_ms / 1000);
159
160
  const remaining = Math.round(ws.remaining_ms / 1000);
160
161
  const progress = ws.deadline_ms > 0
161
162
  ? Math.min(100, Math.round((ws.elapsed_ms / ws.deadline_ms) * 100))
162
163
  : 0;
163
164
 
165
+ const statusBadge = ws.status === 'running'
166
+ ? <Badge variant="info">{ws.phase || 'running'}</Badge>
167
+ : ws.status === 'canceling'
168
+ ? <Badge variant="attention">canceling</Badge>
169
+ : ws.status === 'completed'
170
+ ? <Badge variant="done">{t('agent.completed')}</Badge>
171
+ : <Badge variant="destructive">{t('agent.canceled')}</Badge>;
172
+
164
173
  return (
165
174
  <div
166
175
  key={ws.launch_id}
@@ -170,21 +179,23 @@ function WorkstreamsTab({ workstreams }: WorkstreamsTabProps) {
170
179
  <span className="text-sm font-medium truncate">
171
180
  {ws.workstream_id}
172
181
  </span>
173
- <Badge variant={ws.status === 'running' ? 'info' : 'attention'}>
174
- {ws.status === 'running' ? (ws.phase || 'running') : 'canceling'}
175
- </Badge>
176
- </div>
177
- {/* Progress bar */}
178
- <div className="w-full h-1.5 bg-muted rounded-full overflow-hidden">
179
- <div
180
- className="h-full bg-info rounded-full transition-all duration-500"
181
- style={{ width: `${progress}%` }}
182
- />
183
- </div>
184
- <div className="flex justify-between text-xs text-muted">
185
- <span>{t('agent.elapsed', { seconds: elapsed })}</span>
186
- <span>{t('agent.remaining', { seconds: remaining })}</span>
182
+ {statusBadge}
187
183
  </div>
184
+ {/* Progress bar — only for active workstreams */}
185
+ {isActive && (
186
+ <>
187
+ <div className="w-full h-1.5 bg-muted rounded-full overflow-hidden">
188
+ <div
189
+ className="h-full bg-info rounded-full transition-all duration-500"
190
+ style={{ width: `${progress}%` }}
191
+ />
192
+ </div>
193
+ <div className="flex justify-between text-xs text-muted">
194
+ <span>{t('agent.elapsed', { seconds: elapsed })}</span>
195
+ <span>{t('agent.remaining', { seconds: remaining })}</span>
196
+ </div>
197
+ </>
198
+ )}
188
199
  {/* Actions */}
189
200
  {ws.child_workflow_run_id && (
190
201
  <div className="flex gap-1 pt-1 border-t border-muted">
@@ -244,6 +255,7 @@ export interface AgentRightPanelProps {
244
255
  activeDocumentId?: string | null;
245
256
  onSelectDocument?: (id: string) => void;
246
257
  onCloseDocument?: (id: string) => void;
258
+ onUpdateDocumentTitle?: (id: string, title: string) => void;
247
259
  docRefreshKey?: number;
248
260
  runId?: string;
249
261
 
@@ -259,6 +271,10 @@ export interface AgentRightPanelProps {
259
271
  onClose: () => void;
260
272
  /** Which tab to auto-activate when panel opens */
261
273
  defaultTab?: RightPanelTab;
274
+ /** Controlled active tab (overrides internal state when provided) */
275
+ activeTab?: RightPanelTab;
276
+ /** Callback when the active tab changes */
277
+ onTabChange?: (tab: RightPanelTab) => void;
262
278
  }
263
279
 
264
280
  function AgentRightPanelComponent({
@@ -280,6 +296,7 @@ function AgentRightPanelComponent({
280
296
  activeDocumentId,
281
297
  onSelectDocument,
282
298
  onCloseDocument,
299
+ onUpdateDocumentTitle,
283
300
  docRefreshKey = 0,
284
301
  runId,
285
302
 
@@ -299,9 +316,16 @@ function AgentRightPanelComponent({
299
316
  // Panel
300
317
  onClose,
301
318
  defaultTab,
319
+ activeTab: activeTabProp,
320
+ onTabChange,
302
321
  }: AgentRightPanelProps) {
303
322
  const { t } = useUITranslation();
304
- const [activeTab, setActiveTab] = useState<RightPanelTab>(defaultTab || 'plan');
323
+ const [internalActiveTab, setInternalActiveTab] = useState<RightPanelTab>(defaultTab || 'plan');
324
+ const activeTab = activeTabProp ?? internalActiveTab;
325
+ const handleTabChange = (name: string) => {
326
+ setInternalActiveTab(name as RightPanelTab);
327
+ onTabChange?.(name as RightPanelTab);
328
+ };
305
329
 
306
330
  // Determine which tabs have content (for badges/indicators)
307
331
  const hasWorkstreams = !hideWorkstreams && activeWorkstreams.length > 0;
@@ -309,10 +333,6 @@ function AgentRightPanelComponent({
309
333
  const hasUploads = processingFiles ? processingFiles.size > 0 : false;
310
334
  const hasPlan = showPlan && plan;
311
335
 
312
- const handleCloseDocPanel = useCallback(() => {
313
- setActiveTab('plan');
314
- }, []);
315
-
316
336
  const conversationTab: TabDefinition = {
317
337
  name: 'conversation',
318
338
  label: 'Conversation',
@@ -360,11 +380,11 @@ function AgentRightPanelComponent({
360
380
  content: openDocuments.length > 0 && onSelectDocument && onCloseDocument ? (
361
381
  <DocumentPanel
362
382
  isOpen={true}
363
- onClose={handleCloseDocPanel}
364
383
  documents={openDocuments}
365
384
  activeDocumentId={activeDocumentId ?? null}
366
385
  onSelectDocument={onSelectDocument}
367
386
  onCloseDocument={onCloseDocument}
387
+ onUpdateDocumentTitle={onUpdateDocumentTitle}
368
388
  refreshKey={docRefreshKey}
369
389
  runId={runId}
370
390
  />
@@ -402,7 +422,7 @@ function AgentRightPanelComponent({
402
422
  <Tabs
403
423
  tabs={tabs}
404
424
  current={activeTab}
405
- onTabChange={(name) => setActiveTab(name as RightPanelTab)}
425
+ onTabChange={handleTabChange}
406
426
  fullHeight
407
427
  className="px-0"
408
428
  >
@@ -1,7 +1,7 @@
1
1
  import React, { useCallback, useEffect, useState } from 'react';
2
2
  import { ExternalLinkIcon, FileTextIcon, Loader2Icon, X } from 'lucide-react';
3
3
  import { useUserSession } from '@vertesia/ui/session';
4
- import { Button } from '@vertesia/ui/core';
4
+ import { Button, VTooltip } from '@vertesia/ui/core';
5
5
  import { NavLink } from '@vertesia/ui/router';
6
6
  import { MarkdownRenderer } from '@vertesia/ui/widgets';
7
7
  import { useUITranslation } from '../../../i18n/index.js';
@@ -10,22 +10,22 @@ import type { OpenDocument } from './types/document.js';
10
10
 
11
11
  interface DocumentPanelProps {
12
12
  isOpen: boolean;
13
- onClose: () => void;
14
13
  documents: OpenDocument[];
15
14
  activeDocumentId: string | null;
16
15
  onSelectDocument: (id: string) => void;
17
16
  onCloseDocument: (id: string) => void;
17
+ onUpdateDocumentTitle?: (id: string, title: string) => void;
18
18
  refreshKey: number;
19
19
  runId?: string;
20
20
  }
21
21
 
22
22
  function DocumentPanelComponent({
23
23
  isOpen,
24
- onClose,
25
24
  documents,
26
25
  activeDocumentId,
27
26
  onSelectDocument,
28
27
  onCloseDocument,
28
+ onUpdateDocumentTitle,
29
29
  refreshKey,
30
30
  runId,
31
31
  }: DocumentPanelProps) {
@@ -45,7 +45,9 @@ function DocumentPanelComponent({
45
45
  client.store.objects.retrieve(docId),
46
46
  ]);
47
47
  setContent(textResult.text);
48
- setDocName(obj.name);
48
+ const name = obj.name;
49
+ setDocName(name);
50
+ if (name) onUpdateDocumentTitle?.(docId, name);
49
51
  } catch (err: unknown) {
50
52
  const message = err instanceof Error ? err.message : t('agent.failedToLoadDocument');
51
53
  setError(message);
@@ -53,7 +55,7 @@ function DocumentPanelComponent({
53
55
  } finally {
54
56
  setIsLoading(false);
55
57
  }
56
- }, [client]);
58
+ }, [client, onUpdateDocumentTitle]);
57
59
 
58
60
  // Fetch content when active document changes or refreshKey bumps
59
61
  useEffect(() => {
@@ -77,33 +79,33 @@ function DocumentPanelComponent({
77
79
  </h3>
78
80
  </div>
79
81
  <div className="flex items-center gap-1">
82
+ <DocumentTabBar
83
+ documents={documents}
84
+ activeId={activeDocumentId}
85
+ onSelect={onSelectDocument}
86
+ />
80
87
  {activeDocumentId && (
81
88
  <NavLink
82
89
  href={`/store/objects/${activeDocumentId}#overview`}
83
90
  topLevelNav
84
91
  className="inline-flex items-center justify-center rounded-md text-sm font-medium h-8 w-8 hover:bg-muted/20 text-muted hover:text-foreground"
85
92
  >
86
- <ExternalLinkIcon className="size-4" />
87
- <span className="sr-only">{t('agent.openDocument')}</span>
93
+ <VTooltip description={t('agent.openDocument')} placement="top" size='xs'>
94
+ <ExternalLinkIcon className="size-4" />
95
+ </VTooltip>
88
96
  </NavLink>
89
97
  )}
90
- <Button variant="ghost" size="sm" onClick={onClose}>
98
+ <Button
99
+ variant="ghost"
100
+ size="sm"
101
+ onClick={() => activeDocumentId && onCloseDocument(activeDocumentId)}
102
+ title={t('agent.close')}
103
+ >
91
104
  <X className="size-4" />
92
- <span className="sr-only">{t('agent.close')}</span>
93
105
  </Button>
94
106
  </div>
95
107
  </div>
96
108
 
97
- {/* Tab bar */}
98
- <div className="shrink-0">
99
- <DocumentTabBar
100
- documents={documents}
101
- activeId={activeDocumentId}
102
- onSelect={onSelectDocument}
103
- onClose={onCloseDocument}
104
- />
105
- </div>
106
-
107
109
  {/* Content area */}
108
110
  <div className="flex-1 overflow-y-auto px-4 py-4">
109
111
  {isLoading ? (
@@ -1,49 +1,38 @@
1
- import { XIcon } from 'lucide-react';
2
- import { cn } from '@vertesia/ui/core';
1
+ import { ChevronDownIcon } from 'lucide-react';
2
+ import { Button, Dropdown, MenuItem } from '@vertesia/ui/core';
3
3
  import type { OpenDocument } from './types/document.js';
4
4
 
5
5
  interface DocumentTabBarProps {
6
6
  documents: OpenDocument[];
7
7
  activeId: string | null;
8
8
  onSelect: (id: string) => void;
9
- onClose: (id: string) => void;
10
9
  }
11
10
 
12
- export function DocumentTabBar({ documents, activeId, onSelect, onClose }: DocumentTabBarProps) {
11
+ export function DocumentTabBar({ documents, activeId, onSelect }: DocumentTabBarProps) {
13
12
  if (documents.length === 0) return null;
14
13
 
15
14
  return (
16
- <div className="flex items-center gap-1 overflow-x-auto px-2 py-1.5 border-b border-gray-200 dark:border-gray-700 bg-gray-50 dark:bg-gray-800/50">
17
- {documents.map((doc) => {
18
- const isActive = doc.id === activeId;
19
- return (
20
- <button
15
+ <div className="flex items-center gap-1 px-2 py-1.5">
16
+ <Dropdown
17
+ align="right"
18
+ trigger={
19
+ <Button variant="ghost" size="xs"
20
+ title='All opened documents'
21
+ className="flex items-center gap-1.5 max-w-[220px] text-xs h-7 px-2">
22
+ <ChevronDownIcon className="size-3 shrink-0" />
23
+ </Button>
24
+ }
25
+ >
26
+ {documents.map((doc) => (
27
+ <MenuItem
21
28
  key={doc.id}
22
29
  onClick={() => onSelect(doc.id)}
23
- className={cn(
24
- 'group flex items-center gap-1.5 px-3 py-1.5 text-xs rounded-md transition-colors whitespace-nowrap max-w-[200px]',
25
- isActive
26
- ? 'bg-white dark:bg-gray-700 text-gray-900 dark:text-gray-100 shadow-sm'
27
- : 'text-gray-500 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-700/50'
28
- )}
30
+ className={doc.id === activeId ? 'font-medium' : ''}
29
31
  >
30
- <span className="truncate">{doc.title}</span>
31
- <span
32
- role="button"
33
- onClick={(e) => {
34
- e.stopPropagation();
35
- onClose(doc.id);
36
- }}
37
- className={cn(
38
- 'shrink-0 p-0.5 rounded hover:bg-gray-200 dark:hover:bg-gray-600',
39
- isActive ? 'opacity-60 hover:opacity-100' : 'opacity-0 group-hover:opacity-60 hover:!opacity-100'
40
- )}
41
- >
42
- <XIcon className="size-3" />
43
- </span>
44
- </button>
45
- );
46
- })}
32
+ <span className="truncate max-w-[200px]">{doc.title}</span>
33
+ </MenuItem>
34
+ ))}
35
+ </Dropdown>
47
36
  </div>
48
37
  );
49
38
  }