@vertesia/ui 0.59.0 → 0.61.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (661) hide show
  1. package/lib/esm/core/components/FormItem.js +9 -0
  2. package/lib/esm/core/components/FormItem.js.map +1 -0
  3. package/lib/esm/core/components/InputList.js +4 -3
  4. package/lib/esm/core/components/InputList.js.map +1 -1
  5. package/lib/esm/core/components/index.js +3 -3
  6. package/lib/esm/core/components/index.js.map +1 -1
  7. package/lib/esm/core/components/shadcn/button.js +37 -7
  8. package/lib/esm/core/components/shadcn/button.js.map +1 -1
  9. package/lib/esm/core/components/shadcn/dialog.js +3 -3
  10. package/lib/esm/core/components/shadcn/dialog.js.map +1 -1
  11. package/lib/esm/core/components/shadcn/filters/DynamicLabel.js +38 -0
  12. package/lib/esm/core/components/shadcn/filters/DynamicLabel.js.map +1 -0
  13. package/lib/esm/core/components/shadcn/filters/comboBox.js +24 -26
  14. package/lib/esm/core/components/shadcn/filters/comboBox.js.map +1 -1
  15. package/lib/esm/core/components/shadcn/filters/dateFilter.js +12 -12
  16. package/lib/esm/core/components/shadcn/filters/dateFilter.js.map +1 -1
  17. package/lib/esm/core/components/shadcn/filters/filterBar.js +49 -36
  18. package/lib/esm/core/components/shadcn/filters/filterBar.js.map +1 -1
  19. package/lib/esm/core/components/shadcn/filters/filters.js +31 -23
  20. package/lib/esm/core/components/shadcn/filters/filters.js.map +1 -1
  21. package/lib/esm/core/components/shadcn/filters/selectFilter.js +33 -24
  22. package/lib/esm/core/components/shadcn/filters/selectFilter.js.map +1 -1
  23. package/lib/esm/core/components/shadcn/filters/textFilter.js +2 -2
  24. package/lib/esm/core/components/shadcn/filters/textFilter.js.map +1 -1
  25. package/lib/esm/core/components/shadcn/filters/types.js.map +1 -1
  26. package/lib/esm/core/components/shadcn/input.js +4 -4
  27. package/lib/esm/core/components/shadcn/input.js.map +1 -1
  28. package/lib/esm/core/components/shadcn/selectBox.js +72 -6
  29. package/lib/esm/core/components/shadcn/selectBox.js.map +1 -1
  30. package/lib/esm/core/components/styles.js +1 -1
  31. package/lib/esm/core/components/styles.js.map +1 -1
  32. package/lib/esm/core/components/table/index.js +3 -0
  33. package/lib/esm/core/components/table/index.js.map +1 -1
  34. package/lib/esm/core/index.js +2 -1
  35. package/lib/esm/core/index.js.map +1 -1
  36. package/lib/esm/core/utils/cn.js +6 -0
  37. package/lib/esm/core/utils/cn.js.map +1 -0
  38. package/lib/esm/core/utils/index.js +2 -0
  39. package/lib/esm/core/utils/index.js.map +1 -0
  40. package/lib/esm/features/agent/PayloadBuilder.js +174 -0
  41. package/lib/esm/features/agent/PayloadBuilder.js.map +1 -0
  42. package/lib/esm/features/agent/chat/AnimatedThinkingDots.js +207 -0
  43. package/lib/esm/features/agent/chat/AnimatedThinkingDots.js.map +1 -0
  44. package/lib/esm/features/agent/chat/JumpingDots.js +6 -0
  45. package/lib/esm/features/agent/chat/JumpingDots.js.map +1 -0
  46. package/lib/esm/features/agent/chat/ModernAgentConversation.js +409 -0
  47. package/lib/esm/features/agent/chat/ModernAgentConversation.js.map +1 -0
  48. package/lib/esm/features/agent/chat/ModernAgentOutput/AllMessagesMixed.js +129 -0
  49. package/lib/esm/features/agent/chat/ModernAgentOutput/AllMessagesMixed.js.map +1 -0
  50. package/lib/esm/features/agent/chat/ModernAgentOutput/Header.js +66 -0
  51. package/lib/esm/features/agent/chat/ModernAgentOutput/Header.js.map +1 -0
  52. package/lib/esm/features/agent/chat/ModernAgentOutput/InlineSlideInPanel.js +29 -0
  53. package/lib/esm/features/agent/chat/ModernAgentOutput/InlineSlideInPanel.js.map +1 -0
  54. package/lib/esm/features/agent/chat/ModernAgentOutput/InlineSlidingPlanPanel.js +97 -0
  55. package/lib/esm/features/agent/chat/ModernAgentOutput/InlineSlidingPlanPanel.js.map +1 -0
  56. package/lib/esm/features/agent/chat/ModernAgentOutput/MessageInput.js +46 -0
  57. package/lib/esm/features/agent/chat/ModernAgentOutput/MessageInput.js.map +1 -0
  58. package/lib/esm/features/agent/chat/ModernAgentOutput/MessageItem.js +352 -0
  59. package/lib/esm/features/agent/chat/ModernAgentOutput/MessageItem.js.map +1 -0
  60. package/lib/esm/features/agent/chat/ModernAgentOutput/MessagesContainer.js +20 -0
  61. package/lib/esm/features/agent/chat/ModernAgentOutput/MessagesContainer.js.map +1 -0
  62. package/lib/esm/features/agent/chat/ModernAgentOutput/PlanPanel.js +62 -0
  63. package/lib/esm/features/agent/chat/ModernAgentOutput/PlanPanel.js.map +1 -0
  64. package/lib/esm/features/agent/chat/ModernAgentOutput/SlideInPanel.js +23 -0
  65. package/lib/esm/features/agent/chat/ModernAgentOutput/SlideInPanel.js.map +1 -0
  66. package/lib/esm/features/agent/chat/ModernAgentOutput/SlidingMessages.js +51 -0
  67. package/lib/esm/features/agent/chat/ModernAgentOutput/SlidingMessages.js.map +1 -0
  68. package/lib/esm/features/agent/chat/ModernAgentOutput/SlidingPlanPanel.js +82 -0
  69. package/lib/esm/features/agent/chat/ModernAgentOutput/SlidingPlanPanel.js.map +1 -0
  70. package/lib/esm/features/agent/chat/ModernAgentOutput/StackedMessages.js +13 -0
  71. package/lib/esm/features/agent/chat/ModernAgentOutput/StackedMessages.js.map +1 -0
  72. package/lib/esm/features/agent/chat/ModernAgentOutput/WorkstreamTabs.js +105 -0
  73. package/lib/esm/features/agent/chat/ModernAgentOutput/WorkstreamTabs.js.map +1 -0
  74. package/lib/esm/features/agent/chat/ModernAgentOutput/utils.js +154 -0
  75. package/lib/esm/features/agent/chat/ModernAgentOutput/utils.js.map +1 -0
  76. package/lib/esm/features/agent/chat/SlidingThinkingIndicator.js +266 -0
  77. package/lib/esm/features/agent/chat/SlidingThinkingIndicator.js.map +1 -0
  78. package/lib/esm/features/agent/chat/WaitingMessages.js +60 -0
  79. package/lib/esm/features/agent/chat/WaitingMessages.js.map +1 -0
  80. package/lib/esm/features/agent/chat/index.js +5 -0
  81. package/lib/esm/features/agent/chat/index.js.map +1 -0
  82. package/lib/esm/features/agent/index.js +3 -0
  83. package/lib/esm/features/agent/index.js.map +1 -0
  84. package/lib/esm/features/errors/PanelErrorBoundary.js +11 -0
  85. package/lib/esm/features/errors/PanelErrorBoundary.js.map +1 -0
  86. package/lib/esm/features/errors/RowErrorBoundary.js +9 -0
  87. package/lib/esm/features/errors/RowErrorBoundary.js.map +1 -0
  88. package/lib/esm/features/errors/VertesiaErrorBoundary.js +15 -0
  89. package/lib/esm/features/errors/VertesiaErrorBoundary.js.map +1 -0
  90. package/lib/esm/features/errors/WidgetErrorBoundary.js +11 -0
  91. package/lib/esm/features/errors/WidgetErrorBoundary.js.map +1 -0
  92. package/lib/esm/features/errors/index.js +5 -0
  93. package/lib/esm/features/errors/index.js.map +1 -0
  94. package/lib/esm/features/facets/EnvironmentFacet.js +39 -0
  95. package/lib/esm/features/facets/EnvironmentFacet.js.map +1 -0
  96. package/lib/esm/features/facets/FacetsNav.js +8 -0
  97. package/lib/esm/features/facets/FacetsNav.js.map +1 -0
  98. package/lib/esm/features/facets/InteractionFacet.js +39 -0
  99. package/lib/esm/features/facets/InteractionFacet.js.map +1 -0
  100. package/lib/esm/features/facets/StringFacet.js +12 -0
  101. package/lib/esm/features/facets/StringFacet.js.map +1 -0
  102. package/lib/esm/features/facets/StringListFacet.js +11 -0
  103. package/lib/esm/features/facets/StringListFacet.js.map +1 -0
  104. package/lib/esm/features/facets/TypeFacet.js +42 -0
  105. package/lib/esm/features/facets/TypeFacet.js.map +1 -0
  106. package/lib/esm/features/facets/TypeOptions.js +19 -0
  107. package/lib/esm/features/facets/TypeOptions.js.map +1 -0
  108. package/lib/esm/features/facets/UserFacet.js +33 -0
  109. package/lib/esm/features/facets/UserFacet.js.map +1 -0
  110. package/lib/esm/features/facets/VFacetsNav.js +114 -0
  111. package/lib/esm/features/facets/VFacetsNav.js.map +1 -0
  112. package/lib/esm/features/facets/VStringFacet.js +17 -0
  113. package/lib/esm/features/facets/VStringFacet.js.map +1 -0
  114. package/lib/esm/features/facets/VTypeFacet.js +56 -0
  115. package/lib/esm/features/facets/VTypeFacet.js.map +1 -0
  116. package/lib/esm/features/facets/VUserFacet.js +31 -0
  117. package/lib/esm/features/facets/VUserFacet.js.map +1 -0
  118. package/lib/esm/features/facets/index.js +12 -0
  119. package/lib/esm/features/facets/index.js.map +1 -0
  120. package/lib/esm/features/facets/utils.js +7 -0
  121. package/lib/esm/features/facets/utils.js.map +1 -0
  122. package/lib/esm/features/index.js +9 -1
  123. package/lib/esm/features/index.js.map +1 -1
  124. package/lib/esm/features/layout/GenericPageNavHeader.js +11 -0
  125. package/lib/esm/features/layout/GenericPageNavHeader.js.map +1 -0
  126. package/lib/esm/features/layout/NotFoundView.js +5 -0
  127. package/lib/esm/features/layout/NotFoundView.js.map +1 -0
  128. package/lib/esm/features/layout/index.js +3 -0
  129. package/lib/esm/features/layout/index.js.map +1 -0
  130. package/lib/esm/features/magic-pdf/DownloadPopover.js +13 -0
  131. package/lib/esm/features/magic-pdf/DownloadPopover.js.map +1 -0
  132. package/lib/esm/features/magic-pdf/MagicPdfView.js +44 -0
  133. package/lib/esm/features/magic-pdf/MagicPdfView.js.map +1 -0
  134. package/lib/esm/features/magic-pdf/PageSlider.js +57 -0
  135. package/lib/esm/features/magic-pdf/PageSlider.js.map +1 -0
  136. package/lib/esm/features/magic-pdf/PdfPageProvider.js +133 -0
  137. package/lib/esm/features/magic-pdf/PdfPageProvider.js.map +1 -0
  138. package/lib/esm/features/magic-pdf/TextPageView.js +45 -0
  139. package/lib/esm/features/magic-pdf/TextPageView.js.map +1 -0
  140. package/lib/esm/features/magic-pdf/index.js +2 -0
  141. package/lib/esm/features/magic-pdf/index.js.map +1 -0
  142. package/lib/esm/features/magic-pdf/types.js +2 -0
  143. package/lib/esm/features/magic-pdf/types.js.map +1 -0
  144. package/lib/esm/features/magic-pdf/useResizeOnDrag.js +34 -0
  145. package/lib/esm/features/magic-pdf/useResizeOnDrag.js.map +1 -0
  146. package/lib/esm/features/store/collections/BrowseCollectionView.js +37 -0
  147. package/lib/esm/features/store/collections/BrowseCollectionView.js.map +1 -0
  148. package/lib/esm/features/store/collections/CollectionView.js +53 -0
  149. package/lib/esm/features/store/collections/CollectionView.js.map +1 -0
  150. package/lib/esm/features/store/collections/CollectionsTable.js +60 -0
  151. package/lib/esm/features/store/collections/CollectionsTable.js.map +1 -0
  152. package/lib/esm/features/store/collections/CollectionsView.js +94 -0
  153. package/lib/esm/features/store/collections/CollectionsView.js.map +1 -0
  154. package/lib/esm/features/store/collections/EditCollectionView.js +161 -0
  155. package/lib/esm/features/store/collections/EditCollectionView.js.map +1 -0
  156. package/lib/esm/features/store/collections/index.js +6 -0
  157. package/lib/esm/features/store/collections/index.js.map +1 -0
  158. package/lib/esm/features/store/index.js +4 -0
  159. package/lib/esm/features/store/index.js.map +1 -0
  160. package/lib/esm/features/store/objects/DocumentPreviewPanel.js +150 -0
  161. package/lib/esm/features/store/objects/DocumentPreviewPanel.js.map +1 -0
  162. package/lib/esm/features/store/objects/DocumentSearchResults.js +123 -0
  163. package/lib/esm/features/store/objects/DocumentSearchResults.js.map +1 -0
  164. package/lib/esm/features/store/objects/DocumentSelectionProvider.js +81 -0
  165. package/lib/esm/features/store/objects/DocumentSelectionProvider.js.map +1 -0
  166. package/lib/esm/features/store/objects/DocumentTable.js +278 -0
  167. package/lib/esm/features/store/objects/DocumentTable.js.map +1 -0
  168. package/lib/esm/features/store/objects/ExportPropertiesModal.js +31 -0
  169. package/lib/esm/features/store/objects/ExportPropertiesModal.js.map +1 -0
  170. package/lib/esm/features/store/objects/components/ContentDispositionButton.js +31 -0
  171. package/lib/esm/features/store/objects/components/ContentDispositionButton.js.map +1 -0
  172. package/lib/esm/features/store/objects/components/ContentOverview.js +195 -0
  173. package/lib/esm/features/store/objects/components/ContentOverview.js.map +1 -0
  174. package/lib/esm/features/store/objects/components/DocumentIcon.js +28 -0
  175. package/lib/esm/features/store/objects/components/DocumentIcon.js.map +1 -0
  176. package/lib/esm/features/store/objects/components/DocumentInput.js +52 -0
  177. package/lib/esm/features/store/objects/components/DocumentInput.js.map +1 -0
  178. package/lib/esm/features/store/objects/components/PropertiesEditorModal.js +169 -0
  179. package/lib/esm/features/store/objects/components/PropertiesEditorModal.js.map +1 -0
  180. package/lib/esm/features/store/objects/components/SaveVersionConfirmModal.js +45 -0
  181. package/lib/esm/features/store/objects/components/SaveVersionConfirmModal.js.map +1 -0
  182. package/lib/esm/features/store/objects/components/SelectDocument.js +39 -0
  183. package/lib/esm/features/store/objects/components/SelectDocument.js.map +1 -0
  184. package/lib/esm/features/store/objects/components/SelectDocumentModal.js +7 -0
  185. package/lib/esm/features/store/objects/components/SelectDocumentModal.js.map +1 -0
  186. package/lib/esm/features/store/objects/components/VectorSearchWidget.js +85 -0
  187. package/lib/esm/features/store/objects/components/VectorSearchWidget.js.map +1 -0
  188. package/lib/esm/features/store/objects/components/index.js +10 -0
  189. package/lib/esm/features/store/objects/components/index.js.map +1 -0
  190. package/lib/esm/features/store/objects/components/useDownloadObject.js +21 -0
  191. package/lib/esm/features/store/objects/components/useDownloadObject.js.map +1 -0
  192. package/lib/esm/features/store/objects/index.js +11 -0
  193. package/lib/esm/features/store/objects/index.js.map +1 -0
  194. package/lib/esm/features/store/objects/layout/DocumentTableColumn.js +74 -0
  195. package/lib/esm/features/store/objects/layout/DocumentTableColumn.js.map +1 -0
  196. package/lib/esm/features/store/objects/layout/documentLayout.js +16 -0
  197. package/lib/esm/features/store/objects/layout/documentLayout.js.map +1 -0
  198. package/lib/esm/features/store/objects/layout/index.js +3 -0
  199. package/lib/esm/features/store/objects/layout/index.js.map +1 -0
  200. package/lib/esm/features/store/objects/layout/renderers.js +128 -0
  201. package/lib/esm/features/store/objects/layout/renderers.js.map +1 -0
  202. package/lib/esm/features/store/objects/search/DocumentSearchContext.js +150 -0
  203. package/lib/esm/features/store/objects/search/DocumentSearchContext.js.map +1 -0
  204. package/lib/esm/features/store/objects/search/DocumentSearchProvider.js +41 -0
  205. package/lib/esm/features/store/objects/search/DocumentSearchProvider.js.map +1 -0
  206. package/lib/esm/features/store/objects/search/index.js +3 -0
  207. package/lib/esm/features/store/objects/search/index.js.map +1 -0
  208. package/lib/esm/features/store/objects/selection/ObjectsActionContext.js +149 -0
  209. package/lib/esm/features/store/objects/selection/ObjectsActionContext.js.map +1 -0
  210. package/lib/esm/features/store/objects/selection/ObjectsActionSpec.js +2 -0
  211. package/lib/esm/features/store/objects/selection/ObjectsActionSpec.js.map +1 -0
  212. package/lib/esm/features/store/objects/selection/SelectionActions.js +75 -0
  213. package/lib/esm/features/store/objects/selection/SelectionActions.js.map +1 -0
  214. package/lib/esm/features/store/objects/selection/actions/AddToCollectionAction.js +64 -0
  215. package/lib/esm/features/store/objects/selection/actions/AddToCollectionAction.js.map +1 -0
  216. package/lib/esm/features/store/objects/selection/actions/ChangeTypeAction.js +53 -0
  217. package/lib/esm/features/store/objects/selection/actions/ChangeTypeAction.js.map +1 -0
  218. package/lib/esm/features/store/objects/selection/actions/ConfirmAction.js +30 -0
  219. package/lib/esm/features/store/objects/selection/actions/ConfirmAction.js.map +1 -0
  220. package/lib/esm/features/store/objects/selection/actions/DeleteObjectsAction.js +66 -0
  221. package/lib/esm/features/store/objects/selection/actions/DeleteObjectsAction.js.map +1 -0
  222. package/lib/esm/features/store/objects/selection/actions/ExportPropertiesAction.js +106 -0
  223. package/lib/esm/features/store/objects/selection/actions/ExportPropertiesAction.js.map +1 -0
  224. package/lib/esm/features/store/objects/selection/actions/RemoveFromCollectionAction.js +64 -0
  225. package/lib/esm/features/store/objects/selection/actions/RemoveFromCollectionAction.js.map +1 -0
  226. package/lib/esm/features/store/objects/selection/actions/StartWorkflowComponent.js +72 -0
  227. package/lib/esm/features/store/objects/selection/actions/StartWorkflowComponent.js.map +1 -0
  228. package/lib/esm/features/store/objects/selection/actions/index.js +8 -0
  229. package/lib/esm/features/store/objects/selection/actions/index.js.map +1 -0
  230. package/lib/esm/features/store/objects/selection/index.js +5 -0
  231. package/lib/esm/features/store/objects/selection/index.js.map +1 -0
  232. package/lib/esm/features/store/objects/upload/DocumentUploadModal.js +476 -0
  233. package/lib/esm/features/store/objects/upload/DocumentUploadModal.js.map +1 -0
  234. package/lib/esm/features/store/objects/upload/index.js +4 -0
  235. package/lib/esm/features/store/objects/upload/index.js.map +1 -0
  236. package/lib/esm/features/store/objects/upload/useSmartFileUploadProcessing.js +201 -0
  237. package/lib/esm/features/store/objects/upload/useSmartFileUploadProcessing.js.map +1 -0
  238. package/lib/esm/features/store/objects/upload/useUploadHandler.js +230 -0
  239. package/lib/esm/features/store/objects/upload/useUploadHandler.js.map +1 -0
  240. package/lib/esm/features/store/types/ContentObjectTypeView.js +158 -0
  241. package/lib/esm/features/store/types/ContentObjectTypeView.js.map +1 -0
  242. package/lib/esm/features/store/types/ContentObjectTypesSearch.js +82 -0
  243. package/lib/esm/features/store/types/ContentObjectTypesSearch.js.map +1 -0
  244. package/lib/esm/features/store/types/ContentObjectTypesTable.js +11 -0
  245. package/lib/esm/features/store/types/ContentObjectTypesTable.js.map +1 -0
  246. package/lib/esm/features/store/types/ContentObjectTypesView.js +55 -0
  247. package/lib/esm/features/store/types/ContentObjectTypesView.js.map +1 -0
  248. package/lib/esm/features/store/types/CreateOrUpdateTypeModal.js +26 -0
  249. package/lib/esm/features/store/types/CreateOrUpdateTypeModal.js.map +1 -0
  250. package/lib/esm/features/store/types/ObjectSchemaEditor.js +89 -0
  251. package/lib/esm/features/store/types/ObjectSchemaEditor.js.map +1 -0
  252. package/lib/esm/features/store/types/SelectContentType.js +43 -0
  253. package/lib/esm/features/store/types/SelectContentType.js.map +1 -0
  254. package/lib/esm/features/store/types/SelectContentTypeModal.js +28 -0
  255. package/lib/esm/features/store/types/SelectContentTypeModal.js.map +1 -0
  256. package/lib/esm/features/store/types/TableLayoutEditor.js +78 -0
  257. package/lib/esm/features/store/types/TableLayoutEditor.js.map +1 -0
  258. package/lib/esm/features/store/types/index.js +11 -0
  259. package/lib/esm/features/store/types/index.js.map +1 -0
  260. package/lib/esm/features/store/types/search/ObjectTypeSearchContext.js +98 -0
  261. package/lib/esm/features/store/types/search/ObjectTypeSearchContext.js.map +1 -0
  262. package/lib/esm/features/store/types/search/ObjectTypeSearchProvider.js +15 -0
  263. package/lib/esm/features/store/types/search/ObjectTypeSearchProvider.js.map +1 -0
  264. package/lib/esm/features/store/types/search/index.js +3 -0
  265. package/lib/esm/features/store/types/search/index.js.map +1 -0
  266. package/lib/esm/features/user/UserAvatar.js +18 -0
  267. package/lib/esm/features/user/UserAvatar.js.map +1 -0
  268. package/lib/esm/features/user/UserInfo.js +88 -0
  269. package/lib/esm/features/user/UserInfo.js.map +1 -0
  270. package/lib/esm/features/user/index.js +3 -0
  271. package/lib/esm/features/user/index.js.map +1 -0
  272. package/lib/esm/features/utils/index.js +4 -0
  273. package/lib/esm/features/utils/index.js.map +1 -0
  274. package/lib/esm/features/utils/mimeType.js +9 -0
  275. package/lib/esm/features/utils/mimeType.js.map +1 -0
  276. package/lib/esm/features/utils/rendition.js +47 -0
  277. package/lib/esm/features/utils/rendition.js.map +1 -0
  278. package/lib/esm/features/utils/text.js +10 -0
  279. package/lib/esm/features/utils/text.js.map +1 -0
  280. package/lib/esm/layout/FullHeightLayout.js +1 -1
  281. package/lib/esm/layout/FullHeightLayout.js.map +1 -1
  282. package/lib/esm/layout/Sidebar.js +12 -2
  283. package/lib/esm/layout/Sidebar.js.map +1 -1
  284. package/lib/esm/widgets/Progress.js +5 -0
  285. package/lib/esm/widgets/Progress.js.map +1 -0
  286. package/lib/esm/widgets/codemirror/CodeMirrorEditor.js +1 -1
  287. package/lib/esm/widgets/codemirror/CodeMirrorEditor.js.map +1 -1
  288. package/lib/esm/widgets/form/Form.js +2 -2
  289. package/lib/esm/widgets/form/Form.js.map +1 -1
  290. package/lib/esm/widgets/form/schema.js +11 -5
  291. package/lib/esm/widgets/form/schema.js.map +1 -1
  292. package/lib/esm/widgets/index.js +4 -0
  293. package/lib/esm/widgets/index.js.map +1 -1
  294. package/lib/esm/widgets/popover/Popover.js +73 -0
  295. package/lib/esm/widgets/popover/Popover.js.map +1 -0
  296. package/lib/esm/widgets/popover/context.js +7 -0
  297. package/lib/esm/widgets/popover/context.js.map +1 -0
  298. package/lib/esm/widgets/popover/index.js +3 -0
  299. package/lib/esm/widgets/popover/index.js.map +1 -0
  300. package/lib/esm/widgets/popover/slots.js +22 -0
  301. package/lib/esm/widgets/popover/slots.js.map +1 -0
  302. package/lib/esm/widgets/properties/PropertiesView.js +6 -0
  303. package/lib/esm/widgets/properties/PropertiesView.js.map +1 -0
  304. package/lib/esm/widgets/properties/index.js +2 -0
  305. package/lib/esm/widgets/properties/index.js.map +1 -0
  306. package/lib/esm/widgets/schema-editor/JSONSchemaEditorModal.js +1 -2
  307. package/lib/esm/widgets/schema-editor/JSONSchemaEditorModal.js.map +1 -1
  308. package/lib/esm/widgets/schema-editor/editor/Editable.js +9 -10
  309. package/lib/esm/widgets/schema-editor/editor/Editable.js.map +1 -1
  310. package/lib/esm/widgets/schema-editor/editor/PropertyViewer.js +1 -1
  311. package/lib/esm/widgets/schema-editor/editor/PropertyViewer.js.map +1 -1
  312. package/lib/esm/widgets/schema-editor/editor/SchemaEditor.js +2 -2
  313. package/lib/esm/widgets/schema-editor/editor/SchemaEditor.js.map +1 -1
  314. package/lib/esm/widgets/upload/DropZone.js +162 -0
  315. package/lib/esm/widgets/upload/DropZone.js.map +1 -0
  316. package/lib/esm/widgets/upload/UploadResultCategory.js +19 -0
  317. package/lib/esm/widgets/upload/UploadResultCategory.js.map +1 -0
  318. package/lib/esm/widgets/upload/UploadSummary.js +30 -0
  319. package/lib/esm/widgets/upload/UploadSummary.js.map +1 -0
  320. package/lib/esm/widgets/upload/index.js +4 -0
  321. package/lib/esm/widgets/upload/index.js.map +1 -0
  322. package/lib/tsconfig.tsbuildinfo +1 -1
  323. package/lib/types/core/components/FormItem.d.ts +11 -0
  324. package/lib/types/core/components/index.d.ts +3 -3
  325. package/lib/types/core/components/shadcn/button.d.ts +13 -2
  326. package/lib/types/core/components/shadcn/command.d.ts +7 -7
  327. package/lib/types/core/components/shadcn/filters/DynamicLabel.d.ts +8 -0
  328. package/lib/types/core/components/shadcn/filters/comboBox.d.ts +5 -5
  329. package/lib/types/core/components/shadcn/filters/dateFilter.d.ts +3 -4
  330. package/lib/types/core/components/shadcn/filters/types.d.ts +7 -1
  331. package/lib/types/core/components/shadcn/input.d.ts +4 -4
  332. package/lib/types/core/components/shadcn/selectBox.d.ts +13 -4
  333. package/lib/types/core/components/table/index.d.ts +1 -0
  334. package/lib/types/core/index.d.ts +2 -1
  335. package/lib/types/core/utils/cn.d.ts +2 -0
  336. package/lib/types/core/utils/index.d.ts +1 -0
  337. package/lib/types/features/agent/PayloadBuilder.d.ts +53 -0
  338. package/lib/types/features/agent/chat/AnimatedThinkingDots.d.ts +37 -0
  339. package/lib/types/features/agent/chat/JumpingDots.d.ts +6 -0
  340. package/lib/types/features/agent/chat/ModernAgentConversation.d.ts +24 -0
  341. package/lib/types/features/agent/chat/ModernAgentOutput/AllMessagesMixed.d.ts +21 -0
  342. package/lib/types/features/agent/chat/ModernAgentOutput/Header.d.ts +18 -0
  343. package/lib/types/features/agent/chat/ModernAgentOutput/InlineSlideInPanel.d.ts +10 -0
  344. package/lib/types/features/agent/chat/ModernAgentOutput/InlineSlidingPlanPanel.d.ts +15 -0
  345. package/lib/types/features/agent/chat/ModernAgentOutput/MessageInput.d.ts +12 -0
  346. package/lib/types/features/agent/chat/ModernAgentOutput/MessageItem.d.ts +7 -0
  347. package/lib/types/features/agent/chat/ModernAgentOutput/MessagesContainer.d.ts +9 -0
  348. package/lib/types/features/agent/chat/ModernAgentOutput/PlanPanel.d.ts +8 -0
  349. package/lib/types/features/agent/chat/ModernAgentOutput/SlideInPanel.d.ts +10 -0
  350. package/lib/types/features/agent/chat/ModernAgentOutput/SlidingMessages.d.ts +7 -0
  351. package/lib/types/features/agent/chat/ModernAgentOutput/SlidingPlanPanel.d.ts +9 -0
  352. package/lib/types/features/agent/chat/ModernAgentOutput/StackedMessages.d.ts +7 -0
  353. package/lib/types/features/agent/chat/ModernAgentOutput/WorkstreamTabs.d.ts +21 -0
  354. package/lib/types/features/agent/chat/ModernAgentOutput/utils.d.ts +23 -0
  355. package/lib/types/features/agent/chat/SlidingThinkingIndicator.d.ts +17 -0
  356. package/lib/types/features/agent/chat/WaitingMessages.d.ts +1 -0
  357. package/lib/types/features/agent/chat/index.d.ts +4 -0
  358. package/lib/types/features/agent/index.d.ts +2 -0
  359. package/lib/types/features/errors/PanelErrorBoundary.d.ts +4 -0
  360. package/lib/types/features/errors/RowErrorBoundary.d.ts +7 -0
  361. package/lib/types/features/errors/VertesiaErrorBoundary.d.ts +11 -0
  362. package/lib/types/features/errors/WidgetErrorBoundary.d.ts +4 -0
  363. package/lib/types/features/errors/index.d.ts +4 -0
  364. package/lib/types/features/facets/EnvironmentFacet.d.ts +9 -0
  365. package/lib/types/features/facets/FacetsNav.d.ts +6 -0
  366. package/lib/types/features/facets/InteractionFacet.d.ts +9 -0
  367. package/lib/types/features/facets/StringFacet.d.ts +10 -0
  368. package/lib/types/features/facets/StringListFacet.d.ts +10 -0
  369. package/lib/types/features/facets/TypeFacet.d.ts +15 -0
  370. package/lib/types/features/facets/TypeOptions.d.ts +3 -0
  371. package/lib/types/features/facets/UserFacet.d.ts +11 -0
  372. package/lib/types/features/facets/VFacetsNav.d.ts +7 -0
  373. package/lib/types/features/facets/VStringFacet.d.ts +15 -0
  374. package/lib/types/features/facets/VTypeFacet.d.ts +8 -0
  375. package/lib/types/features/facets/VUserFacet.d.ts +9 -0
  376. package/lib/types/features/facets/index.d.ts +11 -0
  377. package/lib/types/features/facets/utils.d.ts +3 -0
  378. package/lib/types/features/index.d.ts +9 -1
  379. package/lib/types/features/layout/GenericPageNavHeader.d.ts +12 -0
  380. package/lib/types/features/layout/NotFoundView.d.ts +4 -0
  381. package/lib/types/features/layout/index.d.ts +2 -0
  382. package/lib/types/features/magic-pdf/DownloadPopover.d.ts +6 -0
  383. package/lib/types/features/magic-pdf/MagicPdfView.d.ts +6 -0
  384. package/lib/types/features/magic-pdf/PageSlider.d.ts +7 -0
  385. package/lib/types/features/magic-pdf/PdfPageProvider.d.ts +28 -0
  386. package/lib/types/features/magic-pdf/TextPageView.d.ts +7 -0
  387. package/lib/types/features/magic-pdf/index.d.ts +1 -0
  388. package/lib/types/features/magic-pdf/types.d.ts +1 -0
  389. package/lib/types/features/magic-pdf/useResizeOnDrag.d.ts +8 -0
  390. package/lib/types/features/store/collections/BrowseCollectionView.d.ts +6 -0
  391. package/lib/types/features/store/collections/CollectionView.d.ts +5 -0
  392. package/lib/types/features/store/collections/CollectionsTable.d.ts +5 -0
  393. package/lib/types/features/store/collections/CollectionsView.d.ts +10 -0
  394. package/lib/types/features/store/collections/EditCollectionView.d.ts +7 -0
  395. package/lib/types/features/store/collections/index.d.ts +5 -0
  396. package/lib/types/features/store/index.d.ts +3 -0
  397. package/lib/types/features/store/objects/DocumentPreviewPanel.d.ts +7 -0
  398. package/lib/types/features/store/objects/DocumentSearchResults.d.ts +19 -0
  399. package/lib/types/features/store/objects/DocumentSelectionProvider.d.ts +32 -0
  400. package/lib/types/features/store/objects/DocumentTable.d.ts +20 -0
  401. package/lib/types/features/store/objects/ExportPropertiesModal.d.ts +11 -0
  402. package/lib/types/features/store/objects/components/ContentDispositionButton.d.ts +8 -0
  403. package/lib/types/features/store/objects/components/ContentOverview.d.ts +7 -0
  404. package/lib/types/features/store/objects/components/DocumentIcon.d.ts +10 -0
  405. package/lib/types/features/store/objects/components/DocumentInput.d.ts +7 -0
  406. package/lib/types/features/store/objects/components/PropertiesEditorModal.d.ts +7 -0
  407. package/lib/types/features/store/objects/components/SaveVersionConfirmModal.d.ts +8 -0
  408. package/lib/types/features/store/objects/components/SelectDocument.d.ts +8 -0
  409. package/lib/types/features/store/objects/components/SelectDocumentModal.d.ts +8 -0
  410. package/lib/types/features/store/objects/components/VectorSearchWidget.d.ts +10 -0
  411. package/lib/types/features/store/objects/components/index.d.ts +9 -0
  412. package/lib/types/features/store/objects/components/useDownloadObject.d.ts +3 -0
  413. package/lib/types/features/store/objects/index.d.ts +10 -0
  414. package/lib/types/features/store/objects/layout/DocumentTableColumn.d.ts +16 -0
  415. package/lib/types/features/store/objects/layout/documentLayout.d.ts +17 -0
  416. package/lib/types/features/store/objects/layout/index.d.ts +2 -0
  417. package/lib/types/features/store/objects/layout/renderers.d.ts +2 -0
  418. package/lib/types/features/store/objects/search/DocumentSearchContext.d.ts +48 -0
  419. package/lib/types/features/store/objects/search/DocumentSearchProvider.d.ts +15 -0
  420. package/lib/types/features/store/objects/search/index.d.ts +2 -0
  421. package/lib/types/features/store/objects/selection/ObjectsActionContext.d.ts +25 -0
  422. package/lib/types/features/store/objects/selection/ObjectsActionSpec.d.ts +27 -0
  423. package/lib/types/features/store/objects/selection/SelectionActions.d.ts +4 -0
  424. package/lib/types/features/store/objects/selection/actions/AddToCollectionAction.d.ts +3 -0
  425. package/lib/types/features/store/objects/selection/actions/ChangeTypeAction.d.ts +3 -0
  426. package/lib/types/features/store/objects/selection/actions/ConfirmAction.d.ts +15 -0
  427. package/lib/types/features/store/objects/selection/actions/DeleteObjectsAction.d.ts +2 -0
  428. package/lib/types/features/store/objects/selection/actions/ExportPropertiesAction.d.ts +3 -0
  429. package/lib/types/features/store/objects/selection/actions/RemoveFromCollectionAction.d.ts +2 -0
  430. package/lib/types/features/store/objects/selection/actions/StartWorkflowComponent.d.ts +3 -0
  431. package/lib/types/features/store/objects/selection/actions/index.d.ts +7 -0
  432. package/lib/types/features/store/objects/selection/index.d.ts +4 -0
  433. package/lib/types/features/store/objects/upload/DocumentUploadModal.d.ts +37 -0
  434. package/lib/types/features/store/objects/upload/index.d.ts +3 -0
  435. package/lib/types/features/store/objects/upload/useSmartFileUploadProcessing.d.ts +29 -0
  436. package/lib/types/features/store/objects/upload/useUploadHandler.d.ts +49 -0
  437. package/lib/types/features/store/types/ContentObjectTypeView.d.ts +5 -0
  438. package/lib/types/features/store/types/ContentObjectTypesSearch.d.ts +5 -0
  439. package/lib/types/features/store/types/ContentObjectTypesTable.d.ts +7 -0
  440. package/lib/types/features/store/types/ContentObjectTypesView.d.ts +8 -0
  441. package/lib/types/features/store/types/CreateOrUpdateTypeModal.d.ts +14 -0
  442. package/lib/types/features/store/types/ObjectSchemaEditor.d.ts +7 -0
  443. package/lib/types/features/store/types/SelectContentType.d.ts +10 -0
  444. package/lib/types/features/store/types/SelectContentTypeModal.d.ts +32 -0
  445. package/lib/types/features/store/types/TableLayoutEditor.d.ts +8 -0
  446. package/lib/types/features/store/types/index.d.ts +10 -0
  447. package/lib/types/features/store/types/search/ObjectTypeSearchContext.d.ts +35 -0
  448. package/lib/types/features/store/types/search/ObjectTypeSearchProvider.d.ts +10 -0
  449. package/lib/types/features/store/types/search/index.d.ts +2 -0
  450. package/lib/types/features/user/UserAvatar.d.ts +8 -0
  451. package/lib/types/features/user/UserInfo.d.ts +36 -0
  452. package/lib/types/features/user/index.d.ts +2 -0
  453. package/lib/types/features/utils/index.d.ts +3 -0
  454. package/lib/types/features/utils/mimeType.d.ts +4 -0
  455. package/lib/types/features/utils/rendition.d.ts +3 -0
  456. package/lib/types/features/utils/text.d.ts +2 -0
  457. package/lib/types/layout/Sidebar.d.ts +2 -1
  458. package/lib/types/widgets/Progress.d.ts +5 -0
  459. package/lib/types/widgets/form/schema.d.ts +4 -3
  460. package/lib/types/widgets/index.d.ts +4 -0
  461. package/lib/types/widgets/popover/Popover.d.ts +37 -0
  462. package/lib/types/widgets/popover/context.d.ts +7 -0
  463. package/lib/types/widgets/popover/index.d.ts +2 -0
  464. package/lib/types/widgets/popover/slots.d.ts +4 -0
  465. package/lib/types/widgets/properties/PropertiesView.d.ts +10 -0
  466. package/lib/types/widgets/properties/index.d.ts +1 -0
  467. package/lib/types/widgets/upload/DropZone.d.ts +40 -0
  468. package/lib/types/widgets/upload/UploadResultCategory.d.ts +25 -0
  469. package/lib/types/widgets/upload/UploadSummary.d.ts +37 -0
  470. package/lib/types/widgets/upload/index.d.ts +3 -0
  471. package/lib/vertesia-ui-core.js +1 -1
  472. package/lib/vertesia-ui-core.js.map +1 -1
  473. package/lib/vertesia-ui-features.js +1 -1
  474. package/lib/vertesia-ui-features.js.map +1 -1
  475. package/lib/vertesia-ui-layout.js +1 -1
  476. package/lib/vertesia-ui-layout.js.map +1 -1
  477. package/lib/vertesia-ui-router.js.map +1 -1
  478. package/lib/vertesia-ui-session.js.map +1 -1
  479. package/lib/vertesia-ui-widgets.js +1 -1
  480. package/lib/vertesia-ui-widgets.js.map +1 -1
  481. package/package.json +13 -5
  482. package/src/core/components/FormItem.tsx +35 -0
  483. package/src/core/components/InputList.tsx +4 -3
  484. package/src/core/components/index.ts +3 -3
  485. package/src/core/components/shadcn/button.tsx +68 -8
  486. package/src/core/components/shadcn/dialog.tsx +3 -3
  487. package/src/core/components/shadcn/filters/DynamicLabel.tsx +45 -0
  488. package/src/core/components/shadcn/filters/comboBox.tsx +56 -52
  489. package/src/core/components/shadcn/filters/dateFilter.tsx +24 -25
  490. package/src/core/components/shadcn/filters/filterBar.tsx +53 -47
  491. package/src/core/components/shadcn/filters/filters.tsx +43 -30
  492. package/src/core/components/shadcn/filters/selectFilter.tsx +53 -34
  493. package/src/core/components/shadcn/filters/textFilter.tsx +6 -3
  494. package/src/core/components/shadcn/filters/types.ts +8 -1
  495. package/src/core/components/shadcn/input.tsx +5 -5
  496. package/src/core/components/shadcn/selectBox.tsx +138 -33
  497. package/src/core/components/styles.ts +1 -1
  498. package/src/core/components/table/index.tsx +8 -0
  499. package/src/core/index.ts +2 -1
  500. package/src/core/utils/cn.ts +6 -0
  501. package/src/core/utils/index.ts +1 -0
  502. package/src/features/agent/PayloadBuilder.tsx +208 -0
  503. package/src/features/agent/chat/AnimatedThinkingDots.tsx +350 -0
  504. package/src/features/agent/chat/JumpingDots.tsx +16 -0
  505. package/src/features/agent/chat/ModernAgentConversation.tsx +708 -0
  506. package/src/features/agent/chat/ModernAgentOutput/AllMessagesMixed.tsx +246 -0
  507. package/src/features/agent/chat/ModernAgentOutput/Header.tsx +231 -0
  508. package/src/features/agent/chat/ModernAgentOutput/InlineSlideInPanel.tsx +66 -0
  509. package/src/features/agent/chat/ModernAgentOutput/InlineSlidingPlanPanel.tsx +282 -0
  510. package/src/features/agent/chat/ModernAgentOutput/MessageInput.tsx +125 -0
  511. package/src/features/agent/chat/ModernAgentOutput/MessageItem.tsx +562 -0
  512. package/src/features/agent/chat/ModernAgentOutput/MessagesContainer.tsx +51 -0
  513. package/src/features/agent/chat/ModernAgentOutput/PlanPanel.tsx +123 -0
  514. package/src/features/agent/chat/ModernAgentOutput/README-image-support.md +43 -0
  515. package/src/features/agent/chat/ModernAgentOutput/SlideInPanel.tsx +72 -0
  516. package/src/features/agent/chat/ModernAgentOutput/SlidingMessages.tsx +96 -0
  517. package/src/features/agent/chat/ModernAgentOutput/SlidingPlanPanel.tsx +185 -0
  518. package/src/features/agent/chat/ModernAgentOutput/StackedMessages.tsx +33 -0
  519. package/src/features/agent/chat/ModernAgentOutput/WorkstreamTabs.tsx +167 -0
  520. package/src/features/agent/chat/ModernAgentOutput/utils.ts +195 -0
  521. package/src/features/agent/chat/ModernAgentOutput/with-types.d.ts +15 -0
  522. package/src/features/agent/chat/SlidingThinkingIndicator.tsx +459 -0
  523. package/src/features/agent/chat/WaitingMessages.ts +66 -0
  524. package/src/features/agent/chat/index.ts +4 -0
  525. package/src/features/agent/index.ts +2 -0
  526. package/src/features/errors/PanelErrorBoundary.tsx +30 -0
  527. package/src/features/errors/RowErrorBoundary.tsx +28 -0
  528. package/src/features/errors/VertesiaErrorBoundary.tsx +28 -0
  529. package/src/features/errors/WidgetErrorBoundary.tsx +27 -0
  530. package/src/features/errors/index.ts +4 -0
  531. package/src/features/facets/EnvironmentFacet.tsx +53 -0
  532. package/src/features/facets/FacetsNav.tsx +19 -0
  533. package/src/features/facets/InteractionFacet.tsx +53 -0
  534. package/src/features/facets/StringFacet.tsx +23 -0
  535. package/src/features/facets/StringListFacet.tsx +22 -0
  536. package/src/features/facets/TypeFacet.tsx +59 -0
  537. package/src/features/facets/TypeOptions.tsx +22 -0
  538. package/src/features/facets/UserFacet.tsx +61 -0
  539. package/src/features/facets/VFacetsNav.tsx +139 -0
  540. package/src/features/facets/VStringFacet.tsx +34 -0
  541. package/src/features/facets/VTypeFacet.tsx +72 -0
  542. package/src/features/facets/VUserFacet.tsx +47 -0
  543. package/src/features/facets/index.ts +11 -0
  544. package/src/features/facets/utils.tsx +9 -0
  545. package/src/features/index.ts +9 -1
  546. package/src/features/layout/GenericPageNavHeader.tsx +48 -0
  547. package/src/features/layout/NotFoundView.tsx +11 -0
  548. package/src/features/layout/index.ts +2 -0
  549. package/src/features/magic-pdf/DownloadPopover.tsx +32 -0
  550. package/src/features/magic-pdf/MagicPdfView.tsx +102 -0
  551. package/src/features/magic-pdf/PageSlider.tsx +112 -0
  552. package/src/features/magic-pdf/PdfPageProvider.tsx +229 -0
  553. package/src/features/magic-pdf/TextPageView.tsx +65 -0
  554. package/src/features/magic-pdf/index.ts +1 -0
  555. package/src/features/magic-pdf/types.ts +1 -0
  556. package/src/features/magic-pdf/useResizeOnDrag.ts +42 -0
  557. package/src/features/store/collections/BrowseCollectionView.tsx +45 -0
  558. package/src/features/store/collections/CollectionView.tsx +94 -0
  559. package/src/features/store/collections/CollectionsTable.tsx +115 -0
  560. package/src/features/store/collections/CollectionsView.tsx +166 -0
  561. package/src/features/store/collections/EditCollectionView.tsx +253 -0
  562. package/src/features/store/collections/index.ts +5 -0
  563. package/src/features/store/index.ts +3 -0
  564. package/src/features/store/objects/DocumentPreviewPanel.tsx +417 -0
  565. package/src/features/store/objects/DocumentSearchResults.tsx +209 -0
  566. package/src/features/store/objects/DocumentSelectionProvider.tsx +99 -0
  567. package/src/features/store/objects/DocumentTable.tsx +409 -0
  568. package/src/features/store/objects/ExportPropertiesModal.tsx +89 -0
  569. package/src/features/store/objects/components/ContentDispositionButton.tsx +45 -0
  570. package/src/features/store/objects/components/ContentOverview.tsx +466 -0
  571. package/src/features/store/objects/components/DocumentIcon.tsx +87 -0
  572. package/src/features/store/objects/components/DocumentInput.tsx +90 -0
  573. package/src/features/store/objects/components/PropertiesEditorModal.tsx +253 -0
  574. package/src/features/store/objects/components/SaveVersionConfirmModal.tsx +136 -0
  575. package/src/features/store/objects/components/SelectDocument.tsx +69 -0
  576. package/src/features/store/objects/components/SelectDocumentModal.tsx +20 -0
  577. package/src/features/store/objects/components/VectorSearchWidget.tsx +115 -0
  578. package/src/features/store/objects/components/index.ts +9 -0
  579. package/src/features/store/objects/components/useDownloadObject.ts +24 -0
  580. package/src/features/store/objects/index.ts +10 -0
  581. package/src/features/store/objects/layout/DocumentTableColumn.tsx +84 -0
  582. package/src/features/store/objects/layout/documentLayout.tsx +69 -0
  583. package/src/features/store/objects/layout/index.ts +2 -0
  584. package/src/features/store/objects/layout/knowledge.md +238 -0
  585. package/src/features/store/objects/layout/renderers.tsx +139 -0
  586. package/src/features/store/objects/search/DocumentSearchContext.ts +181 -0
  587. package/src/features/store/objects/search/DocumentSearchProvider.tsx +54 -0
  588. package/src/features/store/objects/search/index.ts +2 -0
  589. package/src/features/store/objects/selection/ObjectsActionContext.tsx +196 -0
  590. package/src/features/store/objects/selection/ObjectsActionSpec.ts +31 -0
  591. package/src/features/store/objects/selection/SelectionActions.tsx +160 -0
  592. package/src/features/store/objects/selection/actions/AddToCollectionAction.tsx +114 -0
  593. package/src/features/store/objects/selection/actions/ChangeTypeAction.tsx +76 -0
  594. package/src/features/store/objects/selection/actions/ConfirmAction.tsx +46 -0
  595. package/src/features/store/objects/selection/actions/DeleteObjectsAction.tsx +77 -0
  596. package/src/features/store/objects/selection/actions/ExportPropertiesAction.tsx +117 -0
  597. package/src/features/store/objects/selection/actions/RemoveFromCollectionAction.tsx +77 -0
  598. package/src/features/store/objects/selection/actions/StartWorkflowComponent.tsx +122 -0
  599. package/src/features/store/objects/selection/actions/index.ts +7 -0
  600. package/src/features/store/objects/selection/index.ts +4 -0
  601. package/src/features/store/objects/upload/DocumentUploadModal.tsx +970 -0
  602. package/src/features/store/objects/upload/index.ts +3 -0
  603. package/src/features/store/objects/upload/useSmartFileUploadProcessing.ts +250 -0
  604. package/src/features/store/objects/upload/useUploadHandler.ts +325 -0
  605. package/src/features/store/types/ContentObjectTypeView.tsx +244 -0
  606. package/src/features/store/types/ContentObjectTypesSearch.tsx +111 -0
  607. package/src/features/store/types/ContentObjectTypesTable.tsx +38 -0
  608. package/src/features/store/types/ContentObjectTypesView.tsx +71 -0
  609. package/src/features/store/types/CreateOrUpdateTypeModal.tsx +70 -0
  610. package/src/features/store/types/ObjectSchemaEditor.tsx +127 -0
  611. package/src/features/store/types/SelectContentType.tsx +88 -0
  612. package/src/features/store/types/SelectContentTypeModal.tsx +142 -0
  613. package/src/features/store/types/TableLayoutEditor.tsx +104 -0
  614. package/src/features/store/types/index.ts +10 -0
  615. package/src/features/store/types/search/ObjectTypeSearchContext.tsx +119 -0
  616. package/src/features/store/types/search/ObjectTypeSearchProvider.tsx +24 -0
  617. package/src/features/store/types/search/index.ts +2 -0
  618. package/src/features/user/UserAvatar.tsx +34 -0
  619. package/src/features/user/UserInfo.tsx +215 -0
  620. package/src/features/user/index.ts +2 -0
  621. package/src/features/utils/index.ts +3 -0
  622. package/src/features/utils/mimeType.ts +9 -0
  623. package/src/features/utils/rendition.ts +75 -0
  624. package/src/features/utils/text.ts +10 -0
  625. package/src/layout/FullHeightLayout.tsx +1 -1
  626. package/src/layout/Sidebar.tsx +12 -2
  627. package/src/widgets/Progress.tsx +10 -0
  628. package/src/widgets/codemirror/CodeMirrorEditor.tsx +1 -1
  629. package/src/widgets/form/Form.tsx +2 -2
  630. package/src/widgets/form/schema.ts +14 -7
  631. package/src/widgets/index.ts +5 -1
  632. package/src/widgets/popover/Popover.tsx +171 -0
  633. package/src/widgets/popover/context.ts +15 -0
  634. package/src/widgets/popover/index.ts +2 -0
  635. package/src/widgets/popover/slots.ts +24 -0
  636. package/src/widgets/properties/PropertiesView.tsx +26 -0
  637. package/src/widgets/properties/index.ts +1 -0
  638. package/src/widgets/schema-editor/JSONSchemaEditorModal.tsx +1 -2
  639. package/src/widgets/schema-editor/editor/Editable.tsx +12 -13
  640. package/src/widgets/schema-editor/editor/PropertyViewer.tsx +1 -1
  641. package/src/widgets/schema-editor/editor/SchemaEditor.tsx +4 -4
  642. package/src/widgets/upload/DropZone.tsx +257 -0
  643. package/src/widgets/upload/UploadResultCategory.tsx +81 -0
  644. package/src/widgets/upload/UploadSummary.tsx +116 -0
  645. package/src/widgets/upload/index.ts +3 -0
  646. package/lib/esm/code/index.js +0 -3
  647. package/lib/esm/code/index.js.map +0 -1
  648. package/lib/esm/core/components/Input.js +0 -16
  649. package/lib/esm/core/components/Input.js.map +0 -1
  650. package/lib/esm/form/index.js +0 -3
  651. package/lib/esm/form/index.js.map +0 -1
  652. package/lib/types/code/index.d.ts +0 -0
  653. package/lib/types/core/components/Input.d.ts +0 -8
  654. package/lib/types/form/index.d.ts +0 -0
  655. package/lib/vertesia-ui-code.js +0 -2
  656. package/lib/vertesia-ui-code.js.map +0 -1
  657. package/lib/vertesia-ui-form.js +0 -2
  658. package/lib/vertesia-ui-form.js.map +0 -1
  659. package/src/code/index.ts +0 -1
  660. package/src/core/components/Input.tsx +0 -43
  661. package/src/form/index.ts +0 -1
@@ -0,0 +1,42 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { useUserSession } from "@vertesia/ui/session";
3
+ import { SelectBox } from "@vertesia/ui/core";
4
+ import { useEffect, useState } from "react";
5
+ export function facetOptionLabel(bucket) {
6
+ return `${bucket.name} (${bucket.count})`;
7
+ }
8
+ export function TypeFacet({ search, buckets, placeholder = "Filter by Type", className }) {
9
+ const [options, setOptions] = useState([]);
10
+ const { typeRegistry } = useUserSession();
11
+ const filterValue = search.getFilterValue("type");
12
+ const onChange = (option) => {
13
+ search.setFilterValue("type", option?._id);
14
+ };
15
+ useEffect(() => {
16
+ if (typeRegistry) {
17
+ const options = buckets.map((bucket) => {
18
+ let name;
19
+ if (bucket._id == null) {
20
+ bucket._id = "Document";
21
+ name = "Document";
22
+ }
23
+ else {
24
+ name = typeRegistry.getTypeName(bucket._id);
25
+ if (!name) {
26
+ console.warn("Content Object Type not found", bucket._id);
27
+ name = bucket._id;
28
+ }
29
+ }
30
+ return {
31
+ ...bucket,
32
+ name
33
+ };
34
+ });
35
+ options.sort((a, b) => a.name.localeCompare(b.name));
36
+ setOptions(options);
37
+ }
38
+ }, [buckets, typeRegistry]);
39
+ const value = options?.find((option) => option._id === filterValue);
40
+ return (_jsx(SelectBox, { filterBy: "name", className: className, isClearable: true, optionLabel: facetOptionLabel, options: options, value: value, onChange: onChange, by: '_id', placeholder: placeholder }));
41
+ }
42
+ //# sourceMappingURL=TypeFacet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TypeFacet.js","sourceRoot":"","sources":["../../../../src/features/facets/TypeFacet.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAEtD,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAQ5C,MAAM,UAAU,gBAAgB,CAAC,MAAuB;IACpD,OAAO,GAAG,MAAM,CAAC,IAAI,KAAK,MAAM,CAAC,KAAK,GAAG,CAAC;AAC9C,CAAC;AAQD,MAAM,UAAU,SAAS,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,WAAW,GAAG,gBAAgB,EAAE,SAAS,EAAkB;IACpG,MAAM,CAAC,OAAO,EAAE,UAAU,CAAC,GAAG,QAAQ,CAAoB,EAAE,CAAC,CAAC;IAC9D,MAAM,EAAE,YAAY,EAAE,GAAG,cAAc,EAAE,CAAC;IAC1C,MAAM,WAAW,GAAG,MAAM,CAAC,cAAc,CAAC,MAAM,CAAW,CAAC;IAC5D,MAAM,QAAQ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AC,WAAW,EAAE,gBAAgB,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,EAAC,KAAK,EAAC,WAAW,EAAE,WAAW,GAAI,CACxL,CAAA;AACL,CAAC"}
@@ -0,0 +1,19 @@
1
+ import { useUserSession } from "@vertesia/ui/session";
2
+ export function TypeOptionLabel(buckets) {
3
+ const { typeRegistry } = useUserSession();
4
+ return buckets.map((bucket) => {
5
+ let name;
6
+ if (bucket._id == null) {
7
+ bucket._id = "Document";
8
+ name = "Document";
9
+ }
10
+ else {
11
+ name = typeRegistry?.getTypeName(bucket._id) || bucket._id;
12
+ }
13
+ return {
14
+ name: `${name} (${bucket.count})`,
15
+ value: bucket._id,
16
+ };
17
+ }).sort((a, b) => a.name.localeCompare(b.name));
18
+ }
19
+ //# sourceMappingURL=TypeOptions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TypeOptions.js","sourceRoot":"","sources":["../../../../src/features/facets/TypeOptions.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAItD,MAAM,UAAU,eAAe,CAAC,OAAsB;IAClD,MAAM,EAAE,YAAY,EAAE,GAAG,cAAc,EAAE,CAAC;IAE1C,OAAO,OAAO,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE;QAC1B,IAAI,IAAI,CAAC;QACT,IAAI,MAAM,CAAC,GAAG,IAAI,IAAI,EAAE,CAAC;YACrB,MAAM,CAAC,GAAG,GAAG,UAAU,CAAC;YACxB,IAAI,GAAG,UAAU,CAAC;QACtB,CAAC;aAAM,CAAC;YACJ,IAAI,GAAG,YAAY,EAAE,WAAW,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC;QAC/D,CAAC;QAED,OAAO;YACH,IAAI,EAAE,GAAG,IAAI,KAAK,MAAM,CAAC,KAAK,GAAG;YACjC,KAAK,EAAE,MAAM,CAAC,GAAG;SACpB,CAAC;IACN,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;AACpD,CAAC"}
@@ -0,0 +1,33 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { SelectBox } from "@vertesia/ui/core";
3
+ import { useEffect, useState } from "react";
4
+ import { UserInfo } from '../user/UserInfo';
5
+ export function facetOptionLabel(bucket) {
6
+ if (bucket._id == null) {
7
+ return `UnKnown User (${bucket.count})`;
8
+ }
9
+ else {
10
+ return (_jsx(UserInfo, { userRef: bucket._id, showTitle: true, size: "sm" }));
11
+ }
12
+ }
13
+ export function UserFacet({ search, buckets, placeholder = "Filter by User", className }) {
14
+ const [options, setOptions] = useState([]);
15
+ const filterValue = search.getFilterValue("created_by");
16
+ const onChange = (option) => {
17
+ search.setFilterValue("created_by", option?._id);
18
+ };
19
+ useEffect(() => {
20
+ const fetchOptions = async () => {
21
+ const options = await Promise.all(buckets.map(async (bucket) => {
22
+ return {
23
+ ...bucket,
24
+ };
25
+ }));
26
+ setOptions(options);
27
+ };
28
+ fetchOptions();
29
+ }, [buckets]);
30
+ const value = options?.find((option) => option._id === filterValue);
31
+ return (_jsx(SelectBox, { filterBy: "name", className: className, isClearable: true, optionLabel: facetOptionLabel, options: options, value: value, onChange: onChange, by: '_id', placeholder: placeholder }));
32
+ }
33
+ //# sourceMappingURL=UserFacet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UserFacet.js","sourceRoot":"","sources":["../../../../src/features/facets/UserFacet.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE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AAS,IACN,QAAQ,EAAC,MAAM,EACf,SAAS,EAAE,SAAS,EACpB,WAAW,QACX,WAAW,EAAE,gBAAgB,EAC7B,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE,KAAK,EACZ,QAAQ,EAAE,QAAQ,EAClB,EAAE,EAAC,KAAK,EACR,WAAW,EAAE,WAAW,GAC1B,CACL,CAAA;AACL,CAAC"}
@@ -0,0 +1,114 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { FilterBar } from '@vertesia/ui/core';
3
+ import { useUserSession } from '@vertesia/ui/session';
4
+ import { useState } from 'react';
5
+ import { VStringFacet } from './VStringFacet';
6
+ import { VTypeFacet } from './VTypeFacet';
7
+ import { VUserFacet } from './VUserFacet';
8
+ export function VFacetsNav({ facets, search, textSearch = '' }) {
9
+ const [filters, setFilters] = useState([]);
10
+ const customFilterGroups = [];
11
+ const { typeRegistry } = useUserSession();
12
+ if (textSearch) {
13
+ customFilterGroups.push({
14
+ placeholder: textSearch,
15
+ name: 'name',
16
+ type: 'text',
17
+ options: [],
18
+ });
19
+ }
20
+ if (facets.type) {
21
+ const typeFilterGroup = VTypeFacet({
22
+ buckets: facets.type || [],
23
+ typeRegistry: typeRegistry,
24
+ });
25
+ customFilterGroups.push(typeFilterGroup);
26
+ }
27
+ if (facets.status) {
28
+ const statusFilterGroup = VStringFacet({
29
+ search,
30
+ buckets: facets.status || [],
31
+ name: 'Status'
32
+ });
33
+ customFilterGroups.push(statusFilterGroup);
34
+ }
35
+ if (facets.role) {
36
+ const roleFilterGroup = VStringFacet({
37
+ search,
38
+ buckets: facets.role || [],
39
+ name: 'Role'
40
+ });
41
+ customFilterGroups.push(roleFilterGroup);
42
+ }
43
+ if (facets.location) {
44
+ const locationFilterGroup = VStringFacet({
45
+ search,
46
+ buckets: facets.location || [],
47
+ name: 'Location'
48
+ });
49
+ customFilterGroups.push(locationFilterGroup);
50
+ }
51
+ if (facets.initiated_by) {
52
+ const initiatedByFilterGroup = VUserFacet({
53
+ buckets: facets.initiated_by || [],
54
+ name: 'User'
55
+ });
56
+ customFilterGroups.push(initiatedByFilterGroup);
57
+ }
58
+ if (facets.start) {
59
+ customFilterGroups.push({
60
+ name: 'start',
61
+ placeholder: 'Date after',
62
+ type: 'date',
63
+ options: []
64
+ });
65
+ }
66
+ if (facets.end) {
67
+ customFilterGroups.push({
68
+ name: 'end',
69
+ placeholder: 'Date before',
70
+ type: 'date',
71
+ options: []
72
+ });
73
+ }
74
+ // if (facets.tags) {
75
+ // customFilterGroups.push({
76
+ // name: 'Tags',
77
+ // type: 'text',
78
+ // options: facets.tags.map((tag: string) => ({
79
+ // label: tag,
80
+ // value: tag
81
+ // }))
82
+ // });
83
+ // }
84
+ const handleFilterChange = (value) => {
85
+ const newFilters = typeof value === 'function' ? value(filters) : value;
86
+ if (newFilters.length === 0) {
87
+ search.clearFilters();
88
+ setFilters([]);
89
+ return;
90
+ }
91
+ setFilters(newFilters);
92
+ newFilters.forEach(filter => {
93
+ if (filter.value && filter.value.length > 0) {
94
+ const filterName = filter.name.toLowerCase();
95
+ const filterValue = filter.value[0].value;
96
+ // Map filter names to the expected field names
97
+ switch (filterName) {
98
+ case 'name':
99
+ search.query.search_term = filterValue;
100
+ break;
101
+ case 'user':
102
+ search.query.initiated_by = filterValue === 'Unknown User' ? 'unknown' : filterValue;
103
+ break;
104
+ default:
105
+ search.query[filterName] = filterValue;
106
+ break;
107
+ }
108
+ }
109
+ });
110
+ search.search();
111
+ };
112
+ return (_jsx(FilterBar, { filterGroups: customFilterGroups, filters: filters, setFilters: handleFilterChange }));
113
+ }
114
+ //# sourceMappingURL=VFacetsNav.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VFacetsNav.js","sourceRoot":"","sources":["../../../../src/features/facets/VFacetsNav.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAwB,SAAS,EAAe,MAAM,mBAAmB,CAAC;AACjF,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,O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U,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC;QACxE,IAAI,UAAU,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;YAC1B,MAAM,CAAC,YAAY,EAAE,CAAC;YACtB,UAAU,CAAC,EAAE,CAAC,CAAC;YACf,OAAO;QACX,CAAC;QACD,UAAU,CAAC,UAAU,CAAC,CAAC;QAEvB,UAAU,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE;YACxB,IAAI,MAAM,CAAC,KAAK,IAAI,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;gBAC1C,MAAM,UAAU,GAAG,MAAM,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC;gBAC7C,MAAM,WAAW,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC;gBAE1C,+CAA+C;gBAC/C,QAAQ,UAAU,EAAE,CAAC;oBACjB,KAAK,MAAM;wBACP,MAAM,CAAC,KAAK,CAAC,WAAW,GAAG,WAAW,CAAC;wBACvC,MAAM;oBACV,KAAK,MAAM;wBACP,MAAM,CAAC,KAAK,CAAC,YAAY,GAAG,WAAW,KAAK,cAAc,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,WAAW,CAAC;wBACrF,MAAM;oBACV;wBACK,MAAM,CAAC,KAAa,CAAC,UAAU,CAAC,GAAG,WAAW,CAAC;wBAChD,MAAM;gBACd,CAAC;YACL,CAAC;QACL,CAAC,CAAC,CAAC;QAEH,MAAM,CAAC,MAAM,EAAE,CAAC;IACpB,CAAC,CAAC;IAEF,OAAO,CACH,KAAC,SAAS,IACN,YAAY,EAAE,kBAAkB,EAChC,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,kBAAkB,GAChC,CACL,CAAA;AACL,CAAC"}
@@ -0,0 +1,17 @@
1
+ import { facetOptionLabel } from './utils';
2
+ export function createStringFilterGroup({ buckets, name }) {
3
+ const options = buckets.map((bucket) => ({
4
+ label: facetOptionLabel(bucket),
5
+ value: bucket._id
6
+ }));
7
+ const filterGroup = {
8
+ name: name.charAt(0).toUpperCase() + name.slice(1),
9
+ options: options,
10
+ type: "select"
11
+ };
12
+ return filterGroup;
13
+ }
14
+ export function VStringFacet({ buckets, name, }) {
15
+ return createStringFilterGroup({ buckets, name });
16
+ }
17
+ //# sourceMappingURL=VStringFacet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VStringFacet.js","sourceRoot":"","sources":["../../../../src/features/facets/VStringFacet.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAS3C,MAAM,UAAU,uBAAuB,CAAC,EAAE,OAAO,EAAE,IAAI,EAAoB;IACvE,MAAM,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;QACrC,KAAK,EAAE,gBAAgB,CAAC,MAAM,CAAC;QAC/B,KAAK,EAAE,MAAM,CAAC,GAAG;KACpB,CAAC,CAAC,CAAC;IAEJ,MAAM,WAAW,GAAgB;QAC7B,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;QAClD,OAAO,EAAE,OAAO;QAChB,IAAI,EAAE,QAAQ;KAEjB,CAAC;IAEF,OAAO,WAAW,CAAC;AACvB,CAAC;AAED,MAAM,UAAU,YAAY,CAAC,EAAE,OAAO,EAAE,IAAI,GAM3C;IACG,OAAO,uBAAuB,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;AACtD,CAAC"}
@@ -0,0 +1,56 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ export function VTypeFacet({ buckets, typeRegistry }) {
3
+ // Create a map for quick lookups of type names and counts
4
+ const typeDataMap = new Map();
5
+ buckets.forEach((bucket) => {
6
+ let name;
7
+ let typeId = bucket._id;
8
+ if (bucket._id == null) {
9
+ typeId = "Document";
10
+ name = "Document";
11
+ }
12
+ else {
13
+ name = typeRegistry.getTypeName(bucket._id);
14
+ if (!name) {
15
+ console.warn("Content Object Type not found", bucket._id);
16
+ name = bucket._id;
17
+ }
18
+ }
19
+ typeDataMap.set(typeId, {
20
+ name,
21
+ count: bucket.count
22
+ });
23
+ });
24
+ // Create options with just raw values
25
+ const options = buckets.map((bucket) => {
26
+ const typeId = bucket._id || "Document";
27
+ return {
28
+ value: typeId,
29
+ // Store count as simple fallback label
30
+ label: `(${bucket.count})`
31
+ };
32
+ });
33
+ const customFilterGroups = {
34
+ name: 'Type',
35
+ type: 'select',
36
+ options: options,
37
+ labelRenderer: (typeId) => {
38
+ const typeData = typeDataMap.get(typeId);
39
+ if (!typeData) {
40
+ console.warn(`Type data not found for ${typeId}`);
41
+ return typeId;
42
+ }
43
+ return (_jsxs("div", { className: "w-full flex items-center", children: [_jsx("span", { className: "text-sm truncate", children: typeData.name }), _jsxs("span", { className: "ml-2 text-xs", children: ["(", typeData.count, ")"] })] }));
44
+ },
45
+ filterBy: (optionValue, searchText) => {
46
+ const typeData = typeDataMap.get(optionValue);
47
+ if (!typeData) {
48
+ console.warn(`Type name not found for ${optionValue}`);
49
+ return false;
50
+ }
51
+ return typeData.name.toLowerCase().includes(searchText.toLowerCase());
52
+ }
53
+ };
54
+ return customFilterGroups;
55
+ }
56
+ //# sourceMappingURL=VTypeFacet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VTypeFacet.js","sourceRoot":"","sources":["../../../../src/features/facets/VTypeFacet.tsx"],"names":[],"mappings":";AAQA,MAAM,UAAU,UAAU,CAAC,EAAE,OAAO,EAAE,YAAY,EAAmB;IACjE,0DAA0D;IAC1D,MAAM,WAAW,GAAG,IAAI,GAAG,EAAE,CAAC;IAC9B,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,EAAE;QACvB,IAAI,IAAI,CAAC;QACT,IAA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C,eAAM,SAAS,EAAC,kBAAkB,YAAE,QAAQ,CAAC,IAAI,GAAQ,EACzD,gBAAM,SAAS,EAAC,cAAc,kBAAG,QAAQ,CAAC,KAAK,SAAS,IACtD,CACT,CAAC;QACN,CAAC;QACD,QAAQ,EAAE,CAAC,WAAmB,EAAE,UAAkB,EAAE,EAAE;YAClD,MAAM,QAAQ,GAAG,WAAW,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC;YAC9C,IAAI,CAAC,QAAQ,EAAE,CAAC;gBACZ,OAAO,CAAC,IAAI,CAAC,2BAA2B,WAAW,EAAE,CAAC,CAAC;gBACvD,OAAO,KAAK,CAAC;YACjB,CAAC;YACD,OAAO,QAAQ,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,QAAQ,CAAC,UAAU,CAAC,WAAW,EAAE,CAAC,CAAC;QAC1E,CAAC;KACJ,CAAC;IAEF,OAAO,kBAAkB,CAAC;AAC9B,CAAC"}
@@ -0,0 +1,31 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { UserInfo } from '../user/UserInfo';
3
+ export function createUserFilterGroup({ buckets, name }) {
4
+ const options = buckets.map((bucket) => {
5
+ return {
6
+ value: bucket._id,
7
+ // Store the count for use in labelRenderer
8
+ label: `(${bucket.count})`
9
+ };
10
+ });
11
+ const filterGroup = {
12
+ name: name.charAt(0).toUpperCase() + name.slice(1), // Capitalize first letter
13
+ options: options,
14
+ labelRenderer: (userRef) => {
15
+ const isUnknownUser = userRef === 'Unknown User' || !userRef;
16
+ if (isUnknownUser) {
17
+ // Find the count for this user from buckets
18
+ const bucket = buckets.find(b => b._id === userRef);
19
+ return `Unknown User (${bucket?.count || 0})`;
20
+ }
21
+ // For known users, render UserInfo with count
22
+ const bucket = buckets.find(b => b._id === userRef);
23
+ return (_jsxs("div", { className: "flex items-center justify-between w-full", children: [_jsx(UserInfo, { userRef: userRef, showTitle: true, size: "sm" }), _jsxs("span", { className: "text-muted-foreground ml-2", children: ["(", bucket?.count || 0, ")"] })] }));
24
+ }
25
+ };
26
+ return filterGroup;
27
+ }
28
+ export function VUserFacet({ buckets, name }) {
29
+ return createUserFilterGroup({ buckets, name });
30
+ }
31
+ //# sourceMappingURL=VUserFacet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VUserFacet.js","sourceRoot":"","sources":["../../../../src/features/facets/VUserFacet.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAO5C,MAAM,UAAU,qBAAqB,CAAC,EAAE,OAAO,EAAE,IAAI,EAAkB;IACnE,MAAM,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE;QACnC,OAAO;YACH,KAAK,EAAE,MAAM,CAAC,GAAG;YACjB,2CAA2C;YAC3C,KAAK,EAAE,IAAI,MAAM,CAAC,KAAK,GAAG;SAC7B,CAAC;IACN,CAAC,CAAC,CAAC;IAEH,MAAM,WAAW,GAAgB;QAC7B,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,0BAA0B;QAC9E,OAAO,EAAE,OAAO;QAChB,aAAa,EAAE,CAAC,OAAe,EAAE,EAAE;YAC/B,MAAM,aAAa,GAAG,OAAO,KAAK,cAAc,IAAI,CAAC,OAAO,CAAC;YAE7D,IAAI,aAAa,EAAE,CAAC;gBAChB,4CAA4C;gBAC5C,MAAM,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,KAAK,OAAO,CAAC,CAAC;gBACpD,OAAO,iBAAiB,MAAM,EAAE,KAAK,IAAI,CAAC,GAAG,CAAC;YAClD,CAAC;YAED,8CAA8C;YAC9C,MAAM,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,KAAK,OAAO,CAAC,CAAC;YACpD,OAAO,CACH,eAAK,SAAS,EAAC,0CAA0C,aACrD,KAAC,QAAQ,IAAC,OAAO,EAAE,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,EAAC,IAAI,GAAG,EACzD,gBAAM,SAAS,EAAC,4BAA4B,kBAAG,MAAM,EAAE,KAAK,IAAI,CAAC,SAAS,IACxE,CACT,CAAC;QACN,CAAC;KACJ,CAAC;IAEF,OAAO,WAAW,CAAC;AACvB,CAAC;AAED,MAAM,UAAU,UAAU,CAAC,EAAE,OAAO,EAAE,IAAI,EAAkB;IACxD,OAAO,qBAAqB,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;AACpD,CAAC"}
@@ -0,0 +1,12 @@
1
+ export { EnvironmentFacet } from "./EnvironmentFacet";
2
+ export * from "./FacetsNav";
3
+ export { InteractionFacet } from "./InteractionFacet";
4
+ export { StringFacet } from "./StringFacet";
5
+ export { StringListFacet } from "./StringListFacet";
6
+ export { TypeFacet } from "./TypeFacet";
7
+ export { UserFacet } from "./UserFacet";
8
+ export * from "./VFacetsNav";
9
+ export { VStringFacet } from "./VStringFacet";
10
+ export { VTypeFacet } from "./VTypeFacet";
11
+ export { VUserFacet } from "./VUserFacet";
12
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/features/facets/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,cAAc,aAAa,CAAC;AAC5B,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,cAAc,cAAc,CAAC;AAC7B,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC"}
@@ -0,0 +1,7 @@
1
+ export function facetOptionLabel(bucket) {
2
+ return `${bucket._id} (${bucket.count})`;
3
+ }
4
+ export function facetOptionNameLabel(bucket) {
5
+ return `${bucket.name} (${bucket.count})`;
6
+ }
7
+ //# sourceMappingURL=utils.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../../src/features/facets/utils.tsx"],"names":[],"mappings":"AAEA,MAAM,UAAU,gBAAgB,CAAC,MAAmB;IAChD,OAAO,GAAG,MAAM,CAAC,GAAG,KAAK,MAAM,CAAC,KAAK,GAAG,CAAC;AAC7C,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,MAAuB;IACxD,OAAO,GAAG,MAAM,CAAC,IAAI,KAAK,MAAM,CAAC,KAAK,GAAG,CAAC;AAC9C,CAAC"}
@@ -1,3 +1,11 @@
1
- export * from "./permissions/index.js";
2
1
  export * from "./activity-doc/index.js";
2
+ export * from "./agent";
3
+ export * from "./errors/index.js";
4
+ export * from "./facets/index.js";
5
+ export * from "./layout/index.js";
6
+ export * from "./magic-pdf/index.js";
7
+ export * from "./permissions/index.js";
8
+ export * from "./store/index.js";
9
+ export * from "./user/index.js";
10
+ export * from "./utils/index.js";
3
11
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/features/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,yBAAyB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/features/index.ts"],"names":[],"mappings":"AAAA,cAAc,yBAAyB,CAAC;AACxC,cAAc,SAAS,CAAC;AACxB,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,wBAAwB,CAAC;AACvC,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC"}
@@ -0,0 +1,11 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import clsx from 'clsx';
3
+ import { ChevronRight, Info } from 'lucide-react';
4
+ import { VTooltip } from '@vertesia/ui/core';
5
+ export function GenericPageNavHeader({ className, children, title, description, actions, breadcrumbs, isCompact = false }) {
6
+ return (_jsxs("div", { className: clsx(isCompact ? 'pb-0' : 'pb-2', 'p-4 flex flex-col', className), children: [_jsxs("div", { className: 'flex items-start gap-4', children: [_jsxs("div", { className: "w-full flex place-content-between h-auto min-h-8 flex-col items-start", children: [_jsx("nav", { className: "flex-1 flex justify-start text-xs", children: breadcrumbs?.map((breadcrumb, index) => {
7
+ return (_jsxs("div", { className: "flex items-center text-muted", children: [breadcrumb, index < breadcrumbs.length - 1 && _jsx(ChevronRight, { className: "w-3.5 h-3.5" })] }, index));
8
+ }) }), _jsxs("div", { className: 'flex gap-2 items-center', children: [_jsx("h1", { className: "text-xl font-semibold break-all", children: title }), description &&
9
+ _jsx(VTooltip, { description: description, children: _jsx(Info, { className: "size-4 text-muted" }) })] })] }), _jsx("div", { className: "flex gap-x-4 shrink-0", children: actions })] }), children && _jsx("div", { className: "w-full flex items-center", children: children })] }));
10
+ }
11
+ //# sourceMappingURL=GenericPageNavHeader.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GenericPageNavHeader.js","sourceRoot":"","sources":["../../../../src/features/layout/GenericPageNavHeader.tsx"],"names":[],"mappings":";AAAA,OAAO,IAAI,MAAM,MAAM,CAAC;AAGxB,OAAO,EAAE,YAAY,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAClD,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAY7C,MAAM,UAAU,oBAAoB,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,KAAK,EAAE,WAAW,EAAE,OAAO,EAAE,WAAW,EAAE,SAAS,GAAG,KAAK,EAA6B;IAChJ,OAAO,CACH,eAAK,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,mBAAmB,EAAE,SAAS,CAAC,aAC7E,eAAK,SAAS,EAAC,wBAAwB,aACnC,eAAK,SAAS,EAAC,uEAAuE,aAClF,cAAK,SAAS,EAAC,mCAAmC,YAC7C,WAAW,EAAE,GAAG,CAAC,CAAC,UAAU,EAAE,KAAK,EAAE,EAAE;oCACpC,OAAO,CACH,eAAK,SAAS,EAAC,8BAA8B,aACxC,UAAU,EACV,KAAK,GAAG,WAAW,CAAC,MAAM,GAAG,CAAC,IAAI,KAAC,YAAY,IAAC,SAAS,EAAC,aAAa,GAAG,KAF5B,KAAK,CAGlD,CACT,CAAA;gCACL,CAAC,CAAC,GACA,EACN,eAAK,SAAS,EAAC,yBAAyB,aACpC,aAAI,SAAS,EAAC,iCAAiC,YAAE,KAAK,GAAM,EAExD,WAAW;wCACX,KAAC,QAAQ,IACL,WAAW,EAAE,WAAW,YACxB,KAAC,IAAI,IAAC,SAAS,EAAC,mBAAmB,GAAG,GAC/B,IAEb,IACJ,EACN,cAAK,SAAS,EAAC,uBAAuB,YAAE,OAAO,GAAO,IACpD,EACL,QAAQ,IAAI,cAAK,SAAS,EAAC,0BAA0B,YAAE,QAAQ,GAAO,IACrE,CACT,CAAA;AACL,CAAC"}
@@ -0,0 +1,5 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ export function NotFoundView({}) {
3
+ return (_jsxs("div", { className: "text-center pt-32", children: [_jsx("h1", { className: "text-3xl font-bold text-red-500", children: "404" }), _jsx("p", { className: "text-2xl", children: "Page Not Found" })] }));
4
+ }
5
+ //# sourceMappingURL=NotFoundView.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotFoundView.js","sourceRoot":"","sources":["../../../../src/features/layout/NotFoundView.tsx"],"names":[],"mappings":";AAGA,MAAM,UAAU,YAAY,CAAC,EAAsB;IAC/C,OAAO,CACH,eAAK,SAAS,EAAC,mBAAmB,aAC9B,aAAI,SAAS,EAAC,iCAAiC,oBAAS,EACxD,YAAG,SAAS,EAAC,UAAU,+BAAmB,IACxC,CACT,CAAA;AACL,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from "./GenericPageNavHeader";
2
+ export * from "./NotFoundView";
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/features/layout/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,gBAAgB,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useUserSession } from "@vertesia/ui/session";
3
+ import { Popover } from "@vertesia/ui/widgets";
4
+ import { CloudDownload } from "lucide-react";
5
+ import { getResourceUrl } from "./PdfPageProvider";
6
+ export function DownloadPopover({ object }) {
7
+ const { client } = useUserSession();
8
+ const onDownload = (name) => {
9
+ getResourceUrl(client, object.id, name).then(url => window.open(url, '_blank'));
10
+ };
11
+ return (_jsx("div", { className: "absolute bottom-[58px] right-[20px] w-[36px] h-[36px] cursor-pointer text-indigo-400 border-indigo-400 hover:border-indigo-500 hover:text-indigo-500 border-2 rounded-full shadow-xs flex items-center justify-center", children: _jsxs(Popover, { strategy: 'absolute', placement: 'top-end', zIndex: 100, offset: 20, children: [_jsx(Popover.Trigger, { click: true, children: _jsx(CloudDownload, { className: 'size-6' }) }), _jsx(Popover.Content, { children: _jsxs("div", { className: "rounded-md shadow-md border border-gray-100 bg-white dark:bg-slate-50 dark:border-slate-100 min-w-[200px] flex flex-col divide-y", children: [_jsx("button", { className: "p-2 cursor-pointer hover:bg-slate-50 dark:hover:bg-slate-100", onClick: () => onDownload("annotated.pdf"), children: "annotated.pdf" }), _jsx("button", { className: "p-2 cursor-pointer hover:bg-slate-50 dark:hover:bg-slate-100", onClick: () => onDownload("document.xml"), children: "document.xml" }), _jsx("button", { className: "p-2 cursor-pointer hover:bg-slate-50 dark:hover:bg-slate-100", onClick: () => onDownload("analyzed-pages.json"), children: "analyzed-pages.json" })] }) })] }) }));
12
+ }
13
+ //# sourceMappingURL=DownloadPopover.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DownloadPopover.js","sourceRoot":"","sources":["../../../../src/features/magic-pdf/DownloadPopover.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAKnD,MAAM,UAAU,eAAe,CAAC,EAAE,MAAM,EAAwB;IAC5D,MAAM,EAAE,MAAM,EAAE,GAAG,cAAc,EAAE,CAAA;IACnC,MAAM,UAAU,GAAG,CAAC,IAAY,EAAE,EAAE;QAChC,cAAc,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC,CAAC;IACpF,CAAC,CAAA;IACD,OAAO,CACH,cAAK,SAAS,EAAC,uNAAuN,YAClO,MAAC,OAAO,IAAC,QAAQ,EAAC,UAAU,EAAC,SAAS,EAAC,SAAS,EAAC,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,EAAE,aACpE,KAAC,OAAO,CAAC,OAAO,IAAC,KAAK,kBAClB,KAAC,aAAa,IAAC,SAAS,EAAC,QAAQ,GAAG,GAEtB,EAClB,KAAC,OAAO,CAAC,OAAO,cACZ,eAAK,SAAS,EAAC,kIAAkI,aAC7I,iBAAQ,SAAS,EAAC,8DAA8D,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,eAAe,CAAC,8BAAwB,EACnJ,iBAAQ,SAAS,EAAC,8DAA8D,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,cAAc,CAAC,6BAAuB,EACjJ,iBAAQ,SAAS,EAAC,8DAA8D,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,qBAAqB,CAAC,oCAA8B,IAC7J,GACQ,IACZ,GACR,CACT,CAAA;AACL,CAAC"}
@@ -0,0 +1,44 @@
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
+ import { ErrorBox, useFetch } from "@vertesia/ui/core";
3
+ import { useUserSession } from "@vertesia/ui/session";
4
+ import { X } from "lucide-react";
5
+ import { useRef, useState } from "react";
6
+ import { DownloadPopover } from "./DownloadPopover";
7
+ import { PageSlider } from "./PageSlider";
8
+ import { PdfPageProvider } from "./PdfPageProvider";
9
+ import { TextPageView } from "./TextPageView";
10
+ import { useResizeEW } from "./useResizeOnDrag";
11
+ export function MagicPdfView({ objectId, onClose }) {
12
+ const { client } = useUserSession();
13
+ const { data: object, error } = useFetch(() => client.store.objects.retrieve(objectId, "+text"), [objectId]);
14
+ if (error) {
15
+ return _jsx(ErrorBox, { title: 'Fetching document failed', children: error.message });
16
+ }
17
+ return object ? (_jsx("div", { className: 'fixed inset-0 bg-white dark:bg-slate-700 z-50 flex items-center justify-center', children: _jsx(PdfPageProvider, { object: object, children: _jsx(MagicPdfViewImpl, { object: object, onClose: onClose }) }) })) : "Loading...";
18
+ }
19
+ function MagicPdfViewImpl({ object, onClose }) {
20
+ const [viewType, setViewType] = useState("xml");
21
+ const [pageNumber, setPageNumber] = useState(1);
22
+ const handler = useRef(null);
23
+ const left = useRef(null);
24
+ const right = useRef(null);
25
+ useResizeEW({
26
+ handler, left, right
27
+ });
28
+ return (_jsxs(_Fragment, { children: [_jsxs("div", { ref: left, className: `absolute top-0 left-0 bottom-0 w-[50%] bg-gray-100 dark:bg-slate-800 flex items-stretch justify-stretch py-2`, children: [_jsx(PageSlider, { className: "flex-1", currentPage: pageNumber, onChange: setPageNumber }), _jsx("div", { ref: handler, className: 'w-[2px] p-[2px] m-0 bg-slate-300 cursor-ew-resize' })] }), _jsx("div", { ref: right, className: `absolute top-0 left-[50%] right-0 bottom-0 flex items-stretch justify-stretch overflow-auto p-2`, children: _jsx(TextPageView, { pageNumber: pageNumber, viewType: viewType }) }), _jsx(DownloadPopover, { object: object }), _jsx(ContentSwitcher, { type: viewType, onSwitch: setViewType }), !!onClose &&
29
+ _jsx("div", { className: "absolute top-6 right-7 w-9 h-9 cursor-pointer text-red-400 border-red-400 hover:border-red-500 hover:text-red-500 border-2 rounded-full shadow-xs flex items-center justify-center", onClick: onClose, children: _jsx(X, { className: 'size-6' }) })] }));
30
+ }
31
+ function ContentSwitcher({ type = "xml", onSwitch }) {
32
+ const _onSwitch = () => {
33
+ if (type === "xml") {
34
+ onSwitch("json");
35
+ }
36
+ else if (type === "json") {
37
+ onSwitch("xml");
38
+ }
39
+ };
40
+ return (_jsxs("div", { className: "absolute bottom-[16px] right-[20px] w-[36px] h-[36px] cursor-pointer text-indigo-400 border-indigo-400 hover:border-indigo-500 hover:text-indigo-500 border-2 rounded-full shadow-xs flex items-center justify-center", onClick: _onSwitch, children: [type === "xml" && JSON, type === "json" && XML] }));
41
+ }
42
+ const JSON = _jsx("svg", { width: "16px", height: "16px", viewBox: "0 0 16 16", xmlns: "http://www.w3.org/2000/svg", fill: "currentColor", children: _jsx("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M6 2.984V2h-.09c-.313 0-.616.062-.909.185a2.33 2.33 0 0 0-.775.53 2.23 2.23 0 0 0-.493.753v.001a3.542 3.542 0 0 0-.198.83v.002a6.08 6.08 0 0 0-.024.863c.012.29.018.58.018.869 0 .203-.04.393-.117.572v.001a1.504 1.504 0 0 1-.765.787 1.376 1.376 0 0 1-.558.115H2v.984h.09c.195 0 .38.04.556.121l.001.001c.178.078.329.184.455.318l.002.002c.13.13.233.285.307.465l.001.002c.078.18.117.368.117.566 0 .29-.006.58-.018.869-.012.296-.004.585.024.87v.001c.033.283.099.558.197.824v.001c.106.273.271.524.494.753.223.23.482.407.775.53.293.123.596.185.91.185H6v-.984h-.09c-.2 0-.387-.038-.563-.115a1.613 1.613 0 0 1-.457-.32 1.659 1.659 0 0 1-.309-.467c-.074-.18-.11-.37-.11-.573 0-.228.003-.453.011-.672.008-.228.008-.45 0-.665a4.639 4.639 0 0 0-.055-.64 2.682 2.682 0 0 0-.168-.609A2.284 2.284 0 0 0 3.522 8a2.284 2.284 0 0 0 .738-.955c.08-.192.135-.393.168-.602.033-.21.051-.423.055-.64.008-.22.008-.442 0-.666-.008-.224-.012-.45-.012-.678a1.47 1.47 0 0 1 .877-1.354 1.33 1.33 0 0 1 .563-.121H6zm4 10.032V14h.09c.313 0 .616-.062.909-.185.293-.123.552-.3.775-.53.223-.23.388-.48.493-.753v-.001c.1-.266.165-.543.198-.83v-.002c.028-.28.036-.567.024-.863-.012-.29-.018-.58-.018-.869 0-.203.04-.393.117-.572v-.001a1.502 1.502 0 0 1 .765-.787 1.38 1.38 0 0 1 .558-.115H14v-.984h-.09c-.196 0-.381-.04-.557-.121l-.001-.001a1.376 1.376 0 0 1-.455-.318l-.002-.002a1.415 1.415 0 0 1-.307-.465v-.002a1.405 1.405 0 0 1-.118-.566c0-.29.006-.58.018-.869a6.174 6.174 0 0 0-.024-.87v-.001a3.537 3.537 0 0 0-.197-.824v-.001a2.23 2.23 0 0 0-.494-.753 2.331 2.331 0 0 0-.775-.53 2.325 2.325 0 0 0-.91-.185H10v.984h.09c.2 0 .387.038.562.115.174.082.326.188.457.32.127.134.23.29.309.467.074.18.11.37.11.573 0 .228-.003.452-.011.672-.008.228-.008.45 0 .665.004.222.022.435.055.64.033.214.089.416.168.609a2.285 2.285 0 0 0 .738.955 2.285 2.285 0 0 0-.738.955 2.689 2.689 0 0 0-.168.602c-.033.21-.051.423-.055.64a9.15 9.15 0 0 0 0 .666c.008.224.012.45.012.678a1.471 1.471 0 0 1-.877 1.354 1.33 1.33 0 0 1-.563.121H10z" }) });
43
+ const XML = _jsx("svg", { width: "16px", height: "16px", viewBox: "0 0 16 16", xmlns: "http://www.w3.org/2000/svg", fill: "currentColor", children: _jsx("path", { d: "M4.708 5.578L2.061 8.224l2.647 2.646-.708.708-3-3V7.87l3-3 .708.708zm7-.708L11 5.578l2.647 2.646L11 10.87l.708.708 3-3V7.87l-3-3zM4.908 13l.894.448 5-10L9.908 3l-5 10z" }) });
44
+ //# sourceMappingURL=MagicPdfView.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MagicPdfView.js","sourceRoot":"","sources":["../../../../src/features/magic-pdf/MagicPdfView.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,CAAC,EAAE,MAAM,cAAc,CAAC;AACjC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACzC,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAOhD,MAAM,UAAU,YAAY,CAAC,EAAE,QAAQ,EAAE,OAAO,EAAqB;IACjE,MAAM,EAAE,MAAM,EAAE,GAAG,cAAc,EAAE,CAAC;IAEpC,MAAM,EAAE,IA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EAAC,WAAW,EAAC,KAAK,EAAC,4BAA4B,EAAC,IAAI,EAAC,cAAc,YAClH,eAAM,CAAC,EAAC,yKAAyK,GAAG,GAClL,CAAA"}
@@ -0,0 +1,57 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { Center } from "@vertesia/ui/core";
3
+ import clsx from "clsx";
4
+ import { AtSignIcon, ChevronsDown, ChevronsUp, ImageIcon, InfoIcon } from "lucide-react";
5
+ import { useRef, useState } from "react";
6
+ import { usePdfPagesInfo } from "./PdfPageProvider";
7
+ var ImageType;
8
+ (function (ImageType) {
9
+ ImageType[ImageType["default"] = 0] = "default";
10
+ ImageType[ImageType["instrumented"] = 1] = "instrumented";
11
+ ImageType[ImageType["annotated"] = 2] = "annotated";
12
+ })(ImageType || (ImageType = {}));
13
+ export function PageSlider({ className, currentPage, onChange }) {
14
+ const [imageType, setImageType] = useState(ImageType.default);
15
+ const ref = useRef(null);
16
+ const { urls, annotatedUrls, instrumentedUrls } = usePdfPagesInfo();
17
+ const goPrev = () => {
18
+ if (currentPage > 1) {
19
+ onChange(currentPage - 1);
20
+ if (ref.current) {
21
+ ref.current.querySelector(`div[data-index="${currentPage - 1}"]`)?.scrollIntoView({
22
+ behavior: 'smooth',
23
+ block: 'end',
24
+ inline: 'center'
25
+ });
26
+ }
27
+ }
28
+ };
29
+ const goNext = () => {
30
+ if (currentPage < urls.length) {
31
+ onChange(currentPage + 1);
32
+ if (ref.current) {
33
+ ref.current.querySelector(`div[data-index="${currentPage + 1}"]`)?.scrollIntoView({
34
+ behavior: 'smooth',
35
+ block: 'end',
36
+ inline: 'center'
37
+ });
38
+ }
39
+ }
40
+ };
41
+ const actualUrls = imageType === ImageType.instrumented ? instrumentedUrls :
42
+ (imageType === ImageType.annotated ? annotatedUrls : urls);
43
+ return (_jsxs("div", { ref: ref, className: clsx('flex flex-col items-stretch gap-y-2', className), children: [_jsxs("div", { className: "flex h-5 items-center justify-center relative", children: [_jsx("button", { className: BTN_CLASS, onClick: goPrev, children: _jsx(ChevronsUp, { className: 'w-5 h-5' }) }), _jsxs("div", { className: "absolute right-3 flex gap-x-1", children: [_jsx("button", { className: getRadioButtonClass(ImageType.default, imageType), onClick: () => setImageType(ImageType.default), children: _jsx(ImageIcon, { className: "w-5 h-5 mt-1" }) }), _jsx("button", { className: getRadioButtonClass(ImageType.instrumented, imageType), onClick: () => setImageType(ImageType.instrumented), children: _jsx(InfoIcon, { className: "w-5 h-5 mt-1" }) }), _jsx("button", { className: getRadioButtonClass(ImageType.annotated, imageType), onClick: () => setImageType(ImageType.annotated), children: _jsx(AtSignIcon, { className: "w-5 h-5 mt-1" }) })] })] }), _jsx("div", { className: 'flex flex-col items-center gap-2 flex-1 overflow-y-auto px-2', children: actualUrls.map((url, index) => _jsx(PageThumbnail, { url: url, currentPage: currentPage, pageNumber: index + 1, onSelect: () => onChange(index + 1) }, index)) }), _jsx("div", { className: "flex h-5 items-center justify-center relative", children: _jsx("button", { className: BTN_CLASS, onClick: goNext, children: _jsx(ChevronsDown, { className: 'size-5' }) }) })] }));
44
+ }
45
+ function PageThumbnail({ url, pageNumber, currentPage, onSelect }) {
46
+ return (_jsxs("div", { className: "p-2 hover:bg-gray-200 dark:hover:bg-slate-600 rounded-md", "data-index": pageNumber - 1, children: [_jsx("div", { className: clsx('relative border-[2px] cursor-pointer', pageNumber === currentPage ? "border-blue-500 dark:border-pink-400" : "border-gray-300"), onClick: onSelect, children: _jsx("img", { src: url, alt: `Page ${pageNumber}` }) }), _jsx(Center, { className: "text-sm text-gray-500 dark:text-gray-400 pt-1 font-semibold align", children: pageNumber })] }));
47
+ }
48
+ const BTN_CLASS = "cursor-pointer text-gray-500 dark:text-gray-400 hover:text-blue-600 dark:hover:text-blue-500 hover:font-semibold";
49
+ function getRadioButtonClass(type, currentType) {
50
+ if (type === currentType) {
51
+ return '${BTN_CLASS} text-pink-600';
52
+ }
53
+ else {
54
+ return `${BTN_CLASS}`;
55
+ }
56
+ }
57
+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