@memberjunction/ng-conversations 6.2.2 → 6.3.0-edge.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (252) hide show
  1. package/README.md +49 -24
  2. package/dist/assets/edge-ai.worker.js +32515 -0
  3. package/dist/lib/components/artifact/artifact-share-modal.component.d.ts +39 -6
  4. package/dist/lib/components/artifact/artifact-share-modal.component.d.ts.map +1 -1
  5. package/dist/lib/components/artifact/artifact-share-modal.component.js +620 -74
  6. package/dist/lib/components/artifact/artifact-share-modal.component.js.map +1 -1
  7. package/dist/lib/components/collection/artifact-create-modal.component.js +4 -4
  8. package/dist/lib/components/collection/artifact-create-modal.component.js.map +1 -1
  9. package/dist/lib/components/collection/collection-form-modal.component.js +3 -3
  10. package/dist/lib/components/collection/collection-form-modal.component.js.map +1 -1
  11. package/dist/lib/components/collection/collection-tree.component.d.ts.map +1 -1
  12. package/dist/lib/components/collection/collection-tree.component.js +19 -18
  13. package/dist/lib/components/collection/collection-tree.component.js.map +1 -1
  14. package/dist/lib/components/collection/collection-view.component.d.ts +6 -4
  15. package/dist/lib/components/collection/collection-view.component.d.ts.map +1 -1
  16. package/dist/lib/components/collection/collection-view.component.js +35 -17
  17. package/dist/lib/components/collection/collection-view.component.js.map +1 -1
  18. package/dist/lib/components/collection/collections-full-view.component.d.ts +1 -0
  19. package/dist/lib/components/collection/collections-full-view.component.d.ts.map +1 -1
  20. package/dist/lib/components/collection/collections-full-view.component.js +109 -107
  21. package/dist/lib/components/collection/collections-full-view.component.js.map +1 -1
  22. package/dist/lib/components/conversation/conversation-chat-area.component.d.ts +76 -11
  23. package/dist/lib/components/conversation/conversation-chat-area.component.d.ts.map +1 -1
  24. package/dist/lib/components/conversation/conversation-chat-area.component.js +236 -50
  25. package/dist/lib/components/conversation/conversation-chat-area.component.js.map +1 -1
  26. package/dist/lib/components/conversation/conversation-list.component.d.ts +49 -1
  27. package/dist/lib/components/conversation/conversation-list.component.d.ts.map +1 -1
  28. package/dist/lib/components/conversation/conversation-list.component.js +151 -41
  29. package/dist/lib/components/conversation/conversation-list.component.js.map +1 -1
  30. package/dist/lib/components/conversation/conversation-remote-browser-controller.d.ts +11 -3
  31. package/dist/lib/components/conversation/conversation-remote-browser-controller.d.ts.map +1 -1
  32. package/dist/lib/components/conversation/conversation-remote-browser-controller.js +40 -4
  33. package/dist/lib/components/conversation/conversation-remote-browser-controller.js.map +1 -1
  34. package/dist/lib/components/export/export-modal.component.d.ts +7 -2
  35. package/dist/lib/components/export/export-modal.component.d.ts.map +1 -1
  36. package/dist/lib/components/export/export-modal.component.js +13 -2
  37. package/dist/lib/components/export/export-modal.component.js.map +1 -1
  38. package/dist/lib/components/library/library-create-dialog.component.d.ts +136 -0
  39. package/dist/lib/components/library/library-create-dialog.component.d.ts.map +1 -0
  40. package/dist/lib/components/library/library-create-dialog.component.js +1620 -0
  41. package/dist/lib/components/library/library-create-dialog.component.js.map +1 -0
  42. package/dist/lib/components/library/library-full-view.component.d.ts +10 -4
  43. package/dist/lib/components/library/library-full-view.component.d.ts.map +1 -1
  44. package/dist/lib/components/library/library-full-view.component.js +216 -40
  45. package/dist/lib/components/library/library-full-view.component.js.map +1 -1
  46. package/dist/lib/components/library/library-remote-drive-pane.component.d.ts +97 -0
  47. package/dist/lib/components/library/library-remote-drive-pane.component.d.ts.map +1 -0
  48. package/dist/lib/components/library/library-remote-drive-pane.component.js +1229 -0
  49. package/dist/lib/components/library/library-remote-drive-pane.component.js.map +1 -0
  50. package/dist/lib/components/library/library-workspace.component.d.ts +265 -0
  51. package/dist/lib/components/library/library-workspace.component.d.ts.map +1 -0
  52. package/dist/lib/components/library/library-workspace.component.js +4420 -0
  53. package/dist/lib/components/library/library-workspace.component.js.map +1 -0
  54. package/dist/lib/components/library/library.models.d.ts +162 -0
  55. package/dist/lib/components/library/library.models.d.ts.map +1 -0
  56. package/dist/lib/components/library/library.models.js +2 -0
  57. package/dist/lib/components/library/library.models.js.map +1 -0
  58. package/dist/lib/components/message/conversation-message-rating.component.d.ts +5 -0
  59. package/dist/lib/components/message/conversation-message-rating.component.d.ts.map +1 -1
  60. package/dist/lib/components/message/conversation-message-rating.component.js +72 -16
  61. package/dist/lib/components/message/conversation-message-rating.component.js.map +1 -1
  62. package/dist/lib/components/message/message-input.component.d.ts +26 -14
  63. package/dist/lib/components/message/message-input.component.d.ts.map +1 -1
  64. package/dist/lib/components/message/message-input.component.js +91 -56
  65. package/dist/lib/components/message/message-input.component.js.map +1 -1
  66. package/dist/lib/components/message/message-item.component.d.ts +35 -1
  67. package/dist/lib/components/message/message-item.component.d.ts.map +1 -1
  68. package/dist/lib/components/message/message-item.component.js +583 -392
  69. package/dist/lib/components/message/message-item.component.js.map +1 -1
  70. package/dist/lib/components/message/message-list.component.d.ts.map +1 -1
  71. package/dist/lib/components/message/message-list.component.js +2 -0
  72. package/dist/lib/components/message/message-list.component.js.map +1 -1
  73. package/dist/lib/components/navigation/conversation-navigation.component.js +9 -9
  74. package/dist/lib/components/navigation/conversation-navigation.component.js.map +1 -1
  75. package/dist/lib/components/overlay/chat-overlay.component.d.ts +94 -6
  76. package/dist/lib/components/overlay/chat-overlay.component.d.ts.map +1 -1
  77. package/dist/lib/components/overlay/chat-overlay.component.js +249 -59
  78. package/dist/lib/components/overlay/chat-overlay.component.js.map +1 -1
  79. package/dist/lib/components/project/project-form-modal.component.d.ts +6 -0
  80. package/dist/lib/components/project/project-form-modal.component.d.ts.map +1 -1
  81. package/dist/lib/components/project/project-form-modal.component.js +81 -61
  82. package/dist/lib/components/project/project-form-modal.component.js.map +1 -1
  83. package/dist/lib/components/project/project-selector.component.d.ts +5 -0
  84. package/dist/lib/components/project/project-selector.component.d.ts.map +1 -1
  85. package/dist/lib/components/project/project-selector.component.js +11 -4
  86. package/dist/lib/components/project/project-selector.component.js.map +1 -1
  87. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-channel.d.ts +55 -0
  88. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-channel.d.ts.map +1 -0
  89. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-channel.js +944 -0
  90. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-channel.js.map +1 -0
  91. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-engine.d.ts +66 -0
  92. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-engine.d.ts.map +1 -0
  93. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-engine.js +253 -0
  94. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-engine.js.map +1 -0
  95. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-types.d.ts +80 -0
  96. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-types.d.ts.map +1 -0
  97. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-types.js +49 -0
  98. package/dist/lib/components/realtime/artifact-workspace/artifact-workspace-types.js.map +1 -0
  99. package/dist/lib/components/realtime/artifact-workspace/realtime-artifact-workspace-surface.component.d.ts +54 -0
  100. package/dist/lib/components/realtime/artifact-workspace/realtime-artifact-workspace-surface.component.d.ts.map +1 -0
  101. package/dist/lib/components/realtime/artifact-workspace/realtime-artifact-workspace-surface.component.js +386 -0
  102. package/dist/lib/components/realtime/artifact-workspace/realtime-artifact-workspace-surface.component.js.map +1 -0
  103. package/dist/lib/components/realtime/channels/client-context-channel.d.ts +20 -4
  104. package/dist/lib/components/realtime/channels/client-context-channel.d.ts.map +1 -1
  105. package/dist/lib/components/realtime/channels/client-context-channel.js +62 -8
  106. package/dist/lib/components/realtime/channels/client-context-channel.js.map +1 -1
  107. package/dist/lib/components/realtime/interactive-component/interactive-component-channel.d.ts +1 -0
  108. package/dist/lib/components/realtime/interactive-component/interactive-component-channel.d.ts.map +1 -1
  109. package/dist/lib/components/realtime/interactive-component/interactive-component-channel.js +15 -2
  110. package/dist/lib/components/realtime/interactive-component/interactive-component-channel.js.map +1 -1
  111. package/dist/lib/components/realtime/realtime-agent-banner.component.js +2 -2
  112. package/dist/lib/components/realtime/realtime-agent-banner.component.js.map +1 -1
  113. package/dist/lib/components/realtime/realtime-agent-picker.component.d.ts.map +1 -1
  114. package/dist/lib/components/realtime/realtime-agent-picker.component.js +3 -3
  115. package/dist/lib/components/realtime/realtime-agent-picker.component.js.map +1 -1
  116. package/dist/lib/components/realtime/realtime-composer.component.js +5 -3
  117. package/dist/lib/components/realtime/realtime-composer.component.js.map +1 -1
  118. package/dist/lib/components/realtime/realtime-session-overlay.component.d.ts +81 -32
  119. package/dist/lib/components/realtime/realtime-session-overlay.component.d.ts.map +1 -1
  120. package/dist/lib/components/realtime/realtime-session-overlay.component.js +506 -185
  121. package/dist/lib/components/realtime/realtime-session-overlay.component.js.map +1 -1
  122. package/dist/lib/components/realtime/realtime-session-thread.component.d.ts.map +1 -1
  123. package/dist/lib/components/realtime/realtime-session-thread.component.js +89 -4
  124. package/dist/lib/components/realtime/realtime-session-thread.component.js.map +1 -1
  125. package/dist/lib/components/realtime/realtime-surface-stage.model.d.ts.map +1 -1
  126. package/dist/lib/components/realtime/realtime-surface-stage.model.js +2 -1
  127. package/dist/lib/components/realtime/realtime-surface-stage.model.js.map +1 -1
  128. package/dist/lib/components/realtime/realtime-surface-tab-style.d.ts +4 -4
  129. package/dist/lib/components/realtime/realtime-surface-tab-style.d.ts.map +1 -1
  130. package/dist/lib/components/realtime/realtime-surface-tab-style.js +5 -5
  131. package/dist/lib/components/realtime/realtime-surface-tab-style.js.map +1 -1
  132. package/dist/lib/components/realtime/realtime-surface-tabs.model.d.ts +7 -9
  133. package/dist/lib/components/realtime/realtime-surface-tabs.model.d.ts.map +1 -1
  134. package/dist/lib/components/realtime/realtime-surface-tabs.model.js +12 -13
  135. package/dist/lib/components/realtime/realtime-surface-tabs.model.js.map +1 -1
  136. package/dist/lib/components/realtime/remote-browser/remote-browser-channel.d.ts +27 -0
  137. package/dist/lib/components/realtime/remote-browser/remote-browser-channel.d.ts.map +1 -1
  138. package/dist/lib/components/realtime/remote-browser/remote-browser-channel.js +141 -2
  139. package/dist/lib/components/realtime/remote-browser/remote-browser-channel.js.map +1 -1
  140. package/dist/lib/components/realtime/remote-browser/remote-browser-surface.component.d.ts +101 -3
  141. package/dist/lib/components/realtime/remote-browser/remote-browser-surface.component.d.ts.map +1 -1
  142. package/dist/lib/components/realtime/remote-browser/remote-browser-surface.component.js +503 -55
  143. package/dist/lib/components/realtime/remote-browser/remote-browser-surface.component.js.map +1 -1
  144. package/dist/lib/components/realtime/remote-browser/remote-browser-tools.d.ts.map +1 -1
  145. package/dist/lib/components/realtime/remote-browser/remote-browser-tools.js +2 -2
  146. package/dist/lib/components/realtime/remote-browser/remote-browser-tools.js.map +1 -1
  147. package/dist/lib/components/realtime/whiteboard/whiteboard-artifact-viewer.component.d.ts +48 -5
  148. package/dist/lib/components/realtime/whiteboard/whiteboard-artifact-viewer.component.d.ts.map +1 -1
  149. package/dist/lib/components/realtime/whiteboard/whiteboard-artifact-viewer.component.js +249 -53
  150. package/dist/lib/components/realtime/whiteboard/whiteboard-artifact-viewer.component.js.map +1 -1
  151. package/dist/lib/components/realtime/whiteboard/whiteboard-channel.d.ts.map +1 -1
  152. package/dist/lib/components/realtime/whiteboard/whiteboard-channel.js +1 -1
  153. package/dist/lib/components/realtime/whiteboard/whiteboard-channel.js.map +1 -1
  154. package/dist/lib/components/search/search-panel.component.d.ts +10 -0
  155. package/dist/lib/components/search/search-panel.component.d.ts.map +1 -1
  156. package/dist/lib/components/search/search-panel.component.js +25 -3
  157. package/dist/lib/components/search/search-panel.component.js.map +1 -1
  158. package/dist/lib/components/sidebar/conversation-sidebar.component.d.ts +28 -1
  159. package/dist/lib/components/sidebar/conversation-sidebar.component.d.ts.map +1 -1
  160. package/dist/lib/components/sidebar/conversation-sidebar.component.js +51 -6
  161. package/dist/lib/components/sidebar/conversation-sidebar.component.js.map +1 -1
  162. package/dist/lib/components/task/tasks-full-view.component.d.ts +31 -8
  163. package/dist/lib/components/task/tasks-full-view.component.d.ts.map +1 -1
  164. package/dist/lib/components/task/tasks-full-view.component.js +692 -497
  165. package/dist/lib/components/task/tasks-full-view.component.js.map +1 -1
  166. package/dist/lib/components/workspace/conversation-workspace.component.d.ts.map +1 -1
  167. package/dist/lib/components/workspace/conversation-workspace.component.js +15 -2
  168. package/dist/lib/components/workspace/conversation-workspace.component.js.map +1 -1
  169. package/dist/lib/conversations.module.d.ts +66 -61
  170. package/dist/lib/conversations.module.d.ts.map +1 -1
  171. package/dist/lib/conversations.module.js +60 -1
  172. package/dist/lib/conversations.module.js.map +1 -1
  173. package/dist/lib/events/chat-events.d.ts +45 -0
  174. package/dist/lib/events/chat-events.d.ts.map +1 -1
  175. package/dist/lib/events/chat-events.js +64 -0
  176. package/dist/lib/events/chat-events.js.map +1 -1
  177. package/dist/lib/models/agent-turn.model.d.ts +7 -1
  178. package/dist/lib/models/agent-turn.model.d.ts.map +1 -1
  179. package/dist/lib/models/agent-turn.model.js.map +1 -1
  180. package/dist/lib/services/agent-state.service.d.ts.map +1 -1
  181. package/dist/lib/services/agent-state.service.js +14 -3
  182. package/dist/lib/services/agent-state.service.js.map +1 -1
  183. package/dist/lib/services/artifact-permission.service.d.ts.map +1 -1
  184. package/dist/lib/services/artifact-permission.service.js +14 -3
  185. package/dist/lib/services/artifact-permission.service.js.map +1 -1
  186. package/dist/lib/services/artifact-state.service.d.ts.map +1 -1
  187. package/dist/lib/services/artifact-state.service.js +43 -11
  188. package/dist/lib/services/artifact-state.service.js.map +1 -1
  189. package/dist/lib/services/conversation-agent.service.d.ts +8 -3
  190. package/dist/lib/services/conversation-agent.service.d.ts.map +1 -1
  191. package/dist/lib/services/conversation-agent.service.js +9 -3
  192. package/dist/lib/services/conversation-agent.service.js.map +1 -1
  193. package/dist/lib/services/conversation-tasks-filter.d.ts +59 -2
  194. package/dist/lib/services/conversation-tasks-filter.d.ts.map +1 -1
  195. package/dist/lib/services/conversation-tasks-filter.js +222 -18
  196. package/dist/lib/services/conversation-tasks-filter.js.map +1 -1
  197. package/dist/lib/services/edge-ai/edge-agent-pre-discovery.service.d.ts +85 -0
  198. package/dist/lib/services/edge-ai/edge-agent-pre-discovery.service.d.ts.map +1 -0
  199. package/dist/lib/services/edge-ai/edge-agent-pre-discovery.service.js +257 -0
  200. package/dist/lib/services/edge-ai/edge-agent-pre-discovery.service.js.map +1 -0
  201. package/dist/lib/services/edge-ai/edge-ai-protocol.d.ts +85 -0
  202. package/dist/lib/services/edge-ai/edge-ai-protocol.d.ts.map +1 -0
  203. package/dist/lib/services/edge-ai/edge-ai-protocol.js +10 -0
  204. package/dist/lib/services/edge-ai/edge-ai-protocol.js.map +1 -0
  205. package/dist/lib/services/edge-ai/edge-ai-worker-host.d.ts +90 -0
  206. package/dist/lib/services/edge-ai/edge-ai-worker-host.d.ts.map +1 -0
  207. package/dist/lib/services/edge-ai/edge-ai-worker-host.js +386 -0
  208. package/dist/lib/services/edge-ai/edge-ai-worker-host.js.map +1 -0
  209. package/dist/lib/services/edge-ai/edge-ai.worker.d.ts +13 -0
  210. package/dist/lib/services/edge-ai/edge-ai.worker.d.ts.map +1 -0
  211. package/dist/lib/services/edge-ai/edge-ai.worker.js +201 -0
  212. package/dist/lib/services/edge-ai/edge-ai.worker.js.map +1 -0
  213. package/dist/lib/services/export.service.d.ts +64 -0
  214. package/dist/lib/services/export.service.d.ts.map +1 -1
  215. package/dist/lib/services/export.service.js +185 -6
  216. package/dist/lib/services/export.service.js.map +1 -1
  217. package/dist/lib/services/library-creation.service.d.ts +304 -0
  218. package/dist/lib/services/library-creation.service.d.ts.map +1 -0
  219. package/dist/lib/services/library-creation.service.js +1244 -0
  220. package/dist/lib/services/library-creation.service.js.map +1 -0
  221. package/dist/lib/services/realtime-audio-recorder.d.ts +10 -8
  222. package/dist/lib/services/realtime-audio-recorder.d.ts.map +1 -1
  223. package/dist/lib/services/realtime-audio-recorder.js +28 -12
  224. package/dist/lib/services/realtime-audio-recorder.js.map +1 -1
  225. package/dist/lib/services/realtime-pairing.d.ts +3 -3
  226. package/dist/lib/services/realtime-pairing.js +4 -4
  227. package/dist/lib/services/realtime-pairing.js.map +1 -1
  228. package/dist/lib/services/realtime-session-review.service.d.ts +14 -0
  229. package/dist/lib/services/realtime-session-review.service.d.ts.map +1 -1
  230. package/dist/lib/services/realtime-session-review.service.js +46 -4
  231. package/dist/lib/services/realtime-session-review.service.js.map +1 -1
  232. package/dist/lib/services/realtime-session.service.d.ts +10 -3
  233. package/dist/lib/services/realtime-session.service.d.ts.map +1 -1
  234. package/dist/lib/services/realtime-session.service.js +8 -3
  235. package/dist/lib/services/realtime-session.service.js.map +1 -1
  236. package/dist/lib/services/search.service.d.ts +19 -2
  237. package/dist/lib/services/search.service.d.ts.map +1 -1
  238. package/dist/lib/services/search.service.js +99 -36
  239. package/dist/lib/services/search.service.js.map +1 -1
  240. package/dist/lib/utils/agent-artifact-summary.d.ts +1 -1
  241. package/dist/lib/utils/agent-artifact-summary.d.ts.map +1 -1
  242. package/dist/lib/utils/agent-artifact-summary.js +1 -1
  243. package/dist/lib/utils/agent-artifact-summary.js.map +1 -1
  244. package/dist/lib/utils/decision-routing.d.ts +5 -2
  245. package/dist/lib/utils/decision-routing.d.ts.map +1 -1
  246. package/dist/lib/utils/decision-routing.js +9 -4
  247. package/dist/lib/utils/decision-routing.js.map +1 -1
  248. package/dist/public-api.d.ts +13 -0
  249. package/dist/public-api.d.ts.map +1 -1
  250. package/dist/public-api.js +15 -1
  251. package/dist/public-api.js.map +1 -1
  252. package/package.json +42 -37
@@ -0,0 +1,162 @@
1
+ import { CompositeKey } from '@memberjunction/core';
2
+ import { ArtifactPreviewSnapshot, type ArtifactTypeThumbnailMode, MJArtifactEntity, MJArtifactVersionEntity, MJCollectionEntity, StorageAccountWithProvider } from '@memberjunction/core-entities';
3
+ /**
4
+ * Primary surface layout mode of the Library workspace:
5
+ * - `'hub'`: Spacious zero-left-sidebar landing page (default)
6
+ * - `'navigator'`: Power-user collapsible tree + list/grid + resizable Split Studio
7
+ */
8
+ export type LibrarySurfaceMode = 'hub' | 'navigator';
9
+ /**
10
+ * Unified scope in the single-shell Library UX.
11
+ */
12
+ export type LibraryUnifiedScope = 'home' | 'all' | 'shared' | 'starred' | 'collection' | 'drive';
13
+ /**
14
+ * Unified layout mode (`Grid | List | Split`) that preserves the active scope.
15
+ */
16
+ export type LibraryUnifiedLayout = 'grid' | 'list' | 'split';
17
+ export interface LibraryBreadcrumbSegment {
18
+ Label: string;
19
+ Scope: LibraryUnifiedScope;
20
+ CollectionId?: string | null;
21
+ }
22
+ /**
23
+ * Top-level tabs displayed in `Hub` mode.
24
+ */
25
+ export type LibraryHubTab = 'overview' | 'collections' | 'all' | 'shared' | 'drives';
26
+ /**
27
+ * Active navigation view inside `Navigator` mode.
28
+ */
29
+ export type LibraryNavigatorSection = 'all' | 'collections' | 'shared' | 'starred' | 'collection' | 'drive';
30
+ /**
31
+ * Item layout style in item grids/tables.
32
+ */
33
+ export type LibraryListStyle = 'cards' | 'list';
34
+ /**
35
+ * Semantic category bucket used for visual miniature previews, badges, and filtering.
36
+ */
37
+ export type LibraryCategoryFilter = 'all' | 'documents' | 'spreadsheets' | 'presentations' | 'interactive' | 'queries' | 'files';
38
+ /**
39
+ * Ownership filter used inside `<mj-filter-panel>`.
40
+ */
41
+ export type LibraryOwnershipFilter = 'all' | 'owned' | 'shared' | 'starred';
42
+ /**
43
+ * Rich view-model representing one native Library item (`MJ: Artifacts` + latest `MJ: Artifact Versions`).
44
+ */
45
+ export interface LibraryItemSummary {
46
+ Id: string;
47
+ Name: string;
48
+ Description: string;
49
+ TypeId: string;
50
+ TypeName: string;
51
+ DriverClass: string;
52
+ Icon: string;
53
+ Category: Exclude<LibraryCategoryFilter, 'all'>;
54
+ CategoryBadge: string;
55
+ LatestVersionId: string | null;
56
+ LatestVersionNumber: number;
57
+ VersionCount: number;
58
+ ContentMode: MJArtifactVersionEntity['ContentMode'];
59
+ MimeType: string | null;
60
+ FileName: string | null;
61
+ ContentSnippet: string;
62
+ PreviewSnapshot?: ArtifactPreviewSnapshot | null;
63
+ ThumbnailDataUrl?: string | null;
64
+ ThumbnailPolicyMode?: ArtifactTypeThumbnailMode;
65
+ UpdatedAt: Date;
66
+ OwnerUserId: string;
67
+ OwnerName: string;
68
+ IsOwnedByCurrentUser: boolean;
69
+ IsSharedWithMe: boolean;
70
+ IsStarred: boolean;
71
+ CanEdit: boolean;
72
+ CanShare: boolean;
73
+ CanDelete: boolean;
74
+ CollectionIds: string[];
75
+ CollectionNames: string[];
76
+ ArtifactEntity: MJArtifactEntity;
77
+ }
78
+ /**
79
+ * Hierarchical node representing an `MJ: Collections` record and its nested children.
80
+ */
81
+ export interface LibraryCollectionNode {
82
+ Id: string;
83
+ Name: string;
84
+ Description: string;
85
+ Icon: string;
86
+ Color: string;
87
+ ParentId: string | null;
88
+ OwnerId: string | null;
89
+ OwnerName: string;
90
+ DirectItemCount: number;
91
+ TotalItemCount: number;
92
+ CanEdit: boolean;
93
+ CanShare: boolean;
94
+ CanDelete: boolean;
95
+ Children: LibraryCollectionNode[];
96
+ Entity: MJCollectionEntity;
97
+ }
98
+ /**
99
+ * Summary descriptor for a dynamic Connected Drive (`MJ: File Storage Accounts`).
100
+ */
101
+ export interface LibraryDriveSummary {
102
+ AccountId: string;
103
+ AccountName: string;
104
+ Description: string;
105
+ ProviderId: string;
106
+ ProviderName: string;
107
+ Icon: string;
108
+ SupportsSearch: boolean;
109
+ AccountWithProvider: StorageAccountWithProvider;
110
+ }
111
+ /**
112
+ * Deep-link and agent-context state snapshot emitted by `<mj-library-workspace>`.
113
+ */
114
+ export interface LibraryWorkspaceState {
115
+ Mode: LibrarySurfaceMode;
116
+ HubTab: LibraryHubTab;
117
+ NavigatorSection: LibraryNavigatorSection;
118
+ CollectionId: string | null;
119
+ CollectionName: string | null;
120
+ DriveId: string | null;
121
+ DriveName: string | null;
122
+ DriveFolderPrefix: string;
123
+ ActiveArtifactId: string | null;
124
+ ActiveArtifactName: string | null;
125
+ ActiveVersionNumber: number | null;
126
+ IsFullCanvasOpen: boolean;
127
+ SearchQuery: string;
128
+ CategoryFilter: LibraryCategoryFilter;
129
+ OwnershipFilter: LibraryOwnershipFilter;
130
+ VisibleItems: ReadonlyArray<{
131
+ Id: string;
132
+ Name: string;
133
+ TypeName: string;
134
+ Category: string;
135
+ VersionNumber: number;
136
+ UpdatedAtIso: string;
137
+ }>;
138
+ Collections: ReadonlyArray<{
139
+ Id: string;
140
+ Name: string;
141
+ ParentId: string | null;
142
+ ItemCount: number;
143
+ }>;
144
+ ConnectedDrives: ReadonlyArray<{
145
+ AccountId: string;
146
+ AccountName: string;
147
+ ProviderName: string;
148
+ }>;
149
+ }
150
+ /**
151
+ * Host navigation event emitted by `<mj-library-workspace>` for L3 surface routing (`NavigationService`).
152
+ */
153
+ export interface LibraryHostNavigationEvent {
154
+ Kind: 'entity-record' | 'conversation' | 'collection';
155
+ EntityName?: string;
156
+ CompositeKey?: CompositeKey;
157
+ ConversationId?: string;
158
+ CollectionId?: string;
159
+ ArtifactId?: string;
160
+ VersionNumber?: number;
161
+ }
162
+ //# sourceMappingURL=library.models.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"library.models.d.ts","sourceRoot":"","sources":["../../../../src/lib/components/library/library.models.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,EACL,uBAAuB,EACvB,KAAK,yBAAyB,EAC9B,gBAAgB,EAChB,uBAAuB,EACvB,kBAAkB,EAClB,0BAA0B,EAC3B,MAAM,+BAA+B,CAAC;AAEvC;;;;GAIG;AACH,MAAM,MAAM,kBAAkB,GAAG,KAAK,GAAG,WAAW,CAAC;AAErD;;GAEG;AACH,MAAM,MAAM,mBAAmB,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,GAAG,SAAS,GAAG,YAAY,GAAG,OAAO,CAAC;AAEjG;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC;AAE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EAAE,MAAM,CAAC;QACpB,YAAY,EAAE,MAAM,CAAC;KACtB,CAAC,CAAC;CACJ;AAED;;GAEG;AACH,MAAM,WAAW,0BAA0B;IACzC,IAAI,EAAE,eAAe,GAAG,cAAc,GAAG,YAAY,CAAC;IACtD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=library.models.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"library.models.js","sourceRoot":"","sources":["../../../../src/lib/components/library/library.models.ts"],"names":[],"mappings":"","sourcesContent":["import { CompositeKey } from '@memberjunction/core';\nimport {\n ArtifactPreviewSnapshot,\n type ArtifactTypeThumbnailMode,\n MJArtifactEntity,\n MJArtifactVersionEntity,\n MJCollectionEntity,\n StorageAccountWithProvider,\n} from '@memberjunction/core-entities';\n\n/**\n * Primary surface layout mode of the Library workspace:\n * - `'hub'`: Spacious zero-left-sidebar landing page (default)\n * - `'navigator'`: Power-user collapsible tree + list/grid + resizable Split Studio\n */\nexport type LibrarySurfaceMode = 'hub' | 'navigator';\n\n/**\n * Unified scope in the single-shell Library UX.\n */\nexport type LibraryUnifiedScope = 'home' | 'all' | 'shared' | 'starred' | 'collection' | 'drive';\n\n/**\n * Unified layout mode (`Grid | List | Split`) that preserves the active scope.\n */\nexport type LibraryUnifiedLayout = 'grid' | 'list' | 'split';\n\nexport interface LibraryBreadcrumbSegment {\n Label: string;\n Scope: LibraryUnifiedScope;\n CollectionId?: string | null;\n}\n\n/**\n * Top-level tabs displayed in `Hub` mode.\n */\nexport type LibraryHubTab = 'overview' | 'collections' | 'all' | 'shared' | 'drives';\n\n/**\n * Active navigation view inside `Navigator` mode.\n */\nexport type LibraryNavigatorSection = 'all' | 'collections' | 'shared' | 'starred' | 'collection' | 'drive';\n\n/**\n * Item layout style in item grids/tables.\n */\nexport type LibraryListStyle = 'cards' | 'list';\n\n/**\n * Semantic category bucket used for visual miniature previews, badges, and filtering.\n */\nexport type LibraryCategoryFilter =\n | 'all'\n | 'documents'\n | 'spreadsheets'\n | 'presentations'\n | 'interactive'\n | 'queries'\n | 'files';\n\n/**\n * Ownership filter used inside `<mj-filter-panel>`.\n */\nexport type LibraryOwnershipFilter = 'all' | 'owned' | 'shared' | 'starred';\n\n/**\n * Rich view-model representing one native Library item (`MJ: Artifacts` + latest `MJ: Artifact Versions`).\n */\nexport interface LibraryItemSummary {\n Id: string;\n Name: string;\n Description: string;\n TypeId: string;\n TypeName: string;\n DriverClass: string;\n Icon: string;\n Category: Exclude<LibraryCategoryFilter, 'all'>;\n CategoryBadge: string;\n LatestVersionId: string | null;\n LatestVersionNumber: number;\n VersionCount: number;\n ContentMode: MJArtifactVersionEntity['ContentMode'];\n MimeType: string | null;\n FileName: string | null;\n ContentSnippet: string;\n PreviewSnapshot?: ArtifactPreviewSnapshot | null;\n ThumbnailDataUrl?: string | null;\n ThumbnailPolicyMode?: ArtifactTypeThumbnailMode;\n UpdatedAt: Date;\n OwnerUserId: string;\n OwnerName: string;\n IsOwnedByCurrentUser: boolean;\n IsSharedWithMe: boolean;\n IsStarred: boolean;\n CanEdit: boolean;\n CanShare: boolean;\n CanDelete: boolean;\n CollectionIds: string[];\n CollectionNames: string[];\n ArtifactEntity: MJArtifactEntity;\n}\n\n/**\n * Hierarchical node representing an `MJ: Collections` record and its nested children.\n */\nexport interface LibraryCollectionNode {\n Id: string;\n Name: string;\n Description: string;\n Icon: string;\n Color: string;\n ParentId: string | null;\n OwnerId: string | null;\n OwnerName: string;\n DirectItemCount: number;\n TotalItemCount: number;\n CanEdit: boolean;\n CanShare: boolean;\n CanDelete: boolean;\n Children: LibraryCollectionNode[];\n Entity: MJCollectionEntity;\n}\n\n/**\n * Summary descriptor for a dynamic Connected Drive (`MJ: File Storage Accounts`).\n */\nexport interface LibraryDriveSummary {\n AccountId: string;\n AccountName: string;\n Description: string;\n ProviderId: string;\n ProviderName: string;\n Icon: string;\n SupportsSearch: boolean;\n AccountWithProvider: StorageAccountWithProvider;\n}\n\n/**\n * Deep-link and agent-context state snapshot emitted by `<mj-library-workspace>`.\n */\nexport interface LibraryWorkspaceState {\n Mode: LibrarySurfaceMode;\n HubTab: LibraryHubTab;\n NavigatorSection: LibraryNavigatorSection;\n CollectionId: string | null;\n CollectionName: string | null;\n DriveId: string | null;\n DriveName: string | null;\n DriveFolderPrefix: string;\n ActiveArtifactId: string | null;\n ActiveArtifactName: string | null;\n ActiveVersionNumber: number | null;\n IsFullCanvasOpen: boolean;\n SearchQuery: string;\n CategoryFilter: LibraryCategoryFilter;\n OwnershipFilter: LibraryOwnershipFilter;\n VisibleItems: ReadonlyArray<{\n Id: string;\n Name: string;\n TypeName: string;\n Category: string;\n VersionNumber: number;\n UpdatedAtIso: string;\n }>;\n Collections: ReadonlyArray<{\n Id: string;\n Name: string;\n ParentId: string | null;\n ItemCount: number;\n }>;\n ConnectedDrives: ReadonlyArray<{\n AccountId: string;\n AccountName: string;\n ProviderName: string;\n }>;\n}\n\n/**\n * Host navigation event emitted by `<mj-library-workspace>` for L3 surface routing (`NavigationService`).\n */\nexport interface LibraryHostNavigationEvent {\n Kind: 'entity-record' | 'conversation' | 'collection';\n EntityName?: string;\n CompositeKey?: CompositeKey;\n ConversationId?: string;\n CollectionId?: string;\n ArtifactId?: string;\n VersionNumber?: number;\n}\n"]}
@@ -92,6 +92,11 @@ export declare class ConversationMessageRatingComponent extends BaseAngularCompo
92
92
  private grantConversationAccess;
93
93
  private loadRating;
94
94
  private saveRating;
95
+ private readEntityRating;
96
+ private readEntityComment;
97
+ private writeEntityRating;
98
+ private writeEntityComment;
99
+ private readEntityConversationId;
95
100
  static ɵfac: i0.ɵɵFactoryDeclaration<ConversationMessageRatingComponent, never>;
96
101
  static ɵcmp: i0.ɵɵComponentDeclaration<ConversationMessageRatingComponent, "mj-conversation-message-rating", never, { "ConversationDetailId": { "alias": "ConversationDetailId"; "required": false; }; "conversationDetailId": { "alias": "conversationDetailId"; "required": false; }; "CurrentUser": { "alias": "CurrentUser"; "required": false; }; "currentUser": { "alias": "currentUser"; "required": false; }; "canEdit": { "alias": "canEdit"; "required": false; }; "RatingEntityName": { "alias": "RatingEntityName"; "required": false; }; "ratingEntityName": { "alias": "ratingEntityName"; "required": false; }; "RatingField": { "alias": "RatingField"; "required": false; }; "ratingField": { "alias": "ratingField"; "required": false; }; "RatingCommentField": { "alias": "RatingCommentField"; "required": false; }; "ratingCommentField": { "alias": "ratingCommentField"; "required": false; }; "RatingsData": { "alias": "RatingsData"; "required": false; }; "ratingsData": { "alias": "ratingsData"; "required": false; }; }, {}, never, never, false, never>;
97
102
  }
@@ -1 +1 @@
1
- {"version":3,"file":"conversation-message-rating.component.d.ts","sourceRoot":"","sources":["../../../../src/lib/components/message/conversation-message-rating.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,MAAM,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAC5E,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EAAqC,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AACnF,OAAO,EAAE,UAAU,EAAkB,MAAM,+BAA+B,CAAC;AAC3E,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;;AAiB9D;;;;;;;;GAQG;AACH,qBAuGa,kCAAmC,SAAQ,oBAAqB,YAAW,MAAM;IAsH1F,OAAO,CAAC,GAAG;IACX,OAAO,CAAC,aAAa;IAtHd,oBAAoB,EAAG,MAAM,CAAC;IAEvC,oDAAoD;IACpD,IAAa,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAE9C;IACD,oDAAoD;IACpD,IAAI,oBAAoB,IAAI,MAAM,CAEjC;IACQ,WA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;IACD,QAAQ,UAAS;IAEjB,wCAAwC;IACxC,IAAI,QAAQ,YAEX;IACD,wCAAwC;IACxC,IAAI,QAAQ,CAAC,KAAK,SAAA,EAEjB;gBAGS,GAAG,EAAE,iBAAiB,EACtB,aAAa,EAAE,aAAa;IAKhC,QAAQ;IAIR,gBAAgB,IAAI,OAAO,CAAC,IAAI,CAAC;IA6CvC;;;;;OAKG;YACW,uBAAuB;YAoCvB,UAAU;YAkBV,UAAU;yCAzOb,kCAAkC;2CAAlC,kCAAkC;CAgR9C"}
1
+ {"version":3,"file":"conversation-message-rating.component.d.ts","sourceRoot":"","sources":["../../../../src/lib/components/message/conversation-message-rating.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,MAAM,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAC5E,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EAAqC,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AACnF,OAAO,EAGL,UAAU,EAEX,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;;AAiB9D;;;;;;;;GAQG;AACH,qBAuGa,kCAAmC,SAAQ,oBAAqB,YAAW,MAAM;IAsH1F,OAAO,CAAC,GAAG;IACX,OAAO,CAAC,aAAa;IAtHd,oBAAoB,EAAG,MAAM,CAAC;IAEvC,oDAAoD;IACpD,IAAa,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAE9C;IACD,oDAAoD;IACpD,IAAI,oBAAoB,IAAI,MAAM,CAEjC;IACQ,WAAW,EAAG,QAAQ,CAAC;IAEhC,2CAA2C;IAC3C,IAAa,WAAW,CAAC,KAAK,EAAE,QAAQ,EAEvC;IACD,2CAA2C;IAC3C,IAAI,WAAW,IAAI,QAAQ,CAE1B;IAED;;;;;OAKG;IACM,OAAO,EAAE,OAAO,CAAQ;IAEjC;;;;OAIG;IACM,gBAAgB,EAAE,MAAM,CAA8B;IAE/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AKG;YACW,uBAAuB;YAqCvB,UAAU;YAkBV,UAAU;IAwCxB,OAAO,CAAC,gBAAgB;IAexB,OAAO,CAAC,iBAAiB;IAWzB,OAAO,CAAC,iBAAiB;IAazB,OAAO,CAAC,kBAAkB;IAa1B,OAAO,CAAC,wBAAwB;yCAtUrB,kCAAkC;2CAAlC,kCAAkC;CA6U9C"}
@@ -1,7 +1,7 @@
1
1
  import { Component, Input } from '@angular/core';
2
2
  import { BaseAngularComponent } from '@memberjunction/ng-base-types';
3
3
  import { RunView } from '@memberjunction/core';
4
- import { UserInfoEngine } from '@memberjunction/core-entities';
4
+ import { MJConversationDetailEntity, UserInfoEngine, } from '@memberjunction/core-entities';
5
5
  import * as i0 from "@angular/core";
6
6
  import * as i1 from "../../services/dialog.service";
7
7
  function ConversationMessageRatingComponent_Conditional_2_Conditional_1_Template(rf, ctx) { if (rf & 1) {
@@ -226,7 +226,8 @@ export class ConversationMessageRatingComponent extends BaseAngularComponent {
226
226
  EntityName: 'MJ: Resource Permissions',
227
227
  ExtraFilter: `ResourceTypeID='${CONVERSATIONS_RESOURCE_TYPE_ID}' AND ` +
228
228
  `ResourceRecordID='${conversationID}' AND Type='Role' AND ` +
229
- `RoleID IN ('${FEEDBACK_ROLE_IDS.join("','")}')`
229
+ `RoleID IN ('${FEEDBACK_ROLE_IDS.join("','")}')`,
230
+ ResultType: 'entity_object'
230
231
  });
231
232
  const granted = new Set((existing.Results || []).map((r) => (r.RoleID || '').toLowerCase()));
232
233
  for (const roleID of FEEDBACK_ROLE_IDS) {
@@ -234,12 +235,12 @@ export class ConversationMessageRatingComponent extends BaseAngularComponent {
234
235
  continue;
235
236
  const perm = await md.GetEntityObject('MJ: Resource Permissions');
236
237
  perm.NewRecord();
237
- perm.Set('ResourceTypeID', CONVERSATIONS_RESOURCE_TYPE_ID);
238
- perm.Set('ResourceRecordID', conversationID);
239
- perm.Set('Type', 'Role');
240
- perm.Set('RoleID', roleID);
241
- perm.Set('PermissionLevel', 'View');
242
- perm.Set('Status', 'Approved');
238
+ perm.ResourceTypeID = CONVERSATIONS_RESOURCE_TYPE_ID;
239
+ perm.ResourceRecordID = conversationID;
240
+ perm.Type = 'Role';
241
+ perm.RoleID = roleID;
242
+ perm.PermissionLevel = 'View';
243
+ perm.Status = 'Approved';
243
244
  const ok = await perm.Save();
244
245
  if (!ok) {
245
246
  console.warn('[Rating] Failed to create ResourcePermission for role', roleID, perm.LatestResult);
@@ -255,12 +256,12 @@ export class ConversationMessageRatingComponent extends BaseAngularComponent {
255
256
  return;
256
257
  try {
257
258
  const md = this.ProviderToUse;
258
- const entity = (await md.GetEntityObject(this.RatingEntityName));
259
+ const entity = await md.GetEntityObject(this.RatingEntityName);
259
260
  const loaded = await entity.Load(this.ConversationDetailId);
260
261
  if (loaded) {
261
- const rating = entity.Get(this.RatingField);
262
+ const rating = this.readEntityRating(entity);
262
263
  this.CurrentUserRating = rating != null ? Number(rating) : null;
263
- this.CurrentUserComments = (entity.Get(this.RatingCommentField) ?? '');
264
+ this.CurrentUserComments = this.readEntityComment(entity) ?? '';
264
265
  this.cdr.detectChanges();
265
266
  }
266
267
  }
@@ -284,18 +285,18 @@ export class ConversationMessageRatingComponent extends BaseAngularComponent {
284
285
  this.cdr.detectChanges();
285
286
  try {
286
287
  const md = this.ProviderToUse;
287
- const entity = (await md.GetEntityObject(this.RatingEntityName));
288
+ const entity = await md.GetEntityObject(this.RatingEntityName);
288
289
  const loaded = await entity.Load(this.ConversationDetailId);
289
290
  if (!loaded) {
290
291
  throw new Error(`ConversationDetail ${this.ConversationDetailId} not found in ${this.RatingEntityName}`);
291
292
  }
292
- entity.Set(this.RatingField, rating);
293
- entity.Set(this.RatingCommentField, comments || null);
293
+ this.writeEntityRating(entity, rating);
294
+ this.writeEntityComment(entity, comments || null);
294
295
  const saveResult = await entity.Save();
295
296
  if (!saveResult) {
296
297
  throw new Error(`Save failed: ${entity.LatestResult?.Message ?? 'unknown'}`);
297
298
  }
298
- const conversationID = entity.Get('ConversationID');
299
+ const conversationID = this.readEntityConversationId(entity);
299
300
  return typeof conversationID === 'string' ? conversationID : null;
300
301
  }
301
302
  catch (error) {
@@ -310,6 +311,61 @@ export class ConversationMessageRatingComponent extends BaseAngularComponent {
310
311
  this.cdr.detectChanges();
311
312
  }
312
313
  }
314
+ readEntityRating(entity) {
315
+ if (this.RatingField === 'UserRating' && entity instanceof MJConversationDetailEntity) {
316
+ return entity.UserRating;
317
+ }
318
+ const field = entity.Fields.find((f) => f.Name === this.RatingField);
319
+ if (field && typeof field.Value === 'number') {
320
+ return field.Value;
321
+ }
322
+ if (field && typeof field.Value === 'string' && field.Value.trim() !== '') {
323
+ const parsed = Number(field.Value);
324
+ return Number.isFinite(parsed) ? parsed : null;
325
+ }
326
+ return entity.UserRating ?? null;
327
+ }
328
+ readEntityComment(entity) {
329
+ if (this.RatingCommentField === 'UserFeedback' && entity instanceof MJConversationDetailEntity) {
330
+ return entity.UserFeedback;
331
+ }
332
+ const field = entity.Fields.find((f) => f.Name === this.RatingCommentField);
333
+ if (field && typeof field.Value === 'string') {
334
+ return field.Value;
335
+ }
336
+ return entity.UserFeedback ?? null;
337
+ }
338
+ writeEntityRating(entity, rating) {
339
+ if (this.RatingField === 'UserRating' && entity instanceof MJConversationDetailEntity) {
340
+ entity.UserRating = rating;
341
+ return;
342
+ }
343
+ const field = entity.Fields.find((f) => f.Name === this.RatingField);
344
+ if (field) {
345
+ field.Value = rating;
346
+ return;
347
+ }
348
+ entity.UserRating = rating;
349
+ }
350
+ writeEntityComment(entity, comment) {
351
+ if (this.RatingCommentField === 'UserFeedback' && entity instanceof MJConversationDetailEntity) {
352
+ entity.UserFeedback = comment;
353
+ return;
354
+ }
355
+ const field = entity.Fields.find((f) => f.Name === this.RatingCommentField);
356
+ if (field) {
357
+ field.Value = comment;
358
+ return;
359
+ }
360
+ entity.UserFeedback = comment;
361
+ }
362
+ readEntityConversationId(entity) {
363
+ if (typeof entity.ConversationID === 'string') {
364
+ return entity.ConversationID;
365
+ }
366
+ const field = entity.Fields.find((f) => f.Name === 'ConversationID');
367
+ return field && typeof field.Value === 'string' ? field.Value : null;
368
+ }
313
369
  static ɵfac = function ConversationMessageRatingComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || ConversationMessageRatingComponent)(i0.ɵɵdirectiveInject(i0.ChangeDetectorRef), i0.ɵɵdirectiveInject(i1.DialogService)); };
314
370
  static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ConversationMessageRatingComponent, selectors: [["mj-conversation-message-rating"]], inputs: { ConversationDetailId: "ConversationDetailId", conversationDetailId: "conversationDetailId", CurrentUser: "CurrentUser", currentUser: "currentUser", canEdit: "canEdit", RatingEntityName: "RatingEntityName", ratingEntityName: "ratingEntityName", RatingField: "RatingField", ratingField: "ratingField", RatingCommentField: "RatingCommentField", ratingCommentField: "ratingCommentField", RatingsData: "RatingsData", ratingsData: "ratingsData" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 4, vars: 1, consts: [[1, "rating-container"], [1, "user-rating"], ["type", "button", 1, "rating-button", 3, "has-rated", "disabled", "title"], ["title", "Rating left by the conversation owner \u2014 read-only", 1, "rating-readonly"], ["type", "button", 1, "rating-button", 3, "click", "disabled", "title"], [1, "fa-solid", "fa-pen-to-square"], [1, "my-rating"], ["aria-hidden", "true", 1, "fa-regular", "fa-comment-dots"], [1, "rate-label"], [1, "fa-solid", "fa-comment-dots"]], template: function ConversationMessageRatingComponent_Template(rf, ctx) { if (rf & 1) {
315
371
  i0.ɵɵelementStart(0, "div", 0)(1, "div", 1);
@@ -379,5 +435,5 @@ export class ConversationMessageRatingComponent extends BaseAngularComponent {
379
435
  }], ratingsData: [{
380
436
  type: Input
381
437
  }] }); })();
382
- (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ConversationMessageRatingComponent, { className: "ConversationMessageRatingComponent", filePath: "src/lib/components/message/conversation-message-rating.component.ts", lineNumber: 134 }); })();
438
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ConversationMessageRatingComponent, { className: "ConversationMessageRatingComponent", filePath: "src/lib/components/message/conversation-message-rating.component.ts", lineNumber: 139 }); })();
383
439
  //# sourceMappingURL=conversation-message-rating.component.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"conversation-message-rating.component.js","sourceRoot":"","sources":["../../../../src/lib/components/message/conversation-message-rating.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAA6B,MAAM,eAAe,CAAC;AAC5E,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EAA4B,OAAO,EAAY,MAAM,sBAAsB,CAAC;AACnF,OAAO,EAAc,cAAc,EAAE,MAAM,+BAA+B,CAAC;;;;IA2C7D,uBAAyC;IACzC,+BAAwB;IAAA,YAAqC;IAAA,iBAAO;;;IAA5C,eAAqC;IAArC,qEAAqC;;;IAE7D,uBAA6D;IAC7D,+BAAyB;IAAA,6BAAa;IAAA,iBAAO;;;;IAbjD,iCAOgB;IAHd,sMAAS,yBAAkB,KAAC;IAO1B,AAHF,wGAAiC,kFAGxB;IAIX,iBAAS;;;IAbP,6DAA6C;IAG7C,AAFA,0CAAqB,uFAE0D;;IAG/E,cAMC;IAND,0DAMC;;;IAGH,+BACgE;IAC9D,uBAAwC;IACxC,4BAAM;IAAA,YAAgC;IACxC,AADwC,iBAAO,EACxC;;;IADC,eAAgC;IAAhC,gEAAgC;;AAnDlD,MAAM,oBAAoB,GAAG,8BAA8B,CAAC;AAC5D,MAAM,8BAA8B,GAAG,sCAAsC,CAAC;AAC9E,MAAM,iBAAiB,GAAG;IACxB,sCAAsC,EAAE,YAAY;IACpD,sCAAsC,CAAE,cAAc;CACvD,CAAC;AAUF;;;;;;;;GAQG;AAwGH,MAAM,OAAO,kCAAmC,SAAQ,oBAAoB;IAsHhE;IACA;IAtHD,oBAAoB,CAAU;IAEvC,oDAAoD;IACpD,I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AAC,gBAAiB,MAAc,CAAC,YAAY,EAAE,OAAO,IAAI,SAAS,EAAE,CAAC,CAAC;YACxF,CAAC;YACD,MAAM,cAAc,GAAG,MAAM,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;YACpD,OAAO,OAAO,cAAc,KAAK,QAAQ,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,IAAI,CAAC;QACpE,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,OAAO,CAAC,KAAK,CAAC,uBAAuB,EAAE,KAAK,CAAC,CAAC;YAC9C,IAAI,CAAC,iBAAiB,GAAG,UAAU,CAAC;YACpC,IAAI,CAAC,mBAAmB,GAAG,YAAY,CAAC;YACxC,IAAI,CAAC,GAAG,CAAC,aAAa,EAAE,CAAC;YACzB,OAAO,IAAI,CAAC;QACd,CAAC;gBAAS,CAAC;YACT,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;YACtB,IAAI,CAAC,GAAG,CAAC,aAAa,EAAE,CAAC;QAC3B,CAAC;IACH,CAAC;4HA/QU,kCAAkC;6DAAlC,kCAAkC;YAlGzC,AADF,8BAA8B,aACH;YAkBrB,AAjBF,uGAAe,+EAiByB;YAQ5C,AADE,iBAAM,EACF;;YAzBF,eAuBC;YAvBD,0EAuBC;;;iFA0EI,kCAAkC;cAvG9C,SAAS;6BACI,KAAK,YACP,gCAAgC,YAChC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BT;;kBAwEA,KAAK;;kBAGL,KAAK;;kBAOL,KAAK;;kBAGL,KAAK;;kBAcL,KAAK;;kBAOL,KAAK;;kBAGL,KAAK;;kBASL,KAAK;;kBAGL,KAAK;;kBASL,KAAK;;kBAGL,KAAK;;kBAaL,KAAK;;kBAGL,KAAK;;kFA9EK,kCAAkC","sourcesContent":["import { Component, Input, OnInit, ChangeDetectorRef } from '@angular/core';\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\nimport { BaseEntity, CompositeKey, RunView, UserInfo } from '@memberjunction/core';\nimport { RatingJSON, UserInfoEngine } from '@memberjunction/core-entities';\nimport { DialogService } from '../../services/dialog.service';\n\nconst FEEDBACK_CONSENT_KEY = 'agent-feedback-share-consent';\nconst CONVERSATIONS_RESOURCE_TYPE_ID = '81D4BC3D-9FEB-EF11-B01A-286B35C04427';\nconst FEEDBACK_ROLE_IDS = [\n 'deafccec-6a37-ef11-86d4-000d3a4e707e', // Developer\n 'dfafccec-6a37-ef11-86d4-000d3a4e707e' // Integration\n];\n\n/** Minimal shape we use against the loaded entity. All MJ entity subclasses\n * implement `Load(ID)` via codegen but the base `BaseEntity<unknown>` type\n * doesn't expose it, so we narrow here to keep the call generic across\n * entity names without resorting to `any`. */\ntype LoadableEntity = BaseEntity<unknown> & {\n Load(KeyValuePairs: CompositeKey | string, EntityRelationshipsToLoad?: string[]): Promise<boolean>;\n};\n\n/**\n * Single-rating-per-message rating UI for an AI conversation response.\n *\n * Storage model: the rating + free-form comment live directly on the\n * ConversationDetail row, in `UserRating` (1-10, nullable) and `UserFeedback`\n * (nvarchar(max), nullable). This matches MJ's own pattern on\n * `__mj.ConversationDetail` and Skip's matching columns on\n * `Skip.ConversationDetail`. The host app picks the entity via @Input.\n */\n@Component({\n standalone: false,\n selector: 'mj-conversation-message-rating',\n template: `\n <div class=\"rating-container\">\n <div class=\"user-rating\">\n @if (canEdit) {\n <button\n class=\"rating-button\"\n [class.has-rated]=\"currentUserRating != null\"\n [disabled]=\"isSaving\"\n (click)=\"OpenRatingDialog()\"\n [title]=\"currentUserRating != null ? 'Edit your rating' : 'Rate this response'\"\n [attr.aria-label]=\"currentUserRating != null ? null : 'Rate response'\"\n type=\"button\">\n @if (currentUserRating != null) {\n <i class=\"fa-solid fa-pen-to-square\"></i>\n <span class=\"my-rating\">My rating: {{ currentUserRating }}/10</span>\n } @else {\n <i class=\"fa-regular fa-comment-dots\" aria-hidden=\"true\"></i>\n <span class=\"rate-label\">Rate response</span>\n }\n </button>\n } @else if (currentUserRating != null) {\n <span class=\"rating-readonly\"\n title=\"Rating left by the conversation owner — read-only\">\n <i class=\"fa-solid fa-comment-dots\"></i>\n <span>Rated {{ currentUserRating }}/10</span>\n </span>\n }\n </div>\n </div>\n `,\n styles: [`\n .rating-container {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 4px 0;\n }\n\n .user-rating {\n display: flex;\n gap: 4px;\n margin-left: auto;\n }\n\n .rating-button {\n display: inline-flex;\n align-items: center;\n gap: var(--mj-space-2);\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-strong);\n border-radius: 6px;\n padding: 6px 12px;\n cursor: pointer;\n font-size: 13px;\n color: var(--mj-text-primary);\n opacity: 0.85;\n transition: all 0.15s ease;\n }\n\n .rating-button:hover:not(:disabled) {\n opacity: 1;\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 6%, var(--mj-bg-surface));\n }\n\n .rating-button:disabled {\n cursor: not-allowed;\n opacity: 0.5;\n }\n\n .rating-button.has-rated {\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, var(--mj-bg-surface));\n }\n\n .my-rating {\n font-weight: 500;\n }\n\n /* Phones: \"Rate response\" collapses to its icon */\n @media (max-width: 768px) {\n .rate-label {\n display: none;\n }\n }\n\n .rating-readonly {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: 6px;\n font-size: 12px;\n color: var(--mj-text-secondary);\n background: var(--mj-bg-surface-sunken);\n cursor: default;\n }\n `]\n})\nexport class ConversationMessageRatingComponent extends BaseAngularComponent implements OnInit {\n @Input() ConversationDetailId!: string;\n\n /** @deprecated Use {@link ConversationDetailId}. */\n @Input() set conversationDetailId(value: string) {\n this.ConversationDetailId = value;\n }\n /** @deprecated Use {@link ConversationDetailId}. */\n get conversationDetailId(): string {\n return this.ConversationDetailId;\n }\n @Input() CurrentUser!: UserInfo;\n\n /** @deprecated Use {@link CurrentUser}. */\n @Input() set currentUser(value: UserInfo) {\n this.CurrentUser = value;\n }\n /** @deprecated Use {@link CurrentUser}. */\n get currentUser(): UserInfo {\n return this.CurrentUser;\n }\n\n /**\n * When false, the rating UI renders as a read-only badge instead of an editable\n * button. Set by the parent (MessageItemComponent) to `false` when the current\n * user is not the conversation owner — the rating storage is a single field on\n * the ConversationDetail row, so only the owner is allowed to mutate it.\n */\n @Input() canEdit: boolean = true;\n\n /**\n * Entity name to load/update for the rating. Defaults to MJ's\n * `MJ: Conversation Details` (which has `UserRating`/`UserFeedback`).\n * Skip-Brain hosts pass `'Conversation Details__Skip'`.\n */\n @Input() RatingEntityName: string = 'MJ: Conversation Details';\n\n /** @deprecated Use {@link RatingEntityName}. */\n @Input() set ratingEntityName(value: string) {\n this.RatingEntityName = value;\n }\n /** @deprecated Use {@link RatingEntityName}. */\n get ratingEntityName(): string {\n return this.RatingEntityName;\n }\n\n /** Column on the entity that stores the 1-10 rating. */\n @Input() RatingField: string = 'UserRating';\n\n /** @deprecated Use {@link RatingField}. */\n @Input() set ratingField(value: string) {\n this.RatingField = value;\n }\n /** @deprecated Use {@link RatingField}. */\n get ratingField(): string {\n return this.RatingField;\n }\n\n /** Column on the entity that stores the free-form feedback. */\n @Input() RatingCommentField: string = 'UserFeedback';\n\n /** @deprecated Use {@link RatingCommentField}. */\n @Input() set ratingCommentField(value: string) {\n this.RatingCommentField = value;\n }\n /** @deprecated Use {@link RatingCommentField}. */\n get ratingCommentField(): string {\n return this.RatingCommentField;\n }\n\n /**\n * Optional: legacy pre-loaded ratings array (no longer used by storage; kept\n * to preserve the input shape used by existing call sites like\n * MessageItemComponent).\n */\n @Input() RatingsData?: RatingJSON[];\n\n /** @deprecated Use {@link RatingsData}. */\n @Input() set ratingsData(value: RatingJSON[] | undefined) {\n this.RatingsData = value;\n }\n /** @deprecated Use {@link RatingsData}. */\n get ratingsData(): RatingJSON[] | undefined {\n return this.RatingsData;\n }\n\n CurrentUserRating: number | null = null;\n\n /** @deprecated Use {@link CurrentUserRating}. */\n get currentUserRating(): number | null {\n return this.CurrentUserRating;\n }\n /** @deprecated Use {@link CurrentUserRating}. */\n set currentUserRating(value: number | null) {\n this.CurrentUserRating = value;\n }\n CurrentUserComments: string = '';\n\n /** @deprecated Use {@link CurrentUserComments}. */\n get currentUserComments(): string {\n return this.CurrentUserComments;\n }\n /** @deprecated Use {@link CurrentUserComments}. */\n set currentUserComments(value: string) {\n this.CurrentUserComments = value;\n }\n IsSaving = false;\n\n /** @deprecated Use {@link IsSaving}. */\n get isSaving() {\n return this.IsSaving;\n }\n /** @deprecated Use {@link IsSaving}. */\n set isSaving(value) {\n this.IsSaving = value;\n }\n\n constructor(\n private cdr: ChangeDetectorRef,\n private dialogService: DialogService\n ) {\n super();\n }\n\n async ngOnInit() {\n await this.loadRating();\n }\n\n async OpenRatingDialog(): Promise<void> {\n if (this.IsSaving) return;\n if (!this.canEdit) return;\n\n let consentAcknowledged = false;\n try {\n await UserInfoEngine.Instance.Config();\n consentAcknowledged = UserInfoEngine.Instance.GetSetting(FEEDBACK_CONSENT_KEY) === 'true';\n } catch (e) {\n console.warn('[Rating] Could not read consent flag, will require acknowledgement', e);\n }\n\n const result = await this.dialogService.rating({\n title: this.CurrentUserRating != null ? 'Edit your rating' : 'Rate this response',\n message: 'Rate the response on a 1-10 scale and (optionally) describe what was good or bad.',\n initialRating: this.CurrentUserRating,\n initialComments: this.CurrentUserComments,\n okText: 'Submit',\n requireConsent: !consentAcknowledged\n });\n\n if (result == null) return;\n\n const conversationID = await this.saveRating(result.rating, result.comments);\n\n if (result.consentNewlyAcknowledged) {\n try {\n const saved = await UserInfoEngine.Instance.SetSetting(FEEDBACK_CONSENT_KEY, 'true');\n if (!saved) {\n console.error(\n `[Rating] Failed to persist consent acknowledgement under key \"${FEEDBACK_CONSENT_KEY}\" — ` +\n `the dialog will re-prompt on next rating. Likely cause: the current user lacks ` +\n `create/update permission on the \"MJ: User Settings\" entity.`\n );\n }\n } catch (e) {\n console.error('[Rating] Could not persist consent flag', e);\n }\n }\n\n if (conversationID) {\n await this.grantConversationAccess(conversationID);\n }\n }\n\n /**\n * Grants the Integrations and Developer roles View access to the parent\n * Conversation via `MJ: Resource Permissions`. Idempotent — existing\n * permissions for the same role are not duplicated. Best-effort; any error\n * is logged but does not roll back the rating itself.\n */\n private async grantConversationAccess(conversationID: string): Promise<void> {\n try {\n const md = this.ProviderToUse;\n const rv = RunView.FromMetadataProvider(md);\n const existing = await rv.RunView({\n EntityName: 'MJ: Resource Permissions',\n ExtraFilter:\n `ResourceTypeID='${CONVERSATIONS_RESOURCE_TYPE_ID}' AND ` +\n `ResourceRecordID='${conversationID}' AND Type='Role' AND ` +\n `RoleID IN ('${FEEDBACK_ROLE_IDS.join(\"','\")}')`\n });\n\n const granted = new Set<string>(\n (existing.Results || []).map((r: any) => (r.RoleID || '').toLowerCase())\n );\n\n for (const roleID of FEEDBACK_ROLE_IDS) {\n if (granted.has(roleID.toLowerCase())) continue;\n const perm = await md.GetEntityObject('MJ: Resource Permissions');\n perm.NewRecord();\n perm.Set('ResourceTypeID', CONVERSATIONS_RESOURCE_TYPE_ID);\n perm.Set('ResourceRecordID', conversationID);\n perm.Set('Type', 'Role');\n perm.Set('RoleID', roleID);\n perm.Set('PermissionLevel', 'View');\n perm.Set('Status', 'Approved');\n const ok = await perm.Save();\n if (!ok) {\n console.warn('[Rating] Failed to create ResourcePermission for role', roleID, (perm as any).LatestResult);\n }\n }\n } catch (e) {\n console.warn('[Rating] grantConversationAccess failed:', e);\n }\n }\n\n private async loadRating(): Promise<void> {\n if (!this.ConversationDetailId) return;\n try {\n const md = this.ProviderToUse;\n const entity = (await md.GetEntityObject(this.RatingEntityName)) as LoadableEntity;\n const loaded = await entity.Load(this.ConversationDetailId);\n if (loaded) {\n const rating = entity.Get(this.RatingField);\n this.CurrentUserRating = rating != null ? Number(rating) : null;\n this.CurrentUserComments = (entity.Get(this.RatingCommentField) ?? '') as string;\n this.cdr.detectChanges();\n }\n } catch (error) {\n // Silently swallow — message may not be persisted yet, or entity lookup failed.\n console.warn('[ConversationMessageRating] Could not load existing rating:', error);\n }\n }\n\n private async saveRating(rating: number, comments: string): Promise<string | null> {\n if (this.IsSaving) return null;\n if (rating < 1 || rating > 10) return null;\n if (!this.ConversationDetailId) return null;\n\n const prevRating = this.CurrentUserRating;\n const prevComments = this.CurrentUserComments;\n\n this.IsSaving = true;\n this.CurrentUserRating = rating;\n this.CurrentUserComments = comments;\n this.cdr.detectChanges();\n\n try {\n const md = this.ProviderToUse;\n const entity = (await md.GetEntityObject(this.RatingEntityName)) as LoadableEntity;\n const loaded = await entity.Load(this.ConversationDetailId);\n if (!loaded) {\n throw new Error(`ConversationDetail ${this.ConversationDetailId} not found in ${this.RatingEntityName}`);\n }\n entity.Set(this.RatingField, rating);\n entity.Set(this.RatingCommentField, comments || null);\n const saveResult = await entity.Save();\n if (!saveResult) {\n throw new Error(`Save failed: ${(entity as any).LatestResult?.Message ?? 'unknown'}`);\n }\n const conversationID = entity.Get('ConversationID');\n return typeof conversationID === 'string' ? conversationID : null;\n } catch (error) {\n console.error('[Rating] save failed:', error);\n this.CurrentUserRating = prevRating;\n this.CurrentUserComments = prevComments;\n this.cdr.detectChanges();\n return null;\n } finally {\n this.IsSaving = false;\n this.cdr.detectChanges();\n }\n }\n}\n"]}
1
+ {"version":3,"file":"conversation-message-rating.component.js","sourceRoot":"","sources":["../../../../src/lib/components/message/conversation-message-rating.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAA6B,MAAM,eAAe,CAAC;AAC5E,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EAA4B,OAAO,EAAY,MAAM,sBAAsB,CAAC;AACnF,OAAO,EACL,0BAA0B,EAG1B,cAAc,GACf,MAAM,+BAA+B,CAAC;;;;IA2CzB,uBAAyC;IACzC,+BAAwB;IAAA,YAAqC;IAAA,iBAAO;;;IAA5C,eAAqC;IAArC,qEAA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,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC;IACvE,CAAC;4HA5UU,kCAAkC;6DAAlC,kCAAkC;YAlGzC,AADF,8BAA8B,aACH;YAkBrB,AAjBF,uGAAe,+EAiByB;YAQ5C,AADE,iBAAM,EACF;;YAzBF,eAuBC;YAvBD,0EAuBC;;;iFA0EI,kCAAkC;cAvG9C,SAAS;6BACI,KAAK,YACP,gCAAgC,YAChC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BT;;kBAwEA,KAAK;;kBAGL,KAAK;;kBAOL,KAAK;;kBAGL,KAAK;;kBAcL,KAAK;;kBAOL,KAAK;;kBAGL,KAAK;;kBASL,KAAK;;kBAGL,KAAK;;kBASL,KAAK;;kBAGL,KAAK;;kBAaL,KAAK;;kBAGL,KAAK;;kFA9EK,kCAAkC","sourcesContent":["import { Component, Input, OnInit, ChangeDetectorRef } from '@angular/core';\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\nimport { BaseEntity, CompositeKey, RunView, UserInfo } from '@memberjunction/core';\nimport {\n MJConversationDetailEntity,\n MJResourcePermissionEntity,\n RatingJSON,\n UserInfoEngine,\n} from '@memberjunction/core-entities';\nimport { DialogService } from '../../services/dialog.service';\n\nconst FEEDBACK_CONSENT_KEY = 'agent-feedback-share-consent';\nconst CONVERSATIONS_RESOURCE_TYPE_ID = '81D4BC3D-9FEB-EF11-B01A-286B35C04427';\nconst FEEDBACK_ROLE_IDS = [\n 'deafccec-6a37-ef11-86d4-000d3a4e707e', // Developer\n 'dfafccec-6a37-ef11-86d4-000d3a4e707e' // Integration\n];\n\n/** Structural interface for conversation-detail entities supporting rating persistence without weak `.Get()`/`.Set()`. */\ninterface LoadableRatingEntity extends BaseEntity {\n Load(KeyValuePairs: CompositeKey | string, EntityRelationshipsToLoad?: string[]): Promise<boolean>;\n ConversationID?: string | null;\n UserRating?: number | null;\n UserFeedback?: string | null;\n}\n\n/**\n * Single-rating-per-message rating UI for an AI conversation response.\n *\n * Storage model: the rating + free-form comment live directly on the\n * ConversationDetail row, in `UserRating` (1-10, nullable) and `UserFeedback`\n * (nvarchar(max), nullable). This matches MJ's own pattern on\n * `__mj.ConversationDetail` and Skip's matching columns on\n * `Skip.ConversationDetail`. The host app picks the entity via @Input.\n */\n@Component({\n standalone: false,\n selector: 'mj-conversation-message-rating',\n template: `\n <div class=\"rating-container\">\n <div class=\"user-rating\">\n @if (canEdit) {\n <button\n class=\"rating-button\"\n [class.has-rated]=\"currentUserRating != null\"\n [disabled]=\"isSaving\"\n (click)=\"OpenRatingDialog()\"\n [title]=\"currentUserRating != null ? 'Edit your rating' : 'Rate this response'\"\n [attr.aria-label]=\"currentUserRating != null ? null : 'Rate response'\"\n type=\"button\">\n @if (currentUserRating != null) {\n <i class=\"fa-solid fa-pen-to-square\"></i>\n <span class=\"my-rating\">My rating: {{ currentUserRating }}/10</span>\n } @else {\n <i class=\"fa-regular fa-comment-dots\" aria-hidden=\"true\"></i>\n <span class=\"rate-label\">Rate response</span>\n }\n </button>\n } @else if (currentUserRating != null) {\n <span class=\"rating-readonly\"\n title=\"Rating left by the conversation owner — read-only\">\n <i class=\"fa-solid fa-comment-dots\"></i>\n <span>Rated {{ currentUserRating }}/10</span>\n </span>\n }\n </div>\n </div>\n `,\n styles: [`\n .rating-container {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 4px 0;\n }\n\n .user-rating {\n display: flex;\n gap: 4px;\n margin-left: auto;\n }\n\n .rating-button {\n display: inline-flex;\n align-items: center;\n gap: var(--mj-space-2);\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-strong);\n border-radius: 6px;\n padding: 6px 12px;\n cursor: pointer;\n font-size: 13px;\n color: var(--mj-text-primary);\n opacity: 0.85;\n transition: all 0.15s ease;\n }\n\n .rating-button:hover:not(:disabled) {\n opacity: 1;\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 6%, var(--mj-bg-surface));\n }\n\n .rating-button:disabled {\n cursor: not-allowed;\n opacity: 0.5;\n }\n\n .rating-button.has-rated {\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 10%, var(--mj-bg-surface));\n }\n\n .my-rating {\n font-weight: 500;\n }\n\n /* Phones: \"Rate response\" collapses to its icon */\n @media (max-width: 768px) {\n .rate-label {\n display: none;\n }\n }\n\n .rating-readonly {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n border: 1px solid var(--mj-border-default);\n border-radius: 6px;\n font-size: 12px;\n color: var(--mj-text-secondary);\n background: var(--mj-bg-surface-sunken);\n cursor: default;\n }\n `]\n})\nexport class ConversationMessageRatingComponent extends BaseAngularComponent implements OnInit {\n @Input() ConversationDetailId!: string;\n\n /** @deprecated Use {@link ConversationDetailId}. */\n @Input() set conversationDetailId(value: string) {\n this.ConversationDetailId = value;\n }\n /** @deprecated Use {@link ConversationDetailId}. */\n get conversationDetailId(): string {\n return this.ConversationDetailId;\n }\n @Input() CurrentUser!: UserInfo;\n\n /** @deprecated Use {@link CurrentUser}. */\n @Input() set currentUser(value: UserInfo) {\n this.CurrentUser = value;\n }\n /** @deprecated Use {@link CurrentUser}. */\n get currentUser(): UserInfo {\n return this.CurrentUser;\n }\n\n /**\n * When false, the rating UI renders as a read-only badge instead of an editable\n * button. Set by the parent (MessageItemComponent) to `false` when the current\n * user is not the conversation owner — the rating storage is a single field on\n * the ConversationDetail row, so only the owner is allowed to mutate it.\n */\n @Input() canEdit: boolean = true;\n\n /**\n * Entity name to load/update for the rating. Defaults to MJ's\n * `MJ: Conversation Details` (which has `UserRating`/`UserFeedback`).\n * Skip-Brain hosts pass `'Conversation Details__Skip'`.\n */\n @Input() RatingEntityName: string = 'MJ: Conversation Details';\n\n /** @deprecated Use {@link RatingEntityName}. */\n @Input() set ratingEntityName(value: string) {\n this.RatingEntityName = value;\n }\n /** @deprecated Use {@link RatingEntityName}. */\n get ratingEntityName(): string {\n return this.RatingEntityName;\n }\n\n /** Column on the entity that stores the 1-10 rating. */\n @Input() RatingField: string = 'UserRating';\n\n /** @deprecated Use {@link RatingField}. */\n @Input() set ratingField(value: string) {\n this.RatingField = value;\n }\n /** @deprecated Use {@link RatingField}. */\n get ratingField(): string {\n return this.RatingField;\n }\n\n /** Column on the entity that stores the free-form feedback. */\n @Input() RatingCommentField: string = 'UserFeedback';\n\n /** @deprecated Use {@link RatingCommentField}. */\n @Input() set ratingCommentField(value: string) {\n this.RatingCommentField = value;\n }\n /** @deprecated Use {@link RatingCommentField}. */\n get ratingCommentField(): string {\n return this.RatingCommentField;\n }\n\n /**\n * Optional: legacy pre-loaded ratings array (no longer used by storage; kept\n * to preserve the input shape used by existing call sites like\n * MessageItemComponent).\n */\n @Input() RatingsData?: RatingJSON[];\n\n /** @deprecated Use {@link RatingsData}. */\n @Input() set ratingsData(value: RatingJSON[] | undefined) {\n this.RatingsData = value;\n }\n /** @deprecated Use {@link RatingsData}. */\n get ratingsData(): RatingJSON[] | undefined {\n return this.RatingsData;\n }\n\n CurrentUserRating: number | null = null;\n\n /** @deprecated Use {@link CurrentUserRating}. */\n get currentUserRating(): number | null {\n return this.CurrentUserRating;\n }\n /** @deprecated Use {@link CurrentUserRating}. */\n set currentUserRating(value: number | null) {\n this.CurrentUserRating = value;\n }\n CurrentUserComments: string = '';\n\n /** @deprecated Use {@link CurrentUserComments}. */\n get currentUserComments(): string {\n return this.CurrentUserComments;\n }\n /** @deprecated Use {@link CurrentUserComments}. */\n set currentUserComments(value: string) {\n this.CurrentUserComments = value;\n }\n IsSaving = false;\n\n /** @deprecated Use {@link IsSaving}. */\n get isSaving() {\n return this.IsSaving;\n }\n /** @deprecated Use {@link IsSaving}. */\n set isSaving(value) {\n this.IsSaving = value;\n }\n\n constructor(\n private cdr: ChangeDetectorRef,\n private dialogService: DialogService\n ) {\n super();\n }\n\n async ngOnInit() {\n await this.loadRating();\n }\n\n async OpenRatingDialog(): Promise<void> {\n if (this.IsSaving) return;\n if (!this.canEdit) return;\n\n let consentAcknowledged = false;\n try {\n await UserInfoEngine.Instance.Config();\n consentAcknowledged = UserInfoEngine.Instance.GetSetting(FEEDBACK_CONSENT_KEY) === 'true';\n } catch (e) {\n console.warn('[Rating] Could not read consent flag, will require acknowledgement', e);\n }\n\n const result = await this.dialogService.rating({\n title: this.CurrentUserRating != null ? 'Edit your rating' : 'Rate this response',\n message: 'Rate the response on a 1-10 scale and (optionally) describe what was good or bad.',\n initialRating: this.CurrentUserRating,\n initialComments: this.CurrentUserComments,\n okText: 'Submit',\n requireConsent: !consentAcknowledged\n });\n\n if (result == null) return;\n\n const conversationID = await this.saveRating(result.rating, result.comments);\n\n if (result.consentNewlyAcknowledged) {\n try {\n const saved = await UserInfoEngine.Instance.SetSetting(FEEDBACK_CONSENT_KEY, 'true');\n if (!saved) {\n console.error(\n `[Rating] Failed to persist consent acknowledgement under key \"${FEEDBACK_CONSENT_KEY}\" — ` +\n `the dialog will re-prompt on next rating. Likely cause: the current user lacks ` +\n `create/update permission on the \"MJ: User Settings\" entity.`\n );\n }\n } catch (e) {\n console.error('[Rating] Could not persist consent flag', e);\n }\n }\n\n if (conversationID) {\n await this.grantConversationAccess(conversationID);\n }\n }\n\n /**\n * Grants the Integrations and Developer roles View access to the parent\n * Conversation via `MJ: Resource Permissions`. Idempotent — existing\n * permissions for the same role are not duplicated. Best-effort; any error\n * is logged but does not roll back the rating itself.\n */\n private async grantConversationAccess(conversationID: string): Promise<void> {\n try {\n const md = this.ProviderToUse;\n const rv = RunView.FromMetadataProvider(md);\n const existing = await rv.RunView<MJResourcePermissionEntity>({\n EntityName: 'MJ: Resource Permissions',\n ExtraFilter:\n `ResourceTypeID='${CONVERSATIONS_RESOURCE_TYPE_ID}' AND ` +\n `ResourceRecordID='${conversationID}' AND Type='Role' AND ` +\n `RoleID IN ('${FEEDBACK_ROLE_IDS.join(\"','\")}')`,\n ResultType: 'entity_object'\n });\n\n const granted = new Set<string>(\n (existing.Results || []).map((r) => (r.RoleID || '').toLowerCase())\n );\n\n for (const roleID of FEEDBACK_ROLE_IDS) {\n if (granted.has(roleID.toLowerCase())) continue;\n const perm = await md.GetEntityObject<MJResourcePermissionEntity>('MJ: Resource Permissions');\n perm.NewRecord();\n perm.ResourceTypeID = CONVERSATIONS_RESOURCE_TYPE_ID;\n perm.ResourceRecordID = conversationID;\n perm.Type = 'Role';\n perm.RoleID = roleID;\n perm.PermissionLevel = 'View';\n perm.Status = 'Approved';\n const ok = await perm.Save();\n if (!ok) {\n console.warn('[Rating] Failed to create ResourcePermission for role', roleID, perm.LatestResult);\n }\n }\n } catch (e) {\n console.warn('[Rating] grantConversationAccess failed:', e);\n }\n }\n\n private async loadRating(): Promise<void> {\n if (!this.ConversationDetailId) return;\n try {\n const md = this.ProviderToUse;\n const entity = await md.GetEntityObject<LoadableRatingEntity>(this.RatingEntityName);\n const loaded = await entity.Load(this.ConversationDetailId);\n if (loaded) {\n const rating = this.readEntityRating(entity);\n this.CurrentUserRating = rating != null ? Number(rating) : null;\n this.CurrentUserComments = this.readEntityComment(entity) ?? '';\n this.cdr.detectChanges();\n }\n } catch (error) {\n // Silently swallow — message may not be persisted yet, or entity lookup failed.\n console.warn('[ConversationMessageRating] Could not load existing rating:', error);\n }\n }\n\n private async saveRating(rating: number, comments: string): Promise<string | null> {\n if (this.IsSaving) return null;\n if (rating < 1 || rating > 10) return null;\n if (!this.ConversationDetailId) return null;\n\n const prevRating = this.CurrentUserRating;\n const prevComments = this.CurrentUserComments;\n\n this.IsSaving = true;\n this.CurrentUserRating = rating;\n this.CurrentUserComments = comments;\n this.cdr.detectChanges();\n\n try {\n const md = this.ProviderToUse;\n const entity = await md.GetEntityObject<LoadableRatingEntity>(this.RatingEntityName);\n const loaded = await entity.Load(this.ConversationDetailId);\n if (!loaded) {\n throw new Error(`ConversationDetail ${this.ConversationDetailId} not found in ${this.RatingEntityName}`);\n }\n this.writeEntityRating(entity, rating);\n this.writeEntityComment(entity, comments || null);\n const saveResult = await entity.Save();\n if (!saveResult) {\n throw new Error(`Save failed: ${entity.LatestResult?.Message ?? 'unknown'}`);\n }\n const conversationID = this.readEntityConversationId(entity);\n return typeof conversationID === 'string' ? conversationID : null;\n } catch (error) {\n console.error('[Rating] save failed:', error);\n this.CurrentUserRating = prevRating;\n this.CurrentUserComments = prevComments;\n this.cdr.detectChanges();\n return null;\n } finally {\n this.IsSaving = false;\n this.cdr.detectChanges();\n }\n }\n\n private readEntityRating(entity: LoadableRatingEntity): number | null {\n if (this.RatingField === 'UserRating' && entity instanceof MJConversationDetailEntity) {\n return entity.UserRating;\n }\n const field = entity.Fields.find((f) => f.Name === this.RatingField);\n if (field && typeof field.Value === 'number') {\n return field.Value;\n }\n if (field && typeof field.Value === 'string' && field.Value.trim() !== '') {\n const parsed = Number(field.Value);\n return Number.isFinite(parsed) ? parsed : null;\n }\n return entity.UserRating ?? null;\n }\n\n private readEntityComment(entity: LoadableRatingEntity): string | null {\n if (this.RatingCommentField === 'UserFeedback' && entity instanceof MJConversationDetailEntity) {\n return entity.UserFeedback;\n }\n const field = entity.Fields.find((f) => f.Name === this.RatingCommentField);\n if (field && typeof field.Value === 'string') {\n return field.Value;\n }\n return entity.UserFeedback ?? null;\n }\n\n private writeEntityRating(entity: LoadableRatingEntity, rating: number): void {\n if (this.RatingField === 'UserRating' && entity instanceof MJConversationDetailEntity) {\n entity.UserRating = rating;\n return;\n }\n const field = entity.Fields.find((f) => f.Name === this.RatingField);\n if (field) {\n field.Value = rating;\n return;\n }\n entity.UserRating = rating;\n }\n\n private writeEntityComment(entity: LoadableRatingEntity, comment: string | null): void {\n if (this.RatingCommentField === 'UserFeedback' && entity instanceof MJConversationDetailEntity) {\n entity.UserFeedback = comment;\n return;\n }\n const field = entity.Fields.find((f) => f.Name === this.RatingCommentField);\n if (field) {\n field.Value = comment;\n return;\n }\n entity.UserFeedback = comment;\n }\n\n private readEntityConversationId(entity: LoadableRatingEntity): string | null {\n if (typeof entity.ConversationID === 'string') {\n return entity.ConversationID;\n }\n const field = entity.Fields.find((f) => f.Name === 'ConversationID');\n return field && typeof field.Value === 'string' ? field.Value : null;\n }\n}\n"]}
@@ -340,8 +340,10 @@ export declare class MessageInputComponent extends BaseAngularComponent implemen
340
340
  * answer it, instead of always going back to the last agent that answered. The same call can
341
341
  * name the artifact version the message modifies. The answer replaces continuity only when it
342
342
  * is confident and arrives in time; an error, a slow or unsure answer keeps today's routing, and
343
- * a tagged message or a form response makes no call (see `decision-routing.ts`). False (the
344
- * default) changes nothing: no call, and today's routing.
343
+ * a tagged message or a form response makes no call (see `decision-routing.ts`). On by default:
344
+ * the routing calibration is fitted for a chat's mix, so the decision leaves the last agent only
345
+ * when it is at least 70% likely the person moved on. False makes no call and keeps today's
346
+ * routing.
345
347
  *
346
348
  * What goes to the model: each qualifying message sends these to the model behind the
347
349
  * `Default Decision` prompt, which can be a different vendor from the agents' own: the first
@@ -350,6 +352,14 @@ export declare class MessageInputComponent extends BaseAngularComponent implemen
350
352
  * `MJ: AI Prompt Runs` row, even when the answer comes too late to be used.
351
353
  */
352
354
  EnableDecisionRouting: boolean;
355
+ /**
356
+ * Opt-in Stage 6C.1 client-side Edge AI Pre-Discovery (`bge-small-en-v1.5` Top-5 ->
357
+ * `ms-marco-MiniLM-L-6-v2` in a lazy WASM Web Worker). When enabled (via this input or
358
+ * the `'mj.ai.edgePreDiscovery.enabled'` User Setting), warms up non-blockingly after mount
359
+ * and attaches an untrusted advisory `EdgePreDiscoveryHint` on opening conversation-manager
360
+ * turns. Server remains guard of truth; cold/offline workers fail open with zero delay.
361
+ */
362
+ EnableEdgePreDiscovery: boolean;
353
363
  /** The send slot was clicked in `stop` mode; the chat area stops the run(s). */
354
364
  StopClicked: EventEmitter<void>;
355
365
  MessageSent: EventEmitter<MJConversationDetailEntity>;
@@ -730,6 +740,7 @@ export declare class MessageInputComponent extends BaseAngularComponent implemen
730
740
  /** @deprecated Use {@link VoiceActive}. */
731
741
  set voiceActive(value: boolean);
732
742
  private realtimeActiveSub?;
743
+ private edgeWarmUpTimer;
733
744
  ngOnInit(): Promise<void>;
734
745
  ngOnChanges(changes: SimpleChanges): void;
735
746
  ngAfterViewInit(): void;
@@ -1174,14 +1185,11 @@ export declare class MessageInputComponent extends BaseAngularComponent implemen
1174
1185
  * more predictable and eliminates a common source of confusion where the intent check
1175
1186
  * incorrectly rerouted messages away from the active agent.
1176
1187
  *
1177
- * The checkContinuityIntent() method and the underlying checkAgentContinuityIntent() service
1178
- * method are preserved (not deleted) so we can reintroduce intent checking in the future
1179
- * when browser-local inference is fast enough (~20-50ms) to do this without blocking the
1180
- * user. See PR #2309 for the full discussion.
1181
- *
1182
- * With {@link EnableDecisionRouting} on, a typed routing decision runs before routing instead
1183
- * ({@link decideAgentRouting}); the prompt-based check stays unused. A confident answer from it
1184
- * may name the artifact version this agent should continue from.
1188
+ * Intent checking came back as a typed routing decision rather than an LLM call: with
1189
+ * {@link EnableDecisionRouting} on (the default), {@link decideAgentRouting} runs before routing,
1190
+ * in a few hundred milliseconds, and a confident answer may send the message to another agent or
1191
+ * name the artifact version this agent should continue from. The old prompt-based check is gone
1192
+ * from this component; `ConversationAgentService.CheckAgentContinuityIntent` is deprecated.
1185
1193
  *
1186
1194
  * @param branchId The turn's branch (null is Main).
1187
1195
  * @param targetArtifactVersionId The artifact version the routing decision named, or null.
@@ -1252,11 +1260,15 @@ export declare class MessageInputComponent extends BaseAngularComponent implemen
1252
1260
  private showHostTurnRows;
1253
1261
  /** Fires {@link AfterAgentTurn} for a turn that succeeded. */
1254
1262
  private emitAfterAgentTurn;
1263
+ /** Opt-in gate for Stage 6C.1 local Edge AI pre-discovery. */
1264
+ private isEdgePreDiscoveryEnabled;
1265
+ /** Schedules non-blocking catalog embedding warm-up strictly after mount when opted in. */
1266
+ private scheduleEdgePreDiscoveryWarmUp;
1255
1267
  /**
1256
- * Checks if message should continue with the previous agent, reading the path of `branchId`
1257
- * (null is Main). Emits events to show temporary intent checking message in conversation
1268
+ * Computes an untrusted advisory pre-discovery hint on opening turns with no `@Agent` mention.
1269
+ * Never blocks message sending if the worker is cold, offline, or over its deadline.
1258
1270
  */
1259
- private checkContinuityIntent;
1271
+ private computeEdgePreDiscoveryHint;
1260
1272
  /**
1261
1273
  * Returns focus to the message textarea
1262
1274
  */
@@ -1434,6 +1446,6 @@ export declare class MessageInputComponent extends BaseAngularComponent implemen
1434
1446
  */
1435
1447
  private cleanupCompletionTimestamp;
1436
1448
  static ɵfac: i0.ɵɵFactoryDeclaration<MessageInputComponent, never>;
1437
- static ɵcmp: i0.ɵɵComponentDeclaration<MessageInputComponent, "mj-message-input", never, { "ConversationId": { "alias": "ConversationId"; "required": false; }; "conversationId": { "alias": "conversationId"; "required": false; }; "ConversationName": { "alias": "ConversationName"; "required": false; }; "conversationName": { "alias": "conversationName"; "required": false; }; "CurrentUser": { "alias": "CurrentUser"; "required": false; }; "currentUser": { "alias": "currentUser"; "required": false; }; "Disabled": { "alias": "Disabled"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "ReadOnly": { "alias": "ReadOnly"; "required": false; }; "SendSlotMode": { "alias": "SendSlotMode"; "required": false; }; "StopCount": { "alias": "StopCount"; "required": false; }; "StopLabel": { "alias": "StopLabel"; "required": false; }; "StatusText": { "alias": "StatusText"; "required": false; }; "StatusElapsed": { "alias": "StatusElapsed"; "required": false; }; "Placeholder": { "alias": "Placeholder"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "ParentMessageId": { "alias": "ParentMessageId"; "required": false; }; "parentMessageId": { "alias": "parentMessageId"; "required": false; }; "EnableAttachments": { "alias": "EnableAttachments"; "required": false; }; "enableAttachments": { "alias": "enableAttachments"; "required": false; }; "EnableMentions": { "alias": "EnableMentions"; "required": false; }; "enableMentions": { "alias": "enableMentions"; "required": false; }; "EnableAgentMentions": { "alias": "EnableAgentMentions"; "required": false; }; "enableAgentMentions": { "alias": "enableAgentMentions"; "required": false; }; "EnableEntityMentions": { "alias": "EnableEntityMentions"; "required": false; }; "enableEntityMentions": { "alias": "enableEntityMentions"; "required": false; }; "EnableSkillCommands": { "alias": "EnableSkillCommands"; "required": false; }; "enableSkillCommands": { "alias": "enableSkillCommands"; "required": false; }; "EnablePlanMode": { "alias": "EnablePlanMode"; "required": false; }; "enablePlanMode": { "alias": "enablePlanMode"; "required": false; }; "EnableRealtime": { "alias": "EnableRealtime"; "required": false; }; "enableRealtime": { "alias": "enableRealtime"; "required": false; }; "MaxAttachments": { "alias": "MaxAttachments"; "required": false; }; "maxAttachments": { "alias": "maxAttachments"; "required": false; }; "MaxAttachmentSizeBytes": { "alias": "MaxAttachmentSizeBytes"; "required": false; }; "maxAttachmentSizeBytes": { "alias": "maxAttachmentSizeBytes"; "required": false; }; "AcceptedFileTypes": { "alias": "AcceptedFileTypes"; "required": false; }; "acceptedFileTypes": { "alias": "acceptedFileTypes"; "required": false; }; "ArtifactsByDetailId": { "alias": "ArtifactsByDetailId"; "required": false; }; "artifactsByDetailId": { "alias": "artifactsByDetailId"; "required": false; }; "SystemArtifactsByDetailId": { "alias": "SystemArtifactsByDetailId"; "required": false; }; "systemArtifactsByDetailId": { "alias": "systemArtifactsByDetailId"; "required": false; }; "AgentRunsByDetailId": { "alias": "AgentRunsByDetailId"; "required": false; }; "agentRunsByDetailId": { "alias": "agentRunsByDetailId"; "required": false; }; "EmptyStateMode": { "alias": "EmptyStateMode"; "required": false; }; "emptyStateMode": { "alias": "emptyStateMode"; "required": false; }; "AppContext": { "alias": "AppContext"; "required": false; }; "appContext": { "alias": "appContext"; "required": false; }; "DefaultAgentId": { "alias": "DefaultAgentId"; "required": false; }; "defaultAgentId": { "alias": "defaultAgentId"; "required": false; }; "ConversationDefaultAgentId": { "alias": "ConversationDefaultAgentId"; "required": false; }; "conversationDefaultAgentId": { "alias": "conversationDefaultAgentId"; "required": false; }; "AgentConfigurationPresetId": { "alias": "AgentConfigurationPresetId"; "required": false; }; "agentConfigurationPresetId": { "alias": "agentConfigurationPresetId"; "required": false; }; "InitialMessage": { "alias": "InitialMessage"; "required": false; }; "initialMessage": { "alias": "initialMessage"; "required": false; }; "InitialAttachments": { "alias": "InitialAttachments"; "required": false; }; "initialAttachments": { "alias": "initialAttachments"; "required": false; }; "ConversationHistory": { "alias": "ConversationHistory"; "required": false; }; "conversationHistory": { "alias": "conversationHistory"; "required": false; }; "InProgressMessageIds": { "alias": "InProgressMessageIds"; "required": false; }; "inProgressMessageIds": { "alias": "inProgressMessageIds"; "required": false; }; "ApplicationId": { "alias": "ApplicationId"; "required": false; }; "applicationId": { "alias": "applicationId"; "required": false; }; "AgentReplyMode": { "alias": "AgentReplyMode"; "required": false; }; "AllowedAgentIDs": { "alias": "AllowedAgentIDs"; "required": false; }; "MentionPeople": { "alias": "MentionPeople"; "required": false; }; "AgentHistoryFrom": { "alias": "AgentHistoryFrom"; "required": false; }; "TargetBranchID": { "alias": "TargetBranchID"; "required": false; }; "ResolveTargetBranch": { "alias": "ResolveTargetBranch"; "required": false; }; "AgentTurnHandler": { "alias": "AgentTurnHandler"; "required": false; }; "AutoNameConversation": { "alias": "AutoNameConversation"; "required": false; }; "EnableDecisionRouting": { "alias": "EnableDecisionRouting"; "required": false; }; "InitialDraft": { "alias": "InitialDraft"; "required": false; }; "initialDraft": { "alias": "initialDraft"; "required": false; }; }, { "StopClicked": "StopClicked"; "MessageSent": "MessageSent"; "messageSent": "messageSent"; "MessageStreamed": "MessageStreamed"; "AgentResponse": "AgentResponse"; "agentResponse": "agentResponse"; "BeforeAgentTurn": "BeforeAgentTurn"; "beforeAgentTurn": "beforeAgentTurn"; "AfterAgentTurn": "AfterAgentTurn"; "afterAgentTurn": "afterAgentTurn"; "AgentRunDetected": "AgentRunDetected"; "agentRunDetected": "agentRunDetected"; "AgentRunUpdate": "AgentRunUpdate"; "agentRunUpdate": "agentRunUpdate"; "MessageComplete": "MessageComplete"; "messageComplete": "messageComplete"; "ArtifactCreated": "ArtifactCreated"; "artifactCreated": "artifactCreated"; "ConversationRenamed": "ConversationRenamed"; "conversationRenamed": "conversationRenamed"; "IntentCheckStarted": "IntentCheckStarted"; "intentCheckStarted": "intentCheckStarted"; "IntentCheckCompleted": "IntentCheckCompleted"; "intentCheckCompleted": "intentCheckCompleted"; "InitialMessageAutoSendStarted": "InitialMessageAutoSendStarted"; "initialMessageAutoSendStarted": "initialMessageAutoSendStarted"; "InitialMessageAutoSendFailed": "InitialMessageAutoSendFailed"; "initialMessageAutoSendFailed": "initialMessageAutoSendFailed"; "EmptyStateSubmit": "EmptyStateSubmit"; "emptyStateSubmit": "emptyStateSubmit"; "UploadStateChanged": "UploadStateChanged"; "uploadStateChanged": "uploadStateChanged"; "InitialDraftApplied": "InitialDraftApplied"; "initialDraftApplied": "initialDraftApplied"; "DraftStateChanged": "DraftStateChanged"; "ComposerBlurred": "ComposerBlurred"; }, never, never, false, never>;
1449
+ static ɵcmp: i0.ɵɵComponentDeclaration<MessageInputComponent, "mj-message-input", never, { "ConversationId": { "alias": "ConversationId"; "required": false; }; "conversationId": { "alias": "conversationId"; "required": false; }; "ConversationName": { "alias": "ConversationName"; "required": false; }; "conversationName": { "alias": "conversationName"; "required": false; }; "CurrentUser": { "alias": "CurrentUser"; "required": false; }; "currentUser": { "alias": "currentUser"; "required": false; }; "Disabled": { "alias": "Disabled"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "ReadOnly": { "alias": "ReadOnly"; "required": false; }; "SendSlotMode": { "alias": "SendSlotMode"; "required": false; }; "StopCount": { "alias": "StopCount"; "required": false; }; "StopLabel": { "alias": "StopLabel"; "required": false; }; "StatusText": { "alias": "StatusText"; "required": false; }; "StatusElapsed": { "alias": "StatusElapsed"; "required": false; }; "Placeholder": { "alias": "Placeholder"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "ParentMessageId": { "alias": "ParentMessageId"; "required": false; }; "parentMessageId": { "alias": "parentMessageId"; "required": false; }; "EnableAttachments": { "alias": "EnableAttachments"; "required": false; }; "enableAttachments": { "alias": "enableAttachments"; "required": false; }; "EnableMentions": { "alias": "EnableMentions"; "required": false; }; "enableMentions": { "alias": "enableMentions"; "required": false; }; "EnableAgentMentions": { "alias": "EnableAgentMentions"; "required": false; }; "enableAgentMentions": { "alias": "enableAgentMentions"; "required": false; }; "EnableEntityMentions": { "alias": "EnableEntityMentions"; "required": false; }; "enableEntityMentions": { "alias": "enableEntityMentions"; "required": false; }; "EnableSkillCommands": { "alias": "EnableSkillCommands"; "required": false; }; "enableSkillCommands": { "alias": "enableSkillCommands"; "required": false; }; "EnablePlanMode": { "alias": "EnablePlanMode"; "required": false; }; "enablePlanMode": { "alias": "enablePlanMode"; "required": false; }; "EnableRealtime": { "alias": "EnableRealtime"; "required": false; }; "enableRealtime": { "alias": "enableRealtime"; "required": false; }; "MaxAttachments": { "alias": "MaxAttachments"; "required": false; }; "maxAttachments": { "alias": "maxAttachments"; "required": false; }; "MaxAttachmentSizeBytes": { "alias": "MaxAttachmentSizeBytes"; "required": false; }; "maxAttachmentSizeBytes": { "alias": "maxAttachmentSizeBytes"; "required": false; }; "AcceptedFileTypes": { "alias": "AcceptedFileTypes"; "required": false; }; "acceptedFileTypes": { "alias": "acceptedFileTypes"; "required": false; }; "ArtifactsByDetailId": { "alias": "ArtifactsByDetailId"; "required": false; }; "artifactsByDetailId": { "alias": "artifactsByDetailId"; "required": false; }; "SystemArtifactsByDetailId": { "alias": "SystemArtifactsByDetailId"; "required": false; }; "systemArtifactsByDetailId": { "alias": "systemArtifactsByDetailId"; "required": false; }; "AgentRunsByDetailId": { "alias": "AgentRunsByDetailId"; "required": false; }; "agentRunsByDetailId": { "alias": "agentRunsByDetailId"; "required": false; }; "EmptyStateMode": { "alias": "EmptyStateMode"; "required": false; }; "emptyStateMode": { "alias": "emptyStateMode"; "required": false; }; "AppContext": { "alias": "AppContext"; "required": false; }; "appContext": { "alias": "appContext"; "required": false; }; "DefaultAgentId": { "alias": "DefaultAgentId"; "required": false; }; "defaultAgentId": { "alias": "defaultAgentId"; "required": false; }; "ConversationDefaultAgentId": { "alias": "ConversationDefaultAgentId"; "required": false; }; "conversationDefaultAgentId": { "alias": "conversationDefaultAgentId"; "required": false; }; "AgentConfigurationPresetId": { "alias": "AgentConfigurationPresetId"; "required": false; }; "agentConfigurationPresetId": { "alias": "agentConfigurationPresetId"; "required": false; }; "InitialMessage": { "alias": "InitialMessage"; "required": false; }; "initialMessage": { "alias": "initialMessage"; "required": false; }; "InitialAttachments": { "alias": "InitialAttachments"; "required": false; }; "initialAttachments": { "alias": "initialAttachments"; "required": false; }; "ConversationHistory": { "alias": "ConversationHistory"; "required": false; }; "conversationHistory": { "alias": "conversationHistory"; "required": false; }; "InProgressMessageIds": { "alias": "InProgressMessageIds"; "required": false; }; "inProgressMessageIds": { "alias": "inProgressMessageIds"; "required": false; }; "ApplicationId": { "alias": "ApplicationId"; "required": false; }; "applicationId": { "alias": "applicationId"; "required": false; }; "AgentReplyMode": { "alias": "AgentReplyMode"; "required": false; }; "AllowedAgentIDs": { "alias": "AllowedAgentIDs"; "required": false; }; "MentionPeople": { "alias": "MentionPeople"; "required": false; }; "AgentHistoryFrom": { "alias": "AgentHistoryFrom"; "required": false; }; "TargetBranchID": { "alias": "TargetBranchID"; "required": false; }; "ResolveTargetBranch": { "alias": "ResolveTargetBranch"; "required": false; }; "AgentTurnHandler": { "alias": "AgentTurnHandler"; "required": false; }; "AutoNameConversation": { "alias": "AutoNameConversation"; "required": false; }; "EnableDecisionRouting": { "alias": "EnableDecisionRouting"; "required": false; }; "EnableEdgePreDiscovery": { "alias": "EnableEdgePreDiscovery"; "required": false; }; "InitialDraft": { "alias": "InitialDraft"; "required": false; }; "initialDraft": { "alias": "initialDraft"; "required": false; }; }, { "StopClicked": "StopClicked"; "MessageSent": "MessageSent"; "messageSent": "messageSent"; "MessageStreamed": "MessageStreamed"; "AgentResponse": "AgentResponse"; "agentResponse": "agentResponse"; "BeforeAgentTurn": "BeforeAgentTurn"; "beforeAgentTurn": "beforeAgentTurn"; "AfterAgentTurn": "AfterAgentTurn"; "afterAgentTurn": "afterAgentTurn"; "AgentRunDetected": "AgentRunDetected"; "agentRunDetected": "agentRunDetected"; "AgentRunUpdate": "AgentRunUpdate"; "agentRunUpdate": "agentRunUpdate"; "MessageComplete": "MessageComplete"; "messageComplete": "messageComplete"; "ArtifactCreated": "ArtifactCreated"; "artifactCreated": "artifactCreated"; "ConversationRenamed": "ConversationRenamed"; "conversationRenamed": "conversationRenamed"; "IntentCheckStarted": "IntentCheckStarted"; "intentCheckStarted": "intentCheckStarted"; "IntentCheckCompleted": "IntentCheckCompleted"; "intentCheckCompleted": "intentCheckCompleted"; "InitialMessageAutoSendStarted": "InitialMessageAutoSendStarted"; "initialMessageAutoSendStarted": "initialMessageAutoSendStarted"; "InitialMessageAutoSendFailed": "InitialMessageAutoSendFailed"; "initialMessageAutoSendFailed": "initialMessageAutoSendFailed"; "EmptyStateSubmit": "EmptyStateSubmit"; "emptyStateSubmit": "emptyStateSubmit"; "UploadStateChanged": "UploadStateChanged"; "uploadStateChanged": "uploadStateChanged"; "InitialDraftApplied": "InitialDraftApplied"; "initialDraftApplied": "initialDraftApplied"; "DraftStateChanged": "DraftStateChanged"; "ComposerBlurred": "ComposerBlurred"; }, never, never, false, never>;
1438
1450
  }
1439
1451
  //# sourceMappingURL=message-input.component.d.ts.map