diff --git a/packages/chat-component/public/svg/bubblequestion-icon.svg b/packages/chat-component/public/svg/bubblequestion-icon.svg
new file mode 100644
index 00000000..c964c796
--- /dev/null
+++ b/packages/chat-component/public/svg/bubblequestion-icon.svg
@@ -0,0 +1,3 @@
+
\ No newline at end of file
diff --git a/packages/chat-component/public/svg/spinner-icon.svg b/packages/chat-component/public/svg/spinner-icon.svg
new file mode 100644
index 00000000..f3529891
--- /dev/null
+++ b/packages/chat-component/public/svg/spinner-icon.svg
@@ -0,0 +1,3 @@
+
\ No newline at end of file
diff --git a/packages/chat-component/src/config/global-config.js b/packages/chat-component/src/config/global-config.js
index 765c1b5c..8b610110 100644
--- a/packages/chat-component/src/config/global-config.js
+++ b/packages/chat-component/src/config/global-config.js
@@ -11,7 +11,7 @@ const globalConfig = {
'How to contact a representative?',
],
DEFAULT_PROMPTS_HEADING_CHAT: 'Chat with our support team',
- DEFAULT_PROMPTS_HEADING_ASK: 'Ask a question',
+ DEFAULT_PROMPTS_HEADING_ASK: 'Ask now',
// This are the chat bubbles that will be displayed in the chat
CHAT_MESSAGES: [],
// This are the labels for the chat button and input
@@ -30,13 +30,14 @@ const globalConfig = {
FOLLOW_UP_QUESTIONS_LABEL_TEXT: 'You can also ask...',
SHOW_THOUGH_PROCESS_BUTTON_LABEL_TEXT: 'Show thought process',
HIDE_THOUGH_PROCESS_BUTTON_LABEL_TEXT: 'Hide thought process',
- LOADING_INDICATOR_TEXT: 'Please wait. We are searching for an answer...',
+ LOADING_INDICATOR_TEXT: 'Please wait. We are searching and generating an answer...',
// API ERROR HANDLING IN UI
API_ERROR_MESSAGE: 'Sorry, we are having some problems. Please try again later.',
// Config pertaining the response format
THOUGHT_PROCESS_LABEL: 'Thought Process',
SUPPORT_CONTEXT_LABEL: 'Support Context',
- CITATIONS_LABEL: 'Citations',
+ CITATIONS_LABEL: 'Learn More:',
+ CITATIONS_TAB_LABEL: 'Citations',
};
const NEXT_QUESTION_INDICATOR = 'Next Questions:';
diff --git a/packages/chat-component/src/main.ts b/packages/chat-component/src/main.ts
index 5063b477..7fd974d2 100644
--- a/packages/chat-component/src/main.ts
+++ b/packages/chat-component/src/main.ts
@@ -18,10 +18,10 @@ import iconSuccess from '../public/svg/success-icon.svg?raw';
import iconCopyToClipboard from '../public/svg/copy-icon.svg?raw';
import iconSend from '../public/svg/send-icon.svg?raw';
import iconClose from '../public/svg/close-icon.svg?raw';
-import iconQuestion from '../public/svg/question-icon.svg?raw';
import iconMicOff from '../public/svg/mic-icon.svg?raw';
import iconMicOn from '../public/svg/mic-record-on-icon.svg?raw';
-
+import iconQuestion from '../public/svg/bubblequestion-icon.svg?raw';
+import iconSpinner from '../public/svg/spinner-icon.svg?raw';
import { marked } from 'marked';
/**
@@ -167,6 +167,7 @@ export class ChatComponent extends LitElement {
this.chatThoughts = result.thoughts;
this.chatDataPoints = result.data_points;
this.canShowThoughtProcess = true;
+
return true;
}
@@ -242,6 +243,7 @@ export class ChatComponent extends LitElement {
handleDefaultPromptClick(question: string, event?: Event): void {
event?.preventDefault();
this.questionInput.value = DOMPurify.sanitize(question);
+ this.hideThoughtProcess(event!);
this.currentQuestion = this.questionInput.value;
}
@@ -455,11 +457,11 @@ export class ChatComponent extends LitElement {
// render steps
if (textEntry.followingSteps && textEntry.followingSteps.length > 0) {
entries.push(
- html`