@memberjunction/ng-conversations 2.111.1 → 2.113.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/components/collection/artifact-create-modal.component.js +1 -1
- package/dist/lib/components/collection/artifact-create-modal.component.js.map +1 -1
- package/dist/lib/components/collection/collection-artifact-card.component.d.ts +8 -7
- package/dist/lib/components/collection/collection-artifact-card.component.d.ts.map +1 -1
- package/dist/lib/components/collection/collection-artifact-card.component.js +52 -36
- package/dist/lib/components/collection/collection-artifact-card.component.js.map +1 -1
- package/dist/lib/components/collection/collection-view.component.d.ts +28 -9
- package/dist/lib/components/collection/collection-view.component.d.ts.map +1 -1
- package/dist/lib/components/collection/collection-view.component.js +124 -58
- package/dist/lib/components/collection/collection-view.component.js.map +1 -1
- package/dist/lib/components/collection/collections-full-view.component.d.ts +18 -6
- package/dist/lib/components/collection/collections-full-view.component.d.ts.map +1 -1
- package/dist/lib/components/collection/collections-full-view.component.js +82 -58
- package/dist/lib/components/collection/collections-full-view.component.js.map +1 -1
- package/dist/lib/components/conversation/conversation-chat-area.component.d.ts +37 -0
- package/dist/lib/components/conversation/conversation-chat-area.component.d.ts.map +1 -1
- package/dist/lib/components/conversation/conversation-chat-area.component.js +278 -162
- package/dist/lib/components/conversation/conversation-chat-area.component.js.map +1 -1
- package/dist/lib/components/conversation/conversation-list.component.d.ts +10 -3
- package/dist/lib/components/conversation/conversation-list.component.d.ts.map +1 -1
- package/dist/lib/components/conversation/conversation-list.component.js +118 -77
- package/dist/lib/components/conversation/conversation-list.component.js.map +1 -1
- package/dist/lib/components/global-tasks/global-tasks-panel.component.d.ts +25 -0
- package/dist/lib/components/global-tasks/global-tasks-panel.component.d.ts.map +1 -0
- package/dist/lib/components/global-tasks/global-tasks-panel.component.js +206 -0
- package/dist/lib/components/global-tasks/global-tasks-panel.component.js.map +1 -0
- package/dist/lib/components/message/conversation-message-rating.component.d.ts +47 -0
- package/dist/lib/components/message/conversation-message-rating.component.d.ts.map +1 -0
- package/dist/lib/components/message/conversation-message-rating.component.js +224 -0
- package/dist/lib/components/message/conversation-message-rating.component.js.map +1 -0
- package/dist/lib/components/message/message-input-box.component.d.ts.map +1 -1
- package/dist/lib/components/message/message-input-box.component.js +2 -12
- package/dist/lib/components/message/message-input-box.component.js.map +1 -1
- package/dist/lib/components/message/message-input.component.d.ts +17 -2
- package/dist/lib/components/message/message-input.component.d.ts.map +1 -1
- package/dist/lib/components/message/message-input.component.js +258 -275
- package/dist/lib/components/message/message-input.component.js.map +1 -1
- package/dist/lib/components/message/message-item.component.d.ts +31 -1
- package/dist/lib/components/message/message-item.component.d.ts.map +1 -1
- package/dist/lib/components/message/message-item.component.js +232 -116
- package/dist/lib/components/message/message-item.component.js.map +1 -1
- package/dist/lib/components/message/message-list.component.d.ts +3 -1
- package/dist/lib/components/message/message-list.component.d.ts.map +1 -1
- package/dist/lib/components/message/message-list.component.js +11 -2
- package/dist/lib/components/message/message-list.component.js.map +1 -1
- package/dist/lib/components/navigation/conversation-navigation.component.d.ts +7 -1
- package/dist/lib/components/navigation/conversation-navigation.component.d.ts.map +1 -1
- package/dist/lib/components/navigation/conversation-navigation.component.js +24 -14
- package/dist/lib/components/navigation/conversation-navigation.component.js.map +1 -1
- package/dist/lib/components/tasks/tasks-dropdown.component.d.ts +17 -28
- package/dist/lib/components/tasks/tasks-dropdown.component.d.ts.map +1 -1
- package/dist/lib/components/tasks/tasks-dropdown.component.js +175 -217
- package/dist/lib/components/tasks/tasks-dropdown.component.js.map +1 -1
- package/dist/lib/components/workspace/conversation-workspace.component.d.ts +14 -8
- package/dist/lib/components/workspace/conversation-workspace.component.d.ts.map +1 -1
- package/dist/lib/components/workspace/conversation-workspace.component.js +103 -64
- package/dist/lib/components/workspace/conversation-workspace.component.js.map +1 -1
- package/dist/lib/conversations.module.d.ts +54 -52
- package/dist/lib/conversations.module.d.ts.map +1 -1
- package/dist/lib/conversations.module.js +11 -3
- package/dist/lib/conversations.module.js.map +1 -1
- package/dist/lib/models/conversation-complete-query.model.d.ts +31 -22
- package/dist/lib/models/conversation-complete-query.model.d.ts.map +1 -1
- package/dist/lib/models/conversation-complete-query.model.js +5 -2
- package/dist/lib/models/conversation-complete-query.model.js.map +1 -1
- package/dist/lib/models/lazy-artifact-info.d.ts +3 -0
- package/dist/lib/models/lazy-artifact-info.d.ts.map +1 -1
- package/dist/lib/models/lazy-artifact-info.js +7 -2
- package/dist/lib/models/lazy-artifact-info.js.map +1 -1
- package/dist/lib/services/active-tasks.service.d.ts +18 -0
- package/dist/lib/services/active-tasks.service.d.ts.map +1 -1
- package/dist/lib/services/active-tasks.service.js +53 -3
- package/dist/lib/services/active-tasks.service.js.map +1 -1
- package/dist/lib/services/agent-state.service.d.ts.map +1 -1
- package/dist/lib/services/agent-state.service.js +5 -5
- package/dist/lib/services/agent-state.service.js.map +1 -1
- package/dist/lib/services/artifact-permission.service.d.ts.map +1 -1
- package/dist/lib/services/artifact-permission.service.js +3 -1
- package/dist/lib/services/artifact-permission.service.js.map +1 -1
- package/dist/lib/services/artifact-state.service.d.ts +22 -5
- package/dist/lib/services/artifact-state.service.d.ts.map +1 -1
- package/dist/lib/services/artifact-state.service.js +118 -30
- package/dist/lib/services/artifact-state.service.js.map +1 -1
- package/dist/lib/services/artifact-use-tracking.service.d.ts +35 -0
- package/dist/lib/services/artifact-use-tracking.service.d.ts.map +1 -0
- package/dist/lib/services/artifact-use-tracking.service.js +76 -0
- package/dist/lib/services/artifact-use-tracking.service.js.map +1 -0
- package/dist/lib/services/conversation-agent.service.d.ts +30 -3
- package/dist/lib/services/conversation-agent.service.d.ts.map +1 -1
- package/dist/lib/services/conversation-agent.service.js +101 -12
- package/dist/lib/services/conversation-agent.service.js.map +1 -1
- package/dist/lib/services/conversation-state.service.d.ts +13 -0
- package/dist/lib/services/conversation-state.service.d.ts.map +1 -1
- package/dist/lib/services/conversation-state.service.js +26 -0
- package/dist/lib/services/conversation-state.service.js.map +1 -1
- package/dist/lib/services/mention-autocomplete.service.d.ts.map +1 -1
- package/dist/lib/services/mention-autocomplete.service.js +1 -1
- package/dist/lib/services/mention-autocomplete.service.js.map +1 -1
- package/dist/lib/services/search.service.d.ts.map +1 -1
- package/dist/lib/services/search.service.js +3 -1
- package/dist/lib/services/search.service.js.map +1 -1
- package/dist/public-api.d.ts +3 -0
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +3 -0
- package/dist/public-api.js.map +1 -1
- package/package.json +14 -14
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Component, Input, Output, EventEmitter, ViewChild } from '@angular/core';
|
|
2
|
-
import { RunQuery, Metadata } from '@memberjunction/core';
|
|
2
|
+
import { RunQuery, Metadata, LogStatusEx } from '@memberjunction/core';
|
|
3
3
|
import { LazyArtifactInfo } from '../../models/lazy-artifact-info';
|
|
4
4
|
import { parseConversationDetailComplete } from '../../models/conversation-complete-query.model';
|
|
5
5
|
import { ArtifactViewerPanelComponent } from '@memberjunction/ng-artifacts';
|
|
@@ -20,19 +20,20 @@ import * as i12 from "../message/message-input.component";
|
|
|
20
20
|
import * as i13 from "./conversation-empty-state.component";
|
|
21
21
|
import * as i14 from "../thread/thread-panel.component";
|
|
22
22
|
import * as i15 from "../project/project-selector.component";
|
|
23
|
-
import * as i16 from "../
|
|
24
|
-
import * as i17 from "../
|
|
25
|
-
import * as i18 from "../
|
|
26
|
-
import * as i19 from "../export/export-modal.component";
|
|
23
|
+
import * as i16 from "../agent/active-agent-indicator.component";
|
|
24
|
+
import * as i17 from "../members/members-modal.component";
|
|
25
|
+
import * as i18 from "../export/export-modal.component";
|
|
27
26
|
const _c0 = ["scrollContainer"];
|
|
28
27
|
const _c1 = ["messageInput"];
|
|
29
|
-
const _forTrack0 = ($index, $item) => $item.
|
|
30
|
-
const _forTrack1 = ($index, $item) => $item.
|
|
28
|
+
const _forTrack0 = ($index, $item) => $item.conversationId;
|
|
29
|
+
const _forTrack1 = ($index, $item) => $item.artifactId;
|
|
30
|
+
const _forTrack2 = ($index, $item) => $item.versionId;
|
|
31
|
+
const _c2 = () => [];
|
|
31
32
|
function ConversationChatAreaComponent_div_1_button_4_Template(rf, ctx) { if (rf & 1) {
|
|
32
33
|
const _r2 = i0.ɵɵgetCurrentView();
|
|
33
|
-
i0.ɵɵelementStart(0, "button",
|
|
34
|
+
i0.ɵɵelementStart(0, "button", 28);
|
|
34
35
|
i0.ɵɵlistener("click", function ConversationChatAreaComponent_div_1_button_4_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r2); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.openProjectSelector()); });
|
|
35
|
-
i0.ɵɵelement(1, "i",
|
|
36
|
+
i0.ɵɵelement(1, "i", 29);
|
|
36
37
|
i0.ɵɵelementStart(2, "span");
|
|
37
38
|
i0.ɵɵtext(3);
|
|
38
39
|
i0.ɵɵelementEnd()();
|
|
@@ -43,9 +44,9 @@ function ConversationChatAreaComponent_div_1_button_4_Template(rf, ctx) { if (rf
|
|
|
43
44
|
} }
|
|
44
45
|
function ConversationChatAreaComponent_div_1_button_9_Template(rf, ctx) { if (rf & 1) {
|
|
45
46
|
const _r5 = i0.ɵɵgetCurrentView();
|
|
46
|
-
i0.ɵɵelementStart(0, "button",
|
|
47
|
+
i0.ɵɵelementStart(0, "button", 30);
|
|
47
48
|
i0.ɵɵlistener("click", function ConversationChatAreaComponent_div_1_button_9_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r5); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.viewArtifacts()); });
|
|
48
|
-
i0.ɵɵelement(1, "i",
|
|
49
|
+
i0.ɵɵelement(1, "i", 31);
|
|
49
50
|
i0.ɵɵelementStart(2, "span");
|
|
50
51
|
i0.ɵɵtext(3);
|
|
51
52
|
i0.ɵɵelementEnd()();
|
|
@@ -70,18 +71,15 @@ function ConversationChatAreaComponent_div_1_Template(rf, ctx) { if (rf & 1) {
|
|
|
70
71
|
i0.ɵɵelementStart(10, "mj-active-agent-indicator", 22);
|
|
71
72
|
i0.ɵɵlistener("togglePanel", function ConversationChatAreaComponent_div_1_Template_mj_active_agent_indicator_togglePanel_10_listener() { i0.ɵɵrestoreView(_r1); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onToggleAgentPanel()); })("agentSelected", function ConversationChatAreaComponent_div_1_Template_mj_active_agent_indicator_agentSelected_10_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onAgentSelected($event)); });
|
|
72
73
|
i0.ɵɵelementEnd()();
|
|
73
|
-
i0.ɵɵelementStart(11, "div", 23)(12, "
|
|
74
|
-
i0.ɵɵlistener("
|
|
74
|
+
i0.ɵɵelementStart(11, "div", 23)(12, "button", 24);
|
|
75
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_div_1_Template_button_click_12_listener() { i0.ɵɵrestoreView(_r1); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.exportConversation()); });
|
|
76
|
+
i0.ɵɵelement(13, "i", 25);
|
|
77
|
+
i0.ɵɵtext(14, " Export ");
|
|
75
78
|
i0.ɵɵelementEnd();
|
|
76
|
-
i0.ɵɵelementStart(
|
|
77
|
-
i0.ɵɵlistener("click", function
|
|
78
|
-
i0.ɵɵelement(
|
|
79
|
-
i0.ɵɵtext(
|
|
80
|
-
i0.ɵɵelementEnd();
|
|
81
|
-
i0.ɵɵelementStart(16, "button", 27);
|
|
82
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_div_1_Template_button_click_16_listener() { i0.ɵɵrestoreView(_r1); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.shareConversation()); });
|
|
83
|
-
i0.ɵɵelement(17, "i", 28);
|
|
84
|
-
i0.ɵɵtext(18, " Share ");
|
|
79
|
+
i0.ɵɵelementStart(15, "button", 26);
|
|
80
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_div_1_Template_button_click_15_listener() { i0.ɵɵrestoreView(_r1); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.shareConversation()); });
|
|
81
|
+
i0.ɵɵelement(16, "i", 27);
|
|
82
|
+
i0.ɵɵtext(17, " Share ");
|
|
85
83
|
i0.ɵɵelementEnd()()();
|
|
86
84
|
} if (rf & 2) {
|
|
87
85
|
const conversation_r4 = ctx.ngIf;
|
|
@@ -96,15 +94,13 @@ function ConversationChatAreaComponent_div_1_Template(rf, ctx) { if (rf & 1) {
|
|
|
96
94
|
i0.ɵɵproperty("ngIf", ctx_r2.artifactCountDisplay > 0);
|
|
97
95
|
i0.ɵɵadvance();
|
|
98
96
|
i0.ɵɵproperty("conversationId", ctx_r2.conversationState.activeConversation.ID)("currentUser", ctx_r2.currentUser);
|
|
99
|
-
i0.ɵɵadvance(
|
|
100
|
-
i0.ɵɵproperty("currentUser", ctx_r2.currentUser);
|
|
101
|
-
i0.ɵɵadvance(4);
|
|
97
|
+
i0.ɵɵadvance(5);
|
|
102
98
|
i0.ɵɵclassProp("shared", ctx_r2.isShared);
|
|
103
99
|
i0.ɵɵproperty("title", ctx_r2.isShared ? "Manage sharing" : "Share conversation");
|
|
104
100
|
} }
|
|
105
101
|
function ConversationChatAreaComponent_Conditional_4_Template(rf, ctx) { if (rf & 1) {
|
|
106
102
|
const _r6 = i0.ɵɵgetCurrentView();
|
|
107
|
-
i0.ɵɵelementStart(0, "mj-conversation-empty-state",
|
|
103
|
+
i0.ɵɵelementStart(0, "mj-conversation-empty-state", 32);
|
|
108
104
|
i0.ɵɵlistener("messageSent", function ConversationChatAreaComponent_Conditional_4_Template_mj_conversation_empty_state_messageSent_0_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onEmptyStateMessageSent($event)); });
|
|
109
105
|
i0.ɵɵelementEnd();
|
|
110
106
|
} if (rf & 2) {
|
|
@@ -112,69 +108,73 @@ function ConversationChatAreaComponent_Conditional_4_Template(rf, ctx) { if (rf
|
|
|
112
108
|
i0.ɵɵproperty("currentUser", ctx_r2.currentUser)("disabled", ctx_r2.isProcessing);
|
|
113
109
|
} }
|
|
114
110
|
function ConversationChatAreaComponent_Conditional_5_Template(rf, ctx) { if (rf & 1) {
|
|
115
|
-
i0.ɵɵelementStart(0, "div", 7)(1, "div",
|
|
116
|
-
i0.ɵɵelement(2, "i",
|
|
111
|
+
i0.ɵɵelementStart(0, "div", 7)(1, "div", 33);
|
|
112
|
+
i0.ɵɵelement(2, "i", 34);
|
|
117
113
|
i0.ɵɵelementStart(3, "span");
|
|
118
114
|
i0.ɵɵtext(4, "Loading conversation...");
|
|
119
115
|
i0.ɵɵelementEnd()()();
|
|
120
116
|
} }
|
|
121
117
|
function ConversationChatAreaComponent_Conditional_6_span_4_Template(rf, ctx) { if (rf & 1) {
|
|
122
118
|
const _r8 = i0.ɵɵgetCurrentView();
|
|
123
|
-
i0.ɵɵelementStart(0, "span",
|
|
119
|
+
i0.ɵɵelementStart(0, "span", 41);
|
|
124
120
|
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_6_span_4_Template_span_click_0_listener() { i0.ɵɵrestoreView(_r8); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.scrollToBottomAnimate()); });
|
|
125
|
-
i0.ɵɵelement(1, "i",
|
|
121
|
+
i0.ɵɵelement(1, "i", 42);
|
|
126
122
|
i0.ɵɵelementEnd();
|
|
127
123
|
} }
|
|
128
124
|
function ConversationChatAreaComponent_Conditional_6_Conditional_6_Template(rf, ctx) { if (rf & 1) {
|
|
129
|
-
i0.ɵɵelementStart(0, "div",
|
|
130
|
-
i0.ɵɵelement(2, "i",
|
|
125
|
+
i0.ɵɵelementStart(0, "div", 39)(1, "div", 43);
|
|
126
|
+
i0.ɵɵelement(2, "i", 34);
|
|
131
127
|
i0.ɵɵelementStart(3, "span");
|
|
132
128
|
i0.ɵɵtext(4, "Loading conversation data...");
|
|
133
129
|
i0.ɵɵelementEnd()()();
|
|
134
130
|
} }
|
|
135
|
-
function
|
|
131
|
+
function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
136
132
|
const _r9 = i0.ɵɵgetCurrentView();
|
|
137
|
-
i0.ɵɵelementStart(0, "mj-message-input",
|
|
138
|
-
i0.ɵɵlistener("messageSent", function
|
|
133
|
+
i0.ɵɵelementStart(0, "mj-message-input", 45, 1);
|
|
134
|
+
i0.ɵɵlistener("messageSent", function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template_mj_message_input_messageSent_0_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r2 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r2.onMessageSent($event)); })("agentResponse", function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template_mj_message_input_agentResponse_0_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r2 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r2.onAgentResponse($event)); })("agentRunDetected", function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template_mj_message_input_agentRunDetected_0_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r2 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r2.onAgentRunDetected($event)); })("agentRunUpdate", function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template_mj_message_input_agentRunUpdate_0_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r2 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r2.onAgentRunUpdate($event)); })("messageComplete", function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template_mj_message_input_messageComplete_0_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r2 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r2.onMessageComplete($event)); })("artifactCreated", function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template_mj_message_input_artifactCreated_0_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r2 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r2.onArtifactCreated($event)); })("conversationRenamed", function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template_mj_message_input_conversationRenamed_0_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r2 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r2.onConversationRenamed($event)); })("intentCheckStarted", function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template_mj_message_input_intentCheckStarted_0_listener() { i0.ɵɵrestoreView(_r9); const ctx_r2 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r2.onIntentCheckStarted()); })("intentCheckCompleted", function ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template_mj_message_input_intentCheckCompleted_0_listener() { i0.ɵɵrestoreView(_r9); const ctx_r2 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r2.onIntentCheckCompleted()); });
|
|
139
135
|
i0.ɵɵelementEnd();
|
|
140
136
|
} if (rf & 2) {
|
|
137
|
+
const inputRef_r10 = ctx.$implicit;
|
|
141
138
|
const ctx_r2 = i0.ɵɵnextContext(3);
|
|
142
|
-
i0.ɵɵproperty("
|
|
139
|
+
i0.ɵɵproperty("hidden", inputRef_r10.conversationId !== ctx_r2.conversationState.activeConversation.ID)("conversationId", inputRef_r10.conversationId)("conversationName", inputRef_r10.conversationName)("currentUser", ctx_r2.currentUser)("conversationHistory", inputRef_r10.conversationId === ctx_r2.conversationState.activeConversation.ID ? ctx_r2.messages : i0.ɵɵpureFunction0(10, _c2))("artifactsByDetailId", inputRef_r10.conversationId === ctx_r2.conversationState.activeConversation.ID ? ctx_r2.artifactsByDetailId : ctx_r2.emptyArtifactsMap)("agentRunsByDetailId", inputRef_r10.conversationId === ctx_r2.conversationState.activeConversation.ID ? ctx_r2.agentRunsByDetailId : ctx_r2.emptyAgentRunsMap)("inProgressMessageIds", inputRef_r10.conversationId === ctx_r2.conversationState.activeConversation.ID ? ctx_r2.inProgressMessageIds : ctx_r2.emptyInProgressIds)("disabled", ctx_r2.isProcessing)("initialMessage", inputRef_r10.conversationId === ctx_r2.conversationState.activeConversation.ID ? ctx_r2.conversationState.pendingMessageToSend : null);
|
|
143
140
|
} }
|
|
144
141
|
function ConversationChatAreaComponent_Conditional_6_Conditional_7_Template(rf, ctx) { if (rf & 1) {
|
|
145
|
-
i0.ɵɵ
|
|
142
|
+
i0.ɵɵelementStart(0, "div", 40);
|
|
143
|
+
i0.ɵɵrepeaterCreate(1, ConversationChatAreaComponent_Conditional_6_Conditional_7_For_2_Template, 2, 11, "mj-message-input", 44, _forTrack0);
|
|
144
|
+
i0.ɵɵelementEnd();
|
|
146
145
|
} if (rf & 2) {
|
|
147
146
|
const ctx_r2 = i0.ɵɵnextContext(2);
|
|
148
|
-
i0.ɵɵ
|
|
147
|
+
i0.ɵɵadvance();
|
|
148
|
+
i0.ɵɵrepeater(ctx_r2.getCachedInputs());
|
|
149
149
|
} }
|
|
150
150
|
function ConversationChatAreaComponent_Conditional_6_Template(rf, ctx) { if (rf & 1) {
|
|
151
151
|
const _r7 = i0.ɵɵgetCurrentView();
|
|
152
|
-
i0.ɵɵelementStart(0, "div", 8)(1, "div",
|
|
152
|
+
i0.ɵɵelementStart(0, "div", 8)(1, "div", 35, 0);
|
|
153
153
|
i0.ɵɵlistener("scroll", function ConversationChatAreaComponent_Conditional_6_Template_div_scroll_1_listener() { i0.ɵɵrestoreView(_r7); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.checkScroll()); });
|
|
154
|
-
i0.ɵɵelementStart(3, "mj-conversation-message-list",
|
|
154
|
+
i0.ɵɵelementStart(3, "mj-conversation-message-list", 36);
|
|
155
155
|
i0.ɵɵlistener("replyInThread", function ConversationChatAreaComponent_Conditional_6_Template_mj_conversation_message_list_replyInThread_3_listener($event) { i0.ɵɵrestoreView(_r7); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onReplyInThread($event)); })("viewThread", function ConversationChatAreaComponent_Conditional_6_Template_mj_conversation_message_list_viewThread_3_listener($event) { i0.ɵɵrestoreView(_r7); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onViewThread($event)); })("retryMessage", function ConversationChatAreaComponent_Conditional_6_Template_mj_conversation_message_list_retryMessage_3_listener($event) { i0.ɵɵrestoreView(_r7); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onRetryMessage($event)); })("artifactClicked", function ConversationChatAreaComponent_Conditional_6_Template_mj_conversation_message_list_artifactClicked_3_listener($event) { i0.ɵɵrestoreView(_r7); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onArtifactClicked($event)); })("messageEdited", function ConversationChatAreaComponent_Conditional_6_Template_mj_conversation_message_list_messageEdited_3_listener($event) { i0.ɵɵrestoreView(_r7); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onMessageEdited($event)); })("openEntityRecord", function ConversationChatAreaComponent_Conditional_6_Template_mj_conversation_message_list_openEntityRecord_3_listener($event) { i0.ɵɵrestoreView(_r7); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onOpenEntityRecord($event)); })("suggestedResponseSelected", function ConversationChatAreaComponent_Conditional_6_Template_mj_conversation_message_list_suggestedResponseSelected_3_listener($event) { i0.ɵɵrestoreView(_r7); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onSuggestedResponseSelected($event)); });
|
|
156
156
|
i0.ɵɵelementEnd();
|
|
157
|
-
i0.ɵɵtemplate(4, ConversationChatAreaComponent_Conditional_6_span_4_Template, 2, 0, "span",
|
|
157
|
+
i0.ɵɵtemplate(4, ConversationChatAreaComponent_Conditional_6_span_4_Template, 2, 0, "span", 37);
|
|
158
158
|
i0.ɵɵelementEnd();
|
|
159
|
-
i0.ɵɵelementStart(5, "div",
|
|
160
|
-
i0.ɵɵtemplate(6, ConversationChatAreaComponent_Conditional_6_Conditional_6_Template, 5, 0, "div",
|
|
159
|
+
i0.ɵɵelementStart(5, "div", 38);
|
|
160
|
+
i0.ɵɵtemplate(6, ConversationChatAreaComponent_Conditional_6_Conditional_6_Template, 5, 0, "div", 39)(7, ConversationChatAreaComponent_Conditional_6_Conditional_7_Template, 3, 0, "div", 40);
|
|
161
161
|
i0.ɵɵelementEnd()();
|
|
162
162
|
} if (rf & 2) {
|
|
163
163
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
164
164
|
i0.ɵɵadvance(3);
|
|
165
|
-
i0.ɵɵproperty("messages", ctx_r2.messages)("conversation", ctx_r2.conversationState.activeConversation)("currentUser", ctx_r2.currentUser)("isProcessing", ctx_r2.isProcessing)("artifactMap", ctx_r2.effectiveArtifactsMap)("agentRunMap", ctx_r2.agentRunsByDetailId)("userAvatarMap", ctx_r2.userAvatarMap);
|
|
165
|
+
i0.ɵɵproperty("messages", ctx_r2.messages)("conversation", ctx_r2.conversationState.activeConversation)("currentUser", ctx_r2.currentUser)("isProcessing", ctx_r2.isProcessing)("artifactMap", ctx_r2.effectiveArtifactsMap)("agentRunMap", ctx_r2.agentRunsByDetailId)("ratingsMap", ctx_r2.ratingsByDetailId)("userAvatarMap", ctx_r2.userAvatarMap);
|
|
166
166
|
i0.ɵɵadvance();
|
|
167
167
|
i0.ɵɵproperty("ngIf", ctx_r2.showScrollToBottomIcon && ctx_r2.messages && ctx_r2.messages.length > 0);
|
|
168
168
|
i0.ɵɵadvance(2);
|
|
169
169
|
i0.ɵɵconditional(ctx_r2.isLoadingPeripheralData ? 6 : 7);
|
|
170
170
|
} }
|
|
171
171
|
function ConversationChatAreaComponent_Conditional_7_Template(rf, ctx) { if (rf & 1) {
|
|
172
|
-
const
|
|
173
|
-
i0.ɵɵelementStart(0, "div",
|
|
174
|
-
i0.ɵɵlistener("mousedown", function ConversationChatAreaComponent_Conditional_7_Template_div_mousedown_0_listener($event) { i0.ɵɵrestoreView(
|
|
172
|
+
const _r11 = i0.ɵɵgetCurrentView();
|
|
173
|
+
i0.ɵɵelementStart(0, "div", 46);
|
|
174
|
+
i0.ɵɵlistener("mousedown", function ConversationChatAreaComponent_Conditional_7_Template_div_mousedown_0_listener($event) { i0.ɵɵrestoreView(_r11); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onResizeStart($event)); });
|
|
175
175
|
i0.ɵɵelementEnd();
|
|
176
|
-
i0.ɵɵelementStart(1, "div",
|
|
177
|
-
i0.ɵɵlistener("closed", function ConversationChatAreaComponent_Conditional_7_Template_mj_artifact_viewer_panel_closed_2_listener() { i0.ɵɵrestoreView(
|
|
176
|
+
i0.ɵɵelementStart(1, "div", 47)(2, "mj-artifact-viewer-panel", 48);
|
|
177
|
+
i0.ɵɵlistener("closed", function ConversationChatAreaComponent_Conditional_7_Template_mj_artifact_viewer_panel_closed_2_listener() { i0.ɵɵrestoreView(_r11); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onCloseArtifactPanel()); })("saveToCollectionRequested", function ConversationChatAreaComponent_Conditional_7_Template_mj_artifact_viewer_panel_saveToCollectionRequested_2_listener($event) { i0.ɵɵrestoreView(_r11); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onSaveToCollectionRequested($event)); })("navigateToLink", function ConversationChatAreaComponent_Conditional_7_Template_mj_artifact_viewer_panel_navigateToLink_2_listener($event) { i0.ɵɵrestoreView(_r11); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onArtifactLinkNavigation($event)); })("shareRequested", function ConversationChatAreaComponent_Conditional_7_Template_mj_artifact_viewer_panel_shareRequested_2_listener($event) { i0.ɵɵrestoreView(_r11); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onArtifactShareRequested($event)); });
|
|
178
178
|
i0.ɵɵelementEnd()();
|
|
179
179
|
} if (rf & 2) {
|
|
180
180
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
@@ -184,29 +184,29 @@ function ConversationChatAreaComponent_Conditional_7_Template(rf, ctx) { if (rf
|
|
|
184
184
|
i0.ɵɵproperty("artifactId", ctx_r2.selectedArtifactId)("currentUser", ctx_r2.currentUser)("environmentId", ctx_r2.environmentId)("versionNumber", ctx_r2.selectedVersionNumber)("viewContext", "conversation")("canShare", ctx_r2.canShareSelectedArtifact)("canEdit", ctx_r2.canEditSelectedArtifact)("refreshTrigger", ctx_r2.artifactViewerRefresh$);
|
|
185
185
|
} }
|
|
186
186
|
function ConversationChatAreaComponent_Conditional_9_Template(rf, ctx) { if (rf & 1) {
|
|
187
|
-
const
|
|
188
|
-
i0.ɵɵelementStart(0, "mj-thread-panel",
|
|
189
|
-
i0.ɵɵlistener("closed", function ConversationChatAreaComponent_Conditional_9_Template_mj_thread_panel_closed_0_listener() { i0.ɵɵrestoreView(
|
|
187
|
+
const _r12 = i0.ɵɵgetCurrentView();
|
|
188
|
+
i0.ɵɵelementStart(0, "mj-thread-panel", 49);
|
|
189
|
+
i0.ɵɵlistener("closed", function ConversationChatAreaComponent_Conditional_9_Template_mj_thread_panel_closed_0_listener() { i0.ɵɵrestoreView(_r12); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onThreadClosed()); })("replyAdded", function ConversationChatAreaComponent_Conditional_9_Template_mj_thread_panel_replyAdded_0_listener($event) { i0.ɵɵrestoreView(_r12); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onThreadReplyAdded($event)); });
|
|
190
190
|
i0.ɵɵelementEnd();
|
|
191
191
|
} if (rf & 2) {
|
|
192
192
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
193
193
|
i0.ɵɵproperty("parentMessageId", ctx_r2.conversationState.activeThreadId)("conversationId", (ctx_r2.conversationState.activeConversation == null ? null : ctx_r2.conversationState.activeConversation.ID) || "")("currentUser", ctx_r2.currentUser);
|
|
194
194
|
} }
|
|
195
195
|
function ConversationChatAreaComponent_Conditional_12_Template(rf, ctx) { if (rf & 1) {
|
|
196
|
-
const
|
|
197
|
-
i0.ɵɵelementStart(0, "div",
|
|
198
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_12_Template_div_click_0_listener() { i0.ɵɵrestoreView(
|
|
199
|
-
i0.ɵɵelementStart(1, "div",
|
|
200
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_12_Template_div_click_1_listener($event) { i0.ɵɵrestoreView(
|
|
201
|
-
i0.ɵɵelementStart(2, "div",
|
|
196
|
+
const _r13 = i0.ɵɵgetCurrentView();
|
|
197
|
+
i0.ɵɵelementStart(0, "div", 50);
|
|
198
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_12_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r13); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.showProjectSelector = false); });
|
|
199
|
+
i0.ɵɵelementStart(1, "div", 51);
|
|
200
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_12_Template_div_click_1_listener($event) { i0.ɵɵrestoreView(_r13); return i0.ɵɵresetView($event.stopPropagation()); });
|
|
201
|
+
i0.ɵɵelementStart(2, "div", 52)(3, "h3");
|
|
202
202
|
i0.ɵɵtext(4, "Assign Project");
|
|
203
203
|
i0.ɵɵelementEnd();
|
|
204
|
-
i0.ɵɵelementStart(5, "button",
|
|
205
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_12_Template_button_click_5_listener() { i0.ɵɵrestoreView(
|
|
206
|
-
i0.ɵɵelement(6, "i",
|
|
204
|
+
i0.ɵɵelementStart(5, "button", 53);
|
|
205
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_12_Template_button_click_5_listener() { i0.ɵɵrestoreView(_r13); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.showProjectSelector = false); });
|
|
206
|
+
i0.ɵɵelement(6, "i", 54);
|
|
207
207
|
i0.ɵɵelementEnd()();
|
|
208
|
-
i0.ɵɵelementStart(7, "div",
|
|
209
|
-
i0.ɵɵlistener("projectSelected", function ConversationChatAreaComponent_Conditional_12_Template_mj_project_selector_projectSelected_8_listener($event) { i0.ɵɵrestoreView(
|
|
208
|
+
i0.ɵɵelementStart(7, "div", 55)(8, "mj-project-selector", 56);
|
|
209
|
+
i0.ɵɵlistener("projectSelected", function ConversationChatAreaComponent_Conditional_12_Template_mj_project_selector_projectSelected_8_listener($event) { i0.ɵɵrestoreView(_r13); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onProjectSelected($event)); });
|
|
210
210
|
i0.ɵɵelementEnd()()()();
|
|
211
211
|
} if (rf & 2) {
|
|
212
212
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
@@ -214,10 +214,10 @@ function ConversationChatAreaComponent_Conditional_12_Template(rf, ctx) { if (rf
|
|
|
214
214
|
i0.ɵɵproperty("environmentId", ctx_r2.environmentId)("currentUser", ctx_r2.currentUser)("selectedProjectId", ctx_r2.conversationState.activeConversation.ProjectID);
|
|
215
215
|
} }
|
|
216
216
|
function ConversationChatAreaComponent_Conditional_13_Conditional_6_Template(rf, ctx) { if (rf & 1) {
|
|
217
|
-
const
|
|
218
|
-
i0.ɵɵelementStart(0, "button",
|
|
219
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_Conditional_6_Template_button_click_0_listener() { i0.ɵɵrestoreView(
|
|
220
|
-
i0.ɵɵelement(1, "i",
|
|
217
|
+
const _r15 = i0.ɵɵgetCurrentView();
|
|
218
|
+
i0.ɵɵelementStart(0, "button", 63);
|
|
219
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_Conditional_6_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r15); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.toggleSystemArtifacts()); });
|
|
220
|
+
i0.ɵɵelement(1, "i", 64);
|
|
221
221
|
i0.ɵɵelementStart(2, "span");
|
|
222
222
|
i0.ɵɵtext(3);
|
|
223
223
|
i0.ɵɵelementEnd()();
|
|
@@ -228,109 +228,109 @@ function ConversationChatAreaComponent_Conditional_13_Conditional_6_Template(rf,
|
|
|
228
228
|
i0.ɵɵtextInterpolate1("", ctx_r2.showSystemArtifacts ? "Hide" : "Show", " System");
|
|
229
229
|
} }
|
|
230
230
|
function ConversationChatAreaComponent_Conditional_13_Conditional_10_Template(rf, ctx) { if (rf & 1) {
|
|
231
|
-
i0.ɵɵelementStart(0, "div",
|
|
232
|
-
i0.ɵɵelement(1, "i",
|
|
233
|
-
i0.ɵɵelementStart(2, "p",
|
|
231
|
+
i0.ɵɵelementStart(0, "div", 61);
|
|
232
|
+
i0.ɵɵelement(1, "i", 65);
|
|
233
|
+
i0.ɵɵelementStart(2, "p", 66);
|
|
234
234
|
i0.ɵɵtext(3, "No artifacts in this conversation yet");
|
|
235
235
|
i0.ɵɵelementEnd()();
|
|
236
236
|
} }
|
|
237
237
|
function ConversationChatAreaComponent_Conditional_13_For_12_Conditional_8_Template(rf, ctx) { if (rf & 1) {
|
|
238
238
|
i0.ɵɵtext(0);
|
|
239
239
|
} if (rf & 2) {
|
|
240
|
-
const
|
|
241
|
-
i0.ɵɵtextInterpolate1(" ",
|
|
240
|
+
const artifact_r17 = i0.ɵɵnextContext().$implicit;
|
|
241
|
+
i0.ɵɵtextInterpolate1(" ", artifact_r17.versionCount, " versions ");
|
|
242
242
|
} }
|
|
243
243
|
function ConversationChatAreaComponent_Conditional_13_For_12_Conditional_9_Template(rf, ctx) { if (rf & 1) {
|
|
244
244
|
i0.ɵɵtext(0, " 1 version ");
|
|
245
245
|
} }
|
|
246
246
|
function ConversationChatAreaComponent_Conditional_13_For_12_Conditional_10_Template(rf, ctx) { if (rf & 1) {
|
|
247
|
-
const
|
|
248
|
-
i0.ɵɵelementStart(0, "button",
|
|
249
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_For_12_Conditional_10_Template_button_click_0_listener($event) { i0.ɵɵrestoreView(
|
|
250
|
-
i0.ɵɵelement(1, "i",
|
|
247
|
+
const _r18 = i0.ɵɵgetCurrentView();
|
|
248
|
+
i0.ɵɵelementStart(0, "button", 78);
|
|
249
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_For_12_Conditional_10_Template_button_click_0_listener($event) { i0.ɵɵrestoreView(_r18); const artifact_r17 = i0.ɵɵnextContext().$implicit; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.toggleArtifactExpansion(artifact_r17.artifactId, $event)); });
|
|
250
|
+
i0.ɵɵelement(1, "i", 79);
|
|
251
251
|
i0.ɵɵelementEnd();
|
|
252
252
|
} if (rf & 2) {
|
|
253
|
-
const
|
|
253
|
+
const artifact_r17 = i0.ɵɵnextContext().$implicit;
|
|
254
254
|
const ctx_r2 = i0.ɵɵnextContext(2);
|
|
255
255
|
i0.ɵɵadvance();
|
|
256
|
-
i0.ɵɵclassProp("fa-chevron-down", ctx_r2.expandedArtifactId !==
|
|
256
|
+
i0.ɵɵclassProp("fa-chevron-down", ctx_r2.expandedArtifactId !== artifact_r17.artifactId)("fa-chevron-up", ctx_r2.expandedArtifactId === artifact_r17.artifactId);
|
|
257
257
|
} }
|
|
258
258
|
function ConversationChatAreaComponent_Conditional_13_For_12_Conditional_13_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
259
|
-
const
|
|
260
|
-
i0.ɵɵelementStart(0, "div",
|
|
261
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_For_12_Conditional_13_For_2_Template_div_click_0_listener($event) { const
|
|
262
|
-
i0.ɵɵelementStart(1, "span",
|
|
259
|
+
const _r19 = i0.ɵɵgetCurrentView();
|
|
260
|
+
i0.ɵɵelementStart(0, "div", 81);
|
|
261
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_For_12_Conditional_13_For_2_Template_div_click_0_listener($event) { const version_r20 = i0.ɵɵrestoreView(_r19).$implicit; const artifact_r17 = i0.ɵɵnextContext(2).$implicit; const ctx_r2 = i0.ɵɵnextContext(2); ctx_r2.openArtifactFromModal(artifact_r17.artifactId, version_r20.versionNumber); return i0.ɵɵresetView($event.stopPropagation()); });
|
|
262
|
+
i0.ɵɵelementStart(1, "span", 82);
|
|
263
263
|
i0.ɵɵtext(2);
|
|
264
264
|
i0.ɵɵelementEnd();
|
|
265
|
-
i0.ɵɵelementStart(3, "span",
|
|
265
|
+
i0.ɵɵelementStart(3, "span", 83);
|
|
266
266
|
i0.ɵɵtext(4, "Open this version");
|
|
267
267
|
i0.ɵɵelementEnd();
|
|
268
|
-
i0.ɵɵelement(5, "i",
|
|
268
|
+
i0.ɵɵelement(5, "i", 84);
|
|
269
269
|
i0.ɵɵelementEnd();
|
|
270
270
|
} if (rf & 2) {
|
|
271
|
-
const
|
|
271
|
+
const version_r20 = ctx.$implicit;
|
|
272
272
|
i0.ɵɵadvance(2);
|
|
273
|
-
i0.ɵɵtextInterpolate1("v",
|
|
273
|
+
i0.ɵɵtextInterpolate1("v", version_r20.versionNumber, "");
|
|
274
274
|
} }
|
|
275
275
|
function ConversationChatAreaComponent_Conditional_13_For_12_Conditional_13_Template(rf, ctx) { if (rf & 1) {
|
|
276
|
-
i0.ɵɵelementStart(0, "div",
|
|
277
|
-
i0.ɵɵrepeaterCreate(1, ConversationChatAreaComponent_Conditional_13_For_12_Conditional_13_For_2_Template, 6, 1, "div",
|
|
276
|
+
i0.ɵɵelementStart(0, "div", 77);
|
|
277
|
+
i0.ɵɵrepeaterCreate(1, ConversationChatAreaComponent_Conditional_13_For_12_Conditional_13_For_2_Template, 6, 1, "div", 80, _forTrack2);
|
|
278
278
|
i0.ɵɵelementEnd();
|
|
279
279
|
} if (rf & 2) {
|
|
280
|
-
const
|
|
280
|
+
const artifact_r17 = i0.ɵɵnextContext().$implicit;
|
|
281
281
|
i0.ɵɵadvance();
|
|
282
|
-
i0.ɵɵrepeater(
|
|
282
|
+
i0.ɵɵrepeater(artifact_r17.versions);
|
|
283
283
|
} }
|
|
284
284
|
function ConversationChatAreaComponent_Conditional_13_For_12_Template(rf, ctx) { if (rf & 1) {
|
|
285
|
-
const
|
|
286
|
-
i0.ɵɵelementStart(0, "div",
|
|
287
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_For_12_Template_div_click_1_listener() { const
|
|
288
|
-
i0.ɵɵelementStart(2, "div",
|
|
289
|
-
i0.ɵɵelement(3, "i",
|
|
285
|
+
const _r16 = i0.ɵɵgetCurrentView();
|
|
286
|
+
i0.ɵɵelementStart(0, "div", 67)(1, "div", 68);
|
|
287
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_For_12_Template_div_click_1_listener() { const artifact_r17 = i0.ɵɵrestoreView(_r16).$implicit; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.openArtifactFromModal(artifact_r17.artifactId)); });
|
|
288
|
+
i0.ɵɵelementStart(2, "div", 69);
|
|
289
|
+
i0.ɵɵelement(3, "i", 70);
|
|
290
290
|
i0.ɵɵelementEnd();
|
|
291
|
-
i0.ɵɵelementStart(4, "div",
|
|
291
|
+
i0.ɵɵelementStart(4, "div", 71)(5, "div", 72);
|
|
292
292
|
i0.ɵɵtext(6);
|
|
293
293
|
i0.ɵɵelementEnd();
|
|
294
|
-
i0.ɵɵelementStart(7, "div",
|
|
294
|
+
i0.ɵɵelementStart(7, "div", 73);
|
|
295
295
|
i0.ɵɵtemplate(8, ConversationChatAreaComponent_Conditional_13_For_12_Conditional_8_Template, 1, 1)(9, ConversationChatAreaComponent_Conditional_13_For_12_Conditional_9_Template, 1, 0);
|
|
296
296
|
i0.ɵɵelementEnd()();
|
|
297
|
-
i0.ɵɵtemplate(10, ConversationChatAreaComponent_Conditional_13_For_12_Conditional_10_Template, 2, 4, "button",
|
|
298
|
-
i0.ɵɵelementStart(11, "div",
|
|
299
|
-
i0.ɵɵelement(12, "i",
|
|
297
|
+
i0.ɵɵtemplate(10, ConversationChatAreaComponent_Conditional_13_For_12_Conditional_10_Template, 2, 4, "button", 74);
|
|
298
|
+
i0.ɵɵelementStart(11, "div", 75);
|
|
299
|
+
i0.ɵɵelement(12, "i", 76);
|
|
300
300
|
i0.ɵɵelementEnd()();
|
|
301
|
-
i0.ɵɵtemplate(13, ConversationChatAreaComponent_Conditional_13_For_12_Conditional_13_Template, 3, 0, "div",
|
|
301
|
+
i0.ɵɵtemplate(13, ConversationChatAreaComponent_Conditional_13_For_12_Conditional_13_Template, 3, 0, "div", 77);
|
|
302
302
|
i0.ɵɵelementEnd();
|
|
303
303
|
} if (rf & 2) {
|
|
304
|
-
const
|
|
304
|
+
const artifact_r17 = ctx.$implicit;
|
|
305
305
|
const ctx_r2 = i0.ɵɵnextContext(2);
|
|
306
|
-
i0.ɵɵclassProp("expanded", ctx_r2.expandedArtifactId ===
|
|
306
|
+
i0.ɵɵclassProp("expanded", ctx_r2.expandedArtifactId === artifact_r17.artifactId)("system-artifact", artifact_r17.visibility === "System Only");
|
|
307
307
|
i0.ɵɵadvance(6);
|
|
308
|
-
i0.ɵɵtextInterpolate(
|
|
308
|
+
i0.ɵɵtextInterpolate(artifact_r17.name);
|
|
309
309
|
i0.ɵɵadvance(2);
|
|
310
|
-
i0.ɵɵconditional(
|
|
310
|
+
i0.ɵɵconditional(artifact_r17.versionCount > 1 ? 8 : 9);
|
|
311
311
|
i0.ɵɵadvance(2);
|
|
312
|
-
i0.ɵɵconditional(
|
|
312
|
+
i0.ɵɵconditional(artifact_r17.versionCount > 1 ? 10 : -1);
|
|
313
313
|
i0.ɵɵadvance(3);
|
|
314
|
-
i0.ɵɵconditional(ctx_r2.expandedArtifactId ===
|
|
314
|
+
i0.ɵɵconditional(ctx_r2.expandedArtifactId === artifact_r17.artifactId && artifact_r17.versionCount > 1 ? 13 : -1);
|
|
315
315
|
} }
|
|
316
316
|
function ConversationChatAreaComponent_Conditional_13_Template(rf, ctx) { if (rf & 1) {
|
|
317
|
-
const
|
|
318
|
-
i0.ɵɵelementStart(0, "div",
|
|
319
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_Template_div_click_0_listener() { i0.ɵɵrestoreView(
|
|
320
|
-
i0.ɵɵelementStart(1, "div",
|
|
321
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_Template_div_click_1_listener($event) { i0.ɵɵrestoreView(
|
|
322
|
-
i0.ɵɵelementStart(2, "div",
|
|
317
|
+
const _r14 = i0.ɵɵgetCurrentView();
|
|
318
|
+
i0.ɵɵelementStart(0, "div", 50);
|
|
319
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r14); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.showArtifactsModal = false); });
|
|
320
|
+
i0.ɵɵelementStart(1, "div", 57);
|
|
321
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_Template_div_click_1_listener($event) { i0.ɵɵrestoreView(_r14); return i0.ɵɵresetView($event.stopPropagation()); });
|
|
322
|
+
i0.ɵɵelementStart(2, "div", 52)(3, "h3");
|
|
323
323
|
i0.ɵɵtext(4, "Conversation Artifacts");
|
|
324
324
|
i0.ɵɵelementEnd();
|
|
325
|
-
i0.ɵɵelementStart(5, "div",
|
|
326
|
-
i0.ɵɵtemplate(6, ConversationChatAreaComponent_Conditional_13_Conditional_6_Template, 4, 3, "button",
|
|
327
|
-
i0.ɵɵelementStart(7, "button",
|
|
328
|
-
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_Template_button_click_7_listener() { i0.ɵɵrestoreView(
|
|
329
|
-
i0.ɵɵelement(8, "i",
|
|
325
|
+
i0.ɵɵelementStart(5, "div", 58);
|
|
326
|
+
i0.ɵɵtemplate(6, ConversationChatAreaComponent_Conditional_13_Conditional_6_Template, 4, 3, "button", 59);
|
|
327
|
+
i0.ɵɵelementStart(7, "button", 53);
|
|
328
|
+
i0.ɵɵlistener("click", function ConversationChatAreaComponent_Conditional_13_Template_button_click_7_listener() { i0.ɵɵrestoreView(_r14); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.showArtifactsModal = false); });
|
|
329
|
+
i0.ɵɵelement(8, "i", 54);
|
|
330
330
|
i0.ɵɵelementEnd()()();
|
|
331
|
-
i0.ɵɵelementStart(9, "div",
|
|
332
|
-
i0.ɵɵtemplate(10, ConversationChatAreaComponent_Conditional_13_Conditional_10_Template, 4, 0, "div",
|
|
333
|
-
i0.ɵɵrepeaterCreate(11, ConversationChatAreaComponent_Conditional_13_For_12_Template, 14, 8, "div",
|
|
331
|
+
i0.ɵɵelementStart(9, "div", 60);
|
|
332
|
+
i0.ɵɵtemplate(10, ConversationChatAreaComponent_Conditional_13_Conditional_10_Template, 4, 0, "div", 61);
|
|
333
|
+
i0.ɵɵrepeaterCreate(11, ConversationChatAreaComponent_Conditional_13_For_12_Template, 14, 8, "div", 62, _forTrack1);
|
|
334
334
|
i0.ɵɵelementEnd()()();
|
|
335
335
|
} if (rf & 2) {
|
|
336
336
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
@@ -342,9 +342,9 @@ function ConversationChatAreaComponent_Conditional_13_Template(rf, ctx) { if (rf
|
|
|
342
342
|
i0.ɵɵrepeater(ctx_r2.getArtifactsArray());
|
|
343
343
|
} }
|
|
344
344
|
function ConversationChatAreaComponent_Conditional_14_Template(rf, ctx) { if (rf & 1) {
|
|
345
|
-
const
|
|
346
|
-
i0.ɵɵelementStart(0, "mj-artifact-collection-picker-modal",
|
|
347
|
-
i0.ɵɵlistener("saved", function ConversationChatAreaComponent_Conditional_14_Template_mj_artifact_collection_picker_modal_saved_0_listener($event) { i0.ɵɵrestoreView(
|
|
345
|
+
const _r21 = i0.ɵɵgetCurrentView();
|
|
346
|
+
i0.ɵɵelementStart(0, "mj-artifact-collection-picker-modal", 85);
|
|
347
|
+
i0.ɵɵlistener("saved", function ConversationChatAreaComponent_Conditional_14_Template_mj_artifact_collection_picker_modal_saved_0_listener($event) { i0.ɵɵrestoreView(_r21); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onCollectionPickerSaved($event)); })("cancelled", function ConversationChatAreaComponent_Conditional_14_Template_mj_artifact_collection_picker_modal_cancelled_0_listener() { i0.ɵɵrestoreView(_r21); const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.onCollectionPickerCancelled()); });
|
|
348
348
|
i0.ɵɵelementEnd();
|
|
349
349
|
} if (rf & 2) {
|
|
350
350
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
@@ -416,8 +416,24 @@ export class ConversationChatAreaComponent {
|
|
|
416
416
|
// Agent run mapping: ConversationDetailID -> AIAgentRunEntityExtended
|
|
417
417
|
// Loaded once per conversation and kept in sync as new runs are created
|
|
418
418
|
agentRunsByDetailId = new Map();
|
|
419
|
+
/**
|
|
420
|
+
* Ratings by conversation detail ID (parsed from RatingsJSON)
|
|
421
|
+
*/
|
|
422
|
+
ratingsByDetailId = new Map();
|
|
423
|
+
/**
|
|
424
|
+
* In-progress message IDs for streaming reconnection
|
|
425
|
+
* Passed to message-input component to reconnect PubSub updates
|
|
426
|
+
*/
|
|
427
|
+
inProgressMessageIds = [];
|
|
419
428
|
// Timer for smooth agent run UI updates (updates every second while agent runs)
|
|
420
429
|
agentRunUpdateTimer = null;
|
|
430
|
+
// Cache of message-input metadata for rendering multiple instances
|
|
431
|
+
// Prevents destruction/recreation when switching conversations for performance
|
|
432
|
+
messageInputMetadataCache = new Map();
|
|
433
|
+
// Empty collections for hidden message-input components
|
|
434
|
+
emptyArtifactsMap = new Map();
|
|
435
|
+
emptyAgentRunsMap = new Map();
|
|
436
|
+
emptyInProgressIds = [];
|
|
421
437
|
// Loading state for peripheral data
|
|
422
438
|
isLoadingPeripheralData = false;
|
|
423
439
|
// Subject to trigger artifact viewer refresh when new version is created
|
|
@@ -498,6 +514,14 @@ export class ConversationChatAreaComponent {
|
|
|
498
514
|
this.showArtifactPanel = false;
|
|
499
515
|
this.selectedArtifactId = null;
|
|
500
516
|
if (conversationId) {
|
|
517
|
+
// Add conversation to message-input cache if not already present
|
|
518
|
+
if (!this.messageInputMetadataCache.has(conversationId)) {
|
|
519
|
+
const conversation = this.conversationState.activeConversation;
|
|
520
|
+
this.messageInputMetadataCache.set(conversationId, {
|
|
521
|
+
conversationId: conversationId,
|
|
522
|
+
conversationName: conversation?.Name || null
|
|
523
|
+
});
|
|
524
|
+
}
|
|
501
525
|
// Show loading state
|
|
502
526
|
this.isLoadingConversation = true;
|
|
503
527
|
this.messages = []; // Clear messages to avoid showing stale data
|
|
@@ -522,19 +546,25 @@ export class ConversationChatAreaComponent {
|
|
|
522
546
|
this.agentStateService.stopPolling();
|
|
523
547
|
}
|
|
524
548
|
}
|
|
549
|
+
/**
|
|
550
|
+
* Returns array of cached message-input metadata for rendering
|
|
551
|
+
* This allows multiple message-input components to exist simultaneously (hidden)
|
|
552
|
+
* preserving their state when switching conversations
|
|
553
|
+
*/
|
|
554
|
+
getCachedInputs() {
|
|
555
|
+
return Array.from(this.messageInputMetadataCache.values());
|
|
556
|
+
}
|
|
525
557
|
async loadMessages(conversationId) {
|
|
526
558
|
try {
|
|
527
559
|
// Check if we have cached data for this conversation
|
|
528
560
|
const cachedData = this.conversationDataCache.get(conversationId);
|
|
529
561
|
if (cachedData) {
|
|
530
562
|
// Use cached data - instant load!
|
|
531
|
-
console.log(`📦 Loading conversation ${conversationId} from cache - instant!`);
|
|
532
563
|
this.buildMessagesFromCache(cachedData);
|
|
533
564
|
this.loadPeripheralData(conversationId); // Process cached data for maps
|
|
534
565
|
}
|
|
535
566
|
else {
|
|
536
567
|
// Load from database with single optimized query
|
|
537
|
-
console.log(`🔍 Loading conversation ${conversationId} from database - single query`);
|
|
538
568
|
const rq = new RunQuery();
|
|
539
569
|
const result = await rq.RunQuery({
|
|
540
570
|
QueryName: 'GetConversationComplete',
|
|
@@ -549,7 +579,6 @@ export class ConversationChatAreaComponent {
|
|
|
549
579
|
// Cache the raw results for future use
|
|
550
580
|
const conversationData = result.Results;
|
|
551
581
|
this.conversationDataCache.set(conversationId, conversationData);
|
|
552
|
-
console.log(`💾 Cached ${conversationData.length} conversation details for conversation ${conversationId}`);
|
|
553
582
|
// Build messages and show immediately
|
|
554
583
|
this.buildMessagesFromCache(conversationData);
|
|
555
584
|
// Process peripheral data (agent runs & artifacts) in background
|
|
@@ -560,6 +589,8 @@ export class ConversationChatAreaComponent {
|
|
|
560
589
|
}
|
|
561
590
|
// After loading messages, check for in-progress runs and ensure we're receiving updates
|
|
562
591
|
await this.detectAndReconnectToInProgressRuns(conversationId);
|
|
592
|
+
// Check for pending artifact navigation (from collection link)
|
|
593
|
+
await this.handlePendingArtifactNavigation();
|
|
563
594
|
}
|
|
564
595
|
catch (error) {
|
|
565
596
|
console.error('Error loading messages:', error);
|
|
@@ -588,6 +619,13 @@ export class ConversationChatAreaComponent {
|
|
|
588
619
|
messages.push(message);
|
|
589
620
|
}
|
|
590
621
|
this.messages = messages;
|
|
622
|
+
// Detect in-progress messages for streaming reconnection
|
|
623
|
+
this.inProgressMessageIds = messages
|
|
624
|
+
.filter(m => m.Status === 'In-Progress')
|
|
625
|
+
.map(m => m.ID);
|
|
626
|
+
if (this.inProgressMessageIds.length > 0) {
|
|
627
|
+
LogStatusEx({ message: `🔌 Detected ${this.inProgressMessageIds.length} in-progress messages for reconnection`, verboseOnly: true });
|
|
628
|
+
}
|
|
591
629
|
this.scrollToBottom = true;
|
|
592
630
|
this.cdr.detectChanges(); // Show messages immediately
|
|
593
631
|
}
|
|
@@ -612,7 +650,7 @@ export class ConversationChatAreaComponent {
|
|
|
612
650
|
}
|
|
613
651
|
}
|
|
614
652
|
this.userAvatarMap = userMap;
|
|
615
|
-
|
|
653
|
+
LogStatusEx({ message: `👤 Built user avatar map with ${this.userAvatarMap.size} unique users`, verboseOnly: true });
|
|
616
654
|
}
|
|
617
655
|
/**
|
|
618
656
|
* Process peripheral data (agent runs and artifacts) from cached conversation data
|
|
@@ -627,12 +665,12 @@ export class ConversationChatAreaComponent {
|
|
|
627
665
|
const timestamp = new Date().toISOString();
|
|
628
666
|
// Skip if we've already processed peripheral data for this conversation
|
|
629
667
|
if (this.lastLoadedConversationId === conversationId) {
|
|
630
|
-
|
|
668
|
+
LogStatusEx({ message: `[${timestamp}] ⏭️ Skipping peripheral data processing - already processed for conversation ${conversationId}`, verboseOnly: true });
|
|
631
669
|
return;
|
|
632
670
|
}
|
|
633
671
|
// Mark this conversation as processed to prevent duplicate processing
|
|
634
672
|
this.lastLoadedConversationId = conversationId;
|
|
635
|
-
|
|
673
|
+
LogStatusEx({ message: `[${timestamp}] 📊 Processing peripheral data for conversation ${conversationId} from cache`, verboseOnly: true });
|
|
636
674
|
try {
|
|
637
675
|
// Get cached data - should always be present by the time we get here
|
|
638
676
|
const conversationData = this.conversationDataCache.get(conversationId);
|
|
@@ -662,8 +700,8 @@ export class ConversationChatAreaComponent {
|
|
|
662
700
|
AgentID: agentRunData.AgentID,
|
|
663
701
|
Agent: agentRunData.Agent,
|
|
664
702
|
Status: agentRunData.Status,
|
|
665
|
-
__mj_CreatedAt:
|
|
666
|
-
__mj_UpdatedAt:
|
|
703
|
+
__mj_CreatedAt: agentRunData.__mj_CreatedAt,
|
|
704
|
+
__mj_UpdatedAt: agentRunData.__mj_UpdatedAt,
|
|
667
705
|
TotalPromptTokensUsed: agentRunData.TotalPromptTokensUsed,
|
|
668
706
|
TotalCompletionTokensUsed: agentRunData.TotalCompletionTokensUsed,
|
|
669
707
|
TotalCost: agentRunData.TotalCost,
|
|
@@ -695,10 +733,15 @@ export class ConversationChatAreaComponent {
|
|
|
695
733
|
this.systemArtifactsByDetailId.set(row.ID, systemArtifactList);
|
|
696
734
|
}
|
|
697
735
|
}
|
|
736
|
+
// Build ratings map
|
|
737
|
+
if (parsed.ratings.length > 0) {
|
|
738
|
+
this.ratingsByDetailId.set(row.ID, parsed.ratings);
|
|
739
|
+
}
|
|
698
740
|
}
|
|
699
741
|
// Create new Map references to trigger Angular change detection
|
|
700
742
|
this.agentRunsByDetailId = new Map(this.agentRunsByDetailId);
|
|
701
743
|
this.artifactsByDetailId = new Map(this.artifactsByDetailId);
|
|
744
|
+
this.ratingsByDetailId = new Map(this.ratingsByDetailId);
|
|
702
745
|
this.systemArtifactsByDetailId = new Map(this.systemArtifactsByDetailId);
|
|
703
746
|
// Clear combined cache since we loaded new artifacts
|
|
704
747
|
this._combinedArtifactsMap = null;
|
|
@@ -706,12 +749,12 @@ export class ConversationChatAreaComponent {
|
|
|
706
749
|
this.artifactCount = this.calculateUniqueArtifactCount();
|
|
707
750
|
// Debug: Log summary
|
|
708
751
|
const systemArtifactCount = this.systemArtifactsByDetailId.size;
|
|
709
|
-
|
|
752
|
+
LogStatusEx({ message: `📊 Processed ${this.agentRunsByDetailId.size} agent runs, ${this.artifactsByDetailId.size} user artifact mappings, ${systemArtifactCount} system artifact mappings (${this.artifactCount} unique user artifacts)`, verboseOnly: true });
|
|
710
753
|
// CRITICAL: Trigger message re-render now that agent runs and artifacts are loaded
|
|
711
754
|
// This updates all message components with the newly loaded agent run data
|
|
712
755
|
this.messages = [...this.messages]; // Create new array reference to trigger change detection
|
|
713
756
|
this.cdr.detectChanges();
|
|
714
|
-
|
|
757
|
+
LogStatusEx({ message: `✅ Peripheral data processed successfully for conversation ${conversationId} from cache`, verboseOnly: true });
|
|
715
758
|
}
|
|
716
759
|
catch (error) {
|
|
717
760
|
console.error('Failed to process peripheral data:', error);
|
|
@@ -771,7 +814,7 @@ export class ConversationChatAreaComponent {
|
|
|
771
814
|
imageUrl: userEntity.UserImageURL || null,
|
|
772
815
|
iconClass: userEntity.UserImageIconClass || null
|
|
773
816
|
});
|
|
774
|
-
|
|
817
|
+
LogStatusEx({ message: `👤 Added current user to avatar map`, verboseOnly: true });
|
|
775
818
|
}
|
|
776
819
|
/**
|
|
777
820
|
* Handle agent run detected event from progress updates
|
|
@@ -835,7 +878,7 @@ export class ConversationChatAreaComponent {
|
|
|
835
878
|
if (this.agentRunUpdateTimer !== null) {
|
|
836
879
|
return;
|
|
837
880
|
}
|
|
838
|
-
|
|
881
|
+
LogStatusEx({ message: '⏱️ Starting agent run update timer (1-second interval)', verboseOnly: true });
|
|
839
882
|
this.agentRunUpdateTimer = setInterval(() => {
|
|
840
883
|
// Check if we have any active agent runs
|
|
841
884
|
let hasActiveRuns = false;
|
|
@@ -862,7 +905,7 @@ export class ConversationChatAreaComponent {
|
|
|
862
905
|
*/
|
|
863
906
|
stopAgentRunUpdateTimer() {
|
|
864
907
|
if (this.agentRunUpdateTimer !== null) {
|
|
865
|
-
|
|
908
|
+
LogStatusEx({ message: '⏹️ Stopping agent run update timer', verboseOnly: true });
|
|
866
909
|
clearInterval(this.agentRunUpdateTimer);
|
|
867
910
|
this.agentRunUpdateTimer = null;
|
|
868
911
|
}
|
|
@@ -905,7 +948,7 @@ export class ConversationChatAreaComponent {
|
|
|
905
948
|
*/
|
|
906
949
|
invalidateConversationCache(conversationId) {
|
|
907
950
|
this.conversationDataCache.delete(conversationId);
|
|
908
|
-
|
|
951
|
+
LogStatusEx({ message: `🗑️ Invalidated cache for conversation ${conversationId}`, verboseOnly: true });
|
|
909
952
|
}
|
|
910
953
|
/**
|
|
911
954
|
* Add or update an agent run in the map
|
|
@@ -942,7 +985,7 @@ export class ConversationChatAreaComponent {
|
|
|
942
985
|
* Invalidates and refreshes the conversation cache
|
|
943
986
|
*/
|
|
944
987
|
async reloadArtifactsForMessage(conversationDetailId) {
|
|
945
|
-
|
|
988
|
+
LogStatusEx({ message: `🔄 Reloading artifacts for message ${conversationDetailId}`, verboseOnly: true });
|
|
946
989
|
try {
|
|
947
990
|
const rq = new RunQuery();
|
|
948
991
|
const md = new Metadata();
|
|
@@ -964,7 +1007,7 @@ export class ConversationChatAreaComponent {
|
|
|
964
1007
|
console.error('Failed to reload artifacts:', result.ErrorMessage);
|
|
965
1008
|
return;
|
|
966
1009
|
}
|
|
967
|
-
|
|
1010
|
+
LogStatusEx({ message: `📊 Query result: ${result.Results.length} conversation details loaded`, verboseOnly: true });
|
|
968
1011
|
// Update cache with fresh data
|
|
969
1012
|
const conversationData = result.Results;
|
|
970
1013
|
this.conversationDataCache.set(detail.ConversationID, conversationData);
|
|
@@ -979,7 +1022,7 @@ export class ConversationChatAreaComponent {
|
|
|
979
1022
|
for (const artifactData of parsed.artifacts) {
|
|
980
1023
|
const lazyInfo = new LazyArtifactInfo(artifactData, this.currentUser);
|
|
981
1024
|
artifactList.push(lazyInfo);
|
|
982
|
-
|
|
1025
|
+
LogStatusEx({ message: `✅ Loaded artifact ${artifactData.ArtifactID} v${artifactData.VersionNumber} for message ${conversationDetailId}`, verboseOnly: true });
|
|
983
1026
|
}
|
|
984
1027
|
this.artifactsByDetailId.set(conversationDetailId, artifactList);
|
|
985
1028
|
}
|
|
@@ -1174,7 +1217,7 @@ export class ConversationChatAreaComponent {
|
|
|
1174
1217
|
}
|
|
1175
1218
|
shareConversation() {
|
|
1176
1219
|
// TODO: Implement share functionality
|
|
1177
|
-
|
|
1220
|
+
LogStatusEx({ message: 'Share conversation', verboseOnly: true });
|
|
1178
1221
|
}
|
|
1179
1222
|
onReplyInThread(message) {
|
|
1180
1223
|
// Open thread panel for this message
|
|
@@ -1191,7 +1234,7 @@ export class ConversationChatAreaComponent {
|
|
|
1191
1234
|
onThreadReplyAdded(reply) {
|
|
1192
1235
|
// Optionally refresh the message list to update thread counts
|
|
1193
1236
|
// For now, we'll just log it
|
|
1194
|
-
|
|
1237
|
+
LogStatusEx({ message: 'Thread reply added', verboseOnly: true, additionalArgs: [reply] });
|
|
1195
1238
|
// Reload messages to get updated thread counts
|
|
1196
1239
|
const activeConv = this.conversationState.activeConversation;
|
|
1197
1240
|
if (activeConv) {
|
|
@@ -1205,12 +1248,12 @@ export class ConversationChatAreaComponent {
|
|
|
1205
1248
|
}
|
|
1206
1249
|
onAgentSelected(agentRun) {
|
|
1207
1250
|
// When an agent is clicked in the indicator, could show details
|
|
1208
|
-
|
|
1251
|
+
LogStatusEx({ message: 'Agent selected', verboseOnly: true, additionalArgs: [agentRun.ID] });
|
|
1209
1252
|
// Could open a modal or navigate to agent details
|
|
1210
1253
|
}
|
|
1211
1254
|
onMessageEdited(message) {
|
|
1212
1255
|
// Message was edited and saved, trigger change detection
|
|
1213
|
-
|
|
1256
|
+
LogStatusEx({ message: 'Message edited', verboseOnly: true, additionalArgs: [message.ID] });
|
|
1214
1257
|
// The message entity is already updated in place, so no need to reload
|
|
1215
1258
|
// Just ensure the UI reflects the changes
|
|
1216
1259
|
}
|
|
@@ -1220,17 +1263,23 @@ export class ConversationChatAreaComponent {
|
|
|
1220
1263
|
*/
|
|
1221
1264
|
async onSuggestedResponseSelected(event) {
|
|
1222
1265
|
const messageText = event.customInput || event.text;
|
|
1223
|
-
|
|
1266
|
+
// If we have an active conversation with message input available, use it
|
|
1267
|
+
if (this.messageInputComponent && !this.conversationState.isNewUnsavedConversation) {
|
|
1224
1268
|
await this.messageInputComponent.sendMessageWithText(messageText);
|
|
1225
1269
|
}
|
|
1270
|
+
else if (!this.conversationState.activeConversation || this.conversationState.isNewUnsavedConversation) {
|
|
1271
|
+
// If no conversation or in new unsaved state, route through empty state handler
|
|
1272
|
+
// This will create the conversation and send the message
|
|
1273
|
+
await this.onEmptyStateMessageSent(messageText);
|
|
1274
|
+
}
|
|
1226
1275
|
else {
|
|
1227
|
-
console.error('MessageInputComponent not available');
|
|
1276
|
+
console.error('MessageInputComponent not available and not in a valid state to create conversation');
|
|
1228
1277
|
}
|
|
1229
1278
|
}
|
|
1230
1279
|
onRetryMessage(message) {
|
|
1231
1280
|
// TODO: Implement retry logic
|
|
1232
1281
|
// This should find the parent user message and re-trigger the agent invocation
|
|
1233
|
-
|
|
1282
|
+
LogStatusEx({ message: 'Retry requested for message', verboseOnly: true, additionalArgs: [message.ID] });
|
|
1234
1283
|
// For now, just log it - full implementation would require refactoring agent invocation
|
|
1235
1284
|
}
|
|
1236
1285
|
async onArtifactClicked(data) {
|
|
@@ -1241,7 +1290,7 @@ export class ConversationChatAreaComponent {
|
|
|
1241
1290
|
for (const artifactInfo of artifactList) {
|
|
1242
1291
|
if (artifactInfo.artifactVersionId === data.versionId) {
|
|
1243
1292
|
this.selectedVersionNumber = artifactInfo.versionNumber;
|
|
1244
|
-
|
|
1293
|
+
LogStatusEx({ message: `📦 Opening artifact viewer for v${this.selectedVersionNumber}`, verboseOnly: true });
|
|
1245
1294
|
break;
|
|
1246
1295
|
}
|
|
1247
1296
|
}
|
|
@@ -1396,7 +1445,7 @@ export class ConversationChatAreaComponent {
|
|
|
1396
1445
|
}
|
|
1397
1446
|
}
|
|
1398
1447
|
onConversationRenamed(event) {
|
|
1399
|
-
|
|
1448
|
+
LogStatusEx({ message: '🎉 Conversation renamed', verboseOnly: true, additionalArgs: [event] });
|
|
1400
1449
|
// Pass the event up to workspace component for animation
|
|
1401
1450
|
this.conversationRenamed.emit(event);
|
|
1402
1451
|
}
|
|
@@ -1408,12 +1457,12 @@ export class ConversationChatAreaComponent {
|
|
|
1408
1457
|
if (!messageText || !messageText.trim()) {
|
|
1409
1458
|
return;
|
|
1410
1459
|
}
|
|
1411
|
-
|
|
1460
|
+
LogStatusEx({ message: '📨 Empty state message received', verboseOnly: true, additionalArgs: [messageText] });
|
|
1412
1461
|
try {
|
|
1413
1462
|
this.isProcessing = true;
|
|
1414
1463
|
// Store the message to send after conversation loads (in service to persist across component lifecycle)
|
|
1415
1464
|
this.conversationState.pendingMessageToSend = messageText.trim();
|
|
1416
|
-
|
|
1465
|
+
LogStatusEx({ message: '💾 Stored pending message in service', verboseOnly: true, additionalArgs: [this.conversationState.pendingMessageToSend] });
|
|
1417
1466
|
// Create a new conversation
|
|
1418
1467
|
const newConversation = await this.conversationState.createConversation('New Conversation', // Temporary name - will be auto-named after first message
|
|
1419
1468
|
this.environmentId, this.currentUser);
|
|
@@ -1423,7 +1472,9 @@ export class ConversationChatAreaComponent {
|
|
|
1423
1472
|
this.isProcessing = false;
|
|
1424
1473
|
return;
|
|
1425
1474
|
}
|
|
1426
|
-
|
|
1475
|
+
LogStatusEx({ message: '✅ Created new conversation', verboseOnly: true, additionalArgs: [newConversation.ID] });
|
|
1476
|
+
// Clear the new unsaved conversation state since we've now created it
|
|
1477
|
+
this.conversationState.clearNewConversationState();
|
|
1427
1478
|
// Set as active conversation (this will trigger onConversationChanged which will send the message)
|
|
1428
1479
|
this.conversationState.activeConversationId = newConversation.ID;
|
|
1429
1480
|
}
|
|
@@ -1443,11 +1494,15 @@ export class ConversationChatAreaComponent {
|
|
|
1443
1494
|
// Pass task click up to workspace to navigate to Tasks tab
|
|
1444
1495
|
this.taskClicked.emit(task);
|
|
1445
1496
|
}
|
|
1497
|
+
onNavigateToConversation(event) {
|
|
1498
|
+
// Navigate to the conversation with the active task
|
|
1499
|
+
this.conversationState.setActiveConversation(event.conversationId);
|
|
1500
|
+
}
|
|
1446
1501
|
/**
|
|
1447
1502
|
* Handle navigation request from artifact viewer Links tab
|
|
1448
1503
|
*/
|
|
1449
1504
|
onArtifactLinkNavigation(event) {
|
|
1450
|
-
|
|
1505
|
+
LogStatusEx({ message: '🔗 Chat area: Artifact link clicked', verboseOnly: true, additionalArgs: [event] });
|
|
1451
1506
|
this.artifactLinkClicked.emit(event);
|
|
1452
1507
|
}
|
|
1453
1508
|
/**
|
|
@@ -1549,14 +1604,14 @@ export class ConversationChatAreaComponent {
|
|
|
1549
1604
|
if (inProgressMessages.length === 0) {
|
|
1550
1605
|
return;
|
|
1551
1606
|
}
|
|
1552
|
-
|
|
1607
|
+
LogStatusEx({ message: `🔄 Found ${inProgressMessages.length} in-progress messages, reconnecting...`, verboseOnly: true });
|
|
1553
1608
|
// For each in-progress message, check if there's an active agent run
|
|
1554
1609
|
for (const message of inProgressMessages) {
|
|
1555
1610
|
if (message.AgentID) {
|
|
1556
1611
|
// Check agent state service for this run
|
|
1557
1612
|
const agentRun = this.agentRunsByDetailId.get(message.ID);
|
|
1558
1613
|
if (agentRun && agentRun.Status === 'Running') {
|
|
1559
|
-
|
|
1614
|
+
LogStatusEx({ message: `🔌 Reconnecting to agent run ${agentRun.ID} for message ${message.ID}`, verboseOnly: true });
|
|
1560
1615
|
// Agent state service polling will automatically pick this up
|
|
1561
1616
|
// The WebSocket subscription is already active via PushStatusUpdates()
|
|
1562
1617
|
// No additional action needed - just log for visibility
|
|
@@ -1567,6 +1622,67 @@ export class ConversationChatAreaComponent {
|
|
|
1567
1622
|
// WebSocket subscription is already active via message-input component's subscribeToPushStatus()
|
|
1568
1623
|
// Both will automatically receive updates for these in-progress runs
|
|
1569
1624
|
}
|
|
1625
|
+
/**
|
|
1626
|
+
* Handle pending artifact navigation from collection
|
|
1627
|
+
* Opens the artifact and scrolls to the message containing it
|
|
1628
|
+
*/
|
|
1629
|
+
async handlePendingArtifactNavigation() {
|
|
1630
|
+
const pendingArtifactId = this.conversationState.pendingArtifactId;
|
|
1631
|
+
const pendingVersionNumber = this.conversationState.pendingArtifactVersionNumber;
|
|
1632
|
+
if (!pendingArtifactId) {
|
|
1633
|
+
return; // No pending navigation
|
|
1634
|
+
}
|
|
1635
|
+
console.log('📦 Processing pending artifact navigation:', pendingArtifactId, 'v' + pendingVersionNumber);
|
|
1636
|
+
// Clear pending values immediately to prevent re-processing
|
|
1637
|
+
this.conversationState.pendingArtifactId = null;
|
|
1638
|
+
this.conversationState.pendingArtifactVersionNumber = null;
|
|
1639
|
+
// Find the message containing this artifact version
|
|
1640
|
+
let messageIdWithArtifact = null;
|
|
1641
|
+
for (const [detailId, artifactList] of this.artifactsByDetailId.entries()) {
|
|
1642
|
+
for (const artifactInfo of artifactList) {
|
|
1643
|
+
if (artifactInfo.artifactId === pendingArtifactId) {
|
|
1644
|
+
// Found the artifact - check if version matches (if specified)
|
|
1645
|
+
if (pendingVersionNumber == null || artifactInfo.versionNumber === pendingVersionNumber) {
|
|
1646
|
+
messageIdWithArtifact = detailId;
|
|
1647
|
+
console.log('✅ Found artifact in message:', detailId);
|
|
1648
|
+
break;
|
|
1649
|
+
}
|
|
1650
|
+
}
|
|
1651
|
+
}
|
|
1652
|
+
if (messageIdWithArtifact)
|
|
1653
|
+
break;
|
|
1654
|
+
}
|
|
1655
|
+
if (!messageIdWithArtifact) {
|
|
1656
|
+
console.warn('⚠️ Could not find message containing artifact:', pendingArtifactId);
|
|
1657
|
+
return;
|
|
1658
|
+
}
|
|
1659
|
+
// Open the artifact panel
|
|
1660
|
+
this.selectedArtifactId = pendingArtifactId;
|
|
1661
|
+
this.selectedVersionNumber = pendingVersionNumber ?? undefined;
|
|
1662
|
+
this.showArtifactPanel = true;
|
|
1663
|
+
// Load permissions for the artifact
|
|
1664
|
+
await this.loadArtifactPermissions(pendingArtifactId);
|
|
1665
|
+
// Scroll to the message
|
|
1666
|
+
this.scrollToMessage(messageIdWithArtifact);
|
|
1667
|
+
console.log('✅ Opened artifact and scrolled to message:', messageIdWithArtifact);
|
|
1668
|
+
}
|
|
1669
|
+
/**
|
|
1670
|
+
* Scroll to a specific message in the conversation
|
|
1671
|
+
* @param messageId The conversation detail ID to scroll to
|
|
1672
|
+
*/
|
|
1673
|
+
scrollToMessage(messageId) {
|
|
1674
|
+
// Wait for DOM to update, then scroll
|
|
1675
|
+
setTimeout(() => {
|
|
1676
|
+
const messageElement = document.querySelector(`[data-message-id="${messageId}"]`);
|
|
1677
|
+
if (messageElement) {
|
|
1678
|
+
messageElement.scrollIntoView({ behavior: 'smooth', block: 'center' });
|
|
1679
|
+
console.log('📍 Scrolled to message:', messageId);
|
|
1680
|
+
}
|
|
1681
|
+
else {
|
|
1682
|
+
console.warn('⚠️ Message element not found for ID:', messageId);
|
|
1683
|
+
}
|
|
1684
|
+
}, 300); // Give time for artifact panel to open and DOM to render
|
|
1685
|
+
}
|
|
1570
1686
|
/**
|
|
1571
1687
|
* Handle intent check started - show temporary "Analyzing intent..." message
|
|
1572
1688
|
*/
|
|
@@ -1611,11 +1727,11 @@ export class ConversationChatAreaComponent {
|
|
|
1611
1727
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.scrollContainer = _t.first);
|
|
1612
1728
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.messageInputComponent = _t.first);
|
|
1613
1729
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.artifactViewerComponent = _t.first);
|
|
1614
|
-
} }, inputs: { environmentId: "environmentId", currentUser: "currentUser" }, outputs: { conversationRenamed: "conversationRenamed", openEntityRecord: "openEntityRecord", taskClicked: "taskClicked", artifactLinkClicked: "artifactLinkClicked" }, decls: 15, vars: 18, consts: [["scrollContainer", ""], ["messageInput", ""], [1, "chat-area"], ["class", "chat-header", 4, "ngIf"], [1, "chat-content-area"], [1, "chat-messages-pane"], [3, "currentUser", "disabled"], [1, "conversation-loading-state"], [1, "chat-messages-wrapper"], [3, "saved", "cancelled", "isOpen", "artifact", "currentUser"], [3, "parentMessageId", "conversationId", "currentUser"], [3, "cancelled", "exported", "isVisible", "conversation", "currentUser"], [3, "cancelled", "membersChanged", "isVisible", "conversation", "currentUser"], [1, "modal-overlay"], [3, "isOpen", "environmentId", "currentUser", "excludeCollectionIds"], [1, "chat-header"], [1, "chat-info"], [1, "chat-title"], ["class", "project-tag", "title", "Assign to project", 3, "click", 4, "ngIf"], ["title", "View members", 1, "chat-members", 3, "click"], [1, "fas", "fa-users"], ["class", "artifact-indicator", "title", "View artifacts", 3, "click", 4, "ngIf"], [3, "togglePanel", "agentSelected", "conversationId", "currentUser"], [1, "chat-actions"], [
|
|
1730
|
+
} }, inputs: { environmentId: "environmentId", currentUser: "currentUser" }, outputs: { conversationRenamed: "conversationRenamed", openEntityRecord: "openEntityRecord", taskClicked: "taskClicked", artifactLinkClicked: "artifactLinkClicked" }, decls: 15, vars: 18, consts: [["scrollContainer", ""], ["messageInput", ""], [1, "chat-area"], ["class", "chat-header", 4, "ngIf"], [1, "chat-content-area"], [1, "chat-messages-pane"], [3, "currentUser", "disabled"], [1, "conversation-loading-state"], [1, "chat-messages-wrapper"], [3, "saved", "cancelled", "isOpen", "artifact", "currentUser"], [3, "parentMessageId", "conversationId", "currentUser"], [3, "cancelled", "exported", "isVisible", "conversation", "currentUser"], [3, "cancelled", "membersChanged", "isVisible", "conversation", "currentUser"], [1, "modal-overlay"], [3, "isOpen", "environmentId", "currentUser", "excludeCollectionIds"], [1, "chat-header"], [1, "chat-info"], [1, "chat-title"], ["class", "project-tag", "title", "Assign to project", 3, "click", 4, "ngIf"], ["title", "View members", 1, "chat-members", 3, "click"], [1, "fas", "fa-users"], ["class", "artifact-indicator", "title", "View artifacts", 3, "click", 4, "ngIf"], [3, "togglePanel", "agentSelected", "conversationId", "currentUser"], [1, "chat-actions"], ["title", "Export conversation", 1, "action-btn", 3, "click"], [1, "fas", "fa-download"], [1, "action-btn", "share-btn", 3, "click", "title"], [1, "fas", "fa-share-nodes"], ["title", "Assign to project", 1, "project-tag", 3, "click"], [1, "fas", "fa-folder"], ["title", "View artifacts", 1, "artifact-indicator", 3, "click"], [1, "fas", "fa-cube"], [3, "messageSent", "currentUser", "disabled"], [1, "loading-content"], [1, "fas", "fa-spinner", "fa-spin"], [1, "chat-messages-container", 3, "scroll"], [3, "replyInThread", "viewThread", "retryMessage", "artifactClicked", "messageEdited", "openEntityRecord", "suggestedResponseSelected", "messages", "conversation", "currentUser", "isProcessing", "artifactMap", "agentRunMap", "ratingsMap", "userAvatarMap"], ["class", "scroll-to-bottom-icon", "style", "left: 50%;", 3, "click", 4, "ngIf"], [1, "chat-input-container"], [1, "loading-peripheral-placeholder"], [1, "message-input-container-wrapper"], [1, "scroll-to-bottom-icon", 2, "left", "50%", 3, "click"], [1, "fas", "fa-arrow-down"], [1, "loading-peripheral-content"], [3, "hidden", "conversationId", "conversationName", "currentUser", "conversationHistory", "artifactsByDetailId", "agentRunsByDetailId", "inProgressMessageIds", "disabled", "initialMessage"], [3, "messageSent", "agentResponse", "agentRunDetected", "agentRunUpdate", "messageComplete", "artifactCreated", "conversationRenamed", "intentCheckStarted", "intentCheckCompleted", "hidden", "conversationId", "conversationName", "currentUser", "conversationHistory", "artifactsByDetailId", "agentRunsByDetailId", "inProgressMessageIds", "disabled", "initialMessage"], [1, "resize-handle", 3, "mousedown"], [1, "chat-artifact-pane"], [3, "closed", "saveToCollectionRequested", "navigateToLink", "shareRequested", "artifactId", "currentUser", "environmentId", "versionNumber", "viewContext", "canShare", "canEdit", "refreshTrigger"], [3, "closed", "replyAdded", "parentMessageId", "conversationId", "currentUser"], [1, "modal-overlay", 3, "click"], [1, "modal-content", "project-selector-modal", 3, "click"], [1, "modal-header"], [1, "modal-close-btn", 3, "click"], [1, "fas", "fa-times"], [1, "modal-body"], [3, "projectSelected", "environmentId", "currentUser", "selectedProjectId"], [1, "modal-content", "artifacts-modal", 3, "click"], [1, "modal-header-actions"], ["title", "Toggle system artifacts visibility", 1, "toggle-system-btn", 3, "active"], [1, "modal-body", "artifacts-grid"], [1, "empty-state"], [1, "artifact-modal-card", 3, "expanded", "system-artifact"], ["title", "Toggle system artifacts visibility", 1, "toggle-system-btn", 3, "click"], [1, "fas", "fa-cog"], [1, "fas", "fa-cube", 2, "font-size", "48px", "color", "#D1D5DB", "margin-bottom", "16px"], [2, "color", "#6B7280", "font-size", "14px"], [1, "artifact-modal-card"], [1, "artifact-card-header", 3, "click"], [1, "artifact-modal-icon"], [1, "fas", "fa-file-code"], [1, "artifact-modal-info"], [1, "artifact-modal-title"], [1, "artifact-modal-meta"], [1, "expand-btn"], [1, "artifact-modal-action"], [1, "fas", "fa-external-link-alt"], [1, "artifact-versions-list"], [1, "expand-btn", 3, "click"], [1, "fas"], [1, "artifact-version-item"], [1, "artifact-version-item", 3, "click"], [1, "version-badge"], [1, "version-open-text"], [1, "fas", "fa-arrow-right"], [3, "saved", "cancelled", "isOpen", "environmentId", "currentUser", "excludeCollectionIds"]], template: function ConversationChatAreaComponent_Template(rf, ctx) { if (rf & 1) {
|
|
1615
1731
|
i0.ɵɵelementStart(0, "div", 2);
|
|
1616
|
-
i0.ɵɵtemplate(1, ConversationChatAreaComponent_div_1_Template,
|
|
1732
|
+
i0.ɵɵtemplate(1, ConversationChatAreaComponent_div_1_Template, 18, 10, "div", 3);
|
|
1617
1733
|
i0.ɵɵelementStart(2, "div", 4)(3, "div", 5);
|
|
1618
|
-
i0.ɵɵtemplate(4, ConversationChatAreaComponent_Conditional_4_Template, 1, 2, "mj-conversation-empty-state", 6)(5, ConversationChatAreaComponent_Conditional_5_Template, 5, 0, "div", 7)(6, ConversationChatAreaComponent_Conditional_6_Template, 8,
|
|
1734
|
+
i0.ɵɵtemplate(4, ConversationChatAreaComponent_Conditional_4_Template, 1, 2, "mj-conversation-empty-state", 6)(5, ConversationChatAreaComponent_Conditional_5_Template, 5, 0, "div", 7)(6, ConversationChatAreaComponent_Conditional_6_Template, 8, 10, "div", 8);
|
|
1619
1735
|
i0.ɵɵelementEnd();
|
|
1620
1736
|
i0.ɵɵtemplate(7, ConversationChatAreaComponent_Conditional_7_Template, 3, 10);
|
|
1621
1737
|
i0.ɵɵelementStart(8, "mj-artifact-share-modal", 9);
|
|
@@ -1635,7 +1751,7 @@ export class ConversationChatAreaComponent {
|
|
|
1635
1751
|
i0.ɵɵadvance(2);
|
|
1636
1752
|
i0.ɵɵclassProp("full-width", !ctx.showArtifactPanel);
|
|
1637
1753
|
i0.ɵɵadvance();
|
|
1638
|
-
i0.ɵɵconditional(!ctx.conversationState.activeConversation ? 4 : ctx.isLoadingConversation ? 5 : 6);
|
|
1754
|
+
i0.ɵɵconditional(!ctx.conversationState.activeConversation || ctx.conversationState.isNewUnsavedConversation ? 4 : ctx.isLoadingConversation ? 5 : 6);
|
|
1639
1755
|
i0.ɵɵadvance(3);
|
|
1640
1756
|
i0.ɵɵconditional(ctx.showArtifactPanel && ctx.selectedArtifactId ? 7 : -1);
|
|
1641
1757
|
i0.ɵɵadvance();
|
|
@@ -1652,11 +1768,11 @@ export class ConversationChatAreaComponent {
|
|
|
1652
1768
|
i0.ɵɵconditional(ctx.showArtifactsModal ? 13 : -1);
|
|
1653
1769
|
i0.ɵɵadvance();
|
|
1654
1770
|
i0.ɵɵconditional(ctx.showCollectionPicker ? 14 : -1);
|
|
1655
|
-
} }, dependencies: [i7.NgIf, i8.ArtifactViewerPanelComponent, i9.ArtifactCollectionPickerModalComponent, i10.ArtifactShareModalComponent, i11.MessageListComponent, i12.MessageInputComponent, i13.ConversationEmptyStateComponent, i14.ThreadPanelComponent, i15.ProjectSelectorComponent, i16.TasksDropdownComponent, i17.ActiveAgentIndicatorComponent, i18.MembersModalComponent, i19.ExportModalComponent], styles: ["[_nghost-%COMP%] {\n display: flex;\n width: 100%;\n height: 100%;\n}\n.chat-area[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100%;\n overflow: hidden;\n}\n.chat-header[_ngcontent-%COMP%] {\n flex-shrink: 0;\n padding: 12px 20px;\n border-bottom: 1px solid #D9D9D9;\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: 16px;\n background: #FFF;\n z-index: 10;\n box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);\n}\n.chat-info[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 12px;\n flex: 1;\n min-width: 0;\n}\n.chat-title[_ngcontent-%COMP%] {\n font-size: 16px;\n font-weight: 600;\n color: #333;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.project-tag[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n background: #F4F4F4;\n border: 1px solid #D9D9D9;\n border-radius: 16px;\n font-size: 11px;\n font-weight: 600;\n color: #AAA;\n cursor: pointer;\n transition: all 0.2s;\n height: 28px;\n margin-left: 12px;\n}\n.project-tag[_ngcontent-%COMP%]:hover {\n background: #D9D9D9;\n border-color: #AAA;\n}\n.project-tag[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 10px;\n}\n.chat-members[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 6px 12px;\n background: #F4F4F4;\n border: none;\n border-radius: 20px;\n font-size: 12px;\n font-weight: 500;\n color: #AAA;\n cursor: pointer;\n transition: all 0.2s;\n height: 32px;\n}\n.chat-members[_ngcontent-%COMP%]:hover {\n background: #D9D9D9;\n color: #333;\n}\n.chat-members[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 12px;\n}\n.chat-members[_ngcontent-%COMP%] span[_ngcontent-%COMP%] {\n font-size: 12px;\n font-weight: 500;\n}\n.artifact-indicator[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #3B82F6;\n border: none;\n border-radius: 6px;\n font-size: 13px;\n color: white;\n cursor: pointer;\n transition: all 150ms ease;\n}\n.artifact-indicator[_ngcontent-%COMP%]:hover {\n background: #2563EB;\n}\n.ambient-agent-indicator[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #F3F4F6;\n border: 1px solid #D1D5DB;\n border-radius: 6px;\n font-size: 13px;\n color: #6B7280;\n animation: _ngcontent-%COMP%_pulse 2s ease-in-out infinite;\n}\n.ambient-agent-indicator[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n color: #0076B6;\n}\n@keyframes _ngcontent-%COMP%_pulse {\n 0%, 100% { opacity: 1; }\n 50% { opacity: 0.7; }\n}\n.chat-actions[_ngcontent-%COMP%] {\n display: flex;\n gap: 8px;\n}\n.action-btn[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 8px 12px;\n background: transparent;\n border: 1px solid #E5E7EB;\n cursor: pointer;\n border-radius: 6px;\n font-size: 13px;\n color: #6B7280;\n transition: all 150ms ease;\n}\n.action-btn[_ngcontent-%COMP%]:hover {\n background: #F9FAFB;\n color: #111827;\n}\n.share-btn.shared[_ngcontent-%COMP%] {\n background: #EFF6FF;\n border-color: #1e40af;\n color: #1e40af;\n}\n.share-btn.shared[_ngcontent-%COMP%]:hover {\n background: #DBEAFE;\n color: #1e3a8a;\n}\n.chat-content-area[_ngcontent-%COMP%] {\n flex: 1;\n min-height: 0;\n overflow: hidden;\n display: flex;\n flex-direction: row;\n position: relative;\n}\n.chat-messages-pane[_ngcontent-%COMP%] {\n height: 100%;\n display: flex;\n flex-direction: column;\n min-width: 300px;\n overflow: hidden;\n transition: width 0.3s ease;\n}\n.chat-messages-pane.full-width[_ngcontent-%COMP%] {\n width: 100%;\n}\n.chat-messages-pane[_ngcontent-%COMP%]:not(.full-width) {\n flex: 1;\n}\n.resize-handle[_ngcontent-%COMP%] {\n width: 4px;\n background: transparent;\n cursor: col-resize;\n flex-shrink: 0;\n position: relative;\n transition: background-color 0.2s;\n}\n.resize-handle[_ngcontent-%COMP%]:hover {\n background: #3B82F6;\n}\n.resize-handle[_ngcontent-%COMP%]::before {\n content: '';\n position: absolute;\n left: -4px;\n right: -4px;\n top: 0;\n bottom: 0;\n}\n.chat-artifact-pane[_ngcontent-%COMP%] {\n height: 100%;\n display: flex;\n flex-direction: column;\n background: #FAFAFA;\n overflow: hidden;\n flex-shrink: 0;\n}\n.chat-artifact-pane[_ngcontent-%COMP%] > mj-artifact-viewer-panel[_ngcontent-%COMP%] {\n display: flex;\n flex: 1;\n min-height: 0;\n overflow: hidden;\n}\n.chat-messages-wrapper[_ngcontent-%COMP%] {\n flex: 1;\n display: flex;\n flex-direction: column;\n min-height: 0;\n overflow: hidden;\n}\n.chat-messages-container[_ngcontent-%COMP%] {\n flex: 1;\n overflow-y: auto;\n overflow-x: hidden;\n background: #FFF;\n min-height: 0;\n position: relative;\n}\n.scroll-to-bottom-icon[_ngcontent-%COMP%] {\n position: sticky;\n bottom: 21px; // 21px from bottom of visible scroll area (moved up 5px from original 16px)\n left: 50%;\n transform: translateX(-50%);\n width: 40px;\n height: 40px;\n margin-top: -40px; // Negative margin to not affect scroll height\n margin-left: auto;\n margin-right: auto;\n background: white;\n border: 1px solid #D1D5DB;\n border-radius: 50%;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);\n transition: all 0.2s ease;\n z-index: 100;\n pointer-events: auto;\n}\n.scroll-to-bottom-icon[_ngcontent-%COMP%]:hover {\n background: #F3F4F6;\n border-color: #3B82F6;\n transform: translateX(-50%) translateY(-2px);\n box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);\n}\n.scroll-to-bottom-icon[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n color: #6B7280;\n font-size: 16px;\n transition: color 0.2s;\n}\n.scroll-to-bottom-icon[_ngcontent-%COMP%]:hover i[_ngcontent-%COMP%] {\n color: #3B82F6;\n}\n.chat-input-container[_ngcontent-%COMP%] {\n flex-shrink: 0;\n background: #FFF;\n padding: 0 1.25rem 1.25rem 1.25rem; // Increased padding to prevent clipping rounded corners\n overflow: visible; // Allow box shadow and rounded corners to show fully\n}\n\n//[_ngcontent-%COMP%] Loading[_ngcontent-%COMP%] placeholder[_ngcontent-%COMP%] -[_ngcontent-%COMP%] replaces[_ngcontent-%COMP%] input[_ngcontent-%COMP%] while[_ngcontent-%COMP%] loading\n.loading-peripheral-placeholder[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: center;\n min-height: 140px; // Match typical input area height\n padding: 24px;\n background: rgba(255, 255, 255, 0.5);\n backdrop-filter: blur(2px);\n border-radius: 12px;\n margin: 12px;\n animation: _ngcontent-%COMP%_fadeIn 0.2s ease-in-out;\n}\n.modal-overlay[_ngcontent-%COMP%] {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.5);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 1000;\n}\n.modal-content[_ngcontent-%COMP%] {\n background: white;\n border-radius: 8px;\n box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);\n max-width: 90vw;\n max-height: 90vh;\n display: flex;\n flex-direction: column;\n}\n.project-selector-modal[_ngcontent-%COMP%] {\n width: 600px;\n height: 500px;\n}\n.modal-header[_ngcontent-%COMP%] {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 16px 20px;\n border-bottom: 1px solid #E5E7EB;\n}\n.modal-header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] {\n margin: 0;\n font-size: 18px;\n font-weight: 600;\n}\n.modal-header-actions[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 8px;\n}\n.toggle-system-btn[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n background: #F3F4F6;\n border: 1px solid #E5E7EB;\n cursor: pointer;\n color: #6B7280;\n padding: 6px 12px;\n border-radius: 6px;\n font-size: 13px;\n font-weight: 500;\n transition: all 0.2s;\n}\n.toggle-system-btn[_ngcontent-%COMP%]:hover {\n background: #E5E7EB;\n border-color: #D1D5DB;\n color: #374151;\n}\n.toggle-system-btn.active[_ngcontent-%COMP%] {\n background: #3B82F6;\n border-color: #3B82F6;\n color: white;\n}\n.toggle-system-btn.active[_ngcontent-%COMP%]:hover {\n background: #2563EB;\n border-color: #2563EB;\n}\n.toggle-system-btn[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 12px;\n}\n.modal-close-btn[_ngcontent-%COMP%] {\n background: none;\n border: none;\n cursor: pointer;\n color: #6B7280;\n padding: 4px 8px;\n border-radius: 4px;\n transition: all 0.2s;\n}\n.modal-close-btn[_ngcontent-%COMP%]:hover {\n background: #F3F4F6;\n color: #111827;\n}\n.modal-body[_ngcontent-%COMP%] {\n flex: 1;\n overflow: auto;\n padding: 20px;\n}\n.artifacts-modal[_ngcontent-%COMP%] {\n width: 700px;\n max-height: 600px;\n}\n.artifacts-grid[_ngcontent-%COMP%] {\n display: grid;\n grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));\n gap: 16px;\n}\n.empty-state[_ngcontent-%COMP%] {\n grid-column: 1 / -1;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: 60px 20px;\n}\n.artifact-modal-card[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n background: white;\n border: 1.5px solid #E5E7EB;\n border-radius: 12px;\n transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);\n overflow: hidden;\n}\n.artifact-modal-card.expanded[_ngcontent-%COMP%] {\n border-color: #3B82F6;\n}\n.artifact-modal-card.system-artifact[_ngcontent-%COMP%] {\n opacity: 0.85;\n border-color: #D1D5DB;\n border-style: dashed;\n position: relative;\n}\n.artifact-modal-card.system-artifact[_ngcontent-%COMP%]::before {\n content: 'SYSTEM';\n position: absolute;\n top: 8px;\n right: 8px;\n font-size: 9px;\n font-weight: 600;\n color: #9CA3AF;\n background: #F3F4F6;\n padding: 2px 6px;\n border-radius: 3px;\n letter-spacing: 0.5px;\n z-index: 10;\n}\n.artifact-modal-card.system-artifact[_ngcontent-%COMP%]:hover {\n border-color: #9CA3AF;\n box-shadow: 0 4px 12px rgba(156, 163, 175, 0.15);\n}\n.artifact-card-header[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px;\n cursor: pointer;\n}\n.artifact-card-header[_ngcontent-%COMP%]:hover {\n background: #F9FAFB;\n}\n.artifact-modal-card[_ngcontent-%COMP%]:hover {\n border-color: #3B82F6;\n box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);\n transform: translateY(-2px);\n}\n.artifact-modal-icon[_ngcontent-%COMP%] {\n width: 40px;\n height: 40px;\n display: flex;\n align-items: center;\n justify-content: center;\n background: linear-gradient(135deg, #EFF6FF 0%, #DBEAFE 100%);\n border-radius: 10px;\n color: #3B82F6;\n flex-shrink: 0;\n}\n.artifact-modal-icon[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 18px;\n}\n.artifact-modal-info[_ngcontent-%COMP%] {\n flex: 1;\n min-width: 0;\n}\n.artifact-modal-title[_ngcontent-%COMP%] {\n font-size: 14px;\n font-weight: 600;\n color: #1F2937;\n margin-bottom: 4px;\n}\n.artifact-modal-meta[_ngcontent-%COMP%] {\n font-size: 12px;\n color: #6B7280;\n}\n.artifact-modal-action[_ngcontent-%COMP%] {\n color: #9CA3AF;\n transition: color 0.2s;\n}\n.artifact-modal-card[_ngcontent-%COMP%]:hover .artifact-modal-action[_ngcontent-%COMP%] {\n color: #3B82F6;\n}\n.expand-btn[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 32px;\n height: 32px;\n border: none;\n background: transparent;\n color: #6B7280;\n cursor: pointer;\n border-radius: 6px;\n transition: all 0.2s;\n\n &:hover {\n background: #F3F4F6;\n color: #3B82F6;\n }\n}\n.artifact-versions-list[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n padding: 0 1rem 1rem 1rem;\n background: #F9FAFB;\n}\n.artifact-version-item[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 12px 16px 12px 68px; // Indent to align with title\n cursor: pointer;\n transition: background 0.15s;\n\n &:hover {\n background: #F3F4F6;\n }\n\n .version-badge {\n display: inline-block;\n padding: 4px 8px;\n background: #EEF2FF;\n color: #4F46E5;\n font-size: 12px;\n font-weight: 600;\n font-family: monospace;\n border-radius: 4px;\n }\n\n .version-open-text {\n flex: 1;\n font-size: 13px;\n color: #6B7280;\n }\n\n i {\n color: #9CA3AF;\n font-size: 12px;\n }\n\n &:hover {\n .version-badge {\n background: #4F46E5;\n color: white;\n }\n .version-open-text {\n color: #3B82F6;\n }\n i {\n color: #3B82F6;\n }\n }\n}\n\n//[_ngcontent-%COMP%] Loading[_ngcontent-%COMP%] content[_ngcontent-%COMP%] styling\n.loading-peripheral-content[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px 24px;\n background: white;\n border: 2px solid #E5E7EB;\n border-radius: 12px;\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);\n color: #4B5563;\n font-size: 14px;\n font-weight: 500;\n\n i {\n font-size: 20px;\n color: #9333EA;\n }\n}\n\n@keyframes _ngcontent-%COMP%_fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}\n//[_ngcontent-%COMP%] Loading[_ngcontent-%COMP%] conversation[_ngcontent-%COMP%] state[_ngcontent-%COMP%] -[_ngcontent-%COMP%] centered[_ngcontent-%COMP%] spinner\n.conversation-loading-state[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n width: 100%;\n}\n\n.loading-content[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding-top: 20px;\n gap: 16px;\n color: #6B7280;\n font-size: 15px;\n\n i {\n font-size: 32px;\n color: #3B82F6;\n }\n\n span {\n font-weight: 500;\n }\n}"] });
|
|
1771
|
+
} }, dependencies: [i7.NgIf, i8.ArtifactViewerPanelComponent, i9.ArtifactCollectionPickerModalComponent, i10.ArtifactShareModalComponent, i11.MessageListComponent, i12.MessageInputComponent, i13.ConversationEmptyStateComponent, i14.ThreadPanelComponent, i15.ProjectSelectorComponent, i16.ActiveAgentIndicatorComponent, i17.MembersModalComponent, i18.ExportModalComponent], styles: ["[_nghost-%COMP%] {\n display: flex;\n width: 100%;\n height: 100%;\n}\n.chat-area[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100%;\n overflow: hidden;\n}\n.chat-header[_ngcontent-%COMP%] {\n flex-shrink: 0;\n padding: 12px 20px;\n border-bottom: 1px solid #D9D9D9;\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: 16px;\n background: #FFF;\n z-index: 10;\n box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);\n}\n.chat-info[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 12px;\n flex: 1;\n min-width: 0;\n}\n.chat-title[_ngcontent-%COMP%] {\n font-size: 16px;\n font-weight: 600;\n color: #333;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.project-tag[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n background: #F4F4F4;\n border: 1px solid #D9D9D9;\n border-radius: 16px;\n font-size: 11px;\n font-weight: 600;\n color: #AAA;\n cursor: pointer;\n transition: all 0.2s;\n height: 28px;\n margin-left: 12px;\n}\n.project-tag[_ngcontent-%COMP%]:hover {\n background: #D9D9D9;\n border-color: #AAA;\n}\n.project-tag[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 10px;\n}\n.chat-members[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 6px 12px;\n background: #F4F4F4;\n border: none;\n border-radius: 20px;\n font-size: 12px;\n font-weight: 500;\n color: #AAA;\n cursor: pointer;\n transition: all 0.2s;\n height: 32px;\n}\n.chat-members[_ngcontent-%COMP%]:hover {\n background: #D9D9D9;\n color: #333;\n}\n.chat-members[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 12px;\n}\n.chat-members[_ngcontent-%COMP%] span[_ngcontent-%COMP%] {\n font-size: 12px;\n font-weight: 500;\n}\n.artifact-indicator[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #3B82F6;\n border: none;\n border-radius: 6px;\n font-size: 13px;\n color: white;\n cursor: pointer;\n transition: all 150ms ease;\n}\n.artifact-indicator[_ngcontent-%COMP%]:hover {\n background: #2563EB;\n}\n.ambient-agent-indicator[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #F3F4F6;\n border: 1px solid #D1D5DB;\n border-radius: 6px;\n font-size: 13px;\n color: #6B7280;\n animation: _ngcontent-%COMP%_pulse 2s ease-in-out infinite;\n}\n.ambient-agent-indicator[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n color: #0076B6;\n}\n@keyframes _ngcontent-%COMP%_pulse {\n 0%, 100% { opacity: 1; }\n 50% { opacity: 0.7; }\n}\n.chat-actions[_ngcontent-%COMP%] {\n display: flex;\n gap: 8px;\n}\n.action-btn[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 8px 12px;\n background: transparent;\n border: 1px solid #E5E7EB;\n cursor: pointer;\n border-radius: 6px;\n font-size: 13px;\n color: #6B7280;\n transition: all 150ms ease;\n}\n.action-btn[_ngcontent-%COMP%]:hover {\n background: #F9FAFB;\n color: #111827;\n}\n.share-btn.shared[_ngcontent-%COMP%] {\n background: #EFF6FF;\n border-color: #1e40af;\n color: #1e40af;\n}\n.share-btn.shared[_ngcontent-%COMP%]:hover {\n background: #DBEAFE;\n color: #1e3a8a;\n}\n.chat-content-area[_ngcontent-%COMP%] {\n flex: 1;\n min-height: 0;\n overflow: hidden;\n display: flex;\n flex-direction: row;\n position: relative;\n}\n.chat-messages-pane[_ngcontent-%COMP%] {\n height: 100%;\n display: flex;\n flex-direction: column;\n min-width: 300px;\n overflow: hidden;\n transition: width 0.3s ease;\n}\n.chat-messages-pane.full-width[_ngcontent-%COMP%] {\n width: 100%;\n}\n.chat-messages-pane[_ngcontent-%COMP%]:not(.full-width) {\n flex: 1;\n}\n.resize-handle[_ngcontent-%COMP%] {\n width: 4px;\n background: transparent;\n cursor: col-resize;\n flex-shrink: 0;\n position: relative;\n transition: background-color 0.2s;\n}\n.resize-handle[_ngcontent-%COMP%]:hover {\n background: #3B82F6;\n}\n.resize-handle[_ngcontent-%COMP%]::before {\n content: '';\n position: absolute;\n left: -4px;\n right: -4px;\n top: 0;\n bottom: 0;\n}\n.chat-artifact-pane[_ngcontent-%COMP%] {\n height: 100%;\n display: flex;\n flex-direction: column;\n background: #FAFAFA;\n overflow: hidden;\n flex-shrink: 0;\n}\n.chat-artifact-pane[_ngcontent-%COMP%] > mj-artifact-viewer-panel[_ngcontent-%COMP%] {\n display: flex;\n flex: 1;\n min-height: 0;\n overflow: hidden;\n}\n.chat-messages-wrapper[_ngcontent-%COMP%] {\n flex: 1;\n display: flex;\n flex-direction: column;\n min-height: 0;\n overflow: hidden;\n}\n.chat-messages-container[_ngcontent-%COMP%] {\n flex: 1;\n overflow-y: auto;\n overflow-x: hidden;\n background: #FFF;\n min-height: 0;\n position: relative;\n}\n.scroll-to-bottom-icon[_ngcontent-%COMP%] {\n position: sticky;\n bottom: 21px; // 21px from bottom of visible scroll area (moved up 5px from original 16px)\n left: 50%;\n transform: translateX(-50%);\n width: 40px;\n height: 40px;\n margin-top: -40px; // Negative margin to not affect scroll height\n margin-left: auto;\n margin-right: auto;\n background: white;\n border: 1px solid #D1D5DB;\n border-radius: 50%;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);\n transition: all 0.2s ease;\n z-index: 100;\n pointer-events: auto;\n}\n.scroll-to-bottom-icon[_ngcontent-%COMP%]:hover {\n background: #F3F4F6;\n border-color: #3B82F6;\n transform: translateX(-50%) translateY(-2px);\n box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);\n}\n.scroll-to-bottom-icon[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n color: #6B7280;\n font-size: 16px;\n transition: color 0.2s;\n}\n.scroll-to-bottom-icon[_ngcontent-%COMP%]:hover i[_ngcontent-%COMP%] {\n color: #3B82F6;\n}\n.chat-input-container[_ngcontent-%COMP%] {\n flex-shrink: 0;\n background: #FFF;\n padding: 0 1.25rem 1.25rem 1.25rem; // Increased padding to prevent clipping rounded corners\n overflow: visible; // Allow box shadow and rounded corners to show fully\n}\n\n//[_ngcontent-%COMP%] Loading[_ngcontent-%COMP%] placeholder[_ngcontent-%COMP%] -[_ngcontent-%COMP%] replaces[_ngcontent-%COMP%] input[_ngcontent-%COMP%] while[_ngcontent-%COMP%] loading\n.loading-peripheral-placeholder[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: center;\n min-height: 140px; // Match typical input area height\n padding: 24px;\n background: rgba(255, 255, 255, 0.5);\n backdrop-filter: blur(2px);\n border-radius: 12px;\n margin: 12px;\n animation: _ngcontent-%COMP%_fadeIn 0.2s ease-in-out;\n}\n.modal-overlay[_ngcontent-%COMP%] {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.5);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 1000;\n}\n.modal-content[_ngcontent-%COMP%] {\n background: white;\n border-radius: 8px;\n box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);\n max-width: 90vw;\n max-height: 90vh;\n display: flex;\n flex-direction: column;\n}\n.project-selector-modal[_ngcontent-%COMP%] {\n width: 600px;\n height: 500px;\n}\n.modal-header[_ngcontent-%COMP%] {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 16px 20px;\n border-bottom: 1px solid #E5E7EB;\n}\n.modal-header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] {\n margin: 0;\n font-size: 18px;\n font-weight: 600;\n}\n.modal-header-actions[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 8px;\n}\n.toggle-system-btn[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n background: #F3F4F6;\n border: 1px solid #E5E7EB;\n cursor: pointer;\n color: #6B7280;\n padding: 6px 12px;\n border-radius: 6px;\n font-size: 13px;\n font-weight: 500;\n transition: all 0.2s;\n}\n.toggle-system-btn[_ngcontent-%COMP%]:hover {\n background: #E5E7EB;\n border-color: #D1D5DB;\n color: #374151;\n}\n.toggle-system-btn.active[_ngcontent-%COMP%] {\n background: #3B82F6;\n border-color: #3B82F6;\n color: white;\n}\n.toggle-system-btn.active[_ngcontent-%COMP%]:hover {\n background: #2563EB;\n border-color: #2563EB;\n}\n.toggle-system-btn[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 12px;\n}\n.modal-close-btn[_ngcontent-%COMP%] {\n background: none;\n border: none;\n cursor: pointer;\n color: #6B7280;\n padding: 4px 8px;\n border-radius: 4px;\n transition: all 0.2s;\n}\n.modal-close-btn[_ngcontent-%COMP%]:hover {\n background: #F3F4F6;\n color: #111827;\n}\n.modal-body[_ngcontent-%COMP%] {\n flex: 1;\n overflow: auto;\n padding: 20px;\n}\n.artifacts-modal[_ngcontent-%COMP%] {\n width: 700px;\n max-height: 600px;\n}\n.artifacts-grid[_ngcontent-%COMP%] {\n display: grid;\n grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));\n gap: 16px;\n}\n.empty-state[_ngcontent-%COMP%] {\n grid-column: 1 / -1;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: 60px 20px;\n}\n.artifact-modal-card[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n background: white;\n border: 1.5px solid #E5E7EB;\n border-radius: 12px;\n transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);\n overflow: hidden;\n}\n.artifact-modal-card.expanded[_ngcontent-%COMP%] {\n border-color: #3B82F6;\n}\n.artifact-modal-card.system-artifact[_ngcontent-%COMP%] {\n opacity: 0.85;\n border-color: #D1D5DB;\n border-style: dashed;\n position: relative;\n}\n.artifact-modal-card.system-artifact[_ngcontent-%COMP%]::before {\n content: 'SYSTEM';\n position: absolute;\n top: 8px;\n right: 8px;\n font-size: 9px;\n font-weight: 600;\n color: #9CA3AF;\n background: #F3F4F6;\n padding: 2px 6px;\n border-radius: 3px;\n letter-spacing: 0.5px;\n z-index: 10;\n}\n.artifact-modal-card.system-artifact[_ngcontent-%COMP%]:hover {\n border-color: #9CA3AF;\n box-shadow: 0 4px 12px rgba(156, 163, 175, 0.15);\n}\n.artifact-card-header[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px;\n cursor: pointer;\n}\n.artifact-card-header[_ngcontent-%COMP%]:hover {\n background: #F9FAFB;\n}\n.artifact-modal-card[_ngcontent-%COMP%]:hover {\n border-color: #3B82F6;\n box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);\n transform: translateY(-2px);\n}\n.artifact-modal-icon[_ngcontent-%COMP%] {\n width: 40px;\n height: 40px;\n display: flex;\n align-items: center;\n justify-content: center;\n background: linear-gradient(135deg, #EFF6FF 0%, #DBEAFE 100%);\n border-radius: 10px;\n color: #3B82F6;\n flex-shrink: 0;\n}\n.artifact-modal-icon[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 18px;\n}\n.artifact-modal-info[_ngcontent-%COMP%] {\n flex: 1;\n min-width: 0;\n}\n.artifact-modal-title[_ngcontent-%COMP%] {\n font-size: 14px;\n font-weight: 600;\n color: #1F2937;\n margin-bottom: 4px;\n}\n.artifact-modal-meta[_ngcontent-%COMP%] {\n font-size: 12px;\n color: #6B7280;\n}\n.artifact-modal-action[_ngcontent-%COMP%] {\n color: #9CA3AF;\n transition: color 0.2s;\n}\n.artifact-modal-card[_ngcontent-%COMP%]:hover .artifact-modal-action[_ngcontent-%COMP%] {\n color: #3B82F6;\n}\n.expand-btn[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 32px;\n height: 32px;\n border: none;\n background: transparent;\n color: #6B7280;\n cursor: pointer;\n border-radius: 6px;\n transition: all 0.2s;\n\n &:hover {\n background: #F3F4F6;\n color: #3B82F6;\n }\n}\n.artifact-versions-list[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n padding: 0 1rem 1rem 1rem;\n background: #F9FAFB;\n}\n.artifact-version-item[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 12px 16px 12px 68px; // Indent to align with title\n cursor: pointer;\n transition: background 0.15s;\n\n &:hover {\n background: #F3F4F6;\n }\n\n .version-badge {\n display: inline-block;\n padding: 4px 8px;\n background: #EEF2FF;\n color: #4F46E5;\n font-size: 12px;\n font-weight: 600;\n font-family: monospace;\n border-radius: 4px;\n }\n\n .version-open-text {\n flex: 1;\n font-size: 13px;\n color: #6B7280;\n }\n\n i {\n color: #9CA3AF;\n font-size: 12px;\n }\n\n &:hover {\n .version-badge {\n background: #4F46E5;\n color: white;\n }\n .version-open-text {\n color: #3B82F6;\n }\n i {\n color: #3B82F6;\n }\n }\n}\n\n//[_ngcontent-%COMP%] Loading[_ngcontent-%COMP%] content[_ngcontent-%COMP%] styling\n.loading-peripheral-content[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px 24px;\n background: white;\n border: 2px solid #E5E7EB;\n border-radius: 12px;\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);\n color: #4B5563;\n font-size: 14px;\n font-weight: 500;\n\n i {\n font-size: 20px;\n color: #9333EA;\n }\n}\n\n@keyframes _ngcontent-%COMP%_fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}\n//[_ngcontent-%COMP%] Loading[_ngcontent-%COMP%] conversation[_ngcontent-%COMP%] state[_ngcontent-%COMP%] -[_ngcontent-%COMP%] centered[_ngcontent-%COMP%] spinner\n.conversation-loading-state[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n width: 100%;\n}\n\n.loading-content[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding-top: 20px;\n gap: 16px;\n color: #6B7280;\n font-size: 15px;\n\n i {\n font-size: 32px;\n color: #3B82F6;\n }\n\n span {\n font-weight: 500;\n }\n}"] });
|
|
1656
1772
|
}
|
|
1657
1773
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ConversationChatAreaComponent, [{
|
|
1658
1774
|
type: Component,
|
|
1659
|
-
args: [{ selector: 'mj-conversation-chat-area', template: "<div class=\"chat-area\">\n <!-- Fixed Header -->\n <div class=\"chat-header\" *ngIf=\"conversationState.activeConversation as conversation\">\n <div class=\"chat-info\">\n <div class=\"chat-title\">{{ conversation.Name }}</div>\n <button class=\"project-tag\" (click)=\"openProjectSelector()\" title=\"Assign to project\" *ngIf=\"conversation.ProjectID\">\n <i class=\"fas fa-folder\"></i>\n <span>{{ conversation.Project || 'Project' }}</span>\n </button>\n <button class=\"chat-members\" (click)=\"toggleMembersModal()\" title=\"View members\">\n <i class=\"fas fa-users\"></i>\n <span>{{ memberCount }} member{{ memberCount !== 1 ? 's' : '' }}</span>\n </button>\n <button class=\"artifact-indicator\" (click)=\"viewArtifacts()\" title=\"View artifacts\" *ngIf=\"artifactCountDisplay > 0\">\n <i class=\"fas fa-cube\"></i>\n <span>{{ artifactCountDisplay }} artifact{{ artifactCountDisplay !== 1 ? 's' : '' }}</span>\n </button>\n <mj-active-agent-indicator\n [conversationId]=\"conversationState.activeConversation.ID\"\n [currentUser]=\"currentUser\"\n (togglePanel)=\"onToggleAgentPanel()\"\n (agentSelected)=\"onAgentSelected($event)\">\n </mj-active-agent-indicator>\n </div>\n <div class=\"chat-actions\">\n <mj-tasks-dropdown\n [currentUser]=\"currentUser\"\n (taskClicked)=\"onTaskClicked($event)\">\n </mj-tasks-dropdown>\n <button class=\"action-btn\" (click)=\"exportConversation()\" title=\"Export conversation\">\n <i class=\"fas fa-download\"></i>\n Export\n </button>\n <button class=\"action-btn share-btn\"\n [class.shared]=\"isShared\"\n (click)=\"shareConversation()\"\n [title]=\"isShared ? 'Manage sharing' : 'Share conversation'\">\n <i class=\"fas fa-share-nodes\"></i>\n Share\n </button>\n </div>\n </div>\n\n <!-- Messages and Artifact Split Layout -->\n <div class=\"chat-content-area\">\n <!-- Messages Pane -->\n <div class=\"chat-messages-pane\" [class.full-width]=\"!showArtifactPanel\">\n @if (!conversationState.activeConversation) {\n <!-- Empty State - No conversation selected -->\n <mj-conversation-empty-state\n [currentUser]=\"currentUser\"\n [disabled]=\"isProcessing\"\n (messageSent)=\"onEmptyStateMessageSent($event)\">\n </mj-conversation-empty-state>\n } @else if (isLoadingConversation) {\n <!-- Loading State - Show centered spinner while conversation loads -->\n <div class=\"conversation-loading-state\">\n <div class=\"loading-content\">\n <i class=\"fas fa-spinner fa-spin\"></i>\n <span>Loading conversation...</span>\n </div>\n </div>\n } @else {\n <!-- Normal Message View -->\n <div class=\"chat-messages-wrapper\">\n <div class=\"chat-messages-container\" #scrollContainer (scroll)=\"checkScroll()\">\n <mj-conversation-message-list\n [messages]=\"messages\"\n [conversation]=\"conversationState.activeConversation\"\n [currentUser]=\"currentUser\"\n [isProcessing]=\"isProcessing\"\n [artifactMap]=\"effectiveArtifactsMap\"\n [agentRunMap]=\"agentRunsByDetailId\"\n [userAvatarMap]=\"userAvatarMap\"\n (replyInThread)=\"onReplyInThread($event)\"\n (viewThread)=\"onViewThread($event)\"\n (retryMessage)=\"onRetryMessage($event)\"\n (artifactClicked)=\"onArtifactClicked($event)\"\n (messageEdited)=\"onMessageEdited($event)\"\n (openEntityRecord)=\"onOpenEntityRecord($event)\"\n (suggestedResponseSelected)=\"onSuggestedResponseSelected($event)\">\n </mj-conversation-message-list>\n\n <!-- Scroll to Bottom Icon (positioned within scroll container for proper centering) -->\n <span class=\"scroll-to-bottom-icon\" style=\"left: 50%;\"\n *ngIf=\"showScrollToBottomIcon && messages && messages.length > 0\"\n (click)=\"scrollToBottomAnimate()\">\n <i class=\"fas fa-arrow-down\"></i>\n </span>\n </div>\n\n <!-- Fixed Input Area -->\n <div class=\"chat-input-container\">\n @if (isLoadingPeripheralData) {\n <!-- Loading State -->\n <div class=\"loading-peripheral-placeholder\">\n <div class=\"loading-peripheral-content\">\n <i class=\"fas fa-spinner fa-spin\"></i>\n <span>Loading conversation data...</span>\n </div>\n </div>\n } @else {\n <!-- Input Component -->\n <mj-message-input\n #messageInput\n *ngIf=\"conversationState.activeConversation\"\n [conversationId]=\"conversationState.activeConversation.ID\"\n [currentUser]=\"currentUser\"\n [conversationHistory]=\"messages\"\n [disabled]=\"isProcessing\"\n [initialMessage]=\"conversationState.pendingMessageToSend\"\n (messageSent)=\"onMessageSent($event)\"\n (agentResponse)=\"onAgentResponse($event)\"\n (agentRunDetected)=\"onAgentRunDetected($event)\"\n (agentRunUpdate)=\"onAgentRunUpdate($event)\"\n (messageComplete)=\"onMessageComplete($event)\"\n (artifactCreated)=\"onArtifactCreated($event)\"\n (conversationRenamed)=\"onConversationRenamed($event)\"\n (intentCheckStarted)=\"onIntentCheckStarted()\"\n (intentCheckCompleted)=\"onIntentCheckCompleted()\">\n </mj-message-input>\n }\n </div>\n </div>\n }\n </div>\n\n <!-- Artifact Viewer Pane -->\n @if (showArtifactPanel && selectedArtifactId) {\n <div class=\"resize-handle\" (mousedown)=\"onResizeStart($event)\"></div>\n <div class=\"chat-artifact-pane\" [style.width.%]=\"artifactPaneWidth\">\n <mj-artifact-viewer-panel\n [artifactId]=\"selectedArtifactId\"\n [currentUser]=\"currentUser\"\n [environmentId]=\"environmentId\"\n [versionNumber]=\"selectedVersionNumber\"\n [viewContext]=\"'conversation'\"\n [canShare]=\"canShareSelectedArtifact\"\n [canEdit]=\"canEditSelectedArtifact\"\n [refreshTrigger]=\"artifactViewerRefresh$\"\n (closed)=\"onCloseArtifactPanel()\"\n (saveToCollectionRequested)=\"onSaveToCollectionRequested($event)\"\n (navigateToLink)=\"onArtifactLinkNavigation($event)\"\n (shareRequested)=\"onArtifactShareRequested($event)\">\n </mj-artifact-viewer-panel>\n </div>\n }\n\n <!-- Artifact Share Modal -->\n <mj-artifact-share-modal\n [isOpen]=\"isArtifactShareModalOpen\"\n [artifact]=\"artifactToShare\"\n [currentUser]=\"currentUser\"\n (saved)=\"onArtifactShared()\"\n (cancelled)=\"onArtifactShareModalClose()\">\n </mj-artifact-share-modal>\n </div>\n</div>\n\n<!-- Thread Panel -->\n@if (conversationState.activeThreadId) {\n <mj-thread-panel\n [parentMessageId]=\"conversationState.activeThreadId\"\n [conversationId]=\"conversationState.activeConversation?.ID || ''\"\n [currentUser]=\"currentUser\"\n (closed)=\"onThreadClosed()\"\n (replyAdded)=\"onThreadReplyAdded($event)\">\n </mj-thread-panel>\n}\n\n<!-- Export Modal -->\n<mj-export-modal\n [isVisible]=\"showExportModal\"\n [conversation]=\"conversationState.activeConversation || undefined\"\n [currentUser]=\"currentUser\"\n (cancelled)=\"onExportModalCancelled()\"\n (exported)=\"onExportModalComplete()\">\n</mj-export-modal>\n\n<!-- Members Modal -->\n<mj-members-modal\n [isVisible]=\"showMembersModal\"\n [conversation]=\"conversationState.activeConversation || undefined\"\n [currentUser]=\"currentUser\"\n (cancelled)=\"showMembersModal = false\"\n (membersChanged)=\"showMembersModal = false\">\n</mj-members-modal>\n\n<!-- Project Selector Modal -->\n@if (showProjectSelector && conversationState.activeConversation) {\n <div class=\"modal-overlay\" (click)=\"showProjectSelector = false\">\n <div class=\"modal-content project-selector-modal\" (click)=\"$event.stopPropagation()\">\n <div class=\"modal-header\">\n <h3>Assign Project</h3>\n <button class=\"modal-close-btn\" (click)=\"showProjectSelector = false\">\n <i class=\"fas fa-times\"></i>\n </button>\n </div>\n <div class=\"modal-body\">\n <mj-project-selector\n [environmentId]=\"environmentId\"\n [currentUser]=\"currentUser\"\n [selectedProjectId]=\"conversationState.activeConversation.ProjectID\"\n (projectSelected)=\"onProjectSelected($event)\">\n </mj-project-selector>\n </div>\n </div>\n </div>\n}\n\n<!-- Artifacts Modal -->\n@if (showArtifactsModal) {\n <div class=\"modal-overlay\" (click)=\"showArtifactsModal = false\">\n <div class=\"modal-content artifacts-modal\" (click)=\"$event.stopPropagation()\">\n <div class=\"modal-header\">\n <h3>Conversation Artifacts</h3>\n <div class=\"modal-header-actions\">\n @if (hasSystemArtifacts) {\n <button class=\"toggle-system-btn\"\n [class.active]=\"showSystemArtifacts\"\n (click)=\"toggleSystemArtifacts()\"\n title=\"Toggle system artifacts visibility\">\n <i class=\"fas fa-cog\"></i>\n <span>{{ showSystemArtifacts ? 'Hide' : 'Show' }} System</span>\n </button>\n }\n <button class=\"modal-close-btn\" (click)=\"showArtifactsModal = false\">\n <i class=\"fas fa-times\"></i>\n </button>\n </div>\n </div>\n <div class=\"modal-body artifacts-grid\">\n @if (artifactsByDetailId.size === 0) {\n <div class=\"empty-state\">\n <i class=\"fas fa-cube\" style=\"font-size: 48px; color: #D1D5DB; margin-bottom: 16px;\"></i>\n <p style=\"color: #6B7280; font-size: 14px;\">No artifacts in this conversation yet</p>\n </div>\n }\n @for (artifact of getArtifactsArray(); track artifact.artifactId) {\n <div class=\"artifact-modal-card\"\n [class.expanded]=\"expandedArtifactId === artifact.artifactId\"\n [class.system-artifact]=\"artifact.visibility === 'System Only'\">\n <!-- Main card header - click to open latest version -->\n <div class=\"artifact-card-header\" (click)=\"openArtifactFromModal(artifact.artifactId)\">\n <div class=\"artifact-modal-icon\">\n <i class=\"fas fa-file-code\"></i>\n </div>\n <div class=\"artifact-modal-info\">\n <div class=\"artifact-modal-title\">{{artifact.name}}</div>\n <div class=\"artifact-modal-meta\">\n @if (artifact.versionCount > 1) {\n {{artifact.versionCount}} versions\n } @else {\n 1 version\n }\n </div>\n </div>\n @if (artifact.versionCount > 1) {\n <button class=\"expand-btn\" (click)=\"toggleArtifactExpansion(artifact.artifactId, $event)\">\n <i class=\"fas\" [class.fa-chevron-down]=\"expandedArtifactId !== artifact.artifactId\"\n [class.fa-chevron-up]=\"expandedArtifactId === artifact.artifactId\"></i>\n </button>\n }\n <div class=\"artifact-modal-action\">\n <i class=\"fas fa-external-link-alt\"></i>\n </div>\n </div>\n\n <!-- Expanded version list -->\n @if (expandedArtifactId === artifact.artifactId && artifact.versionCount > 1) {\n <div class=\"artifact-versions-list\">\n @for (version of artifact.versions; track version.versionId) {\n <div class=\"artifact-version-item\" (click)=\"openArtifactFromModal(artifact.artifactId, version.versionNumber); $event.stopPropagation()\">\n <span class=\"version-badge\">v{{version.versionNumber}}</span>\n <span class=\"version-open-text\">Open this version</span>\n <i class=\"fas fa-arrow-right\"></i>\n </div>\n }\n </div>\n }\n </div>\n }\n </div>\n </div>\n </div>\n}\n\n<!-- Collection Picker Modal -->\n@if (showCollectionPicker) {\n <mj-artifact-collection-picker-modal\n [isOpen]=\"showCollectionPicker\"\n [environmentId]=\"environmentId\"\n [currentUser]=\"currentUser\"\n [excludeCollectionIds]=\"collectionPickerExcludedIds\"\n (saved)=\"onCollectionPickerSaved($event)\"\n (cancelled)=\"onCollectionPickerCancelled()\">\n </mj-artifact-collection-picker-modal>\n}", styles: [":host {\n display: flex;\n width: 100%;\n height: 100%;\n}\n.chat-area {\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100%;\n overflow: hidden;\n}\n.chat-header {\n flex-shrink: 0;\n padding: 12px 20px;\n border-bottom: 1px solid #D9D9D9;\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: 16px;\n background: #FFF;\n z-index: 10;\n box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);\n}\n.chat-info {\n display: flex;\n align-items: center;\n gap: 12px;\n flex: 1;\n min-width: 0;\n}\n.chat-title {\n font-size: 16px;\n font-weight: 600;\n color: #333;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.project-tag {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n background: #F4F4F4;\n border: 1px solid #D9D9D9;\n border-radius: 16px;\n font-size: 11px;\n font-weight: 600;\n color: #AAA;\n cursor: pointer;\n transition: all 0.2s;\n height: 28px;\n margin-left: 12px;\n}\n.project-tag:hover {\n background: #D9D9D9;\n border-color: #AAA;\n}\n.project-tag i {\n font-size: 10px;\n}\n.chat-members {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 6px 12px;\n background: #F4F4F4;\n border: none;\n border-radius: 20px;\n font-size: 12px;\n font-weight: 500;\n color: #AAA;\n cursor: pointer;\n transition: all 0.2s;\n height: 32px;\n}\n.chat-members:hover {\n background: #D9D9D9;\n color: #333;\n}\n.chat-members i {\n font-size: 12px;\n}\n.chat-members span {\n font-size: 12px;\n font-weight: 500;\n}\n.artifact-indicator {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #3B82F6;\n border: none;\n border-radius: 6px;\n font-size: 13px;\n color: white;\n cursor: pointer;\n transition: all 150ms ease;\n}\n.artifact-indicator:hover {\n background: #2563EB;\n}\n.ambient-agent-indicator {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #F3F4F6;\n border: 1px solid #D1D5DB;\n border-radius: 6px;\n font-size: 13px;\n color: #6B7280;\n animation: pulse 2s ease-in-out infinite;\n}\n.ambient-agent-indicator i {\n color: #0076B6;\n}\n@keyframes pulse {\n 0%, 100% { opacity: 1; }\n 50% { opacity: 0.7; }\n}\n.chat-actions {\n display: flex;\n gap: 8px;\n}\n.action-btn {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 8px 12px;\n background: transparent;\n border: 1px solid #E5E7EB;\n cursor: pointer;\n border-radius: 6px;\n font-size: 13px;\n color: #6B7280;\n transition: all 150ms ease;\n}\n.action-btn:hover {\n background: #F9FAFB;\n color: #111827;\n}\n.share-btn.shared {\n background: #EFF6FF;\n border-color: #1e40af;\n color: #1e40af;\n}\n.share-btn.shared:hover {\n background: #DBEAFE;\n color: #1e3a8a;\n}\n.chat-content-area {\n flex: 1;\n min-height: 0;\n overflow: hidden;\n display: flex;\n flex-direction: row;\n position: relative;\n}\n.chat-messages-pane {\n height: 100%;\n display: flex;\n flex-direction: column;\n min-width: 300px;\n overflow: hidden;\n transition: width 0.3s ease;\n}\n.chat-messages-pane.full-width {\n width: 100%;\n}\n.chat-messages-pane:not(.full-width) {\n flex: 1;\n}\n.resize-handle {\n width: 4px;\n background: transparent;\n cursor: col-resize;\n flex-shrink: 0;\n position: relative;\n transition: background-color 0.2s;\n}\n.resize-handle:hover {\n background: #3B82F6;\n}\n.resize-handle::before {\n content: '';\n position: absolute;\n left: -4px;\n right: -4px;\n top: 0;\n bottom: 0;\n}\n.chat-artifact-pane {\n height: 100%;\n display: flex;\n flex-direction: column;\n background: #FAFAFA;\n overflow: hidden;\n flex-shrink: 0;\n}\n.chat-artifact-pane > mj-artifact-viewer-panel {\n display: flex;\n flex: 1;\n min-height: 0;\n overflow: hidden;\n}\n.chat-messages-wrapper {\n flex: 1;\n display: flex;\n flex-direction: column;\n min-height: 0;\n overflow: hidden;\n}\n.chat-messages-container {\n flex: 1;\n overflow-y: auto;\n overflow-x: hidden;\n background: #FFF;\n min-height: 0;\n position: relative;\n}\n.scroll-to-bottom-icon {\n position: sticky;\n bottom: 21px; // 21px from bottom of visible scroll area (moved up 5px from original 16px)\n left: 50%;\n transform: translateX(-50%);\n width: 40px;\n height: 40px;\n margin-top: -40px; // Negative margin to not affect scroll height\n margin-left: auto;\n margin-right: auto;\n background: white;\n border: 1px solid #D1D5DB;\n border-radius: 50%;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);\n transition: all 0.2s ease;\n z-index: 100;\n pointer-events: auto;\n}\n.scroll-to-bottom-icon:hover {\n background: #F3F4F6;\n border-color: #3B82F6;\n transform: translateX(-50%) translateY(-2px);\n box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);\n}\n.scroll-to-bottom-icon i {\n color: #6B7280;\n font-size: 16px;\n transition: color 0.2s;\n}\n.scroll-to-bottom-icon:hover i {\n color: #3B82F6;\n}\n.chat-input-container {\n flex-shrink: 0;\n background: #FFF;\n padding: 0 1.25rem 1.25rem 1.25rem; // Increased padding to prevent clipping rounded corners\n overflow: visible; // Allow box shadow and rounded corners to show fully\n}\n\n// Loading placeholder - replaces input while loading\n.loading-peripheral-placeholder {\n display: flex;\n align-items: center;\n justify-content: center;\n min-height: 140px; // Match typical input area height\n padding: 24px;\n background: rgba(255, 255, 255, 0.5);\n backdrop-filter: blur(2px);\n border-radius: 12px;\n margin: 12px;\n animation: fadeIn 0.2s ease-in-out;\n}\n.modal-overlay {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.5);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 1000;\n}\n.modal-content {\n background: white;\n border-radius: 8px;\n box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);\n max-width: 90vw;\n max-height: 90vh;\n display: flex;\n flex-direction: column;\n}\n.project-selector-modal {\n width: 600px;\n height: 500px;\n}\n.modal-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 16px 20px;\n border-bottom: 1px solid #E5E7EB;\n}\n.modal-header h3 {\n margin: 0;\n font-size: 18px;\n font-weight: 600;\n}\n.modal-header-actions {\n display: flex;\n align-items: center;\n gap: 8px;\n}\n.toggle-system-btn {\n display: flex;\n align-items: center;\n gap: 6px;\n background: #F3F4F6;\n border: 1px solid #E5E7EB;\n cursor: pointer;\n color: #6B7280;\n padding: 6px 12px;\n border-radius: 6px;\n font-size: 13px;\n font-weight: 500;\n transition: all 0.2s;\n}\n.toggle-system-btn:hover {\n background: #E5E7EB;\n border-color: #D1D5DB;\n color: #374151;\n}\n.toggle-system-btn.active {\n background: #3B82F6;\n border-color: #3B82F6;\n color: white;\n}\n.toggle-system-btn.active:hover {\n background: #2563EB;\n border-color: #2563EB;\n}\n.toggle-system-btn i {\n font-size: 12px;\n}\n.modal-close-btn {\n background: none;\n border: none;\n cursor: pointer;\n color: #6B7280;\n padding: 4px 8px;\n border-radius: 4px;\n transition: all 0.2s;\n}\n.modal-close-btn:hover {\n background: #F3F4F6;\n color: #111827;\n}\n.modal-body {\n flex: 1;\n overflow: auto;\n padding: 20px;\n}\n.artifacts-modal {\n width: 700px;\n max-height: 600px;\n}\n.artifacts-grid {\n display: grid;\n grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));\n gap: 16px;\n}\n.empty-state {\n grid-column: 1 / -1;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: 60px 20px;\n}\n.artifact-modal-card {\n display: flex;\n flex-direction: column;\n background: white;\n border: 1.5px solid #E5E7EB;\n border-radius: 12px;\n transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);\n overflow: hidden;\n}\n.artifact-modal-card.expanded {\n border-color: #3B82F6;\n}\n.artifact-modal-card.system-artifact {\n opacity: 0.85;\n border-color: #D1D5DB;\n border-style: dashed;\n position: relative;\n}\n.artifact-modal-card.system-artifact::before {\n content: 'SYSTEM';\n position: absolute;\n top: 8px;\n right: 8px;\n font-size: 9px;\n font-weight: 600;\n color: #9CA3AF;\n background: #F3F4F6;\n padding: 2px 6px;\n border-radius: 3px;\n letter-spacing: 0.5px;\n z-index: 10;\n}\n.artifact-modal-card.system-artifact:hover {\n border-color: #9CA3AF;\n box-shadow: 0 4px 12px rgba(156, 163, 175, 0.15);\n}\n.artifact-card-header {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px;\n cursor: pointer;\n}\n.artifact-card-header:hover {\n background: #F9FAFB;\n}\n.artifact-modal-card:hover {\n border-color: #3B82F6;\n box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);\n transform: translateY(-2px);\n}\n.artifact-modal-icon {\n width: 40px;\n height: 40px;\n display: flex;\n align-items: center;\n justify-content: center;\n background: linear-gradient(135deg, #EFF6FF 0%, #DBEAFE 100%);\n border-radius: 10px;\n color: #3B82F6;\n flex-shrink: 0;\n}\n.artifact-modal-icon i {\n font-size: 18px;\n}\n.artifact-modal-info {\n flex: 1;\n min-width: 0;\n}\n.artifact-modal-title {\n font-size: 14px;\n font-weight: 600;\n color: #1F2937;\n margin-bottom: 4px;\n}\n.artifact-modal-meta {\n font-size: 12px;\n color: #6B7280;\n}\n.artifact-modal-action {\n color: #9CA3AF;\n transition: color 0.2s;\n}\n.artifact-modal-card:hover .artifact-modal-action {\n color: #3B82F6;\n}\n.expand-btn {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 32px;\n height: 32px;\n border: none;\n background: transparent;\n color: #6B7280;\n cursor: pointer;\n border-radius: 6px;\n transition: all 0.2s;\n\n &:hover {\n background: #F3F4F6;\n color: #3B82F6;\n }\n}\n.artifact-versions-list {\n display: flex;\n flex-direction: column;\n padding: 0 1rem 1rem 1rem;\n background: #F9FAFB;\n}\n.artifact-version-item {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 12px 16px 12px 68px; // Indent to align with title\n cursor: pointer;\n transition: background 0.15s;\n\n &:hover {\n background: #F3F4F6;\n }\n\n .version-badge {\n display: inline-block;\n padding: 4px 8px;\n background: #EEF2FF;\n color: #4F46E5;\n font-size: 12px;\n font-weight: 600;\n font-family: monospace;\n border-radius: 4px;\n }\n\n .version-open-text {\n flex: 1;\n font-size: 13px;\n color: #6B7280;\n }\n\n i {\n color: #9CA3AF;\n font-size: 12px;\n }\n\n &:hover {\n .version-badge {\n background: #4F46E5;\n color: white;\n }\n .version-open-text {\n color: #3B82F6;\n }\n i {\n color: #3B82F6;\n }\n }\n}\n\n// Loading content styling\n.loading-peripheral-content {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px 24px;\n background: white;\n border: 2px solid #E5E7EB;\n border-radius: 12px;\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);\n color: #4B5563;\n font-size: 14px;\n font-weight: 500;\n\n i {\n font-size: 20px;\n color: #9333EA;\n }\n}\n\n@keyframes fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}\n// Loading conversation state - centered spinner\n.conversation-loading-state {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n width: 100%;\n}\n\n.loading-content {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding-top: 20px;\n gap: 16px;\n color: #6B7280;\n font-size: 15px;\n\n i {\n font-size: 32px;\n color: #3B82F6;\n }\n\n span {\n font-weight: 500;\n }\n}\n"] }]
|
|
1775
|
+
args: [{ selector: 'mj-conversation-chat-area', template: "<div class=\"chat-area\">\n <!-- Fixed Header -->\n <div class=\"chat-header\" *ngIf=\"conversationState.activeConversation as conversation\">\n <div class=\"chat-info\">\n <div class=\"chat-title\">{{ conversation.Name }}</div>\n <button class=\"project-tag\" (click)=\"openProjectSelector()\" title=\"Assign to project\" *ngIf=\"conversation.ProjectID\">\n <i class=\"fas fa-folder\"></i>\n <span>{{ conversation.Project || 'Project' }}</span>\n </button>\n <button class=\"chat-members\" (click)=\"toggleMembersModal()\" title=\"View members\">\n <i class=\"fas fa-users\"></i>\n <span>{{ memberCount }} member{{ memberCount !== 1 ? 's' : '' }}</span>\n </button>\n <button class=\"artifact-indicator\" (click)=\"viewArtifacts()\" title=\"View artifacts\" *ngIf=\"artifactCountDisplay > 0\">\n <i class=\"fas fa-cube\"></i>\n <span>{{ artifactCountDisplay }} artifact{{ artifactCountDisplay !== 1 ? 's' : '' }}</span>\n </button>\n <mj-active-agent-indicator\n [conversationId]=\"conversationState.activeConversation.ID\"\n [currentUser]=\"currentUser\"\n (togglePanel)=\"onToggleAgentPanel()\"\n (agentSelected)=\"onAgentSelected($event)\">\n </mj-active-agent-indicator>\n </div>\n <div class=\"chat-actions\">\n <button class=\"action-btn\" (click)=\"exportConversation()\" title=\"Export conversation\">\n <i class=\"fas fa-download\"></i>\n Export\n </button>\n <button class=\"action-btn share-btn\"\n [class.shared]=\"isShared\"\n (click)=\"shareConversation()\"\n [title]=\"isShared ? 'Manage sharing' : 'Share conversation'\">\n <i class=\"fas fa-share-nodes\"></i>\n Share\n </button>\n </div>\n </div>\n\n <!-- Messages and Artifact Split Layout -->\n <div class=\"chat-content-area\">\n <!-- Messages Pane -->\n <div class=\"chat-messages-pane\" [class.full-width]=\"!showArtifactPanel\">\n @if (!conversationState.activeConversation || conversationState.isNewUnsavedConversation) {\n <!-- Empty State - No conversation selected OR new unsaved conversation -->\n <mj-conversation-empty-state\n [currentUser]=\"currentUser\"\n [disabled]=\"isProcessing\"\n (messageSent)=\"onEmptyStateMessageSent($event)\">\n </mj-conversation-empty-state>\n } @else if (isLoadingConversation) {\n <!-- Loading State - Show centered spinner while conversation loads -->\n <div class=\"conversation-loading-state\">\n <div class=\"loading-content\">\n <i class=\"fas fa-spinner fa-spin\"></i>\n <span>Loading conversation...</span>\n </div>\n </div>\n } @else {\n <!-- Normal Message View -->\n <div class=\"chat-messages-wrapper\">\n <div class=\"chat-messages-container\" #scrollContainer (scroll)=\"checkScroll()\">\n <mj-conversation-message-list\n [messages]=\"messages\"\n [conversation]=\"conversationState.activeConversation\"\n [currentUser]=\"currentUser\"\n [isProcessing]=\"isProcessing\"\n [artifactMap]=\"effectiveArtifactsMap\"\n [agentRunMap]=\"agentRunsByDetailId\"\n [ratingsMap]=\"ratingsByDetailId\"\n [userAvatarMap]=\"userAvatarMap\"\n (replyInThread)=\"onReplyInThread($event)\"\n (viewThread)=\"onViewThread($event)\"\n (retryMessage)=\"onRetryMessage($event)\"\n (artifactClicked)=\"onArtifactClicked($event)\"\n (messageEdited)=\"onMessageEdited($event)\"\n (openEntityRecord)=\"onOpenEntityRecord($event)\"\n (suggestedResponseSelected)=\"onSuggestedResponseSelected($event)\">\n </mj-conversation-message-list>\n\n <!-- Scroll to Bottom Icon (positioned within scroll container for proper centering) -->\n <span class=\"scroll-to-bottom-icon\" style=\"left: 50%;\"\n *ngIf=\"showScrollToBottomIcon && messages && messages.length > 0\"\n (click)=\"scrollToBottomAnimate()\">\n <i class=\"fas fa-arrow-down\"></i>\n </span>\n </div>\n\n <!-- Fixed Input Area -->\n <div class=\"chat-input-container\">\n @if (isLoadingPeripheralData) {\n <!-- Loading State -->\n <div class=\"loading-peripheral-placeholder\">\n <div class=\"loading-peripheral-content\">\n <i class=\"fas fa-spinner fa-spin\"></i>\n <span>Loading conversation data...</span>\n </div>\n </div>\n } @else {\n <!-- Input Component - Multiple instances cached, only one visible -->\n <div class=\"message-input-container-wrapper\">\n @for (inputRef of getCachedInputs(); track inputRef.conversationId) {\n <mj-message-input\n #messageInput\n [hidden]=\"inputRef.conversationId !== conversationState.activeConversation.ID\"\n [conversationId]=\"inputRef.conversationId\"\n [conversationName]=\"inputRef.conversationName\"\n [currentUser]=\"currentUser\"\n [conversationHistory]=\"inputRef.conversationId === conversationState.activeConversation.ID ? messages : []\"\n [artifactsByDetailId]=\"inputRef.conversationId === conversationState.activeConversation.ID ? artifactsByDetailId : emptyArtifactsMap\"\n [agentRunsByDetailId]=\"inputRef.conversationId === conversationState.activeConversation.ID ? agentRunsByDetailId : emptyAgentRunsMap\"\n [inProgressMessageIds]=\"inputRef.conversationId === conversationState.activeConversation.ID ? inProgressMessageIds : emptyInProgressIds\"\n [disabled]=\"isProcessing\"\n [initialMessage]=\"inputRef.conversationId === conversationState.activeConversation.ID ? conversationState.pendingMessageToSend : null\"\n (messageSent)=\"onMessageSent($event)\"\n (agentResponse)=\"onAgentResponse($event)\"\n (agentRunDetected)=\"onAgentRunDetected($event)\"\n (agentRunUpdate)=\"onAgentRunUpdate($event)\"\n (messageComplete)=\"onMessageComplete($event)\"\n (artifactCreated)=\"onArtifactCreated($event)\"\n (conversationRenamed)=\"onConversationRenamed($event)\"\n (intentCheckStarted)=\"onIntentCheckStarted()\"\n (intentCheckCompleted)=\"onIntentCheckCompleted()\">\n </mj-message-input>\n }\n </div>\n }\n </div>\n </div>\n }\n </div>\n\n <!-- Artifact Viewer Pane -->\n @if (showArtifactPanel && selectedArtifactId) {\n <div class=\"resize-handle\" (mousedown)=\"onResizeStart($event)\"></div>\n <div class=\"chat-artifact-pane\" [style.width.%]=\"artifactPaneWidth\">\n <mj-artifact-viewer-panel\n [artifactId]=\"selectedArtifactId\"\n [currentUser]=\"currentUser\"\n [environmentId]=\"environmentId\"\n [versionNumber]=\"selectedVersionNumber\"\n [viewContext]=\"'conversation'\"\n [canShare]=\"canShareSelectedArtifact\"\n [canEdit]=\"canEditSelectedArtifact\"\n [refreshTrigger]=\"artifactViewerRefresh$\"\n (closed)=\"onCloseArtifactPanel()\"\n (saveToCollectionRequested)=\"onSaveToCollectionRequested($event)\"\n (navigateToLink)=\"onArtifactLinkNavigation($event)\"\n (shareRequested)=\"onArtifactShareRequested($event)\">\n </mj-artifact-viewer-panel>\n </div>\n }\n\n <!-- Artifact Share Modal -->\n <mj-artifact-share-modal\n [isOpen]=\"isArtifactShareModalOpen\"\n [artifact]=\"artifactToShare\"\n [currentUser]=\"currentUser\"\n (saved)=\"onArtifactShared()\"\n (cancelled)=\"onArtifactShareModalClose()\">\n </mj-artifact-share-modal>\n </div>\n</div>\n\n<!-- Thread Panel -->\n@if (conversationState.activeThreadId) {\n <mj-thread-panel\n [parentMessageId]=\"conversationState.activeThreadId\"\n [conversationId]=\"conversationState.activeConversation?.ID || ''\"\n [currentUser]=\"currentUser\"\n (closed)=\"onThreadClosed()\"\n (replyAdded)=\"onThreadReplyAdded($event)\">\n </mj-thread-panel>\n}\n\n<!-- Export Modal -->\n<mj-export-modal\n [isVisible]=\"showExportModal\"\n [conversation]=\"conversationState.activeConversation || undefined\"\n [currentUser]=\"currentUser\"\n (cancelled)=\"onExportModalCancelled()\"\n (exported)=\"onExportModalComplete()\">\n</mj-export-modal>\n\n<!-- Members Modal -->\n<mj-members-modal\n [isVisible]=\"showMembersModal\"\n [conversation]=\"conversationState.activeConversation || undefined\"\n [currentUser]=\"currentUser\"\n (cancelled)=\"showMembersModal = false\"\n (membersChanged)=\"showMembersModal = false\">\n</mj-members-modal>\n\n<!-- Project Selector Modal -->\n@if (showProjectSelector && conversationState.activeConversation) {\n <div class=\"modal-overlay\" (click)=\"showProjectSelector = false\">\n <div class=\"modal-content project-selector-modal\" (click)=\"$event.stopPropagation()\">\n <div class=\"modal-header\">\n <h3>Assign Project</h3>\n <button class=\"modal-close-btn\" (click)=\"showProjectSelector = false\">\n <i class=\"fas fa-times\"></i>\n </button>\n </div>\n <div class=\"modal-body\">\n <mj-project-selector\n [environmentId]=\"environmentId\"\n [currentUser]=\"currentUser\"\n [selectedProjectId]=\"conversationState.activeConversation.ProjectID\"\n (projectSelected)=\"onProjectSelected($event)\">\n </mj-project-selector>\n </div>\n </div>\n </div>\n}\n\n<!-- Artifacts Modal -->\n@if (showArtifactsModal) {\n <div class=\"modal-overlay\" (click)=\"showArtifactsModal = false\">\n <div class=\"modal-content artifacts-modal\" (click)=\"$event.stopPropagation()\">\n <div class=\"modal-header\">\n <h3>Conversation Artifacts</h3>\n <div class=\"modal-header-actions\">\n @if (hasSystemArtifacts) {\n <button class=\"toggle-system-btn\"\n [class.active]=\"showSystemArtifacts\"\n (click)=\"toggleSystemArtifacts()\"\n title=\"Toggle system artifacts visibility\">\n <i class=\"fas fa-cog\"></i>\n <span>{{ showSystemArtifacts ? 'Hide' : 'Show' }} System</span>\n </button>\n }\n <button class=\"modal-close-btn\" (click)=\"showArtifactsModal = false\">\n <i class=\"fas fa-times\"></i>\n </button>\n </div>\n </div>\n <div class=\"modal-body artifacts-grid\">\n @if (artifactsByDetailId.size === 0) {\n <div class=\"empty-state\">\n <i class=\"fas fa-cube\" style=\"font-size: 48px; color: #D1D5DB; margin-bottom: 16px;\"></i>\n <p style=\"color: #6B7280; font-size: 14px;\">No artifacts in this conversation yet</p>\n </div>\n }\n @for (artifact of getArtifactsArray(); track artifact.artifactId) {\n <div class=\"artifact-modal-card\"\n [class.expanded]=\"expandedArtifactId === artifact.artifactId\"\n [class.system-artifact]=\"artifact.visibility === 'System Only'\">\n <!-- Main card header - click to open latest version -->\n <div class=\"artifact-card-header\" (click)=\"openArtifactFromModal(artifact.artifactId)\">\n <div class=\"artifact-modal-icon\">\n <i class=\"fas fa-file-code\"></i>\n </div>\n <div class=\"artifact-modal-info\">\n <div class=\"artifact-modal-title\">{{artifact.name}}</div>\n <div class=\"artifact-modal-meta\">\n @if (artifact.versionCount > 1) {\n {{artifact.versionCount}} versions\n } @else {\n 1 version\n }\n </div>\n </div>\n @if (artifact.versionCount > 1) {\n <button class=\"expand-btn\" (click)=\"toggleArtifactExpansion(artifact.artifactId, $event)\">\n <i class=\"fas\" [class.fa-chevron-down]=\"expandedArtifactId !== artifact.artifactId\"\n [class.fa-chevron-up]=\"expandedArtifactId === artifact.artifactId\"></i>\n </button>\n }\n <div class=\"artifact-modal-action\">\n <i class=\"fas fa-external-link-alt\"></i>\n </div>\n </div>\n\n <!-- Expanded version list -->\n @if (expandedArtifactId === artifact.artifactId && artifact.versionCount > 1) {\n <div class=\"artifact-versions-list\">\n @for (version of artifact.versions; track version.versionId) {\n <div class=\"artifact-version-item\" (click)=\"openArtifactFromModal(artifact.artifactId, version.versionNumber); $event.stopPropagation()\">\n <span class=\"version-badge\">v{{version.versionNumber}}</span>\n <span class=\"version-open-text\">Open this version</span>\n <i class=\"fas fa-arrow-right\"></i>\n </div>\n }\n </div>\n }\n </div>\n }\n </div>\n </div>\n </div>\n}\n\n<!-- Collection Picker Modal -->\n@if (showCollectionPicker) {\n <mj-artifact-collection-picker-modal\n [isOpen]=\"showCollectionPicker\"\n [environmentId]=\"environmentId\"\n [currentUser]=\"currentUser\"\n [excludeCollectionIds]=\"collectionPickerExcludedIds\"\n (saved)=\"onCollectionPickerSaved($event)\"\n (cancelled)=\"onCollectionPickerCancelled()\">\n </mj-artifact-collection-picker-modal>\n}", styles: [":host {\n display: flex;\n width: 100%;\n height: 100%;\n}\n.chat-area {\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100%;\n overflow: hidden;\n}\n.chat-header {\n flex-shrink: 0;\n padding: 12px 20px;\n border-bottom: 1px solid #D9D9D9;\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: 16px;\n background: #FFF;\n z-index: 10;\n box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);\n}\n.chat-info {\n display: flex;\n align-items: center;\n gap: 12px;\n flex: 1;\n min-width: 0;\n}\n.chat-title {\n font-size: 16px;\n font-weight: 600;\n color: #333;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.project-tag {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 4px 10px;\n background: #F4F4F4;\n border: 1px solid #D9D9D9;\n border-radius: 16px;\n font-size: 11px;\n font-weight: 600;\n color: #AAA;\n cursor: pointer;\n transition: all 0.2s;\n height: 28px;\n margin-left: 12px;\n}\n.project-tag:hover {\n background: #D9D9D9;\n border-color: #AAA;\n}\n.project-tag i {\n font-size: 10px;\n}\n.chat-members {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 6px 12px;\n background: #F4F4F4;\n border: none;\n border-radius: 20px;\n font-size: 12px;\n font-weight: 500;\n color: #AAA;\n cursor: pointer;\n transition: all 0.2s;\n height: 32px;\n}\n.chat-members:hover {\n background: #D9D9D9;\n color: #333;\n}\n.chat-members i {\n font-size: 12px;\n}\n.chat-members span {\n font-size: 12px;\n font-weight: 500;\n}\n.artifact-indicator {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #3B82F6;\n border: none;\n border-radius: 6px;\n font-size: 13px;\n color: white;\n cursor: pointer;\n transition: all 150ms ease;\n}\n.artifact-indicator:hover {\n background: #2563EB;\n}\n.ambient-agent-indicator {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 6px 12px;\n background: #F3F4F6;\n border: 1px solid #D1D5DB;\n border-radius: 6px;\n font-size: 13px;\n color: #6B7280;\n animation: pulse 2s ease-in-out infinite;\n}\n.ambient-agent-indicator i {\n color: #0076B6;\n}\n@keyframes pulse {\n 0%, 100% { opacity: 1; }\n 50% { opacity: 0.7; }\n}\n.chat-actions {\n display: flex;\n gap: 8px;\n}\n.action-btn {\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 8px 12px;\n background: transparent;\n border: 1px solid #E5E7EB;\n cursor: pointer;\n border-radius: 6px;\n font-size: 13px;\n color: #6B7280;\n transition: all 150ms ease;\n}\n.action-btn:hover {\n background: #F9FAFB;\n color: #111827;\n}\n.share-btn.shared {\n background: #EFF6FF;\n border-color: #1e40af;\n color: #1e40af;\n}\n.share-btn.shared:hover {\n background: #DBEAFE;\n color: #1e3a8a;\n}\n.chat-content-area {\n flex: 1;\n min-height: 0;\n overflow: hidden;\n display: flex;\n flex-direction: row;\n position: relative;\n}\n.chat-messages-pane {\n height: 100%;\n display: flex;\n flex-direction: column;\n min-width: 300px;\n overflow: hidden;\n transition: width 0.3s ease;\n}\n.chat-messages-pane.full-width {\n width: 100%;\n}\n.chat-messages-pane:not(.full-width) {\n flex: 1;\n}\n.resize-handle {\n width: 4px;\n background: transparent;\n cursor: col-resize;\n flex-shrink: 0;\n position: relative;\n transition: background-color 0.2s;\n}\n.resize-handle:hover {\n background: #3B82F6;\n}\n.resize-handle::before {\n content: '';\n position: absolute;\n left: -4px;\n right: -4px;\n top: 0;\n bottom: 0;\n}\n.chat-artifact-pane {\n height: 100%;\n display: flex;\n flex-direction: column;\n background: #FAFAFA;\n overflow: hidden;\n flex-shrink: 0;\n}\n.chat-artifact-pane > mj-artifact-viewer-panel {\n display: flex;\n flex: 1;\n min-height: 0;\n overflow: hidden;\n}\n.chat-messages-wrapper {\n flex: 1;\n display: flex;\n flex-direction: column;\n min-height: 0;\n overflow: hidden;\n}\n.chat-messages-container {\n flex: 1;\n overflow-y: auto;\n overflow-x: hidden;\n background: #FFF;\n min-height: 0;\n position: relative;\n}\n.scroll-to-bottom-icon {\n position: sticky;\n bottom: 21px; // 21px from bottom of visible scroll area (moved up 5px from original 16px)\n left: 50%;\n transform: translateX(-50%);\n width: 40px;\n height: 40px;\n margin-top: -40px; // Negative margin to not affect scroll height\n margin-left: auto;\n margin-right: auto;\n background: white;\n border: 1px solid #D1D5DB;\n border-radius: 50%;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);\n transition: all 0.2s ease;\n z-index: 100;\n pointer-events: auto;\n}\n.scroll-to-bottom-icon:hover {\n background: #F3F4F6;\n border-color: #3B82F6;\n transform: translateX(-50%) translateY(-2px);\n box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);\n}\n.scroll-to-bottom-icon i {\n color: #6B7280;\n font-size: 16px;\n transition: color 0.2s;\n}\n.scroll-to-bottom-icon:hover i {\n color: #3B82F6;\n}\n.chat-input-container {\n flex-shrink: 0;\n background: #FFF;\n padding: 0 1.25rem 1.25rem 1.25rem; // Increased padding to prevent clipping rounded corners\n overflow: visible; // Allow box shadow and rounded corners to show fully\n}\n\n// Loading placeholder - replaces input while loading\n.loading-peripheral-placeholder {\n display: flex;\n align-items: center;\n justify-content: center;\n min-height: 140px; // Match typical input area height\n padding: 24px;\n background: rgba(255, 255, 255, 0.5);\n backdrop-filter: blur(2px);\n border-radius: 12px;\n margin: 12px;\n animation: fadeIn 0.2s ease-in-out;\n}\n.modal-overlay {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.5);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 1000;\n}\n.modal-content {\n background: white;\n border-radius: 8px;\n box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);\n max-width: 90vw;\n max-height: 90vh;\n display: flex;\n flex-direction: column;\n}\n.project-selector-modal {\n width: 600px;\n height: 500px;\n}\n.modal-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 16px 20px;\n border-bottom: 1px solid #E5E7EB;\n}\n.modal-header h3 {\n margin: 0;\n font-size: 18px;\n font-weight: 600;\n}\n.modal-header-actions {\n display: flex;\n align-items: center;\n gap: 8px;\n}\n.toggle-system-btn {\n display: flex;\n align-items: center;\n gap: 6px;\n background: #F3F4F6;\n border: 1px solid #E5E7EB;\n cursor: pointer;\n color: #6B7280;\n padding: 6px 12px;\n border-radius: 6px;\n font-size: 13px;\n font-weight: 500;\n transition: all 0.2s;\n}\n.toggle-system-btn:hover {\n background: #E5E7EB;\n border-color: #D1D5DB;\n color: #374151;\n}\n.toggle-system-btn.active {\n background: #3B82F6;\n border-color: #3B82F6;\n color: white;\n}\n.toggle-system-btn.active:hover {\n background: #2563EB;\n border-color: #2563EB;\n}\n.toggle-system-btn i {\n font-size: 12px;\n}\n.modal-close-btn {\n background: none;\n border: none;\n cursor: pointer;\n color: #6B7280;\n padding: 4px 8px;\n border-radius: 4px;\n transition: all 0.2s;\n}\n.modal-close-btn:hover {\n background: #F3F4F6;\n color: #111827;\n}\n.modal-body {\n flex: 1;\n overflow: auto;\n padding: 20px;\n}\n.artifacts-modal {\n width: 700px;\n max-height: 600px;\n}\n.artifacts-grid {\n display: grid;\n grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));\n gap: 16px;\n}\n.empty-state {\n grid-column: 1 / -1;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: 60px 20px;\n}\n.artifact-modal-card {\n display: flex;\n flex-direction: column;\n background: white;\n border: 1.5px solid #E5E7EB;\n border-radius: 12px;\n transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);\n overflow: hidden;\n}\n.artifact-modal-card.expanded {\n border-color: #3B82F6;\n}\n.artifact-modal-card.system-artifact {\n opacity: 0.85;\n border-color: #D1D5DB;\n border-style: dashed;\n position: relative;\n}\n.artifact-modal-card.system-artifact::before {\n content: 'SYSTEM';\n position: absolute;\n top: 8px;\n right: 8px;\n font-size: 9px;\n font-weight: 600;\n color: #9CA3AF;\n background: #F3F4F6;\n padding: 2px 6px;\n border-radius: 3px;\n letter-spacing: 0.5px;\n z-index: 10;\n}\n.artifact-modal-card.system-artifact:hover {\n border-color: #9CA3AF;\n box-shadow: 0 4px 12px rgba(156, 163, 175, 0.15);\n}\n.artifact-card-header {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px;\n cursor: pointer;\n}\n.artifact-card-header:hover {\n background: #F9FAFB;\n}\n.artifact-modal-card:hover {\n border-color: #3B82F6;\n box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);\n transform: translateY(-2px);\n}\n.artifact-modal-icon {\n width: 40px;\n height: 40px;\n display: flex;\n align-items: center;\n justify-content: center;\n background: linear-gradient(135deg, #EFF6FF 0%, #DBEAFE 100%);\n border-radius: 10px;\n color: #3B82F6;\n flex-shrink: 0;\n}\n.artifact-modal-icon i {\n font-size: 18px;\n}\n.artifact-modal-info {\n flex: 1;\n min-width: 0;\n}\n.artifact-modal-title {\n font-size: 14px;\n font-weight: 600;\n color: #1F2937;\n margin-bottom: 4px;\n}\n.artifact-modal-meta {\n font-size: 12px;\n color: #6B7280;\n}\n.artifact-modal-action {\n color: #9CA3AF;\n transition: color 0.2s;\n}\n.artifact-modal-card:hover .artifact-modal-action {\n color: #3B82F6;\n}\n.expand-btn {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 32px;\n height: 32px;\n border: none;\n background: transparent;\n color: #6B7280;\n cursor: pointer;\n border-radius: 6px;\n transition: all 0.2s;\n\n &:hover {\n background: #F3F4F6;\n color: #3B82F6;\n }\n}\n.artifact-versions-list {\n display: flex;\n flex-direction: column;\n padding: 0 1rem 1rem 1rem;\n background: #F9FAFB;\n}\n.artifact-version-item {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 12px 16px 12px 68px; // Indent to align with title\n cursor: pointer;\n transition: background 0.15s;\n\n &:hover {\n background: #F3F4F6;\n }\n\n .version-badge {\n display: inline-block;\n padding: 4px 8px;\n background: #EEF2FF;\n color: #4F46E5;\n font-size: 12px;\n font-weight: 600;\n font-family: monospace;\n border-radius: 4px;\n }\n\n .version-open-text {\n flex: 1;\n font-size: 13px;\n color: #6B7280;\n }\n\n i {\n color: #9CA3AF;\n font-size: 12px;\n }\n\n &:hover {\n .version-badge {\n background: #4F46E5;\n color: white;\n }\n .version-open-text {\n color: #3B82F6;\n }\n i {\n color: #3B82F6;\n }\n }\n}\n\n// Loading content styling\n.loading-peripheral-content {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px 24px;\n background: white;\n border: 2px solid #E5E7EB;\n border-radius: 12px;\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);\n color: #4B5563;\n font-size: 14px;\n font-weight: 500;\n\n i {\n font-size: 20px;\n color: #9333EA;\n }\n}\n\n@keyframes fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}\n// Loading conversation state - centered spinner\n.conversation-loading-state {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n width: 100%;\n}\n\n.loading-content {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding-top: 20px;\n gap: 16px;\n color: #6B7280;\n font-size: 15px;\n\n i {\n font-size: 32px;\n color: #3B82F6;\n }\n\n span {\n font-weight: 500;\n }\n}\n"] }]
|
|
1660
1776
|
}], () => [{ type: i1.ConversationStateService }, { type: i2.AgentStateService }, { type: i3.ConversationAgentService }, { type: i4.ActiveTasksService }, { type: i0.ChangeDetectorRef }, { type: i5.MentionAutocompleteService }, { type: i6.ArtifactPermissionService }], { environmentId: [{
|
|
1661
1777
|
type: Input
|
|
1662
1778
|
}], currentUser: [{
|