@memberjunction/ng-chat 5.21.0 → 5.22.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.
@@ -10,8 +10,14 @@ export declare class ChatMessage {
10
10
  message: string;
11
11
  senderName: string;
12
12
  senderType: 'user' | 'ai';
13
- id?: any;
14
- constructor(message: string, senderName: string, senderType: 'user' | 'ai', id?: any);
13
+ id?: string | number | null;
14
+ /** Optional: indicates a tool execution is in progress */
15
+ toolName?: string;
16
+ /** Optional: indicates a thinking/processing state */
17
+ isThinking?: boolean;
18
+ /** Timestamp when the message was created */
19
+ timestamp: Date;
20
+ constructor(message: string, senderName: string, senderType: 'user' | 'ai', id?: string | number | null);
15
21
  }
16
22
  export declare class ChatComponent implements AfterViewInit {
17
23
  private markdownService;
@@ -1 +1 @@
1
- {"version":3,"file":"chat.component.d.ts","sourceRoot":"","sources":["../../../src/lib/chat/chat.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAa,UAAU,EAAE,YAAY,EAA4B,MAAM,eAAe,CAAC;AAChI,OAAO,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAC;;AAI9D,qBAAa,mBAAmB;IACvB,OAAO,EAAE,MAAM,CAAI;IACnB,UAAU,EAAE,MAAM,CAAI;IACtB,MAAM,EAAE,MAAM,CAAI;CAC1B;AACD,qBAAa,WAAW;IACf,OAAO,EAAG,MAAM,CAAC;IACjB,UAAU,EAAG,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,GAAG,IAAI,CAAU;IACnC,EAAE,CAAC,EAAE,GAAG,CAAC;gBAEJ,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,IAAI,EAAE,EAAE,GAAE,GAAU;CAM3F;AAED,qBAMa,aAAc,YAAW,aAAa;IAuDrC,OAAO,CAAC,eAAe;IAAmB,OAAO,CAAC,EAAE;IAtDvD,cAAc,EAAE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AAS,EAAE,OAAO,CAAQ;IAC5B,iBAAiB,EAAE,OAAO,CAAQ;IACzC;;OAEG;IACa,WAAW,EAAE,MAAM,CAAuB;IAE1D,OAAO,CAAC,qBAAqB,CAAkB;IAC/C,IAAoB,oBAAoB,IAAI,OAAO,CAElD;IACD,IAAW,oBAAoB,CAAC,KAAK,EAAE,OAAO,EAM7C;IAED,eAAe,IAAI,IAAI;IAIb,YAAY,4BAAmC;IAC/C,kBAAkB,qBAA4B;IAEN,OAAO,CAAC,iBAAiB,CAAc;IAClE,QAAQ,EAAE,UAAU,GAAG,SAAS,CAAC;IAEjD,cAAc,EAAE,MAAM,CAAM;IAC5B,qBAAqB,EAAE,OAAO,CAAS;gBAC1B,eAAe,EAAE,eAAe,EAAU,EAAE,EAAE,iBAAiB;IAE5E,kBAAkB,IAAI,IAAI;IAO1B,iBAAiB,CAAC,KAAK,EAAE,GAAG;IAMnC,SAAS,CAAC,eAAe;IAclB,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,IAAI,EAAE,EAAE,EAAE,GAAG,EAAE,SAAS,GAAE,OAAc,GAAG,IAAI;IAKrH,eAAe,CAAC,OAAO,EAAE,MAAM;IAI/B,eAAe;IAIf,gBAAgB;IAYvB,SAAS,CAAC,aAAa;cAIP,aAAa,CAAC,OAAO,EAAE,WAAW,EAAE,SAAS,GAAE,OAAc;IA0C7E,SAAS,CAAC,sBAAsB,CAAC,OAAO,GAAE,OAAc,GAAG,IAAI;IAgBxD,wBAAwB,EAAE,OAAO,CAAS;IAEjD,iBAAiB,IAAI,IAAI;yCA7Kd,aAAa;2CAAb,aAAa;CAqLzB"}
@@ -3,22 +3,19 @@ import { LogError } from '@memberjunction/core';
3
3
  import * as i0 from "@angular/core";
4
4
  import * as i1 from "@memberjunction/ng-markdown";
5
5
  import * as i2 from "@angular/forms";
6
- import * as i3 from "@memberjunction/ng-shared-generic";
7
- import * as i4 from "@progress/kendo-angular-buttons";
8
- import * as i5 from "@progress/kendo-angular-dialog";
9
6
  const _c0 = ["messagesContainer"];
10
7
  const _c1 = ["theInput"];
11
8
  function ChatComponent_Conditional_1_Conditional_2_Template(rf, ctx) { if (rf & 1) {
12
- i0.ɵɵelement(0, "img", 14);
9
+ i0.ɵɵelement(0, "img", 16);
13
10
  } if (rf & 2) {
14
11
  const ctx_r1 = i0.ɵɵnextContext(2);
15
12
  i0.ɵɵproperty("src", ctx_r1.AILargeImageURL, i0.ɵɵsanitizeUrl);
16
13
  } }
17
14
  function ChatComponent_Conditional_1_Conditional_7_Template(rf, ctx) { if (rf & 1) {
18
15
  const _r3 = i0.ɵɵgetCurrentView();
19
- i0.ɵɵelementStart(0, "div", 19);
16
+ i0.ɵɵelementStart(0, "div", 21);
20
17
  i0.ɵɵlistener("click", function ChatComponent_Conditional_1_Conditional_7_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.SendUserMessage(ctx_r1.WelcomeQuestions[0].prompt)); });
21
- i0.ɵɵelementStart(1, "span", 20);
18
+ i0.ɵɵelementStart(1, "span", 22);
22
19
  i0.ɵɵtext(2);
23
20
  i0.ɵɵelementEnd();
24
21
  i0.ɵɵelementStart(3, "span");
@@ -33,9 +30,9 @@ function ChatComponent_Conditional_1_Conditional_7_Template(rf, ctx) { if (rf &
33
30
  } }
34
31
  function ChatComponent_Conditional_1_Conditional_8_Template(rf, ctx) { if (rf & 1) {
35
32
  const _r4 = i0.ɵɵgetCurrentView();
36
- i0.ɵɵelementStart(0, "div", 19);
33
+ i0.ɵɵelementStart(0, "div", 21);
37
34
  i0.ɵɵlistener("click", function ChatComponent_Conditional_1_Conditional_8_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.SendUserMessage(ctx_r1.WelcomeQuestions[1].prompt)); });
38
- i0.ɵɵelementStart(1, "span", 20);
35
+ i0.ɵɵelementStart(1, "span", 22);
39
36
  i0.ɵɵtext(2);
40
37
  i0.ɵɵelementEnd();
41
38
  i0.ɵɵelementStart(3, "span");
@@ -50,9 +47,9 @@ function ChatComponent_Conditional_1_Conditional_8_Template(rf, ctx) { if (rf &
50
47
  } }
51
48
  function ChatComponent_Conditional_1_Conditional_10_Template(rf, ctx) { if (rf & 1) {
52
49
  const _r5 = i0.ɵɵgetCurrentView();
53
- i0.ɵɵelementStart(0, "div", 19);
50
+ i0.ɵɵelementStart(0, "div", 21);
54
51
  i0.ɵɵlistener("click", function ChatComponent_Conditional_1_Conditional_10_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r5); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.SendUserMessage(ctx_r1.WelcomeQuestions[2].prompt)); });
55
- i0.ɵɵelementStart(1, "span", 20);
52
+ i0.ɵɵelementStart(1, "span", 22);
56
53
  i0.ɵɵtext(2);
57
54
  i0.ɵɵelementEnd();
58
55
  i0.ɵɵelementStart(3, "span");
@@ -67,9 +64,9 @@ function ChatComponent_Conditional_1_Conditional_10_Template(rf, ctx) { if (rf &
67
64
  } }
68
65
  function ChatComponent_Conditional_1_Conditional_11_Template(rf, ctx) { if (rf & 1) {
69
66
  const _r6 = i0.ɵɵgetCurrentView();
70
- i0.ɵɵelementStart(0, "div", 19);
67
+ i0.ɵɵelementStart(0, "div", 21);
71
68
  i0.ɵɵlistener("click", function ChatComponent_Conditional_1_Conditional_11_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r6); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.SendUserMessage(ctx_r1.WelcomeQuestions[3].prompt)); });
72
- i0.ɵɵelementStart(1, "span", 20);
69
+ i0.ɵɵelementStart(1, "span", 22);
73
70
  i0.ɵɵtext(2);
74
71
  i0.ɵɵelementEnd();
75
72
  i0.ɵɵelementStart(3, "span");
@@ -83,18 +80,18 @@ function ChatComponent_Conditional_1_Conditional_11_Template(rf, ctx) { if (rf &
83
80
  i0.ɵɵtextInterpolate(ctx_r1.WelcomeQuestions[3].bottomLine);
84
81
  } }
85
82
  function ChatComponent_Conditional_1_Template(rf, ctx) { if (rf & 1) {
86
- i0.ɵɵelementStart(0, "div", 3)(1, "div", 13);
87
- i0.ɵɵconditionalCreate(2, ChatComponent_Conditional_1_Conditional_2_Template, 1, 1, "img", 14);
88
- i0.ɵɵelementStart(3, "div", 15);
83
+ i0.ɵɵelementStart(0, "div", 3)(1, "div", 15);
84
+ i0.ɵɵconditionalCreate(2, ChatComponent_Conditional_1_Conditional_2_Template, 1, 1, "img", 16);
85
+ i0.ɵɵelementStart(3, "div", 17);
89
86
  i0.ɵɵtext(4, "What can I help with today?");
90
87
  i0.ɵɵelementEnd()();
91
- i0.ɵɵelementStart(5, "div", 16)(6, "div", 17);
92
- i0.ɵɵconditionalCreate(7, ChatComponent_Conditional_1_Conditional_7_Template, 5, 2, "div", 18);
93
- i0.ɵɵconditionalCreate(8, ChatComponent_Conditional_1_Conditional_8_Template, 5, 2, "div", 18);
88
+ i0.ɵɵelementStart(5, "div", 18)(6, "div", 19);
89
+ i0.ɵɵconditionalCreate(7, ChatComponent_Conditional_1_Conditional_7_Template, 5, 2, "div", 20);
90
+ i0.ɵɵconditionalCreate(8, ChatComponent_Conditional_1_Conditional_8_Template, 5, 2, "div", 20);
94
91
  i0.ɵɵelementEnd();
95
- i0.ɵɵelementStart(9, "div", 17);
96
- i0.ɵɵconditionalCreate(10, ChatComponent_Conditional_1_Conditional_10_Template, 5, 2, "div", 18);
97
- i0.ɵɵconditionalCreate(11, ChatComponent_Conditional_1_Conditional_11_Template, 5, 2, "div", 18);
92
+ i0.ɵɵelementStart(9, "div", 19);
93
+ i0.ɵɵconditionalCreate(10, ChatComponent_Conditional_1_Conditional_10_Template, 5, 2, "div", 20);
94
+ i0.ɵɵconditionalCreate(11, ChatComponent_Conditional_1_Conditional_11_Template, 5, 2, "div", 20);
98
95
  i0.ɵɵelementEnd()()();
99
96
  } if (rf & 2) {
100
97
  const ctx_r1 = i0.ɵɵnextContext();
@@ -111,31 +108,37 @@ function ChatComponent_Conditional_1_Template(rf, ctx) { if (rf & 1) {
111
108
  } }
112
109
  function ChatComponent_Conditional_6_Template(rf, ctx) { if (rf & 1) {
113
110
  const _r7 = i0.ɵɵgetCurrentView();
114
- i0.ɵɵelementStart(0, "span", 21);
111
+ i0.ɵɵelementStart(0, "span", 23);
115
112
  i0.ɵɵlistener("click", function ChatComponent_Conditional_6_Template_span_click_0_listener() { i0.ɵɵrestoreView(_r7); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.ScrollMessagesToBottom()); });
116
113
  i0.ɵɵelementEnd();
117
114
  } }
118
- function ChatComponent_Conditional_8_Template(rf, ctx) { if (rf & 1) {
119
- i0.ɵɵelement(0, "mj-loading", 7);
120
- } if (rf & 2) {
121
- i0.ɵɵproperty("showText", false);
115
+ function ChatComponent_Conditional_7_Template(rf, ctx) { if (rf & 1) {
116
+ i0.ɵɵelementStart(0, "div", 6);
117
+ i0.ɵɵelement(1, "div", 24)(2, "div", 24)(3, "div", 24);
118
+ i0.ɵɵelementStart(4, "span", 25);
119
+ i0.ɵɵtext(5, "Thinking...");
120
+ i0.ɵɵelementEnd()();
122
121
  } }
123
122
  function ChatComponent_Conditional_17_Template(rf, ctx) { if (rf & 1) {
124
123
  const _r8 = i0.ɵɵgetCurrentView();
125
- i0.ɵɵelementStart(0, "kendo-dialog")(1, "p");
126
- i0.ɵɵtext(2);
124
+ i0.ɵɵelementStart(0, "div", 26);
125
+ i0.ɵɵlistener("click", function ChatComponent_Conditional_17_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.showingClearAllDialog = false); });
126
+ i0.ɵɵelementStart(1, "div", 27);
127
+ i0.ɵɵlistener("click", function ChatComponent_Conditional_17_Template_div_click_1_listener($event) { i0.ɵɵrestoreView(_r8); return i0.ɵɵresetView($event.stopPropagation()); });
128
+ i0.ɵɵelementStart(2, "p", 28);
129
+ i0.ɵɵtext(3);
127
130
  i0.ɵɵelementEnd();
128
- i0.ɵɵelementStart(3, "kendo-dialog-actions")(4, "button", 22);
129
- i0.ɵɵlistener("click", function ChatComponent_Conditional_17_Template_button_click_4_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.HandleClearChat()); });
130
- i0.ɵɵtext(5, "Yes");
131
+ i0.ɵɵelementStart(4, "div", 29)(5, "button", 30);
132
+ i0.ɵɵlistener("click", function ChatComponent_Conditional_17_Template_button_click_5_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.HandleClearChat()); });
133
+ i0.ɵɵtext(6, "Yes");
131
134
  i0.ɵɵelementEnd();
132
- i0.ɵɵelementStart(6, "button", 23);
133
- i0.ɵɵlistener("click", function ChatComponent_Conditional_17_Template_button_click_6_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.showingClearAllDialog = false); });
134
- i0.ɵɵtext(7, "No");
135
- i0.ɵɵelementEnd()()();
135
+ i0.ɵɵelementStart(7, "button", 31);
136
+ i0.ɵɵlistener("click", function ChatComponent_Conditional_17_Template_button_click_7_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.showingClearAllDialog = false); });
137
+ i0.ɵɵtext(8, "No");
138
+ i0.ɵɵelementEnd()()()();
136
139
  } if (rf & 2) {
137
140
  const ctx_r1 = i0.ɵɵnextContext();
138
- i0.ɵɵadvance(2);
141
+ i0.ɵɵadvance(3);
139
142
  i0.ɵɵtextInterpolate(ctx_r1.ClearAllMessagesPrompt);
140
143
  } }
141
144
  export class ChatWelcomeQuestion {
@@ -148,11 +151,18 @@ export class ChatMessage {
148
151
  senderName;
149
152
  senderType = 'user';
150
153
  id;
154
+ /** Optional: indicates a tool execution is in progress */
155
+ toolName;
156
+ /** Optional: indicates a thinking/processing state */
157
+ isThinking;
158
+ /** Timestamp when the message was created */
159
+ timestamp = new Date();
151
160
  constructor(message, senderName, senderType, id = null) {
152
161
  this.message = message;
153
162
  this.senderName = senderName;
154
163
  this.senderType = senderType;
155
164
  this.id = id;
165
+ this.timestamp = new Date();
156
166
  }
157
167
  }
158
168
  export class ChatComponent {
@@ -321,7 +331,7 @@ export class ChatComponent {
321
331
  let _t;
322
332
  i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.messagesContainer = _t.first);
323
333
  i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.theInput = _t.first);
324
- } }, inputs: { InitialMessage: "InitialMessage", Messages: "Messages", AIImageURL: "AIImageURL", AILargeImageURL: "AILargeImageURL", WelcomeQuestions: "WelcomeQuestions", ClearAllMessagesPrompt: "ClearAllMessagesPrompt", AllowSend: "AllowSend", Placeholder: "Placeholder", ShowWaitingIndicator: "ShowWaitingIndicator" }, outputs: { MessageAdded: "MessageAdded", ClearChatRequested: "ClearChatRequested" }, standalone: false, decls: 18, vars: 10, consts: [["messagesContainer", ""], ["theInput", ""], [1, "chat-wrapper"], [1, "welcome-wrapper"], [1, "chat-messages", 3, "scroll"], [1, "scroll-to-bottom", "fas", "fa-arrow-down"], [1, "chat-input-area"], ["size", "small", 1, "loader", 3, "showText"], [1, "text-area-wrapper"], [3, "ngModelChange", "input", "keyup.enter", "ngModel", "disabled", "placeholder"], ["kendoButton", "", 3, "click", "disabled"], ["title", "Clear Chat", 1, "fa-solid", "fa-trash-can"], ["title", "Send Message", 1, "fas", "fa-solid", "fa-arrow-up"], [1, "welcome-message"], [3, "src"], [1, "welcome-header-text"], [1, "welcome-suggested-questions"], [1, "welcome-suggested-questions-col"], [1, "welcome-question"], [1, "welcome-question", 3, "click"], [1, "welcome-question-header"], [1, "scroll-to-bottom", "fas", "fa-arrow-down", 3, "click"], ["kendoButton", "", "themeColor", "primary", 3, "click"], ["kendoButton", "", 3, "click"]], template: function ChatComponent_Template(rf, ctx) { if (rf & 1) {
334
+ } }, inputs: { InitialMessage: "InitialMessage", Messages: "Messages", AIImageURL: "AIImageURL", AILargeImageURL: "AILargeImageURL", WelcomeQuestions: "WelcomeQuestions", ClearAllMessagesPrompt: "ClearAllMessagesPrompt", AllowSend: "AllowSend", Placeholder: "Placeholder", ShowWaitingIndicator: "ShowWaitingIndicator" }, outputs: { MessageAdded: "MessageAdded", ClearChatRequested: "ClearChatRequested" }, standalone: false, decls: 18, vars: 10, consts: [["messagesContainer", ""], ["theInput", ""], [1, "chat-wrapper"], [1, "welcome-wrapper"], [1, "chat-messages", 3, "scroll"], [1, "scroll-to-bottom", "fas", "fa-arrow-down"], [1, "typing-indicator"], [1, "chat-input-area"], [1, "text-area-wrapper"], [3, "ngModelChange", "input", "keyup.enter", "ngModel", "disabled", "placeholder"], ["title", "Clear Chat", 1, "chat-action-btn", 3, "click", "disabled"], [1, "fa-solid", "fa-trash-can"], ["title", "Send Message", 1, "chat-action-btn", "chat-send-btn", 3, "click", "disabled"], [1, "fa-solid", "fa-arrow-up"], [1, "chat-dialog-overlay"], [1, "welcome-message"], [3, "src"], [1, "welcome-header-text"], [1, "welcome-suggested-questions"], [1, "welcome-suggested-questions-col"], [1, "welcome-question"], [1, "welcome-question", 3, "click"], [1, "welcome-question-header"], [1, "scroll-to-bottom", "fas", "fa-arrow-down", 3, "click"], [1, "typing-dot"], [1, "typing-text"], [1, "chat-dialog-overlay", 3, "click"], [1, "chat-dialog", 3, "click"], [1, "chat-dialog-message"], [1, "chat-dialog-actions"], [1, "chat-dialog-btn", "chat-dialog-btn-primary", 3, "click"], [1, "chat-dialog-btn", 3, "click"]], template: function ChatComponent_Template(rf, ctx) { if (rf & 1) {
325
335
  const _r1 = i0.ɵɵgetCurrentView();
326
336
  i0.ɵɵelementStart(0, "div", 2);
327
337
  i0.ɵɵconditionalCreate(1, ChatComponent_Conditional_1_Template, 12, 5, "div", 3);
@@ -331,22 +341,21 @@ export class ChatComponent {
331
341
  i0.ɵɵtext(5);
332
342
  i0.ɵɵelementEnd()();
333
343
  i0.ɵɵconditionalCreate(6, ChatComponent_Conditional_6_Template, 1, 0, "span", 5);
334
- i0.ɵɵelementStart(7, "div", 6);
335
- i0.ɵɵconditionalCreate(8, ChatComponent_Conditional_8_Template, 1, 1, "mj-loading", 7);
336
- i0.ɵɵelementStart(9, "div", 8)(10, "textarea", 9, 1);
344
+ i0.ɵɵconditionalCreate(7, ChatComponent_Conditional_7_Template, 6, 0, "div", 6);
345
+ i0.ɵɵelementStart(8, "div", 7)(9, "div", 8)(10, "textarea", 9, 1);
337
346
  i0.ɵɵtwoWayListener("ngModelChange", function ChatComponent_Template_textarea_ngModelChange_10_listener($event) { i0.ɵɵrestoreView(_r1); i0.ɵɵtwoWayBindingSet(ctx.currentMessage, $event) || (ctx.currentMessage = $event); return i0.ɵɵresetView($event); });
338
347
  i0.ɵɵlistener("input", function ChatComponent_Template_textarea_input_10_listener($event) { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.handleInputChange($event)); })("keyup.enter", function ChatComponent_Template_textarea_keyup_enter_10_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.SendCurrentMessage()); });
339
348
  i0.ɵɵtext(12, " ");
340
349
  i0.ɵɵelementEnd()();
341
350
  i0.ɵɵelementStart(13, "button", 10);
342
351
  i0.ɵɵlistener("click", function ChatComponent_Template_button_click_13_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.showingClearAllDialog = true); });
343
- i0.ɵɵelement(14, "span", 11);
352
+ i0.ɵɵelement(14, "i", 11);
344
353
  i0.ɵɵelementEnd();
345
- i0.ɵɵelementStart(15, "button", 10);
354
+ i0.ɵɵelementStart(15, "button", 12);
346
355
  i0.ɵɵlistener("click", function ChatComponent_Template_button_click_15_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.SendCurrentMessage()); });
347
- i0.ɵɵelement(16, "span", 12);
356
+ i0.ɵɵelement(16, "i", 13);
348
357
  i0.ɵɵelementEnd()()();
349
- i0.ɵɵconditionalCreate(17, ChatComponent_Conditional_17_Template, 8, 1, "kendo-dialog");
358
+ i0.ɵɵconditionalCreate(17, ChatComponent_Conditional_17_Template, 9, 1, "div", 14);
350
359
  } if (rf & 2) {
351
360
  i0.ɵɵadvance();
352
361
  i0.ɵɵconditional(ctx.Messages.length === 0 && !ctx.ShowWaitingIndicator ? 1 : -1);
@@ -354,9 +363,9 @@ export class ChatComponent {
354
363
  i0.ɵɵtextInterpolate(ctx.InitialMessage);
355
364
  i0.ɵɵadvance();
356
365
  i0.ɵɵconditional(ctx.ShowScrollToBottomButton ? 6 : -1);
357
- i0.ɵɵadvance(2);
358
- i0.ɵɵconditional(ctx.ShowWaitingIndicator ? 8 : -1);
359
- i0.ɵɵadvance(2);
366
+ i0.ɵɵadvance();
367
+ i0.ɵɵconditional(ctx.ShowWaitingIndicator ? 7 : -1);
368
+ i0.ɵɵadvance(3);
360
369
  i0.ɵɵtwoWayProperty("ngModel", ctx.currentMessage);
361
370
  i0.ɵɵproperty("disabled", ctx.ShowWaitingIndicator)("placeholder", ctx.Placeholder);
362
371
  i0.ɵɵadvance(3);
@@ -365,11 +374,11 @@ export class ChatComponent {
365
374
  i0.ɵɵproperty("disabled", !ctx.InternalAllowSend || ctx.currentMessage.length === 0 || ctx.ShowWaitingIndicator);
366
375
  i0.ɵɵadvance(2);
367
376
  i0.ɵɵconditional(ctx.showingClearAllDialog ? 17 : -1);
368
- } }, dependencies: [i2.DefaultValueAccessor, i2.NgControlStatus, i2.NgModel, i3.LoadingComponent, i4.ButtonComponent, i5.DialogComponent, i5.DialogActionsComponent], styles: [".loader[_ngcontent-%COMP%] {\n position: absolute;\n left: 0px;\n}\n\n.chat-wrapper[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n position: relative; \n\n}\n\n.chat-messages[_ngcontent-%COMP%] {\n overflow-y: auto; \n\n overflow-x: hidden; \n\n \n\n margin-bottom: 5px;\n\n margin-top: 2px; \n\n\n flex: 1;\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]::-webkit-scrollbar {\n width: 0;\n background: transparent; \n\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]:hover::-webkit-scrollbar {\n width: 12px; \n\n background-color: var(--mj-bg-surface-sunken); \n\n\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]:hover::-webkit-scrollbar-thumb {\n background-color: var(--mj-text-muted); \n\n opacity: 0.5; \n\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]:hover::-webkit-scrollbar-thumb {\n border-radius: 10px;\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]:hover::-webkit-scrollbar-thumb:hover {\n background: var(--mj-text-secondary); \n\n}\n\n\n.chat-messages[_ngcontent-%COMP%] {\n scrollbar-width: thin; \n\n scrollbar-color: var(--mj-text-muted) var(--mj-bg-surface-sunken); \n\n}\n \n\n\n\n.chat-input-area[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n display: flex;\n justify-content: center;\n align-items: center;\n padding-top: 12px;\n min-height: 35px;\n margin-bottom: 15px;\n}\n.chat-input-area[_ngcontent-%COMP%] > button[_ngcontent-%COMP%] {\n vertical-align: top;\n width: 30px;\n height: 30px;\n margin-top: 3px;\n border-radius: 12px;\n}\n.chat-input-area[_ngcontent-%COMP%] > button[_ngcontent-%COMP%]:first-of-type {\n margin-left: -40px;\n}\n.chat-input-area[_ngcontent-%COMP%] > button[_ngcontent-%COMP%]:last-child {\n margin-left: -65px;\n}\n\n.text-area-wrapper[_ngcontent-%COMP%] {\n padding: 3px;\n border: solid 1px color-mix(in srgb, var(--mj-text-primary) 8%, transparent);\n border-radius: 15px;\n\n margin-top: 4px;\n margin-right: -1px;\n min-height: 42px;\n max-height: 100%; \n\n\n overflow: hidden; \n align-items: center;\n\n \n\n max-width: 710px; \n width: 75%; \n\n padding-right: 90px; \n\n} \n.text-area-wrapper[_ngcontent-%COMP%] > textarea[_ngcontent-%COMP%] {\n border: 0;\n outline: 0;\n resize: none;\n\n min-height: 20px; \n\n\n width: 100%;\n overflow-y: hidden; \n\n\n font-family: S\u00F6hne, ui-sans-serif, system-ui, -apple-system, \"Segoe UI\", Roboto, Ubuntu, Cantarell, \"Noto Sans\", sans-serif, \"Helvetica Neue\", Arial, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";\n font-size: 1rem;\n\n margin-left: 7px;\n margin-top: 7px;\n margin-bottom: 5px;\n}\n\n.text-area-wrapper[_ngcontent-%COMP%] > textarea[_ngcontent-%COMP%]:disabled {\n background-color: var(--mj-bg-surface-card);\n}\n\n\n .chat-message-wrap {\n display: flex;\n align-items: flex-start; \n\n margin-bottom: 10px;\n margin-right: 10px;\n}\n\n .chat-message-image {\n margin-top: 12px;\n font-size: 24px; \n\n margin-right: 10px; \n\n width: 50px;\n flex-shrink: 0; \n \n}\n\n\n\n .chat-message {\n padding-left: 7px;\n padding-right: 7px;\n margin-bottom: 10px;\n border-radius: 5px;\n background-color: var(--mj-bg-surface-sunken);\n box-shadow: var(--mj-shadow-sm);\n word-wrap: break-word;\n}\n\n .chat-message-ai {\n background-color: color-mix(in srgb, var(--mj-brand-primary) 5%, var(--mj-bg-surface));\n}\n\n.scroll-to-bottom[_ngcontent-%COMP%] {\n position: absolute; \n\n left: 50%; \n\n transform: translateX(-50%); \n\n bottom: 100px; \n\n z-index: 1000; \n\n border-radius: 50%;\n width: 35px;\n height: 35px;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 22px;\n background-color: var(--mj-bg-surface-sunken);\n box-shadow: var(--mj-shadow-md); \n\n cursor: pointer;\n}\n\n\n\n\n\n.welcome-wrapper[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 100%;\n width: 100%;\n overflow: hidden;\n}\n\n.welcome-message[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n text-align: center;\n overflow: hidden;\n height: 100%;\n}\n\n\n.welcome-message[_ngcontent-%COMP%] img[_ngcontent-%COMP%] {\n width: 120px;\n height: 50px;\n margin-bottom: 20px; \n\n}\n\n.welcome-header-text[_ngcontent-%COMP%] {\n font-size: larger;\n font-weight: bold;\n}\n\n\n\n.welcome-suggested-questions[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-content: center;\n}\n.welcome-suggested-questions-col[_ngcontent-%COMP%] {\n display: flex;\n}\n\n\n\n.welcome-question[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column; \n\n align-items: left;;\n width: 300px; \n justify-content: space-between;\n margin: 5px; \n\n border: solid 1px color-mix(in srgb, var(--mj-text-primary) 8%, transparent);\n border-radius: 15px;\n padding: 10px;\n cursor: pointer;\n}\n\n.welcome-question[_ngcontent-%COMP%]:hover {\n background-color: color-mix(in srgb, var(--mj-text-primary) 5%, transparent);\n}\n\n\n.welcome-question-header[_ngcontent-%COMP%] {\n font-size: 12pt;\n font-weight: bold;\n display: block; \n\n}\n\n\n\n.welcome-question[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:not(.welcome-question-header) {\n font-weight: normal;\n font-size: 10pt;\n}"] });
377
+ } }, dependencies: [i2.DefaultValueAccessor, i2.NgControlStatus, i2.NgModel], styles: [".loader[_ngcontent-%COMP%] {\n position: absolute;\n left: 0px;\n}\n\n.chat-wrapper[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n position: relative; \n\n}\n\n.chat-messages[_ngcontent-%COMP%] {\n overflow-y: auto; \n\n overflow-x: hidden; \n\n \n\n margin-bottom: 5px;\n\n margin-top: 2px; \n\n\n flex: 1;\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]::-webkit-scrollbar {\n width: 0;\n background: transparent; \n\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]:hover::-webkit-scrollbar {\n width: 12px; \n\n background-color: var(--mj-bg-surface-sunken); \n\n\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]:hover::-webkit-scrollbar-thumb {\n background-color: var(--mj-text-muted); \n\n opacity: 0.5; \n\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]:hover::-webkit-scrollbar-thumb {\n border-radius: 10px;\n}\n\n\n\n.chat-messages[_ngcontent-%COMP%]:hover::-webkit-scrollbar-thumb:hover {\n background: var(--mj-text-secondary); \n\n}\n\n\n.chat-messages[_ngcontent-%COMP%] {\n scrollbar-width: thin; \n\n scrollbar-color: var(--mj-text-muted) var(--mj-bg-surface-sunken); \n\n}\n \n\n\n\n.chat-input-area[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n display: flex;\n justify-content: center;\n align-items: center;\n padding-top: 12px;\n min-height: 35px;\n margin-bottom: 15px;\n}\n.chat-input-area[_ngcontent-%COMP%] > button[_ngcontent-%COMP%] {\n vertical-align: top;\n width: 30px;\n height: 30px;\n margin-top: 3px;\n border-radius: 12px;\n}\n.chat-input-area[_ngcontent-%COMP%] > button[_ngcontent-%COMP%]:first-of-type {\n margin-left: -40px;\n}\n.chat-input-area[_ngcontent-%COMP%] > button[_ngcontent-%COMP%]:last-child {\n margin-left: -65px;\n}\n\n.text-area-wrapper[_ngcontent-%COMP%] {\n padding: 3px;\n border: solid 1px color-mix(in srgb, var(--mj-text-primary) 8%, transparent);\n border-radius: 15px;\n\n margin-top: 4px;\n margin-right: -1px;\n min-height: 42px;\n max-height: 100%; \n\n\n overflow: hidden; \n align-items: center;\n\n \n\n max-width: 710px; \n width: 75%; \n\n padding-right: 90px; \n\n} \n.text-area-wrapper[_ngcontent-%COMP%] > textarea[_ngcontent-%COMP%] {\n border: 0;\n outline: 0;\n resize: none;\n\n min-height: 20px; \n\n\n width: 100%;\n overflow-y: hidden; \n\n\n font-family: S\u00F6hne, ui-sans-serif, system-ui, -apple-system, \"Segoe UI\", Roboto, Ubuntu, Cantarell, \"Noto Sans\", sans-serif, \"Helvetica Neue\", Arial, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";\n font-size: 1rem;\n\n margin-left: 7px;\n margin-top: 7px;\n margin-bottom: 5px;\n}\n\n.text-area-wrapper[_ngcontent-%COMP%] > textarea[_ngcontent-%COMP%]:disabled {\n background-color: var(--mj-bg-surface-card);\n}\n\n\n .chat-message-wrap {\n display: flex;\n align-items: flex-start; \n\n margin-bottom: 10px;\n margin-right: 10px;\n}\n\n .chat-message-image {\n margin-top: 12px;\n font-size: 24px; \n\n margin-right: 10px; \n\n width: 50px;\n flex-shrink: 0; \n \n}\n\n\n\n .chat-message {\n padding-left: 7px;\n padding-right: 7px;\n margin-bottom: 10px;\n border-radius: 5px;\n background-color: var(--mj-bg-surface-sunken);\n box-shadow: var(--mj-shadow-sm);\n word-wrap: break-word;\n}\n\n .chat-message-ai {\n background-color: color-mix(in srgb, var(--mj-brand-primary) 5%, var(--mj-bg-surface));\n}\n\n.scroll-to-bottom[_ngcontent-%COMP%] {\n position: absolute; \n\n left: 50%; \n\n transform: translateX(-50%); \n\n bottom: 100px; \n\n z-index: 1000; \n\n border-radius: 50%;\n width: 35px;\n height: 35px;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 22px;\n background-color: var(--mj-bg-surface-sunken);\n box-shadow: var(--mj-shadow-md); \n\n cursor: pointer;\n}\n\n\n\n\n\n.welcome-wrapper[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 100%;\n width: 100%;\n overflow: hidden;\n}\n\n.welcome-message[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n text-align: center;\n overflow: hidden;\n height: 100%;\n}\n\n\n.welcome-message[_ngcontent-%COMP%] img[_ngcontent-%COMP%] {\n width: 120px;\n height: 50px;\n margin-bottom: 20px; \n\n}\n\n.welcome-header-text[_ngcontent-%COMP%] {\n font-size: larger;\n font-weight: bold;\n}\n\n\n\n.welcome-suggested-questions[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-content: center;\n}\n.welcome-suggested-questions-col[_ngcontent-%COMP%] {\n display: flex;\n}\n\n\n\n.welcome-question[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column; \n\n align-items: left;;\n width: 300px; \n justify-content: space-between;\n margin: 5px; \n\n border: solid 1px color-mix(in srgb, var(--mj-text-primary) 8%, transparent);\n border-radius: 15px;\n padding: 10px;\n cursor: pointer;\n}\n\n.welcome-question[_ngcontent-%COMP%]:hover {\n background-color: color-mix(in srgb, var(--mj-text-primary) 5%, transparent);\n}\n\n\n.welcome-question-header[_ngcontent-%COMP%] {\n font-size: 12pt;\n font-weight: bold;\n display: block; \n\n}\n\n\n\n.welcome-question[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:not(.welcome-question-header) {\n font-weight: normal;\n font-size: 10pt;\n}\n\n\n\n\n.chat-action-btn[_ngcontent-%COMP%] {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 30px;\n height: 30px;\n border: 1px solid var(--mj-border-default);\n border-radius: 50%;\n background: var(--mj-bg-surface);\n color: var(--mj-text-secondary);\n font-size: 13px;\n cursor: pointer;\n transition: all 0.15s ease;\n padding: 0;\n}\n\n.chat-action-btn[_ngcontent-%COMP%]:hover:not(:disabled) {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n border-color: var(--mj-border-strong);\n}\n\n.chat-action-btn[_ngcontent-%COMP%]:disabled {\n opacity: 0.4;\n cursor: not-allowed;\n}\n\n.chat-send-btn[_ngcontent-%COMP%] {\n background: var(--mj-brand-primary);\n border-color: var(--mj-brand-primary);\n color: var(--mj-text-inverse);\n}\n\n.chat-send-btn[_ngcontent-%COMP%]:hover:not(:disabled) {\n background: var(--mj-brand-primary-hover);\n border-color: var(--mj-brand-primary-hover);\n color: var(--mj-text-inverse);\n}\n\n\n\n\n.chat-dialog-overlay[_ngcontent-%COMP%] {\n position: fixed;\n inset: 0;\n background: var(--mj-bg-overlay);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 10000;\n}\n\n.chat-dialog[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: 10px;\n padding: 24px;\n min-width: 280px;\n max-width: 400px;\n box-shadow: 0 8px 32px color-mix(in srgb, var(--mj-text-primary) 15%, transparent);\n}\n\n.chat-dialog-message[_ngcontent-%COMP%] {\n margin: 0 0 20px 0;\n font-size: 14px;\n color: var(--mj-text-primary);\n line-height: 1.5;\n}\n\n.chat-dialog-actions[_ngcontent-%COMP%] {\n display: flex;\n gap: 8px;\n}\n\n.chat-dialog-btn[_ngcontent-%COMP%] {\n padding: 8px 20px;\n border: 1px solid var(--mj-border-default);\n border-radius: 6px;\n background: var(--mj-bg-surface);\n color: var(--mj-text-secondary);\n font-size: 13px;\n font-weight: 500;\n cursor: pointer;\n transition: all 0.15s ease;\n}\n\n.chat-dialog-btn[_ngcontent-%COMP%]:hover {\n background: var(--mj-bg-surface-hover);\n}\n\n.chat-dialog-btn-primary[_ngcontent-%COMP%] {\n background: var(--mj-brand-primary);\n border-color: var(--mj-brand-primary);\n color: var(--mj-text-inverse);\n}\n\n.chat-dialog-btn-primary[_ngcontent-%COMP%]:hover {\n background: var(--mj-brand-primary-hover);\n}\n\n\n\n\n\n\n\n\n.typing-indicator[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 4px;\n padding: 8px 16px;\n margin: 4px 0;\n}\n\n.typing-dot[_ngcontent-%COMP%] {\n width: 6px;\n height: 6px;\n border-radius: 50%;\n background: var(--mj-brand-primary);\n animation: _ngcontent-%COMP%_typingBounce 1.4s infinite ease-in-out both;\n}\n\n.typing-dot[_ngcontent-%COMP%]:nth-child(1) { animation-delay: 0s; }\n.typing-dot[_ngcontent-%COMP%]:nth-child(2) { animation-delay: 0.16s; }\n.typing-dot[_ngcontent-%COMP%]:nth-child(3) { animation-delay: 0.32s; }\n\n@keyframes _ngcontent-%COMP%_typingBounce {\n 0%, 80%, 100% {\n transform: scale(0.6);\n opacity: 0.4;\n }\n 40% {\n transform: scale(1);\n opacity: 1;\n }\n}\n\n.typing-text[_ngcontent-%COMP%] {\n font-size: 0.78rem;\n color: var(--mj-text-muted);\n margin-left: 4px;\n}\n\n\n\n .chat-message pre {\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-subtle);\n border-radius: 8px;\n padding: 12px 16px;\n overflow-x: auto;\n margin: 8px 0;\n font-size: 0.85rem;\n line-height: 1.5;\n}\n\n .chat-message code {\n font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', monospace;\n font-size: 0.85em;\n}\n\n .chat-message p code {\n background: var(--mj-bg-surface-sunken);\n padding: 0.15em 0.4em;\n border-radius: 4px;\n font-size: 0.85em;\n}\n\n\n\n .chat-message-wrap {\n animation: _ngcontent-%COMP%_messageSlideIn 0.3s ease-out;\n}\n\n@keyframes _ngcontent-%COMP%_messageSlideIn {\n from {\n opacity: 0;\n transform: translateY(8px);\n }\n to {\n opacity: 1;\n transform: translateY(0);\n }\n}\n\n\n\n .chat-tool-execution {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 8px 12px;\n background: color-mix(in srgb, var(--mj-brand-primary) 8%, var(--mj-bg-surface));\n border: 1px solid color-mix(in srgb, var(--mj-brand-primary) 20%, var(--mj-bg-surface));\n border-radius: 8px;\n margin: 4px 0;\n font-size: 0.82rem;\n color: var(--mj-text-secondary);\n}\n\n .chat-tool-execution i {\n color: var(--mj-brand-primary);\n}\n\n\n\n@media (max-width: 640px) {\n .chat-input-area[_ngcontent-%COMP%] {\n padding: 8px;\n margin-bottom: 8px;\n }\n\n .text-area-wrapper[_ngcontent-%COMP%] {\n width: 100%;\n max-width: none;\n padding-right: 70px;\n }\n\n .welcome-suggested-questions-col[_ngcontent-%COMP%] {\n flex-direction: column;\n }\n\n .welcome-question[_ngcontent-%COMP%] {\n width: 100%;\n }\n\n .chat-message-image {\n width: 32px;\n font-size: 18px;\n margin-right: 8px;\n }\n}"] });
369
378
  }
370
379
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ChatComponent, [{
371
380
  type: Component,
372
- args: [{ standalone: false, selector: 'mj-chat', template: "<div class=\"chat-wrapper\">\n @if(Messages.length === 0 && !ShowWaitingIndicator) {\n <div class=\"welcome-wrapper\">\n <div class='welcome-message'>\n @if(AILargeImageURL) {\n <img [src]=\"AILargeImageURL\"/>\n }\n <div class=\"welcome-header-text\">What can I help with today?</div>\n </div>\n <div class='welcome-suggested-questions'>\n <div class=\"welcome-suggested-questions-col\">\n @if (WelcomeQuestions.length > 0) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[0].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[0].topLine}}</span>\n <span>{{WelcomeQuestions[0].bottomLine}}</span>\n </div>\n }\n @if (WelcomeQuestions.length > 1) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[1].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[1].topLine}}</span>\n <span>{{WelcomeQuestions[1].bottomLine}}</span>\n </div> \n }\n </div>\n <div class=\"welcome-suggested-questions-col\">\n @if (WelcomeQuestions.length > 2) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[2].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[2].topLine}}</span>\n <span>{{WelcomeQuestions[2].bottomLine}}</span>\n </div> \n }\n @if (WelcomeQuestions.length > 3) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[3].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[3].topLine}}</span>\n <span>{{WelcomeQuestions[3].bottomLine}}</span>\n </div> \n }\n </div>\n </div>\n </div> \n }\n\n <div class=\"chat-messages\" \n #messagesContainer \n (scroll)=\"handleCheckScroll()\">\n <!-- messages go here -->\n <span>{{InitialMessage}}</span>\n </div>\n @if (ShowScrollToBottomButton) {\n <span class=\"scroll-to-bottom fas fa-arrow-down\" (click)=\"ScrollMessagesToBottom()\"></span>\n }\n\n <div class = \"chat-input-area\">\n @if (ShowWaitingIndicator) {\n <mj-loading [showText]=\"false\" size=\"small\" class=\"loader\"></mj-loading>\n }\n <div class=\"text-area-wrapper\">\n <textarea #theInput \n [(ngModel)]=\"currentMessage\" \n [disabled]=\"ShowWaitingIndicator\" \n [placeholder]=\"Placeholder\" \n (input)=\"handleInputChange($event)\"\n (keyup.enter)=\"SendCurrentMessage()\" >\n </textarea>\n </div>\n <button kendoButton \n [disabled]=\"Messages.length === 0 || ShowWaitingIndicator\"\n (click)=\"showingClearAllDialog = true\">\n <span class=\"fa-solid fa-trash-can\" title=\"Clear Chat\">\n </span>\n </button>\n <button kendoButton\n [disabled]=\"!InternalAllowSend || currentMessage.length === 0 || ShowWaitingIndicator\" \n (click)=\"SendCurrentMessage()\">\n <span class=\"fas fa-solid fa-arrow-up\" title=\"Send Message\"></span>\n </button>\n </div>\n</div>\n@if (showingClearAllDialog) {\n <kendo-dialog>\n <p>{{ClearAllMessagesPrompt}}</p>\n <kendo-dialog-actions>\n <button kendoButton (click)=\"HandleClearChat()\" themeColor=\"primary\">Yes</button>\n <button kendoButton (click)=\"showingClearAllDialog = false\">No</button>\n </kendo-dialog-actions>\n </kendo-dialog>\n}\n", styles: [".loader {\n position: absolute;\n left: 0px;\n}\n\n.chat-wrapper {\n display: flex;\n flex-direction: column;\n position: relative; /* Add this line if the wrapper needs to be a reference point */\n}\n\n.chat-messages {\n overflow-y: auto; /* enable scrolling if the content overflows */\n overflow-x: hidden; /* hide horizontal scrollbar */\n /* border: solid 1px rgba(0, 0, 0, 0.08); */\n margin-bottom: 5px;\n\n margin-top: 2px; /* align it with the top of converation history exactly*/\n\n flex: 1;\n}\n\n/* Hide scrollbar for Chrome, Safari and Opera */\n.chat-messages::-webkit-scrollbar {\n width: 0;\n background: transparent; /* Optional: just make scrollbar invisible */\n}\n\n/* Optional: Show scrollbar on hover */\n.chat-messages:hover::-webkit-scrollbar {\n width: 12px; /* Adjust the width of the scrollbar here */\n background-color: var(--mj-bg-surface-sunken); /* Adjust the background color of the scrollbar here */\n\n}\n\n/* Handle on hover */\n.chat-messages:hover::-webkit-scrollbar-thumb {\n background-color: var(--mj-text-muted); /* Adjust the color of the scrollbar handle here */\n opacity: 0.5; /* Adjust the opacity of the scrollbar handle here */\n}\n\n/* Handle rounded corners */\n.chat-messages:hover::-webkit-scrollbar-thumb {\n border-radius: 10px;\n}\n\n/* Optional: handle's hover effect */\n.chat-messages:hover::-webkit-scrollbar-thumb:hover {\n background: var(--mj-text-secondary); /* Adjust hover color here */\n}\n/* Works on Firefox */\n.chat-messages {\n scrollbar-width: thin; /* \"auto\" or \"thin\" */\n scrollbar-color: var(--mj-text-muted) var(--mj-bg-surface-sunken); /* thumb and track color */\n}\n \n\n\n\n.chat-input-area {\n background: var(--mj-bg-surface-card);\n display: flex;\n justify-content: center;\n align-items: center;\n padding-top: 12px;\n min-height: 35px;\n margin-bottom: 15px;\n}\n.chat-input-area > button {\n vertical-align: top;\n width: 30px;\n height: 30px;\n margin-top: 3px;\n border-radius: 12px;\n}\n.chat-input-area > button:first-of-type {\n margin-left: -40px;\n}\n.chat-input-area > button:last-child {\n margin-left: -65px;\n}\n\n.text-area-wrapper {\n padding: 3px;\n border: solid 1px color-mix(in srgb, var(--mj-text-primary) 8%, transparent);\n border-radius: 15px;\n\n margin-top: 4px;\n margin-right: -1px;\n min-height: 42px;\n max-height: 100%; /* Prevent it from growing beyond the container */\n\n overflow: hidden; \n align-items: center;\n\n /*combined width and padding is 800*/\n max-width: 710px; \n width: 75%; /*take up 75% but no more than 710px*/\n padding-right: 90px; /* Space for the buttons */\n} \n.text-area-wrapper > textarea {\n border: 0;\n outline: 0;\n resize: none;\n\n min-height: 20px; /* Initial height */\n\n width: 100%;\n overflow-y: hidden; /* Hide scrollbar */\n\n font-family: S\u00F6hne, ui-sans-serif, system-ui, -apple-system, \"Segoe UI\", Roboto, Ubuntu, Cantarell, \"Noto Sans\", sans-serif, \"Helvetica Neue\", Arial, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";\n font-size: 1rem;\n\n margin-left: 7px;\n margin-top: 7px;\n margin-bottom: 5px;\n}\n\n.text-area-wrapper > textarea:disabled {\n background-color: var(--mj-bg-surface-card);\n}\n\n\n::ng-deep .chat-message-wrap {\n display: flex;\n align-items: flex-start; /* Align items to the top */\n margin-bottom: 10px;\n margin-right: 10px;\n}\n\n::ng-deep .chat-message-image {\n margin-top: 12px;\n font-size: 24px; /* Adjust size as necessary */\n margin-right: 10px; /* Space between the icon and the message text */\n width: 50px;\n flex-shrink: 0; /* Prevents the icon from shrinking */ \n}\n\n/* Styling for dynamic markdown content and message differentiation */\n::ng-deep .chat-message {\n padding-left: 7px;\n padding-right: 7px;\n margin-bottom: 10px;\n border-radius: 5px;\n background-color: var(--mj-bg-surface-sunken);\n box-shadow: var(--mj-shadow-sm);\n word-wrap: break-word;\n}\n\n::ng-deep .chat-message-ai {\n background-color: color-mix(in srgb, var(--mj-brand-primary) 5%, var(--mj-bg-surface));\n}\n\n.scroll-to-bottom {\n position: absolute; /* Or absolute, depending on your layout specifics */\n left: 50%; /* Start from the middle of the container */\n transform: translateX(-50%); /* Move it back by half of its own width to truly center it */\n bottom: 100px; /* Adjust based on the height of your input area */\n z-index: 1000; /* Make sure it's above all other content */\n border-radius: 50%;\n width: 35px;\n height: 35px;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 22px;\n background-color: var(--mj-bg-surface-sunken);\n box-shadow: var(--mj-shadow-md); /* Optional: Adds a subtle shadow for better visibility */\n cursor: pointer;\n}\n\n\n\n/* Center the welcome message vertically and horizontally */\n.welcome-wrapper {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 100%;\n width: 100%;\n overflow: hidden;\n}\n\n.welcome-message {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n text-align: center;\n overflow: hidden;\n height: 100%;\n}\n\n\n.welcome-message img {\n width: 120px;\n height: 50px;\n margin-bottom: 20px; /* Adds some space between the image and the text below */\n}\n\n.welcome-header-text {\n font-size: larger;\n font-weight: bold;\n}\n\n/* Position the welcome-suggested-questions at the bottom of its container */\n.welcome-suggested-questions {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-content: center;\n}\n.welcome-suggested-questions-col {\n display: flex;\n}\n\n/* Flex layout for questions, two per row */\n.welcome-question {\n display: flex;\n flex-direction: column; /* Stack the header and text vertically */\n align-items: left;;\n width: 300px; \n justify-content: space-between;\n margin: 5px; /* Adds some space around each question */\n border: solid 1px color-mix(in srgb, var(--mj-text-primary) 8%, transparent);\n border-radius: 15px;\n padding: 10px;\n cursor: pointer;\n}\n\n.welcome-question:hover {\n background-color: color-mix(in srgb, var(--mj-text-primary) 5%, transparent);\n}\n\n\n.welcome-question-header {\n font-size: 12pt;\n font-weight: bold;\n display: block; /* Ensures the header is on its own line */\n}\n\n/* Non-bold text for the content below the header */\n.welcome-question span:not(.welcome-question-header) {\n font-weight: normal;\n font-size: 10pt;\n}\n"] }]
381
+ args: [{ standalone: false, selector: 'mj-chat', template: "<div class=\"chat-wrapper\">\n @if(Messages.length === 0 && !ShowWaitingIndicator) {\n <div class=\"welcome-wrapper\">\n <div class='welcome-message'>\n @if(AILargeImageURL) {\n <img [src]=\"AILargeImageURL\"/>\n }\n <div class=\"welcome-header-text\">What can I help with today?</div>\n </div>\n <div class='welcome-suggested-questions'>\n <div class=\"welcome-suggested-questions-col\">\n @if (WelcomeQuestions.length > 0) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[0].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[0].topLine}}</span>\n <span>{{WelcomeQuestions[0].bottomLine}}</span>\n </div>\n }\n @if (WelcomeQuestions.length > 1) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[1].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[1].topLine}}</span>\n <span>{{WelcomeQuestions[1].bottomLine}}</span>\n </div> \n }\n </div>\n <div class=\"welcome-suggested-questions-col\">\n @if (WelcomeQuestions.length > 2) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[2].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[2].topLine}}</span>\n <span>{{WelcomeQuestions[2].bottomLine}}</span>\n </div> \n }\n @if (WelcomeQuestions.length > 3) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[3].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[3].topLine}}</span>\n <span>{{WelcomeQuestions[3].bottomLine}}</span>\n </div> \n }\n </div>\n </div>\n </div> \n }\n\n <div class=\"chat-messages\" \n #messagesContainer \n (scroll)=\"handleCheckScroll()\">\n <!-- messages go here -->\n <span>{{InitialMessage}}</span>\n </div>\n @if (ShowScrollToBottomButton) {\n <span class=\"scroll-to-bottom fas fa-arrow-down\" (click)=\"ScrollMessagesToBottom()\"></span>\n }\n\n @if (ShowWaitingIndicator) {\n <div class=\"typing-indicator\">\n <div class=\"typing-dot\"></div>\n <div class=\"typing-dot\"></div>\n <div class=\"typing-dot\"></div>\n <span class=\"typing-text\">Thinking...</span>\n </div>\n }\n\n <div class = \"chat-input-area\">\n <div class=\"text-area-wrapper\">\n <textarea #theInput \n [(ngModel)]=\"currentMessage\" \n [disabled]=\"ShowWaitingIndicator\" \n [placeholder]=\"Placeholder\" \n (input)=\"handleInputChange($event)\"\n (keyup.enter)=\"SendCurrentMessage()\" >\n </textarea>\n </div>\n <button class=\"chat-action-btn\"\n [disabled]=\"Messages.length === 0 || ShowWaitingIndicator\"\n (click)=\"showingClearAllDialog = true\"\n title=\"Clear Chat\">\n <i class=\"fa-solid fa-trash-can\"></i>\n </button>\n <button class=\"chat-action-btn chat-send-btn\"\n [disabled]=\"!InternalAllowSend || currentMessage.length === 0 || ShowWaitingIndicator\"\n (click)=\"SendCurrentMessage()\"\n title=\"Send Message\">\n <i class=\"fa-solid fa-arrow-up\"></i>\n </button>\n </div>\n</div>\n@if (showingClearAllDialog) {\n <div class=\"chat-dialog-overlay\" (click)=\"showingClearAllDialog = false\">\n <div class=\"chat-dialog\" (click)=\"$event.stopPropagation()\">\n <p class=\"chat-dialog-message\">{{ClearAllMessagesPrompt}}</p>\n <div class=\"chat-dialog-actions\">\n <button class=\"chat-dialog-btn chat-dialog-btn-primary\" (click)=\"HandleClearChat()\">Yes</button>\n <button class=\"chat-dialog-btn\" (click)=\"showingClearAllDialog = false\">No</button>\n </div>\n </div>\n </div>\n}\n", styles: [".loader {\n position: absolute;\n left: 0px;\n}\n\n.chat-wrapper {\n display: flex;\n flex-direction: column;\n position: relative; /* Add this line if the wrapper needs to be a reference point */\n}\n\n.chat-messages {\n overflow-y: auto; /* enable scrolling if the content overflows */\n overflow-x: hidden; /* hide horizontal scrollbar */\n /* border: solid 1px rgba(0, 0, 0, 0.08); */\n margin-bottom: 5px;\n\n margin-top: 2px; /* align it with the top of converation history exactly*/\n\n flex: 1;\n}\n\n/* Hide scrollbar for Chrome, Safari and Opera */\n.chat-messages::-webkit-scrollbar {\n width: 0;\n background: transparent; /* Optional: just make scrollbar invisible */\n}\n\n/* Optional: Show scrollbar on hover */\n.chat-messages:hover::-webkit-scrollbar {\n width: 12px; /* Adjust the width of the scrollbar here */\n background-color: var(--mj-bg-surface-sunken); /* Adjust the background color of the scrollbar here */\n\n}\n\n/* Handle on hover */\n.chat-messages:hover::-webkit-scrollbar-thumb {\n background-color: var(--mj-text-muted); /* Adjust the color of the scrollbar handle here */\n opacity: 0.5; /* Adjust the opacity of the scrollbar handle here */\n}\n\n/* Handle rounded corners */\n.chat-messages:hover::-webkit-scrollbar-thumb {\n border-radius: 10px;\n}\n\n/* Optional: handle's hover effect */\n.chat-messages:hover::-webkit-scrollbar-thumb:hover {\n background: var(--mj-text-secondary); /* Adjust hover color here */\n}\n/* Works on Firefox */\n.chat-messages {\n scrollbar-width: thin; /* \"auto\" or \"thin\" */\n scrollbar-color: var(--mj-text-muted) var(--mj-bg-surface-sunken); /* thumb and track color */\n}\n \n\n\n\n.chat-input-area {\n background: var(--mj-bg-surface-card);\n display: flex;\n justify-content: center;\n align-items: center;\n padding-top: 12px;\n min-height: 35px;\n margin-bottom: 15px;\n}\n.chat-input-area > button {\n vertical-align: top;\n width: 30px;\n height: 30px;\n margin-top: 3px;\n border-radius: 12px;\n}\n.chat-input-area > button:first-of-type {\n margin-left: -40px;\n}\n.chat-input-area > button:last-child {\n margin-left: -65px;\n}\n\n.text-area-wrapper {\n padding: 3px;\n border: solid 1px color-mix(in srgb, var(--mj-text-primary) 8%, transparent);\n border-radius: 15px;\n\n margin-top: 4px;\n margin-right: -1px;\n min-height: 42px;\n max-height: 100%; /* Prevent it from growing beyond the container */\n\n overflow: hidden; \n align-items: center;\n\n /*combined width and padding is 800*/\n max-width: 710px; \n width: 75%; /*take up 75% but no more than 710px*/\n padding-right: 90px; /* Space for the buttons */\n} \n.text-area-wrapper > textarea {\n border: 0;\n outline: 0;\n resize: none;\n\n min-height: 20px; /* Initial height */\n\n width: 100%;\n overflow-y: hidden; /* Hide scrollbar */\n\n font-family: S\u00F6hne, ui-sans-serif, system-ui, -apple-system, \"Segoe UI\", Roboto, Ubuntu, Cantarell, \"Noto Sans\", sans-serif, \"Helvetica Neue\", Arial, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";\n font-size: 1rem;\n\n margin-left: 7px;\n margin-top: 7px;\n margin-bottom: 5px;\n}\n\n.text-area-wrapper > textarea:disabled {\n background-color: var(--mj-bg-surface-card);\n}\n\n\n::ng-deep .chat-message-wrap {\n display: flex;\n align-items: flex-start; /* Align items to the top */\n margin-bottom: 10px;\n margin-right: 10px;\n}\n\n::ng-deep .chat-message-image {\n margin-top: 12px;\n font-size: 24px; /* Adjust size as necessary */\n margin-right: 10px; /* Space between the icon and the message text */\n width: 50px;\n flex-shrink: 0; /* Prevents the icon from shrinking */ \n}\n\n/* Styling for dynamic markdown content and message differentiation */\n::ng-deep .chat-message {\n padding-left: 7px;\n padding-right: 7px;\n margin-bottom: 10px;\n border-radius: 5px;\n background-color: var(--mj-bg-surface-sunken);\n box-shadow: var(--mj-shadow-sm);\n word-wrap: break-word;\n}\n\n::ng-deep .chat-message-ai {\n background-color: color-mix(in srgb, var(--mj-brand-primary) 5%, var(--mj-bg-surface));\n}\n\n.scroll-to-bottom {\n position: absolute; /* Or absolute, depending on your layout specifics */\n left: 50%; /* Start from the middle of the container */\n transform: translateX(-50%); /* Move it back by half of its own width to truly center it */\n bottom: 100px; /* Adjust based on the height of your input area */\n z-index: 1000; /* Make sure it's above all other content */\n border-radius: 50%;\n width: 35px;\n height: 35px;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 22px;\n background-color: var(--mj-bg-surface-sunken);\n box-shadow: var(--mj-shadow-md); /* Optional: Adds a subtle shadow for better visibility */\n cursor: pointer;\n}\n\n\n\n/* Center the welcome message vertically and horizontally */\n.welcome-wrapper {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n height: 100%;\n width: 100%;\n overflow: hidden;\n}\n\n.welcome-message {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n text-align: center;\n overflow: hidden;\n height: 100%;\n}\n\n\n.welcome-message img {\n width: 120px;\n height: 50px;\n margin-bottom: 20px; /* Adds some space between the image and the text below */\n}\n\n.welcome-header-text {\n font-size: larger;\n font-weight: bold;\n}\n\n/* Position the welcome-suggested-questions at the bottom of its container */\n.welcome-suggested-questions {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-content: center;\n}\n.welcome-suggested-questions-col {\n display: flex;\n}\n\n/* Flex layout for questions, two per row */\n.welcome-question {\n display: flex;\n flex-direction: column; /* Stack the header and text vertically */\n align-items: left;;\n width: 300px; \n justify-content: space-between;\n margin: 5px; /* Adds some space around each question */\n border: solid 1px color-mix(in srgb, var(--mj-text-primary) 8%, transparent);\n border-radius: 15px;\n padding: 10px;\n cursor: pointer;\n}\n\n.welcome-question:hover {\n background-color: color-mix(in srgb, var(--mj-text-primary) 5%, transparent);\n}\n\n\n.welcome-question-header {\n font-size: 12pt;\n font-weight: bold;\n display: block; /* Ensures the header is on its own line */\n}\n\n/* Non-bold text for the content below the header */\n.welcome-question span:not(.welcome-question-header) {\n font-weight: normal;\n font-size: 10pt;\n}\n\n/* ---- Action buttons (replaces Kendo buttons) ---- */\n\n.chat-action-btn {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 30px;\n height: 30px;\n border: 1px solid var(--mj-border-default);\n border-radius: 50%;\n background: var(--mj-bg-surface);\n color: var(--mj-text-secondary);\n font-size: 13px;\n cursor: pointer;\n transition: all 0.15s ease;\n padding: 0;\n}\n\n.chat-action-btn:hover:not(:disabled) {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n border-color: var(--mj-border-strong);\n}\n\n.chat-action-btn:disabled {\n opacity: 0.4;\n cursor: not-allowed;\n}\n\n.chat-send-btn {\n background: var(--mj-brand-primary);\n border-color: var(--mj-brand-primary);\n color: var(--mj-text-inverse);\n}\n\n.chat-send-btn:hover:not(:disabled) {\n background: var(--mj-brand-primary-hover);\n border-color: var(--mj-brand-primary-hover);\n color: var(--mj-text-inverse);\n}\n\n/* ---- Confirmation dialog (replaces Kendo dialog) ---- */\n\n.chat-dialog-overlay {\n position: fixed;\n inset: 0;\n background: var(--mj-bg-overlay);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 10000;\n}\n\n.chat-dialog {\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: 10px;\n padding: 24px;\n min-width: 280px;\n max-width: 400px;\n box-shadow: 0 8px 32px color-mix(in srgb, var(--mj-text-primary) 15%, transparent);\n}\n\n.chat-dialog-message {\n margin: 0 0 20px 0;\n font-size: 14px;\n color: var(--mj-text-primary);\n line-height: 1.5;\n}\n\n.chat-dialog-actions {\n display: flex;\n gap: 8px;\n}\n\n.chat-dialog-btn {\n padding: 8px 20px;\n border: 1px solid var(--mj-border-default);\n border-radius: 6px;\n background: var(--mj-bg-surface);\n color: var(--mj-text-secondary);\n font-size: 13px;\n font-weight: 500;\n cursor: pointer;\n transition: all 0.15s ease;\n}\n\n.chat-dialog-btn:hover {\n background: var(--mj-bg-surface-hover);\n}\n\n.chat-dialog-btn-primary {\n background: var(--mj-brand-primary);\n border-color: var(--mj-brand-primary);\n color: var(--mj-text-inverse);\n}\n\n.chat-dialog-btn-primary:hover {\n background: var(--mj-brand-primary-hover);\n}\n\n/* ================================================================\n Modernized Chat Styles (Task 9)\n ================================================================ */\n\n/* Typing/thinking indicator with animated dots */\n.typing-indicator {\n display: flex;\n align-items: center;\n gap: 4px;\n padding: 8px 16px;\n margin: 4px 0;\n}\n\n.typing-dot {\n width: 6px;\n height: 6px;\n border-radius: 50%;\n background: var(--mj-brand-primary);\n animation: typingBounce 1.4s infinite ease-in-out both;\n}\n\n.typing-dot:nth-child(1) { animation-delay: 0s; }\n.typing-dot:nth-child(2) { animation-delay: 0.16s; }\n.typing-dot:nth-child(3) { animation-delay: 0.32s; }\n\n@keyframes typingBounce {\n 0%, 80%, 100% {\n transform: scale(0.6);\n opacity: 0.4;\n }\n 40% {\n transform: scale(1);\n opacity: 1;\n }\n}\n\n.typing-text {\n font-size: 0.78rem;\n color: var(--mj-text-muted);\n margin-left: 4px;\n}\n\n/* Improved code block styling in markdown */\n::ng-deep .chat-message pre {\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-subtle);\n border-radius: 8px;\n padding: 12px 16px;\n overflow-x: auto;\n margin: 8px 0;\n font-size: 0.85rem;\n line-height: 1.5;\n}\n\n::ng-deep .chat-message code {\n font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', monospace;\n font-size: 0.85em;\n}\n\n::ng-deep .chat-message p code {\n background: var(--mj-bg-surface-sunken);\n padding: 0.15em 0.4em;\n border-radius: 4px;\n font-size: 0.85em;\n}\n\n/* Smooth message entry animation */\n::ng-deep .chat-message-wrap {\n animation: messageSlideIn 0.3s ease-out;\n}\n\n@keyframes messageSlideIn {\n from {\n opacity: 0;\n transform: translateY(8px);\n }\n to {\n opacity: 1;\n transform: translateY(0);\n }\n}\n\n/* Tool execution visualization */\n::ng-deep .chat-tool-execution {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 8px 12px;\n background: color-mix(in srgb, var(--mj-brand-primary) 8%, var(--mj-bg-surface));\n border: 1px solid color-mix(in srgb, var(--mj-brand-primary) 20%, var(--mj-bg-surface));\n border-radius: 8px;\n margin: 4px 0;\n font-size: 0.82rem;\n color: var(--mj-text-secondary);\n}\n\n::ng-deep .chat-tool-execution i {\n color: var(--mj-brand-primary);\n}\n\n/* Mobile-first responsive adjustments */\n@media (max-width: 640px) {\n .chat-input-area {\n padding: 8px;\n margin-bottom: 8px;\n }\n\n .text-area-wrapper {\n width: 100%;\n max-width: none;\n padding-right: 70px;\n }\n\n .welcome-suggested-questions-col {\n flex-direction: column;\n }\n\n .welcome-question {\n width: 100%;\n }\n\n ::ng-deep .chat-message-image {\n width: 32px;\n font-size: 18px;\n margin-right: 8px;\n }\n}\n"] }]
373
382
  }], () => [{ type: i1.MarkdownService }, { type: i0.ChangeDetectorRef }], { InitialMessage: [{
374
383
  type: Input
375
384
  }], Messages: [{
@@ -399,5 +408,5 @@ export class ChatComponent {
399
408
  type: ViewChild,
400
409
  args: ['theInput']
401
410
  }] }); })();
402
- (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ChatComponent, { className: "ChatComponent", filePath: "src/lib/chat/chat.component.ts", lineNumber: 31 }); })();
411
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ChatComponent, { className: "ChatComponent", filePath: "src/lib/chat/chat.component.ts", lineNumber: 38 }); })();
403
412
  //# sourceMappingURL=chat.component.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"chat.component.js","sourceRoot":"","sources":["../../../src/lib/chat/chat.component.ts","../../../src/lib/chat/chat.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAoC,SAAS,EAAc,YAAY,EAAE,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAEhI,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAA;;;;;;;;;;ICG3B,0BAA8B;;;IAAzB,8DAAuB;;;;IAOxB,+BAAoF;IAAtD,6LAAS,+CAAiC,CAAC,SAAS,KAAC;IAC/E,gCAAsC;IAAA,YAA+B;IAAA,iBAAO;IAC5E,4BAAM;IAAA,YAAkC;IAC5C,AAD4C,iBAAO,EAC7C;;;IAFoC,eAA+B;IAA/B,wDAA+B;IAC/D,eAAkC;IAAlC,2DAAkC;;;;IAI5C,+BAAoF;IAAtD,6LAAS,+CAAiC,CAAC,SAAS,KAAC;IAC/E,gCAAsC;IAAA,YAA+B;IAAA,iBAAO;IAC5E,4BAAM;IAAA,YAAkC;IAC5C,AAD4C,iBAAO,EAC7C;;;IAFoC,eAA+B;IAA/B,wDAA+B;IAC/D,eAAkC;IAAlC,2DAAkC;;;;IAM5C,+BAAoF;IAAtD,8LAAS,+CAAiC,CAAC,SAAS,KAAC;IAC/E,gCAAsC;IAAA,YAA+B;IAAA,iBAAO;IAC5E,4BAAM;IAAA,YAAkC;IAC5C,AAD4C,iBAAO,EAC7C;;;IAFoC,eAA+B;IAA/B,wDAA+B;IAC/D,eAAkC;IAAlC,2DAAkC;;;;IAI5C,+BAAoF;IAAtD,8LAAS,+CAAiC,CAAC,SAAS,KAAC;IAC/E,gCAAsC;IAAA,YAA+B;IAAA,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AAoB,KAAC;YAC9B,4BAAmE;YAGnF,AADI,AADI,iBAAS,EACP,EACJ;YACN,uFAA6B;;YA7EzB,cAuCC;YAvCD,iFAuCC;YAMS,eAAkB;YAAlB,wCAAkB;YAE5B,cAEC;YAFD,uDAEC;YAGG,eAEC;YAFD,mDAEC;YAGe,eAA4B;YAA5B,kDAA4B;YAE5B,AADA,mDAAiC,gCACN;YAMnC,eAA0D;YAA1D,gFAA0D;YAM1D,eAAsF;YAAtF,gHAAsF;YAMtG,eAQC;YARD,qDAQC;;;iFDxDY,aAAa;cANzB,SAAS;6BACI,KAAK,YACP,SAAS;;kBAKlB,KAAK;;kBACL,KAAK;;kBAIL,KAAK;;kBACL,KAAK;;kBAML,KAAK;;kBAKL,KAAK;;kBAML,KAAK;;kBAKL,KAAK;;kBAGL,KAAK;;kBAeL,MAAM;;kBACN,MAAM;;kBAEN,SAAS;mBAAC,mBAAmB,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE;;kBAC/C,SAAS;mBAAC,UAAU;;kFAnDV,aAAa","sourcesContent":["import { AfterViewInit, ChangeDetectorRef, Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';\nimport { MarkdownService } from '@memberjunction/ng-markdown';\nimport { LogError } from '@memberjunction/core'\n\n\nexport class ChatWelcomeQuestion {\n public topLine: string=\"\";\n public bottomLine: string=\"\";\n public prompt: string=\"\";\n}\nexport class ChatMessage {\n public message!: string;\n public senderName!: string;\n public senderType: 'user' | 'ai' = 'user';\n public id?: any;\n\n constructor(message: string, senderName: string, senderType: 'user' | 'ai', id: any = null) {\n this.message = message;\n this.senderName = senderName;\n this.senderType = senderType;\n this.id = id;\n }\n}\n\n@Component({\n standalone: false,\n selector: 'mj-chat',\n templateUrl: './chat.component.html',\n styleUrl: './chat.component.css'\n})\nexport class ChatComponent implements AfterViewInit {\n @Input() InitialMessage: string = '';\n @Input() Messages: ChatMessage[] = [];\n /**\n * Optional, provide this to show an image for the AI. If not provided, a default robot icon will be shown.\n */\n @Input() AIImageURL: string = '';\n @Input() AILargeImageURL: string = '';\n\n /**\n * Optional, provide up to 4 welcome questions with example prompts. \n * These will be shown to the user when the chat is first opened and there are no messages.\n */\n @Input() WelcomeQuestions: ChatWelcomeQuestion[] = [];\n\n /**\n * Optional, provide a prompt for the user when they click the clear all messages button.\n */\n @Input() ClearAllMessagesPrompt: string = 'Are you sure you want to clear all messages?';\n\n /**\n * Set this to enable/disable sending of a message. Whenever the input is empty, this field will be\n * ignored and the send button will be disabled.\n */\n @Input() AllowSend: boolean = true;\n public InternalAllowSend: boolean = true;\n /**\n * The placeholder text for the input field\n */\n @Input() public Placeholder: string = 'Type a message...';\n\n private _ShowWaitingIndicator: boolean = false;\n @Input() public get ShowWaitingIndicator(): boolean {\n return this._ShowWaitingIndicator;\n }\n public set ShowWaitingIndicator(value: boolean) {\n this._ShowWaitingIndicator = value;\n this.cd?.detectChanges(); // Manually trigger change detection\n if (!value) {\n this.FocusTextArea();\n }\n }\n\n ngAfterViewInit(): void {\n this.FocusTextArea();\n }\n\n @Output() MessageAdded = new EventEmitter<ChatMessage>();\n @Output() ClearChatRequested = new EventEmitter<void>();\n\n @ViewChild('messagesContainer', { static: true }) private messagesContainer!: ElementRef;\n @ViewChild('theInput') theInput: ElementRef | undefined;\n\n public currentMessage: string = '';\n public showingClearAllDialog: boolean = false;\n constructor(private markdownService: MarkdownService, private cd: ChangeDetectorRef) {}\n\n public SendCurrentMessage(): void {\n if (this.currentMessage.trim() !== '') {\n this.SendMessage(this.currentMessage, 'User', 'user', null);\n this.currentMessage = ''; // Clear the input field\n }\n }\n\n public handleInputChange(event: any) {\n const val = this.theInput?.nativeElement.value;\n this.InternalAllowSend = this.AllowSend && (val ? val.length > 0 : false);\n this.resizeTextInput();\n }\n\n protected resizeTextInput() {\n try {\n const textarea = this.theInput?.nativeElement;\n if (textarea) {\n textarea.style.height = 'auto'; // Reset height to recalculate\n textarea.style.height = `${textarea.scrollHeight}px`; // Set to scrollHeight \n }\n }\n catch (e) {\n LogError(e);\n }\n }\n\n\n public SendMessage(message: string, senderName: string, senderType: 'user' | 'ai', id: any, fireEvent: boolean = true): void {\n const newMessage = new ChatMessage(message, senderName, senderType, id);\n this.AppendMessage(newMessage, fireEvent); \n }\n\n public SendUserMessage(message: string) {\n this.SendMessage(message, 'User', 'user', null);\n }\n\n public HandleClearChat() {\n this.ClearChatRequested.emit();\n }\n\n public ClearAllMessages() {\n this.Messages = [];\n this.messagesContainer.nativeElement.innerHTML = `<span>${this.InitialMessage}</span>`;\n\n this.ScrollMessagesToBottom();\n\n this.cd.detectChanges(); // Manually trigger change detection\n\n this.FocusTextArea();\n this.showingClearAllDialog = false;\n }\n\n protected FocusTextArea() {\n setTimeout(() => this.theInput?.nativeElement.focus(), 0); // use a timeout to ensure that angular has updated the DOM\n }\n\n protected async AppendMessage(message: ChatMessage, fireEvent: boolean = true) {\n const messageWrapElement = document.createElement('div');\n messageWrapElement.className = \"chat-message-wrap\";\n const imageElement = document.createElement('span');\n if (message.senderType === 'ai') {\n if (this.AIImageURL) {\n const img = document.createElement('img');\n img.src = this.AIImageURL;\n img.style.maxWidth = '24px';\n imageElement.appendChild(img);\n }\n else\n imageElement.classList.add('fa-solid', 'fa-robot');\n }\n else {\n imageElement.classList.add('fa-solid', 'fa-user');\n }\n imageElement.classList.add(\"chat-message-image\");\n\n messageWrapElement.appendChild(imageElement);\n const messageElement = document.createElement('div');\n messageElement.innerHTML = await this.markdownService.parse(message.message);\n messageElement.className = \"chat-message\"; \n if (message.senderType === 'ai') {\n messageElement.classList.add('chat-message-ai');\n }\n messageWrapElement.appendChild(messageElement);\n\n this.Messages.push(message);\n if (this.Messages.length === 1) {\n // clear out the default message\n this.messagesContainer.nativeElement.innerHTML = '';\n }\n this.messagesContainer.nativeElement.appendChild(messageWrapElement); \n if (fireEvent)\n this.MessageAdded.emit(message); \n\n this.ScrollMessagesToBottom(false);\n\n this.cd.detectChanges(); // Manually trigger change detection\n }\n\n protected ScrollMessagesToBottom(animate: boolean = true): void {\n try {\n if (animate) {\n const element = this.messagesContainer.nativeElement;\n element.scrollTo({\n top: element.scrollHeight,\n behavior: 'smooth' // This enables the smooth scrolling\n }); \n }\n else {\n this.messagesContainer.nativeElement.scrollTop = this.messagesContainer.nativeElement.scrollHeight;\n }\n } catch(err) {}\n }\n\n\n public ShowScrollToBottomButton: boolean = false;\n\n handleCheckScroll(): void {\n const element = this.messagesContainer.nativeElement;\n if (element.scrollHeight - element.scrollTop > element.clientHeight) {\n this.ShowScrollToBottomButton = true;\n } else {\n this.ShowScrollToBottomButton = false;\n }\n }\n}\n","<div class=\"chat-wrapper\">\n @if(Messages.length === 0 && !ShowWaitingIndicator) {\n <div class=\"welcome-wrapper\">\n <div class='welcome-message'>\n @if(AILargeImageURL) {\n <img [src]=\"AILargeImageURL\"/>\n }\n <div class=\"welcome-header-text\">What can I help with today?</div>\n </div>\n <div class='welcome-suggested-questions'>\n <div class=\"welcome-suggested-questions-col\">\n @if (WelcomeQuestions.length > 0) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[0].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[0].topLine}}</span>\n <span>{{WelcomeQuestions[0].bottomLine}}</span>\n </div>\n }\n @if (WelcomeQuestions.length > 1) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[1].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[1].topLine}}</span>\n <span>{{WelcomeQuestions[1].bottomLine}}</span>\n </div> \n }\n </div>\n <div class=\"welcome-suggested-questions-col\">\n @if (WelcomeQuestions.length > 2) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[2].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[2].topLine}}</span>\n <span>{{WelcomeQuestions[2].bottomLine}}</span>\n </div> \n }\n @if (WelcomeQuestions.length > 3) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[3].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[3].topLine}}</span>\n <span>{{WelcomeQuestions[3].bottomLine}}</span>\n </div> \n }\n </div>\n </div>\n </div> \n }\n\n <div class=\"chat-messages\" \n #messagesContainer \n (scroll)=\"handleCheckScroll()\">\n <!-- messages go here -->\n <span>{{InitialMessage}}</span>\n </div>\n @if (ShowScrollToBottomButton) {\n <span class=\"scroll-to-bottom fas fa-arrow-down\" (click)=\"ScrollMessagesToBottom()\"></span>\n }\n\n <div class = \"chat-input-area\">\n @if (ShowWaitingIndicator) {\n <mj-loading [showText]=\"false\" size=\"small\" class=\"loader\"></mj-loading>\n }\n <div class=\"text-area-wrapper\">\n <textarea #theInput \n [(ngModel)]=\"currentMessage\" \n [disabled]=\"ShowWaitingIndicator\" \n [placeholder]=\"Placeholder\" \n (input)=\"handleInputChange($event)\"\n (keyup.enter)=\"SendCurrentMessage()\" >\n </textarea>\n </div>\n <button kendoButton \n [disabled]=\"Messages.length === 0 || ShowWaitingIndicator\"\n (click)=\"showingClearAllDialog = true\">\n <span class=\"fa-solid fa-trash-can\" title=\"Clear Chat\">\n </span>\n </button>\n <button kendoButton\n [disabled]=\"!InternalAllowSend || currentMessage.length === 0 || ShowWaitingIndicator\" \n (click)=\"SendCurrentMessage()\">\n <span class=\"fas fa-solid fa-arrow-up\" title=\"Send Message\"></span>\n </button>\n </div>\n</div>\n@if (showingClearAllDialog) {\n <kendo-dialog>\n <p>{{ClearAllMessagesPrompt}}</p>\n <kendo-dialog-actions>\n <button kendoButton (click)=\"HandleClearChat()\" themeColor=\"primary\">Yes</button>\n <button kendoButton (click)=\"showingClearAllDialog = false\">No</button>\n </kendo-dialog-actions>\n </kendo-dialog>\n}\n"]}
1
+ {"version":3,"file":"chat.component.js","sourceRoot":"","sources":["../../../src/lib/chat/chat.component.ts","../../../src/lib/chat/chat.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAoC,SAAS,EAAc,YAAY,EAAE,KAAK,EAAE,MAAM,EAAE,S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AAC;YAElC,yBAAoC;YAGhD,AADI,AADI,iBAAS,EACP,EACJ;YACN,kFAA6B;;YApFzB,cAuCC;YAvCD,iFAuCC;YAMS,eAAkB;YAAlB,wCAAkB;YAE5B,cAEC;YAFD,uDAEC;YAED,cAOC;YAPD,mDAOC;YAKmB,eAA4B;YAA5B,kDAA4B;YAE5B,AADA,mDAAiC,gCACN;YAMnC,eAA0D;YAA1D,gFAA0D;YAM1D,eAAsF;YAAtF,gHAAsF;YAOtG,eAUC;YAVD,qDAUC;;;iFD1DY,aAAa;cANzB,SAAS;6BACI,KAAK,YACP,SAAS;;kBAKlB,KAAK;;kBACL,KAAK;;kBAIL,KAAK;;kBACL,KAAK;;kBAML,KAAK;;kBAKL,KAAK;;kBAML,KAAK;;kBAKL,KAAK;;kBAGL,KAAK;;kBAeL,MAAM;;kBACN,MAAM;;kBAEN,SAAS;mBAAC,mBAAmB,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE;;kBAC/C,SAAS;mBAAC,UAAU;;kFAnDV,aAAa","sourcesContent":["import { AfterViewInit, ChangeDetectorRef, Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';\nimport { MarkdownService } from '@memberjunction/ng-markdown';\nimport { LogError } from '@memberjunction/core'\n\n\nexport class ChatWelcomeQuestion {\n public topLine: string=\"\";\n public bottomLine: string=\"\";\n public prompt: string=\"\";\n}\nexport class ChatMessage {\n public message!: string;\n public senderName!: string;\n public senderType: 'user' | 'ai' = 'user';\n public id?: string | number | null;\n /** Optional: indicates a tool execution is in progress */\n public toolName?: string;\n /** Optional: indicates a thinking/processing state */\n public isThinking?: boolean;\n /** Timestamp when the message was created */\n public timestamp: Date = new Date();\n\n constructor(message: string, senderName: string, senderType: 'user' | 'ai', id: string | number | null = null) {\n this.message = message;\n this.senderName = senderName;\n this.senderType = senderType;\n this.id = id;\n this.timestamp = new Date();\n }\n}\n\n@Component({\n standalone: false,\n selector: 'mj-chat',\n templateUrl: './chat.component.html',\n styleUrl: './chat.component.css'\n})\nexport class ChatComponent implements AfterViewInit {\n @Input() InitialMessage: string = '';\n @Input() Messages: ChatMessage[] = [];\n /**\n * Optional, provide this to show an image for the AI. If not provided, a default robot icon will be shown.\n */\n @Input() AIImageURL: string = '';\n @Input() AILargeImageURL: string = '';\n\n /**\n * Optional, provide up to 4 welcome questions with example prompts. \n * These will be shown to the user when the chat is first opened and there are no messages.\n */\n @Input() WelcomeQuestions: ChatWelcomeQuestion[] = [];\n\n /**\n * Optional, provide a prompt for the user when they click the clear all messages button.\n */\n @Input() ClearAllMessagesPrompt: string = 'Are you sure you want to clear all messages?';\n\n /**\n * Set this to enable/disable sending of a message. Whenever the input is empty, this field will be\n * ignored and the send button will be disabled.\n */\n @Input() AllowSend: boolean = true;\n public InternalAllowSend: boolean = true;\n /**\n * The placeholder text for the input field\n */\n @Input() public Placeholder: string = 'Type a message...';\n\n private _ShowWaitingIndicator: boolean = false;\n @Input() public get ShowWaitingIndicator(): boolean {\n return this._ShowWaitingIndicator;\n }\n public set ShowWaitingIndicator(value: boolean) {\n this._ShowWaitingIndicator = value;\n this.cd?.detectChanges(); // Manually trigger change detection\n if (!value) {\n this.FocusTextArea();\n }\n }\n\n ngAfterViewInit(): void {\n this.FocusTextArea();\n }\n\n @Output() MessageAdded = new EventEmitter<ChatMessage>();\n @Output() ClearChatRequested = new EventEmitter<void>();\n\n @ViewChild('messagesContainer', { static: true }) private messagesContainer!: ElementRef;\n @ViewChild('theInput') theInput: ElementRef | undefined;\n\n public currentMessage: string = '';\n public showingClearAllDialog: boolean = false;\n constructor(private markdownService: MarkdownService, private cd: ChangeDetectorRef) {}\n\n public SendCurrentMessage(): void {\n if (this.currentMessage.trim() !== '') {\n this.SendMessage(this.currentMessage, 'User', 'user', null);\n this.currentMessage = ''; // Clear the input field\n }\n }\n\n public handleInputChange(event: any) {\n const val = this.theInput?.nativeElement.value;\n this.InternalAllowSend = this.AllowSend && (val ? val.length > 0 : false);\n this.resizeTextInput();\n }\n\n protected resizeTextInput() {\n try {\n const textarea = this.theInput?.nativeElement;\n if (textarea) {\n textarea.style.height = 'auto'; // Reset height to recalculate\n textarea.style.height = `${textarea.scrollHeight}px`; // Set to scrollHeight \n }\n }\n catch (e) {\n LogError(e);\n }\n }\n\n\n public SendMessage(message: string, senderName: string, senderType: 'user' | 'ai', id: any, fireEvent: boolean = true): void {\n const newMessage = new ChatMessage(message, senderName, senderType, id);\n this.AppendMessage(newMessage, fireEvent); \n }\n\n public SendUserMessage(message: string) {\n this.SendMessage(message, 'User', 'user', null);\n }\n\n public HandleClearChat() {\n this.ClearChatRequested.emit();\n }\n\n public ClearAllMessages() {\n this.Messages = [];\n this.messagesContainer.nativeElement.innerHTML = `<span>${this.InitialMessage}</span>`;\n\n this.ScrollMessagesToBottom();\n\n this.cd.detectChanges(); // Manually trigger change detection\n\n this.FocusTextArea();\n this.showingClearAllDialog = false;\n }\n\n protected FocusTextArea() {\n setTimeout(() => this.theInput?.nativeElement.focus(), 0); // use a timeout to ensure that angular has updated the DOM\n }\n\n protected async AppendMessage(message: ChatMessage, fireEvent: boolean = true) {\n const messageWrapElement = document.createElement('div');\n messageWrapElement.className = \"chat-message-wrap\";\n const imageElement = document.createElement('span');\n if (message.senderType === 'ai') {\n if (this.AIImageURL) {\n const img = document.createElement('img');\n img.src = this.AIImageURL;\n img.style.maxWidth = '24px';\n imageElement.appendChild(img);\n }\n else\n imageElement.classList.add('fa-solid', 'fa-robot');\n }\n else {\n imageElement.classList.add('fa-solid', 'fa-user');\n }\n imageElement.classList.add(\"chat-message-image\");\n\n messageWrapElement.appendChild(imageElement);\n const messageElement = document.createElement('div');\n messageElement.innerHTML = await this.markdownService.parse(message.message);\n messageElement.className = \"chat-message\"; \n if (message.senderType === 'ai') {\n messageElement.classList.add('chat-message-ai');\n }\n messageWrapElement.appendChild(messageElement);\n\n this.Messages.push(message);\n if (this.Messages.length === 1) {\n // clear out the default message\n this.messagesContainer.nativeElement.innerHTML = '';\n }\n this.messagesContainer.nativeElement.appendChild(messageWrapElement); \n if (fireEvent)\n this.MessageAdded.emit(message); \n\n this.ScrollMessagesToBottom(false);\n\n this.cd.detectChanges(); // Manually trigger change detection\n }\n\n protected ScrollMessagesToBottom(animate: boolean = true): void {\n try {\n if (animate) {\n const element = this.messagesContainer.nativeElement;\n element.scrollTo({\n top: element.scrollHeight,\n behavior: 'smooth' // This enables the smooth scrolling\n }); \n }\n else {\n this.messagesContainer.nativeElement.scrollTop = this.messagesContainer.nativeElement.scrollHeight;\n }\n } catch(err) {}\n }\n\n\n public ShowScrollToBottomButton: boolean = false;\n\n handleCheckScroll(): void {\n const element = this.messagesContainer.nativeElement;\n if (element.scrollHeight - element.scrollTop > element.clientHeight) {\n this.ShowScrollToBottomButton = true;\n } else {\n this.ShowScrollToBottomButton = false;\n }\n }\n}\n","<div class=\"chat-wrapper\">\n @if(Messages.length === 0 && !ShowWaitingIndicator) {\n <div class=\"welcome-wrapper\">\n <div class='welcome-message'>\n @if(AILargeImageURL) {\n <img [src]=\"AILargeImageURL\"/>\n }\n <div class=\"welcome-header-text\">What can I help with today?</div>\n </div>\n <div class='welcome-suggested-questions'>\n <div class=\"welcome-suggested-questions-col\">\n @if (WelcomeQuestions.length > 0) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[0].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[0].topLine}}</span>\n <span>{{WelcomeQuestions[0].bottomLine}}</span>\n </div>\n }\n @if (WelcomeQuestions.length > 1) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[1].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[1].topLine}}</span>\n <span>{{WelcomeQuestions[1].bottomLine}}</span>\n </div> \n }\n </div>\n <div class=\"welcome-suggested-questions-col\">\n @if (WelcomeQuestions.length > 2) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[2].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[2].topLine}}</span>\n <span>{{WelcomeQuestions[2].bottomLine}}</span>\n </div> \n }\n @if (WelcomeQuestions.length > 3) {\n <div class=\"welcome-question\" (click)=\"SendUserMessage(WelcomeQuestions[3].prompt)\">\n <span class=\"welcome-question-header\">{{WelcomeQuestions[3].topLine}}</span>\n <span>{{WelcomeQuestions[3].bottomLine}}</span>\n </div> \n }\n </div>\n </div>\n </div> \n }\n\n <div class=\"chat-messages\" \n #messagesContainer \n (scroll)=\"handleCheckScroll()\">\n <!-- messages go here -->\n <span>{{InitialMessage}}</span>\n </div>\n @if (ShowScrollToBottomButton) {\n <span class=\"scroll-to-bottom fas fa-arrow-down\" (click)=\"ScrollMessagesToBottom()\"></span>\n }\n\n @if (ShowWaitingIndicator) {\n <div class=\"typing-indicator\">\n <div class=\"typing-dot\"></div>\n <div class=\"typing-dot\"></div>\n <div class=\"typing-dot\"></div>\n <span class=\"typing-text\">Thinking...</span>\n </div>\n }\n\n <div class = \"chat-input-area\">\n <div class=\"text-area-wrapper\">\n <textarea #theInput \n [(ngModel)]=\"currentMessage\" \n [disabled]=\"ShowWaitingIndicator\" \n [placeholder]=\"Placeholder\" \n (input)=\"handleInputChange($event)\"\n (keyup.enter)=\"SendCurrentMessage()\" >\n </textarea>\n </div>\n <button class=\"chat-action-btn\"\n [disabled]=\"Messages.length === 0 || ShowWaitingIndicator\"\n (click)=\"showingClearAllDialog = true\"\n title=\"Clear Chat\">\n <i class=\"fa-solid fa-trash-can\"></i>\n </button>\n <button class=\"chat-action-btn chat-send-btn\"\n [disabled]=\"!InternalAllowSend || currentMessage.length === 0 || ShowWaitingIndicator\"\n (click)=\"SendCurrentMessage()\"\n title=\"Send Message\">\n <i class=\"fa-solid fa-arrow-up\"></i>\n </button>\n </div>\n</div>\n@if (showingClearAllDialog) {\n <div class=\"chat-dialog-overlay\" (click)=\"showingClearAllDialog = false\">\n <div class=\"chat-dialog\" (click)=\"$event.stopPropagation()\">\n <p class=\"chat-dialog-message\">{{ClearAllMessagesPrompt}}</p>\n <div class=\"chat-dialog-actions\">\n <button class=\"chat-dialog-btn chat-dialog-btn-primary\" (click)=\"HandleClearChat()\">Yes</button>\n <button class=\"chat-dialog-btn\" (click)=\"showingClearAllDialog = false\">No</button>\n </div>\n </div>\n </div>\n}\n"]}
@@ -4,13 +4,10 @@ import * as i2 from "@angular/common";
4
4
  import * as i3 from "@angular/forms";
5
5
  import * as i4 from "@memberjunction/ng-container-directives";
6
6
  import * as i5 from "@memberjunction/ng-shared-generic";
7
- import * as i6 from "@progress/kendo-angular-indicators";
8
- import * as i7 from "@progress/kendo-angular-buttons";
9
- import * as i8 from "@progress/kendo-angular-dialog";
10
- import * as i9 from "@memberjunction/ng-markdown";
7
+ import * as i6 from "@memberjunction/ng-markdown";
11
8
  export declare class ChatModule {
12
9
  static ɵfac: i0.ɵɵFactoryDeclaration<ChatModule, never>;
13
- static ɵmod: i0.ɵɵNgModuleDeclaration<ChatModule, [typeof i1.ChatComponent], [typeof i2.CommonModule, typeof i3.FormsModule, typeof i4.ContainerDirectivesModule, typeof i5.SharedGenericModule, typeof i6.IndicatorsModule, typeof i7.ButtonsModule, typeof i8.DialogModule, typeof i9.MarkdownModule], [typeof i1.ChatComponent]>;
10
+ static ɵmod: i0.ɵɵNgModuleDeclaration<ChatModule, [typeof i1.ChatComponent], [typeof i2.CommonModule, typeof i3.FormsModule, typeof i4.ContainerDirectivesModule, typeof i5.SharedGenericModule, typeof i6.MarkdownModule], [typeof i1.ChatComponent]>;
14
11
  static ɵinj: i0.ɵɵInjectorDeclaration<ChatModule>;
15
12
  }
16
13
  //# sourceMappingURL=module.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../src/lib/module.ts"],"names":[],"mappings":";;;;;;;;;;AAeA,qBAkBa,UAAU;yCAAV,UAAU;0CAAV,UAAU;0CAAV,UAAU;CAAI"}
1
+ {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../src/lib/module.ts"],"names":[],"mappings":";;;;;;;AAYA,qBAea,UAAU;yCAAV,UAAU;0CAAV,UAAU;0CAAV,UAAU;CAAI"}
@@ -7,9 +7,6 @@ import { MarkdownModule } from '@memberjunction/ng-markdown';
7
7
  import { ChatComponent } from './chat/chat.component';
8
8
  import { ContainerDirectivesModule } from '@memberjunction/ng-container-directives';
9
9
  import { SharedGenericModule } from '@memberjunction/ng-shared-generic';
10
- import { IndicatorsModule } from '@progress/kendo-angular-indicators';
11
- import { ButtonsModule } from '@progress/kendo-angular-buttons';
12
- import { DialogModule } from '@progress/kendo-angular-dialog';
13
10
  import * as i0 from "@angular/core";
14
11
  export class ChatModule {
15
12
  static ɵfac = function ChatModule_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || ChatModule)(); };
@@ -18,9 +15,6 @@ export class ChatModule {
18
15
  FormsModule,
19
16
  ContainerDirectivesModule,
20
17
  SharedGenericModule,
21
- IndicatorsModule,
22
- ButtonsModule,
23
- DialogModule,
24
18
  MarkdownModule] });
25
19
  }
26
20
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ChatModule, [{
@@ -34,9 +28,6 @@ export class ChatModule {
34
28
  FormsModule,
35
29
  ContainerDirectivesModule,
36
30
  SharedGenericModule,
37
- IndicatorsModule,
38
- ButtonsModule,
39
- DialogModule,
40
31
  MarkdownModule
41
32
  ],
42
33
  exports: [
@@ -48,8 +39,5 @@ export class ChatModule {
48
39
  FormsModule,
49
40
  ContainerDirectivesModule,
50
41
  SharedGenericModule,
51
- IndicatorsModule,
52
- ButtonsModule,
53
- DialogModule,
54
42
  MarkdownModule], exports: [ChatComponent] }); })();
55
43
  //# sourceMappingURL=module.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"module.js","sourceRoot":"","sources":["../../src/lib/module.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,WAAW;AACX,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAE7D,QAAQ;AACR,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACtD,OAAO,EAAE,yBAAyB,EAAE,MAAM,yCAAyC,CAAC;AACpF,OAAO,EAAE,mBAAmB,EAAE,MAAM,mCAAmC,CAAC;AACxE,OAAO,EAAE,gBAAgB,EAAE,MAAM,oCAAoC,CAAC;AACtE,OAAO,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAC;AAChE,OAAO,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;;AAoB9D,MAAM,OAAO,UAAU;oGAAV,UAAU;4DAAV,UAAU;gEAbnB,YAAY;YACZ,WAAW;YACX,yBAAyB;YACzB,mBAAmB;YACnB,gBAAgB;YAChB,aAAa;YACb,YAAY;YACZ,cAAc;;iFAML,UAAU;cAlBtB,QAAQ;eAAC;gBACR,YAAY,EAAE;oBACZ,aAAa;iBACd;gBACD,OAAO,EAAE;oBACP,YAAY;oBACZ,WAAW;oBACX,yBAAyB;oBACzB,mBAAmB;oBACnB,gBAAgB;oBAChB,aAAa;oBACb,YAAY;oBACZ,cAAc;iBACf;gBACD,OAAO,EAAE;oBACP,aAAa;iBACd;aACF;;wFACY,UAAU,mBAhBnB,aAAa,aAGb,YAAY;QACZ,WAAW;QACX,yBAAyB;QACzB,mBAAmB;QACnB,gBAAgB;QAChB,aAAa;QACb,YAAY;QACZ,cAAc,aAGd,aAAa","sourcesContent":["import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormsModule } from '@angular/forms';\n\n// Markdown\nimport { MarkdownModule } from '@memberjunction/ng-markdown';\n\n// LOCAL\nimport { ChatComponent } from './chat/chat.component';\nimport { ContainerDirectivesModule } from '@memberjunction/ng-container-directives';\nimport { SharedGenericModule } from '@memberjunction/ng-shared-generic';\nimport { IndicatorsModule } from '@progress/kendo-angular-indicators';\nimport { ButtonsModule } from '@progress/kendo-angular-buttons';\nimport { DialogModule } from '@progress/kendo-angular-dialog';\n\n@NgModule({\n declarations: [\n ChatComponent\n ],\n imports: [\n CommonModule,\n FormsModule,\n ContainerDirectivesModule,\n SharedGenericModule,\n IndicatorsModule,\n ButtonsModule,\n DialogModule,\n MarkdownModule\n ],\n exports: [\n ChatComponent\n ]\n})\nexport class ChatModule { }"]}
1
+ {"version":3,"file":"module.js","sourceRoot":"","sources":["../../src/lib/module.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,WAAW;AACX,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAE7D,QAAQ;AACR,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACtD,OAAO,EAAE,yBAAyB,EAAE,MAAM,yCAAyC,CAAC;AACpF,OAAO,EAAE,mBAAmB,EAAE,MAAM,mCAAmC,CAAC;;AAiBxE,MAAM,OAAO,UAAU;oGAAV,UAAU;4DAAV,UAAU;gEAVnB,YAAY;YACZ,WAAW;YACX,yBAAyB;YACzB,mBAAmB;YACnB,cAAc;;iFAML,UAAU;cAftB,QAAQ;eAAC;gBACR,YAAY,EAAE;oBACZ,aAAa;iBACd;gBACD,OAAO,EAAE;oBACP,YAAY;oBACZ,WAAW;oBACX,yBAAyB;oBACzB,mBAAmB;oBACnB,cAAc;iBACf;gBACD,OAAO,EAAE;oBACP,aAAa;iBACd;aACF;;wFACY,UAAU,mBAbnB,aAAa,aAGb,YAAY;QACZ,WAAW;QACX,yBAAyB;QACzB,mBAAmB;QACnB,cAAc,aAGd,aAAa","sourcesContent":["import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormsModule } from '@angular/forms';\n\n// Markdown\nimport { MarkdownModule } from '@memberjunction/ng-markdown';\n\n// LOCAL\nimport { ChatComponent } from './chat/chat.component';\nimport { ContainerDirectivesModule } from '@memberjunction/ng-container-directives';\nimport { SharedGenericModule } from '@memberjunction/ng-shared-generic';\n\n@NgModule({\n declarations: [\n ChatComponent\n ],\n imports: [\n CommonModule,\n FormsModule,\n ContainerDirectivesModule,\n SharedGenericModule,\n MarkdownModule\n ],\n exports: [\n ChatComponent\n ]\n})\nexport class ChatModule { }"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@memberjunction/ng-chat",
3
- "version": "5.21.0",
3
+ "version": "5.22.0",
4
4
  "description": "MemberJunction: Reusable Chat Component - can be used for AI or peer to peer chat applications.",
5
5
  "main": "./dist/public-api.js",
6
6
  "typings": "./dist/public-api.d.ts",
@@ -26,14 +26,11 @@
26
26
  "@angular/forms": "21.1.3"
27
27
  },
28
28
  "dependencies": {
29
- "@memberjunction/core": "5.21.0",
30
- "@memberjunction/ng-container-directives": "5.21.0",
31
- "@memberjunction/ng-shared-generic": "5.21.0",
32
- "@progress/kendo-angular-indicators": "22.0.1",
33
- "@progress/kendo-angular-buttons": "22.0.1",
34
- "@progress/kendo-angular-dialog": "22.0.1",
29
+ "@memberjunction/core": "5.22.0",
30
+ "@memberjunction/ng-container-directives": "5.22.0",
31
+ "@memberjunction/ng-shared-generic": "5.22.0",
35
32
  "tslib": "^2.8.1",
36
- "@memberjunction/ng-markdown": "5.21.0"
33
+ "@memberjunction/ng-markdown": "5.22.0"
37
34
  },
38
35
  "sideEffects": false,
39
36
  "repository": {