cmcts-c-agent-embedding 1.0.2 → 1.0.3-vpcp

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. package/.env +1 -1
  2. package/.idea/AugmentWebviewStateStore.xml +10 -0
  3. package/NUNITO_FONT_IMPLEMENTATION.md +128 -0
  4. package/README.md +1 -1
  5. package/dist/components/Badge.d.ts.map +1 -1
  6. package/dist/components/Bot.d.ts +8 -0
  7. package/dist/components/Bot.d.ts.map +1 -1
  8. package/dist/components/FeedbackContentDialog.d.ts +3 -0
  9. package/dist/components/FeedbackContentDialog.d.ts.map +1 -1
  10. package/dist/components/Toast.d.ts +10 -0
  11. package/dist/components/Toast.d.ts.map +1 -0
  12. package/dist/components/avatars/DefaultAvatar.d.ts.map +1 -1
  13. package/dist/components/bubbles/BotBubble.d.ts +7 -0
  14. package/dist/components/bubbles/BotBubble.d.ts.map +1 -1
  15. package/dist/components/bubbles/GuestBubble.d.ts.map +1 -1
  16. package/dist/components/bubbles/LoadingBubble.d.ts.map +1 -1
  17. package/dist/components/bubbles/SourceBubble.d.ts +1 -0
  18. package/dist/components/bubbles/SourceBubble.d.ts.map +1 -1
  19. package/dist/components/buttons/FeedbackButtons.d.ts +1 -0
  20. package/dist/components/buttons/FeedbackButtons.d.ts.map +1 -1
  21. package/dist/components/buttons/SendButton.d.ts.map +1 -1
  22. package/dist/components/icons/CmcIcon.d.ts +3 -0
  23. package/dist/components/icons/CmcIcon.d.ts.map +1 -0
  24. package/dist/components/icons/FullScreenIcon.d.ts +3 -0
  25. package/dist/components/icons/FullScreenIcon.d.ts.map +1 -0
  26. package/dist/components/icons/ResetBtn.d.ts +3 -0
  27. package/dist/components/icons/ResetBtn.d.ts.map +1 -0
  28. package/dist/components/icons/SendIconOff.d.ts +3 -0
  29. package/dist/components/icons/SendIconOff.d.ts.map +1 -0
  30. package/dist/components/icons/SendIconOn.d.ts +3 -0
  31. package/dist/components/icons/SendIconOn.d.ts.map +1 -0
  32. package/dist/components/icons/ThumbsDownIcon.d.ts +3 -1
  33. package/dist/components/icons/ThumbsDownIcon.d.ts.map +1 -1
  34. package/dist/components/icons/ThumbsUpIcon.d.ts +3 -1
  35. package/dist/components/icons/ThumbsUpIcon.d.ts.map +1 -1
  36. package/dist/components/icons/index.d.ts +1 -1
  37. package/dist/components/icons/index.d.ts.map +1 -1
  38. package/dist/components/image/PreviewImage.d.ts +5 -0
  39. package/dist/components/image/PreviewImage.d.ts.map +1 -0
  40. package/dist/components/inputs/textInput/components/ShortTextInput.d.ts +1 -0
  41. package/dist/components/inputs/textInput/components/ShortTextInput.d.ts.map +1 -1
  42. package/dist/components/inputs/textInput/components/TextInput.d.ts +8 -2
  43. package/dist/components/inputs/textInput/components/TextInput.d.ts.map +1 -1
  44. package/dist/constants.d.ts.map +1 -1
  45. package/dist/features/bubble/components/Bubble.d.ts.map +1 -1
  46. package/dist/features/bubble/components/BubbleButton.d.ts.map +1 -1
  47. package/dist/features/bubble/types.d.ts +1 -0
  48. package/dist/features/bubble/types.d.ts.map +1 -1
  49. package/dist/features/full/components/Full.d.ts.map +1 -1
  50. package/dist/features/popup/components/Popup.d.ts.map +1 -1
  51. package/dist/queries/sendMessageQuery.d.ts +37 -1
  52. package/dist/queries/sendMessageQuery.d.ts.map +1 -1
  53. package/dist/utils/isMobileSignal.d.ts +3 -1
  54. package/dist/utils/isMobileSignal.d.ts.map +1 -1
  55. package/dist/utils/ultimateJsonParser.d.ts +2 -0
  56. package/dist/utils/ultimateJsonParser.d.ts.map +1 -0
  57. package/dist/web.d.ts +4 -0
  58. package/dist/web.d.ts.map +1 -1
  59. package/dist/web.js +1 -1
  60. package/dist/window.d.ts +2 -0
  61. package/dist/window.d.ts.map +1 -1
  62. package/package.json +6 -3
  63. package/public/icon_bot.png +0 -0
  64. package/public/index.html +139 -128
  65. package/public/logo.png +0 -0
  66. package/.husky/pre-commit +0 -18
  67. package/a.json +0 -57
  68. package/bun.lockb +0 -0
  69. package/dist/BubbleChat.d.ts +0 -13
  70. package/dist/BubbleChat.d.ts.map +0 -1
  71. package/dist/FullPageChat.d.ts +0 -18
  72. package/dist/FullPageChat.d.ts.map +0 -1
  73. package/dist/components/ImageUploadButton.d.ts +0 -11
  74. package/dist/components/ImageUploadButton.d.ts.map +0 -1
  75. package/dist/components/RecordAudioButton.d.ts +0 -11
  76. package/dist/components/RecordAudioButton.d.ts.map +0 -1
  77. package/dist/components/SendButton.d.ts +0 -12
  78. package/dist/components/SendButton.d.ts.map +0 -1
  79. package/dist/index.js +0 -1
  80. package/test.html +0 -17
package/dist/window.d.ts CHANGED
@@ -8,6 +8,8 @@ type BotProps = {
8
8
  observersConfig?: observersConfigType;
9
9
  theme?: BubbleTheme;
10
10
  chatwootUrl?: string;
11
+ roomIds?: Record<string, string>;
12
+ isUseFAQ?: undefined;
11
13
  };
12
14
  export declare const initFull: (props: BotProps & {
13
15
  id?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"window.d.ts","sourceRoot":"","sources":["../src/window.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAGtD,KAAK,QAAQ,GAAG;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,CAAC,OAAO,EAAE,WAAW,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACpD,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACzC,eAAe,CAAC,EAAE,mBAAmB,CAAC;IACtC,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAIF,eAAO,MAAM,QAAQ,UAAW,QAAQ,GAAG;IAAE,EAAE,CAAC,EAAE,MAAM,CAAA;CAAE,SAMzD,CAAC;AAEF,eAAO,MAAM,IAAI,UAAW,QAAQ,SAMnC,CAAC;AAEF,eAAO,MAAM,OAAO,YAEnB,CAAC;AAEF,KAAK,OAAO,GAAG;IACb,QAAQ,EAAE,OAAO,QAAQ,CAAC;IAC1B,IAAI,EAAE,OAAO,IAAI,CAAC;IAClB,OAAO,EAAE,OAAO,OAAO,CAAC;CACzB,CAAC;AAQF,eAAO,MAAM,YAAY;sBAhCO,QAAQ,GAAG;QAAE,EAAE,CAAC,EAAE,MAAM,CAAA;KAAE;kBAQ9B,QAAQ;;CA4BlC,CAAC;AAEH,eAAO,MAAM,qBAAqB,QAAS,OAAO,SAGjD,CAAC"}
1
+ {"version":3,"file":"window.d.ts","sourceRoot":"","sources":["../src/window.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAGtD,KAAK,QAAQ,GAAG;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,CAAC,OAAO,EAAE,WAAW,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACpD,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACzC,eAAe,CAAC,EAAE,mBAAmB,CAAC;IACtC,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB,CAAC;AAIF,eAAO,MAAM,QAAQ,UAAW,QAAQ,GAAG;IAAE,EAAE,CAAC,EAAE,MAAM,CAAA;CAAE,SAMzD,CAAC;AAEF,eAAO,MAAM,IAAI,UAAW,QAAQ,SAMnC,CAAC;AAEF,eAAO,MAAM,OAAO,YAEnB,CAAC;AAEF,KAAK,OAAO,GAAG;IACb,QAAQ,EAAE,OAAO,QAAQ,CAAC;IAC1B,IAAI,EAAE,OAAO,IAAI,CAAC;IAClB,OAAO,EAAE,OAAO,OAAO,CAAC;CACzB,CAAC;AAQF,eAAO,MAAM,YAAY;sBAhCO,QAAQ,GAAG;QAAE,EAAE,CAAC,EAAE,MAAM,CAAA;KAAE;kBAQ9B,QAAQ;;CA4BlC,CAAC;AAEH,eAAO,MAAM,qBAAqB,QAAS,OAAO,SAGjD,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cmcts-c-agent-embedding",
3
- "version": "1.0.2",
3
+ "version": "1.0.3-vpcp",
4
4
  "description": "Javascript library to display flowise chatbot on your website",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -13,13 +13,15 @@
13
13
  "format": "prettier --write \"**/*.{js,jsx,ts,tsx,md,mdx}\"",
14
14
  "format:check": "prettier --check \"**/*.{js,jsx,ts,tsx,md,mdx}\"",
15
15
  "prepare": "husky install",
16
- "start": "node server.js"
16
+ "start": "node server.js",
17
+ "build-and-publish": "yarn build && npm publish"
17
18
  },
18
19
  "license": "MIT",
19
20
  "dependencies": {
20
21
  "@babel/core": "^7.22.1",
21
22
  "@microsoft/fetch-event-source": "^2.0.1",
22
23
  "@ts-stack/markdown": "^1.4.0",
24
+ "@types/pdfjs-dist": "^2.10.378",
23
25
  "axios": "^1.7.7",
24
26
  "c-agent-embedding": "^1.0.4",
25
27
  "c-agent-embedding-react": "^1.0.1",
@@ -32,6 +34,7 @@
32
34
  "lodash": "^4.17.21",
33
35
  "multer": "^1.4.5-lts.1",
34
36
  "node-fetch": "^3.3.2",
37
+ "pdfjs-dist": "3.11.174",
35
38
  "prettier": "^3.4.2",
36
39
  "solid-element": "1.7.0",
37
40
  "solid-js": "1.7.1",
@@ -74,4 +77,4 @@
74
77
  "uuid": "^9.0.1"
75
78
  },
76
79
  "packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
77
- }
80
+ }
Binary file
package/public/index.html CHANGED
@@ -8,139 +8,150 @@
8
8
 
9
9
  <!doctype html>
10
10
  <html lang="en">
11
- <head>
12
- <meta charset="UTF-8" />
13
- <meta name="viewport" content="width=device-width, initial-scale=1.0" />
14
- <title>Flowise Chatbot Widget</title>
15
- </head>
16
11
 
17
- <body>
18
- <div id="root">
19
- <flowise-fullchatbot></flowise-fullchatbot>
20
- </div>
21
- <script type="module">
22
- import Chatbot from './web.js';
12
+ <head>
13
+ <meta charset="UTF-8" />
14
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
15
+ <title>Flowise Chatbot Widget</title>
16
+ <!-- Preload Nunito font for better performance -->
17
+ <link rel="preconnect" href="https://fonts.googleapis.com">
18
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
19
+ <link href="https://fonts.googleapis.com/css2?family=Nunito:ital,wght@0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap" rel="stylesheet">
20
+ </head>
23
21
 
24
- const customStringify = (obj) => {
25
- let stringified = JSON.stringify(obj, null, 4)
26
- .replace(/"([^"]+)":/g, '$1:')
27
- .replace(/: "([^"]+)"/g, (match, value) => (value.includes('<') ? `: "${value}"` : `: '${value}'`))
28
- .replace(/: "(true|false|\d+)"/g, ': $1')
29
- .replace(/customCSS: ""/g, 'customCSS: ``');
30
- return stringified
31
- .split('\n')
32
- .map((line, index) => {
33
- if (index === 0) return line;
34
- return ' '.repeat(8) + line;
35
- })
36
- .join('\n');
37
- };
22
+ <body>
23
+ <div id="root">
24
+ <flowise-fullchatbot></flowise-fullchatbot>
25
+ </div>
26
+ <script type="module">
27
+ import Chatbot from './web.js';
38
28
 
39
- // Example initialization:
40
- // If your .env contains:
41
- // agent1=xyz789-uvw456,https://example.com
42
- // support=abc123-def456,https://example.com
43
- // salesbot=ghi123-jkl456,https://example.com
44
- //
45
- // Then use the environment variable name as chatflowid:
46
- Chatbot.initFull({
47
- // chatflowid: '6a63bb88-88f7-4c4d-805e-9c027c85707b', // or 'support', 'salesbot', etc.
48
- chatflowid: 'b573e66d-0e28-4798-8e4f-fbbaff8e236f', // or 'support', 'salesbot', etc.
49
- // apiHost: 'https://stock.cmcts.ai/c-agent',
50
- apiHost: 'http://localhost:3003',
51
- chatwootUrl: 'http://203.145.47.214:8003',
52
- theme: customStringify({
53
- button: {
54
- backgroundColor: '#3B81F6',
55
- right: 20,
56
- bottom: 20,
57
- size: 48,
58
- dragAndDrop: true,
59
- iconColor: 'white',
60
- customIconSrc: 'https://raw.githubusercontent.com/walkxcode/dashboard-icons/main/svg/google-messages.svg',
61
- autoWindowOpen: {
62
- autoOpen: true,
63
- openDelay: 2,
64
- autoOpenOnMobile: false,
65
- },
29
+ const customStringify = (obj) => {
30
+ let stringified = JSON.stringify(obj, null, 4)
31
+ .replace(/"([^"]+)":/g, '$1:')
32
+ .replace(/: "([^"]+)"/g, (match, value) => (value.includes('<') ? `: "${value}"` : `: '${value}'`))
33
+ .replace(/: "(true|false|\d+)"/g, ': $1')
34
+ .replace(/customCSS: ""/g, 'customCSS: ``');
35
+ return stringified
36
+ .split('\n')
37
+ .map((line, index) => {
38
+ if (index === 0) return line;
39
+ return ' '.repeat(8) + line;
40
+ })
41
+ .join('\n');
42
+ };
43
+
44
+ // Example initialization:
45
+ // If your .env contains:
46
+ // agent1=xyz789-uvw456,https://example.com
47
+ // support=abc123-def456,https://example.com
48
+ // salesbot=ghi123-jkl456,https://example.com
49
+ //
50
+ // Then use the environment variable name as chatflowid:
51
+ Chatbot.initFull({
52
+ // chatflowid: '6a63bb88-88f7-4c4d-805e-9c027c85707b', // or 'support', 'salesbot', etc.
53
+ // chatflowid: 'b573e66d-0e28-4798-8e4f-fbbaff8e236f', // or 'support', 'salesbot', etc.
54
+ // chatflowid: '7ee803b4-e3f8-4f33-bf85-ef9ab9d6f693', // or 'support', 'salesbot', etc.
55
+ chatflowid: '1755164d-cb72-4325-9831-83b295ce42bc', // or 'support', 'salesbot', etc.
56
+ apiHost: 'https://vib.cagent.cmcts.ai',
57
+ // apiHost: 'https://c-agent.cmcts.studio.ai.vn',
58
+ chatwootUrl: 'https://livechat.cagent.cmcts.ai',
59
+ roomIds: {
60
+ '0123456789': 'Xa6HmhfbU5K73ZhHnspzKhqs',
61
+ },
62
+ theme: customStringify({
63
+ button: {
64
+ backgroundColor: '#3B81F6',
65
+ right: 20,
66
+ bottom: 20,
67
+ size: 48,
68
+ dragAndDrop: true,
69
+ iconColor: 'white',
70
+ customIconSrc: 'https://raw.githubusercontent.com/walkxcode/dashboard-icons/main/svg/google-messages.svg',
71
+ autoWindowOpen: {
72
+ autoOpen: true,
73
+ openDelay: 2,
74
+ autoOpenOnMobile: false,
66
75
  },
67
- tooltip: {
68
- showTooltip: true,
69
- tooltipMessage: 'Hi There 👋!',
70
- tooltipBackgroundColor: 'black',
71
- tooltipTextColor: 'white',
72
- tooltipFontSize: 16,
76
+ },
77
+ tooltip: {
78
+ showTooltip: true,
79
+ tooltipMessage: 'Hi There 👋!',
80
+ tooltipBackgroundColor: 'black',
81
+ tooltipTextColor: 'white',
82
+ tooltipFontSize: 16,
83
+ },
84
+ disclaimer: {
85
+ title: 'Disclaimer',
86
+ message: 'By using this chatbot, you agree to the <a target="_blank" href="https://flowiseai.com/terms">Terms & Condition</a>',
87
+ textColor: 'black',
88
+ buttonColor: '#3b82f6',
89
+ buttonText: 'Start Chatting',
90
+ buttonTextColor: 'white',
91
+ blurredBackgroundColor: 'rgba(0, 0, 0, 0.4)',
92
+ backgroundColor: 'white',
93
+ },
94
+ customCSS: ``,
95
+ chatWindow: {
96
+ showTitle: true,
97
+ showAgentMessages: true,
98
+ title: 'Agent Studio Bot',
99
+ titleAvatarSrc: 'https://raw.githubusercontent.com/walkxcode/dashboard-icons/main/svg/google-messages.svg',
100
+ welcomeMessage: 'Hello! This is custom welcome message',
101
+ errorMessage: 'This is a custom error message',
102
+ backgroundColor: '#ffffff',
103
+ backgroundImage: 'enter image path or link',
104
+ height: 700,
105
+ width: 400,
106
+ fontSize: 16,
107
+ starterPrompts: ['What is a bot?', 'Who are you?'],
108
+ starterPromptFontSize: 15,
109
+ clearChatOnReload: false,
110
+ sourceDocsTitle: 'Sources:',
111
+ renderHTML: true,
112
+ botMessage: {
113
+ backgroundColor: '#f7f8ff',
114
+ textColor: '#303235',
115
+ showAvatar: true,
116
+ avatarSrc: 'https://raw.githubusercontent.com/zahidkhawaja/langchain-chat-nextjs/main/public/parroticon.png',
73
117
  },
74
- disclaimer: {
75
- title: 'Disclaimer',
76
- message: 'By using this chatbot, you agree to the <a target="_blank" href="https://flowiseai.com/terms">Terms & Condition</a>',
77
- textColor: 'black',
78
- buttonColor: '#3b82f6',
79
- buttonText: 'Start Chatting',
80
- buttonTextColor: 'white',
81
- blurredBackgroundColor: 'rgba(0, 0, 0, 0.4)',
82
- backgroundColor: 'white',
118
+ userMessage: {
119
+ backgroundColor: '#3B81F6',
120
+ textColor: '#ffffff',
121
+ showAvatar: true,
122
+ avatarSrc: 'https://raw.githubusercontent.com/zahidkhawaja/langchain-chat-nextjs/main/public/usericon.png',
83
123
  },
84
- customCSS: ``,
85
- chatWindow: {
86
- showTitle: true,
87
- showAgentMessages: true,
88
- title: 'Agent Studio Bot',
89
- titleAvatarSrc: 'https://raw.githubusercontent.com/walkxcode/dashboard-icons/main/svg/google-messages.svg',
90
- welcomeMessage: 'Hello! This is custom welcome message',
91
- errorMessage: 'This is a custom error message',
124
+ textInput: {
125
+ placeholder: 'Type your question',
92
126
  backgroundColor: '#ffffff',
93
- backgroundImage: 'enter image path or link',
94
- height: 700,
95
- width: 400,
96
- fontSize: 16,
97
- starterPrompts: ['What is a bot?', 'Who are you?'],
98
- starterPromptFontSize: 15,
99
- clearChatOnReload: false,
100
- sourceDocsTitle: 'Sources:',
101
- renderHTML: true,
102
- botMessage: {
103
- backgroundColor: '#f7f8ff',
104
- textColor: '#303235',
105
- showAvatar: true,
106
- avatarSrc: 'https://raw.githubusercontent.com/zahidkhawaja/langchain-chat-nextjs/main/public/parroticon.png',
107
- },
108
- userMessage: {
109
- backgroundColor: '#3B81F6',
110
- textColor: '#ffffff',
111
- showAvatar: true,
112
- avatarSrc: 'https://raw.githubusercontent.com/zahidkhawaja/langchain-chat-nextjs/main/public/usericon.png',
113
- },
114
- textInput: {
115
- placeholder: 'Type your question',
116
- backgroundColor: '#ffffff',
117
- textColor: '#303235',
118
- sendButtonColor: '#3B81F6',
119
- maxChars: 50,
120
- maxCharsWarningMessage: 'You exceeded the characters limit. Please input less than 50 characters.',
121
- autoFocus: true,
122
- sendMessageSound: true,
123
- sendSoundLocation: 'send_message.mp3',
124
- receiveMessageSound: true,
125
- receiveSoundLocation: 'receive_message.mp3',
126
- },
127
- feedback: {
128
- color: '#303235',
129
- },
130
- dateTimeToggle: {
131
- date: true,
132
- time: true,
133
- },
134
- footer: {
135
- textColor: '#303235',
136
- text: 'Powered by',
137
- company: 'Agent Studio',
138
- // companyLink: 'https://flowiseai.com'
139
- companyLink: '#',
140
- },
127
+ textColor: '#303235',
128
+ sendButtonColor: '#3B81F6',
129
+ maxChars: 50,
130
+ maxCharsWarningMessage: 'You exceeded the characters limit. Please input less than 50 characters.',
131
+ autoFocus: true,
132
+ sendMessageSound: true,
133
+ sendSoundLocation: 'send_message.mp3',
134
+ receiveMessageSound: true,
135
+ receiveSoundLocation: 'receive_message.mp3',
136
+ },
137
+ feedback: {
138
+ color: '#303235',
141
139
  },
142
- }),
143
- });
144
- </script>
145
- </body>
146
- </html>
140
+ dateTimeToggle: {
141
+ date: true,
142
+ time: true,
143
+ },
144
+ footer: {
145
+ textColor: '#303235',
146
+ text: 'Powered by',
147
+ company: 'Agent Studio',
148
+ // companyLink: 'https://flowiseai.com'
149
+ companyLink: '#',
150
+ },
151
+ },
152
+ }),
153
+ });
154
+ </script>
155
+ </body>
156
+
157
+ </html>
Binary file
package/.husky/pre-commit DELETED
@@ -1,18 +0,0 @@
1
- #!/usr/bin/env sh
2
- . "$(dirname -- "$0")/_/husky.sh"
3
-
4
- set -e # Exit on any error
5
-
6
- echo "Running ESLint for linting..."
7
- npm run lint
8
-
9
- echo "Running ESLint for fixing issues..."
10
- npm run lint-fix
11
-
12
- echo "Formatting code..."
13
- npm run format
14
-
15
- echo "Checking formatting..."
16
- npm run format:check
17
-
18
- echo "Pre-commit checks passed."
package/a.json DELETED
@@ -1,57 +0,0 @@
1
- [
2
- {
3
- "agentName": "question_analyzer",
4
- "messages": [
5
- "{\"sub_requests\":[\"gọi tư vấn viên\"],\"convesation_related\":true,\"worker_call\":false,\"name\":\"Van dong\",\"phone_number\":\"0376561156\",\"human_support\":true,\"unsatisfied_times\":0}"
6
- ],
7
- "usedTools": [
8
- null
9
- ],
10
- "sourceDocuments": [
11
- null
12
- ],
13
- "artifacts": [
14
- null
15
- ],
16
- "state": {
17
- "worker_call": false,
18
- "sub_requests": [
19
- "gọi tư vấn viên"
20
- ],
21
- "current_date": "Thursday, December 26, 2024 at 05:11 AM UTC",
22
- "name": "Van dong",
23
- "phone_number": "0376561156",
24
- "human_support": true
25
- },
26
- "nodeName": "seqLLMNode",
27
- "nodeId": "seqLLMNode_0"
28
- },
29
- {
30
- "agentName": "check_call_CMC_worker",
31
- "messages": [
32
- "human_router"
33
- ],
34
- "nodeName": "seqCondition",
35
- "nodeId": "seqCondition_0"
36
- },
37
- {
38
- "agentName": "human_router",
39
- "messages": [
40
- "{\"assistant_phone_number\":\"034567812\",\"assistant_name\":\"Huy - Tư vấn viên học phí, học bổng\"}"
41
- ],
42
- "usedTools": [
43
- null
44
- ],
45
- "sourceDocuments": [
46
- null
47
- ],
48
- "artifacts": [
49
- null
50
- ],
51
- "state": {
52
- "human_support": false
53
- },
54
- "nodeName": "seqLLMNode",
55
- "nodeId": "seqLLMNode_3"
56
- }
57
- ]
package/bun.lockb DELETED
Binary file
@@ -1,13 +0,0 @@
1
- /// <reference types="react" />
2
- import type { BubbleProps } from 'cmcts-c-agent-embedding';
3
- type Props = BubbleProps;
4
- declare global {
5
- namespace JSX {
6
- interface IntrinsicElements {
7
- 'flowise-chatbot': React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>;
8
- }
9
- }
10
- }
11
- export declare const BubbleChat: (props: Props) => null;
12
- export {};
13
- //# sourceMappingURL=BubbleChat.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"BubbleChat.d.ts","sourceRoot":"","sources":["../src/BubbleChat.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAG1D,KAAK,KAAK,GAAG,WAAW,CAAA;AAExB,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,GAAG,CAAC;QACZ,UAAU,iBAAiB;YACzB,iBAAiB,EAAE,KAAK,CAAC,iBAAiB,CACxC,KAAK,CAAC,cAAc,CAAC,WAAW,CAAC,EACjC,WAAW,CACZ,CAAA;SACF;KACF;CACF;AAID,eAAO,MAAM,UAAU,UAAW,KAAK,SAkCtC,CAAA"}
@@ -1,18 +0,0 @@
1
- /// <reference types="react" />
2
- import type { BotProps } from 'cmcts-c-agent-embedding';
3
- type Props = BotProps & {
4
- style?: React.CSSProperties;
5
- className?: string;
6
- };
7
- declare global {
8
- namespace JSX {
9
- interface IntrinsicElements {
10
- 'flowise-fullchatbot': React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement> & {
11
- class?: string;
12
- };
13
- }
14
- }
15
- }
16
- export declare const FullPageChat: ({ style, className, ...assignableProps }: Props) => JSX.Element;
17
- export {};
18
- //# sourceMappingURL=FullPageChat.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"FullPageChat.d.ts","sourceRoot":"","sources":["../src/FullPageChat.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAA;AAGvD,KAAK,KAAK,GAAG,QAAQ,GAAG;IACtB,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAA;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,GAAG,CAAC;QACZ,UAAU,iBAAiB;YACzB,qBAAqB,EAAE,KAAK,CAAC,iBAAiB,CAC5C,KAAK,CAAC,cAAc,CAAC,WAAW,CAAC,EACjC,WAAW,CACZ,GAAG;gBAAE,KAAK,CAAC,EAAE,MAAM,CAAA;aAAE,CAAA;SACvB;KACF;CACF;AAID,eAAO,MAAM,YAAY,6CAA8C,KAAK,gBAe3E,CAAA"}
@@ -1,11 +0,0 @@
1
- import { JSX } from 'solid-js/jsx-runtime';
2
- type ImageUploadButtonProps = {
3
- buttonColor?: string;
4
- isDisabled?: boolean;
5
- isLoading?: boolean;
6
- disableIcon?: boolean;
7
- } & JSX.ButtonHTMLAttributes<HTMLButtonElement>;
8
- export declare const ImageUploadButton: (props: ImageUploadButtonProps) => JSX.Element;
9
- export declare const Spinner: (props: JSX.SvgSVGAttributes<SVGSVGElement>) => JSX.Element;
10
- export {};
11
- //# sourceMappingURL=ImageUploadButton.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ImageUploadButton.d.ts","sourceRoot":"","sources":["../../src/components/ImageUploadButton.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAG3C,KAAK,sBAAsB,GAAG;IAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB,GAAG,GAAG,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,CAAC;AAEhD,eAAO,MAAM,iBAAiB,UAAW,sBAAsB,gBAiB9D,CAAC;AAEF,eAAO,MAAM,OAAO,UAAW,IAAI,gBAAgB,CAAC,aAAa,CAAC,gBAgBjE,CAAC"}
@@ -1,11 +0,0 @@
1
- import { JSX } from 'solid-js/jsx-runtime';
2
- type RecordAudioButtonProps = {
3
- buttonColor?: string;
4
- isDisabled?: boolean;
5
- isLoading?: boolean;
6
- disableIcon?: boolean;
7
- } & JSX.ButtonHTMLAttributes<HTMLButtonElement>;
8
- export declare const RecordAudioButton: (props: RecordAudioButtonProps) => JSX.Element;
9
- export declare const Spinner: (props: JSX.SvgSVGAttributes<SVGSVGElement>) => JSX.Element;
10
- export {};
11
- //# sourceMappingURL=RecordAudioButton.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RecordAudioButton.d.ts","sourceRoot":"","sources":["../../src/components/RecordAudioButton.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAG3C,KAAK,sBAAsB,GAAG;IAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB,GAAG,GAAG,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,CAAC;AAEhD,eAAO,MAAM,iBAAiB,UAAW,sBAAsB,gBAiB9D,CAAC;AAEF,eAAO,MAAM,OAAO,UAAW,IAAI,gBAAgB,CAAC,aAAa,CAAC,gBAgBjE,CAAC"}
@@ -1,12 +0,0 @@
1
- import { JSX } from 'solid-js/jsx-runtime';
2
- type SendButtonProps = {
3
- sendButtonColor?: string;
4
- isDisabled?: boolean;
5
- isLoading?: boolean;
6
- disableIcon?: boolean;
7
- } & JSX.ButtonHTMLAttributes<HTMLButtonElement>;
8
- export declare const SendButton: (props: SendButtonProps) => JSX.Element;
9
- export declare const DeleteButton: (props: SendButtonProps) => JSX.Element;
10
- export declare const Spinner: (props: JSX.SvgSVGAttributes<SVGSVGElement>) => JSX.Element;
11
- export {};
12
- //# sourceMappingURL=SendButton.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"SendButton.d.ts","sourceRoot":"","sources":["../../src/components/SendButton.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAI3C,KAAK,eAAe,GAAG;IACrB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB,GAAG,GAAG,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,CAAC;AAEhD,eAAO,MAAM,UAAU,UAAW,eAAe,gBAiBhD,CAAC;AACF,eAAO,MAAM,YAAY,UAAW,eAAe,gBAkBlD,CAAC;AAEF,eAAO,MAAM,OAAO,UAAW,IAAI,gBAAgB,CAAC,aAAa,CAAC,gBAgBjE,CAAC"}