bibot 1.0.42 → 1.0.45

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.
@@ -1,11 +1,8 @@
1
1
  import React from 'react';
2
- import { BiBotProps, ChatBubbleConfigProps, predefinedQuestionsType } from '../types/coreInterfaces';
2
+ import { BiBotProps, ChatBubbleConfigProps, MESSAGES, predefinedQuestionsType } from '../types/coreInterfaces';
3
3
  declare const useBiBotChatBot: ({ clientId, client_session_id, test }: BiBotProps) => {
4
4
  chatIsOpen: boolean;
5
- messages: {
6
- sender: 'user' | 'bot';
7
- text: string;
8
- }[];
5
+ messages: MESSAGES;
9
6
  isLoading: boolean;
10
7
  messageEndRef: React.RefObject<HTMLDivElement>;
11
8
  userInput: string;
package/dist/index.js CHANGED
@@ -3637,7 +3637,8 @@ var useBiBotChatBot = function useBiBotChatBot(_ref) {
3637
3637
  client_id: clientId,
3638
3638
  q: input,
3639
3639
  session_id: client_session_id ? client_session_id : state.sessionId,
3640
- chat_id: v4()
3640
+ chat_id: v4(),
3641
+ chat_history: messages
3641
3642
  })).then(function (response) {
3642
3643
  setMessages(function (messages) {
3643
3644
  return [].concat(messages, [{