@botonic/react 0.55.1 → 0.57.0-rslib-esm.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.
Files changed (1207) hide show
  1. package/lib/esm/app.js +4 -5
  2. package/lib/esm/app.js.map +1 -1
  3. package/lib/esm/assets/types.d.ts +4 -0
  4. package/lib/esm/botonic-tester.js +79 -33
  5. package/lib/esm/botonic-tester.js.map +1 -1
  6. package/lib/esm/components/audio.d.ts +1 -1
  7. package/lib/esm/components/audio.js +52 -20
  8. package/lib/esm/components/audio.js.map +1 -1
  9. package/lib/esm/components/button/index.d.ts +1 -1
  10. package/lib/esm/components/button/index.js +113 -69
  11. package/lib/esm/components/button/index.js.map +1 -1
  12. package/lib/esm/components/button/styles.js +27 -25
  13. package/lib/esm/components/button/styles.js.map +1 -1
  14. package/lib/esm/components/buttons-disabler.d.ts +1 -1
  15. package/lib/esm/components/buttons-disabler.js +37 -34
  16. package/lib/esm/components/buttons-disabler.js.map +1 -1
  17. package/lib/esm/components/carousel.d.ts +1 -1
  18. package/lib/esm/components/carousel.js +143 -66
  19. package/lib/esm/components/carousel.js.map +1 -1
  20. package/lib/esm/components/components.js +5 -8
  21. package/lib/esm/components/components.js.map +1 -1
  22. package/lib/esm/components/constants.js +5 -5
  23. package/lib/esm/components/constants.js.map +1 -1
  24. package/lib/esm/components/custom-message.d.ts +1 -1
  25. package/lib/esm/components/custom-message.js +84 -35
  26. package/lib/esm/components/custom-message.js.map +1 -1
  27. package/lib/esm/components/document.d.ts +1 -1
  28. package/lib/esm/components/document.js +58 -26
  29. package/lib/esm/components/document.js.map +1 -1
  30. package/lib/esm/components/element.js +41 -29
  31. package/lib/esm/components/element.js.map +1 -1
  32. package/lib/esm/components/handoff.js +51 -29
  33. package/lib/esm/components/handoff.js.map +1 -1
  34. package/lib/esm/components/image.d.ts +1 -1
  35. package/lib/esm/components/image.js +71 -30
  36. package/lib/esm/components/image.js.map +1 -1
  37. package/lib/esm/components/index-types.d.ts +1 -1
  38. package/lib/esm/components/index-types.js +3 -2
  39. package/lib/esm/components/index-types.js.map +1 -1
  40. package/lib/esm/components/index.d.ts +33 -32
  41. package/lib/esm/components/index.js +98 -68
  42. package/lib/esm/components/index.js.map +1 -1
  43. package/lib/esm/components/location.js +57 -20
  44. package/lib/esm/components/location.js.map +1 -1
  45. package/lib/esm/components/markdown.js +53 -60
  46. package/lib/esm/components/markdown.js.map +1 -1
  47. package/lib/esm/components/message/index.js +205 -102
  48. package/lib/esm/components/message/index.js.map +1 -1
  49. package/lib/esm/components/message/message-footer.d.ts +1 -1
  50. package/lib/esm/components/message/message-footer.js +36 -18
  51. package/lib/esm/components/message/message-footer.js.map +1 -1
  52. package/lib/esm/components/message/message-image.d.ts +1 -1
  53. package/lib/esm/components/message/message-image.js +44 -24
  54. package/lib/esm/components/message/message-image.js.map +1 -1
  55. package/lib/esm/components/message/styles.js +34 -34
  56. package/lib/esm/components/message/styles.js.map +1 -1
  57. package/lib/esm/components/message/timestamps.d.ts +1 -1
  58. package/lib/esm/components/message/timestamps.js +54 -32
  59. package/lib/esm/components/message/timestamps.js.map +1 -1
  60. package/lib/esm/components/message-template.js +24 -11
  61. package/lib/esm/components/message-template.js.map +1 -1
  62. package/lib/esm/components/multichannel/facebook/facebook.js +33 -20
  63. package/lib/esm/components/multichannel/facebook/facebook.js.map +1 -1
  64. package/lib/esm/components/multichannel/index-types.js +4 -2
  65. package/lib/esm/components/multichannel/index-types.js.map +1 -1
  66. package/lib/esm/components/multichannel/index.d.ts +6 -6
  67. package/lib/esm/components/multichannel/index.js +24 -15
  68. package/lib/esm/components/multichannel/index.js.map +1 -1
  69. package/lib/esm/components/multichannel/multichannel-button.js +63 -42
  70. package/lib/esm/components/multichannel/multichannel-button.js.map +1 -1
  71. package/lib/esm/components/multichannel/multichannel-carousel.js +84 -41
  72. package/lib/esm/components/multichannel/multichannel-carousel.js.map +1 -1
  73. package/lib/esm/components/multichannel/multichannel-context.js +10 -8
  74. package/lib/esm/components/multichannel/multichannel-context.js.map +1 -1
  75. package/lib/esm/components/multichannel/multichannel-reply.js +34 -20
  76. package/lib/esm/components/multichannel/multichannel-reply.js.map +1 -1
  77. package/lib/esm/components/multichannel/multichannel-text.js +196 -94
  78. package/lib/esm/components/multichannel/multichannel-text.js.map +1 -1
  79. package/lib/esm/components/multichannel/multichannel-utils.js +22 -35
  80. package/lib/esm/components/multichannel/multichannel-utils.js.map +1 -1
  81. package/lib/esm/components/multichannel/multichannel.js +91 -43
  82. package/lib/esm/components/multichannel/multichannel.js.map +1 -1
  83. package/lib/esm/components/multichannel/whatsapp/constants.js +15 -13
  84. package/lib/esm/components/multichannel/whatsapp/constants.js.map +1 -1
  85. package/lib/esm/components/multichannel/whatsapp/markdown-meta.js +3 -3
  86. package/lib/esm/components/multichannel/whatsapp/markdown-meta.js.map +1 -1
  87. package/lib/esm/components/pic.js +46 -23
  88. package/lib/esm/components/pic.js.map +1 -1
  89. package/lib/esm/components/raw.js +65 -24
  90. package/lib/esm/components/raw.js.map +1 -1
  91. package/lib/esm/components/reply.d.ts +1 -1
  92. package/lib/esm/components/reply.js +68 -32
  93. package/lib/esm/components/reply.js.map +1 -1
  94. package/lib/esm/components/share-button.js +24 -11
  95. package/lib/esm/components/share-button.js.map +1 -1
  96. package/lib/esm/components/subtitle.js +37 -19
  97. package/lib/esm/components/subtitle.js.map +1 -1
  98. package/lib/esm/components/system-debug-trace/debug-message.d.ts +1 -1
  99. package/lib/esm/components/system-debug-trace/debug-message.js +104 -54
  100. package/lib/esm/components/system-debug-trace/debug-message.js.map +1 -1
  101. package/lib/esm/components/system-debug-trace/events/ai-agent/ai-agent.d.ts +2 -2
  102. package/lib/esm/components/system-debug-trace/events/ai-agent/ai-agent.js +121 -34
  103. package/lib/esm/components/system-debug-trace/events/ai-agent/ai-agent.js.map +1 -1
  104. package/lib/esm/components/system-debug-trace/events/ai-agent/executed-tools.d.ts +1 -1
  105. package/lib/esm/components/system-debug-trace/events/ai-agent/executed-tools.js +38 -13
  106. package/lib/esm/components/system-debug-trace/events/ai-agent/executed-tools.js.map +1 -1
  107. package/lib/esm/components/system-debug-trace/events/ai-agent/index.d.ts +2 -2
  108. package/lib/esm/components/system-debug-trace/events/ai-agent/index.js +6 -5
  109. package/lib/esm/components/system-debug-trace/events/ai-agent/index.js.map +1 -1
  110. package/lib/esm/components/system-debug-trace/events/ai-agent/parse-tools.d.ts +1 -1
  111. package/lib/esm/components/system-debug-trace/events/ai-agent/parse-tools.js +10 -12
  112. package/lib/esm/components/system-debug-trace/events/ai-agent/parse-tools.js.map +1 -1
  113. package/lib/esm/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.d.ts +2 -2
  114. package/lib/esm/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.js +11 -17
  115. package/lib/esm/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.js.map +1 -1
  116. package/lib/esm/components/system-debug-trace/events/ai-agent/types.d.ts +1 -1
  117. package/lib/esm/components/system-debug-trace/events/ai-agent/types.js +3 -2
  118. package/lib/esm/components/system-debug-trace/events/ai-agent/types.js.map +1 -1
  119. package/lib/esm/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.d.ts +2 -2
  120. package/lib/esm/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.js +23 -23
  121. package/lib/esm/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.js.map +1 -1
  122. package/lib/esm/components/system-debug-trace/events/ai-agent-router/ai-agent-router.d.ts +2 -2
  123. package/lib/esm/components/system-debug-trace/events/ai-agent-router/ai-agent-router.js +88 -18
  124. package/lib/esm/components/system-debug-trace/events/ai-agent-router/ai-agent-router.js.map +1 -1
  125. package/lib/esm/components/system-debug-trace/events/ai-agent-router/index.d.ts +2 -2
  126. package/lib/esm/components/system-debug-trace/events/ai-agent-router/index.js +6 -5
  127. package/lib/esm/components/system-debug-trace/events/ai-agent-router/index.js.map +1 -1
  128. package/lib/esm/components/system-debug-trace/events/ai-agent-router/types.d.ts +2 -2
  129. package/lib/esm/components/system-debug-trace/events/ai-agent-router/types.js +3 -2
  130. package/lib/esm/components/system-debug-trace/events/ai-agent-router/types.js.map +1 -1
  131. package/lib/esm/components/system-debug-trace/events/bot-action.d.ts +1 -1
  132. package/lib/esm/components/system-debug-trace/events/bot-action.js +28 -12
  133. package/lib/esm/components/system-debug-trace/events/bot-action.js.map +1 -1
  134. package/lib/esm/components/system-debug-trace/events/components/guardrail-item.js +38 -11
  135. package/lib/esm/components/system-debug-trace/events/components/guardrail-item.js.map +1 -1
  136. package/lib/esm/components/system-debug-trace/events/components/index.d.ts +2 -2
  137. package/lib/esm/components/system-debug-trace/events/components/index.js +6 -5
  138. package/lib/esm/components/system-debug-trace/events/components/index.js.map +1 -1
  139. package/lib/esm/components/system-debug-trace/events/components/sources-section.d.ts +1 -1
  140. package/lib/esm/components/system-debug-trace/events/components/sources-section.js +46 -17
  141. package/lib/esm/components/system-debug-trace/events/components/sources-section.js.map +1 -1
  142. package/lib/esm/components/system-debug-trace/events/conditional-channel.d.ts +1 -1
  143. package/lib/esm/components/system-debug-trace/events/conditional-channel.js +28 -12
  144. package/lib/esm/components/system-debug-trace/events/conditional-channel.js.map +1 -1
  145. package/lib/esm/components/system-debug-trace/events/conditional-country.d.ts +1 -1
  146. package/lib/esm/components/system-debug-trace/events/conditional-country.js +28 -12
  147. package/lib/esm/components/system-debug-trace/events/conditional-country.js.map +1 -1
  148. package/lib/esm/components/system-debug-trace/events/conditional-custom.d.ts +1 -1
  149. package/lib/esm/components/system-debug-trace/events/conditional-custom.js +59 -17
  150. package/lib/esm/components/system-debug-trace/events/conditional-custom.js.map +1 -1
  151. package/lib/esm/components/system-debug-trace/events/conditional-queue-status.d.ts +1 -1
  152. package/lib/esm/components/system-debug-trace/events/conditional-queue-status.js +72 -20
  153. package/lib/esm/components/system-debug-trace/events/conditional-queue-status.js.map +1 -1
  154. package/lib/esm/components/system-debug-trace/events/constants.js +5 -5
  155. package/lib/esm/components/system-debug-trace/events/constants.js.map +1 -1
  156. package/lib/esm/components/system-debug-trace/events/fallback.d.ts +1 -1
  157. package/lib/esm/components/system-debug-trace/events/fallback.js +29 -12
  158. package/lib/esm/components/system-debug-trace/events/fallback.js.map +1 -1
  159. package/lib/esm/components/system-debug-trace/events/handoff-success.d.ts +1 -1
  160. package/lib/esm/components/system-debug-trace/events/handoff-success.js +84 -27
  161. package/lib/esm/components/system-debug-trace/events/handoff-success.js.map +1 -1
  162. package/lib/esm/components/system-debug-trace/events/index.d.ts +14 -14
  163. package/lib/esm/components/system-debug-trace/events/index.js +30 -17
  164. package/lib/esm/components/system-debug-trace/events/index.js.map +1 -1
  165. package/lib/esm/components/system-debug-trace/events/keyword.d.ts +1 -1
  166. package/lib/esm/components/system-debug-trace/events/keyword.js +29 -12
  167. package/lib/esm/components/system-debug-trace/events/keyword.js.map +1 -1
  168. package/lib/esm/components/system-debug-trace/events/knowledge-bases-types.js +3 -2
  169. package/lib/esm/components/system-debug-trace/events/knowledge-bases-types.js.map +1 -1
  170. package/lib/esm/components/system-debug-trace/events/redirect-flow.d.ts +1 -1
  171. package/lib/esm/components/system-debug-trace/events/redirect-flow.js +28 -12
  172. package/lib/esm/components/system-debug-trace/events/redirect-flow.js.map +1 -1
  173. package/lib/esm/components/system-debug-trace/events/smart-intent.d.ts +1 -1
  174. package/lib/esm/components/system-debug-trace/events/smart-intent.js +28 -11
  175. package/lib/esm/components/system-debug-trace/events/smart-intent.js.map +1 -1
  176. package/lib/esm/components/system-debug-trace/events/webview-action-triggered.d.ts +1 -1
  177. package/lib/esm/components/system-debug-trace/events/webview-action-triggered.js +45 -19
  178. package/lib/esm/components/system-debug-trace/events/webview-action-triggered.js.map +1 -1
  179. package/lib/esm/components/system-debug-trace/hooks/use-knowledge-base-info.d.ts +2 -2
  180. package/lib/esm/components/system-debug-trace/hooks/use-knowledge-base-info.js +45 -38
  181. package/lib/esm/components/system-debug-trace/hooks/use-knowledge-base-info.js.map +1 -1
  182. package/lib/esm/components/system-debug-trace/hooks/use-last-label-position.js +22 -19
  183. package/lib/esm/components/system-debug-trace/hooks/use-last-label-position.js.map +1 -1
  184. package/lib/esm/components/system-debug-trace/icons/ai-router.js +69 -12
  185. package/lib/esm/components/system-debug-trace/icons/ai-router.js.map +1 -1
  186. package/lib/esm/components/system-debug-trace/icons/ai-specialist.js +83 -13
  187. package/lib/esm/components/system-debug-trace/icons/ai-specialist.js.map +1 -1
  188. package/lib/esm/components/system-debug-trace/icons/arrow-progress.d.ts +1 -1
  189. package/lib/esm/components/system-debug-trace/icons/arrow-progress.js +21 -10
  190. package/lib/esm/components/system-debug-trace/icons/arrow-progress.js.map +1 -1
  191. package/lib/esm/components/system-debug-trace/icons/brain.d.ts +1 -1
  192. package/lib/esm/components/system-debug-trace/icons/brain.js +21 -10
  193. package/lib/esm/components/system-debug-trace/icons/brain.js.map +1 -1
  194. package/lib/esm/components/system-debug-trace/icons/caret-down.d.ts +1 -1
  195. package/lib/esm/components/system-debug-trace/icons/caret-down.js +21 -10
  196. package/lib/esm/components/system-debug-trace/icons/caret-down.js.map +1 -1
  197. package/lib/esm/components/system-debug-trace/icons/caret-up.d.ts +1 -1
  198. package/lib/esm/components/system-debug-trace/icons/caret-up.js +21 -10
  199. package/lib/esm/components/system-debug-trace/icons/caret-up.js.map +1 -1
  200. package/lib/esm/components/system-debug-trace/icons/circle-check.d.ts +1 -1
  201. package/lib/esm/components/system-debug-trace/icons/circle-check.js +20 -9
  202. package/lib/esm/components/system-debug-trace/icons/circle-check.js.map +1 -1
  203. package/lib/esm/components/system-debug-trace/icons/code.d.ts +1 -1
  204. package/lib/esm/components/system-debug-trace/icons/code.js +20 -9
  205. package/lib/esm/components/system-debug-trace/icons/code.js.map +1 -1
  206. package/lib/esm/components/system-debug-trace/icons/file-pdf.d.ts +1 -1
  207. package/lib/esm/components/system-debug-trace/icons/file-pdf.js +21 -10
  208. package/lib/esm/components/system-debug-trace/icons/file-pdf.js.map +1 -1
  209. package/lib/esm/components/system-debug-trace/icons/file-word.d.ts +1 -1
  210. package/lib/esm/components/system-debug-trace/icons/file-word.js +21 -10
  211. package/lib/esm/components/system-debug-trace/icons/file-word.js.map +1 -1
  212. package/lib/esm/components/system-debug-trace/icons/hand.d.ts +1 -1
  213. package/lib/esm/components/system-debug-trace/icons/hand.js +21 -10
  214. package/lib/esm/components/system-debug-trace/icons/hand.js.map +1 -1
  215. package/lib/esm/components/system-debug-trace/icons/head-set.d.ts +1 -1
  216. package/lib/esm/components/system-debug-trace/icons/head-set.js +21 -10
  217. package/lib/esm/components/system-debug-trace/icons/head-set.js.map +1 -1
  218. package/lib/esm/components/system-debug-trace/icons/index.d.ts +16 -16
  219. package/lib/esm/components/system-debug-trace/icons/index.js +34 -19
  220. package/lib/esm/components/system-debug-trace/icons/index.js.map +1 -1
  221. package/lib/esm/components/system-debug-trace/icons/life-ring.d.ts +1 -1
  222. package/lib/esm/components/system-debug-trace/icons/life-ring.js +21 -10
  223. package/lib/esm/components/system-debug-trace/icons/life-ring.js.map +1 -1
  224. package/lib/esm/components/system-debug-trace/icons/link.d.ts +1 -1
  225. package/lib/esm/components/system-debug-trace/icons/link.js +21 -10
  226. package/lib/esm/components/system-debug-trace/icons/link.js.map +1 -1
  227. package/lib/esm/components/system-debug-trace/icons/quote-right.d.ts +1 -1
  228. package/lib/esm/components/system-debug-trace/icons/quote-right.js +21 -10
  229. package/lib/esm/components/system-debug-trace/icons/quote-right.js.map +1 -1
  230. package/lib/esm/components/system-debug-trace/icons/screwdriver-wrench.d.ts +1 -1
  231. package/lib/esm/components/system-debug-trace/icons/screwdriver-wrench.js +21 -10
  232. package/lib/esm/components/system-debug-trace/icons/screwdriver-wrench.js.map +1 -1
  233. package/lib/esm/components/system-debug-trace/icons/split.d.ts +1 -1
  234. package/lib/esm/components/system-debug-trace/icons/split.js +21 -10
  235. package/lib/esm/components/system-debug-trace/icons/split.js.map +1 -1
  236. package/lib/esm/components/system-debug-trace/icons/wand.d.ts +1 -1
  237. package/lib/esm/components/system-debug-trace/icons/wand.js +21 -10
  238. package/lib/esm/components/system-debug-trace/icons/wand.js.map +1 -1
  239. package/lib/esm/components/system-debug-trace/icons/window-restore.d.ts +1 -1
  240. package/lib/esm/components/system-debug-trace/icons/window-restore.js +21 -10
  241. package/lib/esm/components/system-debug-trace/icons/window-restore.js.map +1 -1
  242. package/lib/esm/components/system-debug-trace/index.js +35 -15
  243. package/lib/esm/components/system-debug-trace/index.js.map +1 -1
  244. package/lib/esm/components/system-debug-trace/styles.js +49 -45
  245. package/lib/esm/components/system-debug-trace/styles.js.map +1 -1
  246. package/lib/esm/components/system-debug-trace/types.d.ts +1 -1
  247. package/lib/esm/components/system-debug-trace/types.js +3 -2
  248. package/lib/esm/components/system-debug-trace/types.js.map +1 -1
  249. package/lib/esm/components/text.d.ts +1 -1
  250. package/lib/esm/components/text.js +57 -31
  251. package/lib/esm/components/text.js.map +1 -1
  252. package/lib/esm/components/title.js +33 -17
  253. package/lib/esm/components/title.js.map +1 -1
  254. package/lib/esm/components/video.d.ts +1 -1
  255. package/lib/esm/components/video.js +48 -21
  256. package/lib/esm/components/video.js.map +1 -1
  257. package/lib/esm/components/webchat-settings.d.ts +2 -2
  258. package/lib/esm/components/webchat-settings.js +43 -24
  259. package/lib/esm/components/webchat-settings.js.map +1 -1
  260. package/lib/esm/components/whatsapp-button-list.js +65 -38
  261. package/lib/esm/components/whatsapp-button-list.js.map +1 -1
  262. package/lib/esm/components/whatsapp-catalog.js +41 -18
  263. package/lib/esm/components/whatsapp-catalog.js.map +1 -1
  264. package/lib/esm/components/whatsapp-cta-url-button.js +58 -44
  265. package/lib/esm/components/whatsapp-cta-url-button.js.map +1 -1
  266. package/lib/esm/components/whatsapp-interactive-media-carousel.js +53 -19
  267. package/lib/esm/components/whatsapp-interactive-media-carousel.js.map +1 -1
  268. package/lib/esm/components/whatsapp-media-carousel.js +49 -24
  269. package/lib/esm/components/whatsapp-media-carousel.js.map +1 -1
  270. package/lib/esm/components/whatsapp-product-carousel.js +48 -22
  271. package/lib/esm/components/whatsapp-product-carousel.js.map +1 -1
  272. package/lib/esm/components/whatsapp-product-list.js +46 -19
  273. package/lib/esm/components/whatsapp-product-list.js.map +1 -1
  274. package/lib/esm/components/whatsapp-product.js +42 -18
  275. package/lib/esm/components/whatsapp-product.js.map +1 -1
  276. package/lib/esm/components/whatsapp-request-contact-info.d.ts +4 -0
  277. package/lib/esm/components/whatsapp-request-contact-info.js +49 -0
  278. package/lib/esm/components/whatsapp-request-contact-info.js.map +1 -0
  279. package/lib/esm/components/whatsapp-template/index.d.ts +1 -1
  280. package/lib/esm/components/whatsapp-template/index.js +45 -18
  281. package/lib/esm/components/whatsapp-template/index.js.map +1 -1
  282. package/lib/esm/components/whatsapp-template/types.d.ts +9 -2
  283. package/lib/esm/components/whatsapp-template/types.js +13 -12
  284. package/lib/esm/components/whatsapp-template/types.js.map +1 -1
  285. package/lib/esm/constants.js +39 -24
  286. package/lib/esm/constants.js.map +1 -1
  287. package/lib/esm/contexts.d.ts +1 -1
  288. package/lib/esm/contexts.js +20 -17
  289. package/lib/esm/contexts.js.map +1 -1
  290. package/lib/esm/debug-system-messages.d.ts +1 -1
  291. package/lib/esm/debug-system-messages.js +80 -65
  292. package/lib/esm/debug-system-messages.js.map +1 -1
  293. package/lib/esm/dev-app.d.ts +4 -4
  294. package/lib/esm/dev-app.js +104 -67
  295. package/lib/esm/dev-app.js.map +1 -1
  296. package/lib/esm/index-types.d.ts +8 -8
  297. package/lib/esm/index-types.js +9 -9
  298. package/lib/esm/index-types.js.map +1 -1
  299. package/lib/esm/index.d.ts +12 -12
  300. package/lib/esm/index.js +33 -25
  301. package/lib/esm/index.js.map +1 -1
  302. package/lib/esm/message-utils.js +40 -55
  303. package/lib/esm/message-utils.js.map +1 -1
  304. package/lib/esm/msg-to-botonic.js +166 -76
  305. package/lib/esm/msg-to-botonic.js.map +1 -1
  306. package/lib/esm/node-app.d.ts +1 -1
  307. package/lib/esm/node-app.js +17 -15
  308. package/lib/esm/node-app.js.map +1 -1
  309. package/lib/esm/package.json +3 -0
  310. package/lib/esm/react-bot.d.ts +2 -2
  311. package/lib/esm/react-bot.js +39 -26
  312. package/lib/esm/react-bot.js.map +1 -1
  313. package/lib/esm/shared/styles.js +12 -10
  314. package/lib/esm/shared/styles.js.map +1 -1
  315. package/lib/esm/util/dom.js +13 -16
  316. package/lib/esm/util/dom.js.map +1 -1
  317. package/lib/esm/util/environment.js +15 -24
  318. package/lib/esm/util/environment.js.map +1 -1
  319. package/lib/esm/util/error-boundary.js +29 -18
  320. package/lib/esm/util/error-boundary.js.map +1 -1
  321. package/lib/esm/util/functional.js +7 -14
  322. package/lib/esm/util/functional.js.map +1 -1
  323. package/lib/esm/util/i18n.js +12 -21
  324. package/lib/esm/util/i18n.js.map +1 -1
  325. package/lib/esm/util/index.d.ts +10 -10
  326. package/lib/esm/util/index.js +22 -13
  327. package/lib/esm/util/index.js.map +1 -1
  328. package/lib/esm/util/logs.js +17 -9
  329. package/lib/esm/util/logs.js.map +1 -1
  330. package/lib/esm/util/objects.js +14 -19
  331. package/lib/esm/util/objects.js.map +1 -1
  332. package/lib/esm/util/react.js +33 -27
  333. package/lib/esm/util/react.js.map +1 -1
  334. package/lib/esm/util/regexs.js +8 -11
  335. package/lib/esm/util/regexs.js.map +1 -1
  336. package/lib/esm/util/strings.js +4 -5
  337. package/lib/esm/util/strings.js.map +1 -1
  338. package/lib/esm/util/webchat.d.ts +2 -2
  339. package/lib/esm/util/webchat.js +48 -47
  340. package/lib/esm/util/webchat.js.map +1 -1
  341. package/lib/esm/util/webviews.d.ts +1 -1
  342. package/lib/esm/util/webviews.js +3 -3
  343. package/lib/esm/util/webviews.js.map +1 -1
  344. package/lib/esm/webchat/chat-area/index.js +42 -18
  345. package/lib/esm/webchat/chat-area/index.js.map +1 -1
  346. package/lib/esm/webchat/chat-area/styles.js +9 -7
  347. package/lib/esm/webchat/chat-area/styles.js.map +1 -1
  348. package/lib/esm/webchat/components/common.js +17 -10
  349. package/lib/esm/webchat/components/common.js.map +1 -1
  350. package/lib/esm/webchat/components/conditional-animation.js +32 -14
  351. package/lib/esm/webchat/components/conditional-animation.js.map +1 -1
  352. package/lib/esm/webchat/components/opened-persistent-menu.js +61 -26
  353. package/lib/esm/webchat/components/opened-persistent-menu.js.map +1 -1
  354. package/lib/esm/webchat/constants.js +5 -5
  355. package/lib/esm/webchat/constants.js.map +1 -1
  356. package/lib/esm/webchat/context/actions.js +6 -7
  357. package/lib/esm/webchat/context/actions.js.map +1 -1
  358. package/lib/esm/webchat/context/index.d.ts +3 -3
  359. package/lib/esm/webchat/context/index.js +59 -43
  360. package/lib/esm/webchat/context/index.js.map +1 -1
  361. package/lib/esm/webchat/context/messages-reducer.d.ts +2 -2
  362. package/lib/esm/webchat/context/messages-reducer.js +78 -66
  363. package/lib/esm/webchat/context/messages-reducer.js.map +1 -1
  364. package/lib/esm/webchat/context/types.d.ts +4 -4
  365. package/lib/esm/webchat/context/types.js +3 -2
  366. package/lib/esm/webchat/context/types.js.map +1 -1
  367. package/lib/esm/webchat/context/use-webchat.d.ts +5 -5
  368. package/lib/esm/webchat/context/use-webchat.js +144 -102
  369. package/lib/esm/webchat/context/use-webchat.js.map +1 -1
  370. package/lib/esm/webchat/context/webchat-reducer.d.ts +2 -2
  371. package/lib/esm/webchat/context/webchat-reducer.js +110 -51
  372. package/lib/esm/webchat/context/webchat-reducer.js.map +1 -1
  373. package/lib/esm/webchat/cover-component/index.js +24 -13
  374. package/lib/esm/webchat/cover-component/index.js.map +1 -1
  375. package/lib/esm/webchat/custom-messages/index.d.ts +1 -1
  376. package/lib/esm/webchat/custom-messages/index.js +5 -6
  377. package/lib/esm/webchat/custom-messages/index.js.map +1 -1
  378. package/lib/esm/webchat/custom-messages/rating/icons/face-angry.d.ts +1 -1
  379. package/lib/esm/webchat/custom-messages/rating/icons/face-angry.js +25 -7
  380. package/lib/esm/webchat/custom-messages/rating/icons/face-angry.js.map +1 -1
  381. package/lib/esm/webchat/custom-messages/rating/icons/face-frown.d.ts +1 -1
  382. package/lib/esm/webchat/custom-messages/rating/icons/face-frown.js +25 -7
  383. package/lib/esm/webchat/custom-messages/rating/icons/face-frown.js.map +1 -1
  384. package/lib/esm/webchat/custom-messages/rating/icons/face-grin-beam.d.ts +1 -1
  385. package/lib/esm/webchat/custom-messages/rating/icons/face-grin-beam.js +25 -7
  386. package/lib/esm/webchat/custom-messages/rating/icons/face-grin-beam.js.map +1 -1
  387. package/lib/esm/webchat/custom-messages/rating/icons/face-meh.d.ts +1 -1
  388. package/lib/esm/webchat/custom-messages/rating/icons/face-meh.js +25 -7
  389. package/lib/esm/webchat/custom-messages/rating/icons/face-meh.js.map +1 -1
  390. package/lib/esm/webchat/custom-messages/rating/icons/face-smile.d.ts +1 -1
  391. package/lib/esm/webchat/custom-messages/rating/icons/face-smile.js +25 -7
  392. package/lib/esm/webchat/custom-messages/rating/icons/face-smile.js.map +1 -1
  393. package/lib/esm/webchat/custom-messages/rating/icons/index.d.ts +6 -6
  394. package/lib/esm/webchat/custom-messages/rating/icons/index.js +14 -9
  395. package/lib/esm/webchat/custom-messages/rating/icons/index.js.map +1 -1
  396. package/lib/esm/webchat/custom-messages/rating/icons/star.d.ts +1 -1
  397. package/lib/esm/webchat/custom-messages/rating/icons/star.js +25 -7
  398. package/lib/esm/webchat/custom-messages/rating/icons/star.js.map +1 -1
  399. package/lib/esm/webchat/custom-messages/rating/index.d.ts +1 -1
  400. package/lib/esm/webchat/custom-messages/rating/index.js +77 -28
  401. package/lib/esm/webchat/custom-messages/rating/index.js.map +1 -1
  402. package/lib/esm/webchat/custom-messages/rating/rating-selector.d.ts +1 -1
  403. package/lib/esm/webchat/custom-messages/rating/rating-selector.js +49 -18
  404. package/lib/esm/webchat/custom-messages/rating/rating-selector.js.map +1 -1
  405. package/lib/esm/webchat/custom-messages/rating/smileys.d.ts +1 -1
  406. package/lib/esm/webchat/custom-messages/rating/smileys.js +20 -13
  407. package/lib/esm/webchat/custom-messages/rating/smileys.js.map +1 -1
  408. package/lib/esm/webchat/custom-messages/rating/stars.d.ts +1 -1
  409. package/lib/esm/webchat/custom-messages/rating/stars.js +15 -8
  410. package/lib/esm/webchat/custom-messages/rating/stars.js.map +1 -1
  411. package/lib/esm/webchat/custom-messages/rating/styles.js +10 -8
  412. package/lib/esm/webchat/custom-messages/rating/styles.js.map +1 -1
  413. package/lib/esm/webchat/custom-messages/rating/types.js +6 -6
  414. package/lib/esm/webchat/custom-messages/rating/types.js.map +1 -1
  415. package/lib/esm/webchat/devices/index.js +10 -13
  416. package/lib/esm/webchat/devices/index.js.map +1 -1
  417. package/lib/esm/webchat/global.d.ts +3 -0
  418. package/lib/esm/webchat/header/default-header.js +71 -21
  419. package/lib/esm/webchat/header/default-header.js.map +1 -1
  420. package/lib/esm/webchat/header/index.js +42 -17
  421. package/lib/esm/webchat/header/index.js.map +1 -1
  422. package/lib/esm/webchat/header/styles.js +26 -22
  423. package/lib/esm/webchat/header/styles.js.map +1 -1
  424. package/lib/esm/webchat/hooks/index.d.ts +10 -10
  425. package/lib/esm/webchat/hooks/index.js +32 -23
  426. package/lib/esm/webchat/hooks/index.js.map +1 -1
  427. package/lib/esm/webchat/hooks/use-component-visible.js +17 -10
  428. package/lib/esm/webchat/hooks/use-component-visible.js.map +1 -1
  429. package/lib/esm/webchat/hooks/use-component-will-mount.js +9 -7
  430. package/lib/esm/webchat/hooks/use-component-will-mount.js.map +1 -1
  431. package/lib/esm/webchat/hooks/use-device-adapter.js +43 -24
  432. package/lib/esm/webchat/hooks/use-device-adapter.js.map +1 -1
  433. package/lib/esm/webchat/hooks/use-previous.js +9 -6
  434. package/lib/esm/webchat/hooks/use-previous.js.map +1 -1
  435. package/lib/esm/webchat/hooks/use-scroll-to-bottom.js +16 -12
  436. package/lib/esm/webchat/hooks/use-scroll-to-bottom.js.map +1 -1
  437. package/lib/esm/webchat/hooks/use-scrollbar-controller.js +48 -43
  438. package/lib/esm/webchat/hooks/use-scrollbar-controller.js.map +1 -1
  439. package/lib/esm/webchat/hooks/use-typing.d.ts +2 -2
  440. package/lib/esm/webchat/hooks/use-typing.js +24 -18
  441. package/lib/esm/webchat/hooks/use-typing.js.map +1 -1
  442. package/lib/esm/webchat/hooks/use-virtual-keyboard-detection.js +18 -12
  443. package/lib/esm/webchat/hooks/use-virtual-keyboard-detection.js.map +1 -1
  444. package/lib/esm/webchat/hooks/use-webchat-dimensions.js +24 -21
  445. package/lib/esm/webchat/hooks/use-webchat-dimensions.js.map +1 -1
  446. package/lib/esm/webchat/hooks/use-webchat-resizer.js +21 -21
  447. package/lib/esm/webchat/hooks/use-webchat-resizer.js.map +1 -1
  448. package/lib/esm/webchat/index-types.d.ts +1 -1
  449. package/lib/esm/webchat/index-types.js +3 -2
  450. package/lib/esm/webchat/index-types.js.map +1 -1
  451. package/lib/esm/webchat/index.d.ts +5 -5
  452. package/lib/esm/webchat/index.js +16 -13
  453. package/lib/esm/webchat/index.js.map +1 -1
  454. package/lib/esm/webchat/input-panel/attachment.js +60 -19
  455. package/lib/esm/webchat/input-panel/attachment.js.map +1 -1
  456. package/lib/esm/webchat/input-panel/emoji-picker.js +41 -20
  457. package/lib/esm/webchat/input-panel/emoji-picker.js.map +1 -1
  458. package/lib/esm/webchat/input-panel/index.js +87 -29
  459. package/lib/esm/webchat/input-panel/index.js.map +1 -1
  460. package/lib/esm/webchat/input-panel/opened-emoji-picker.js +37 -13
  461. package/lib/esm/webchat/input-panel/opened-emoji-picker.js.map +1 -1
  462. package/lib/esm/webchat/input-panel/persistent-menu.js +38 -17
  463. package/lib/esm/webchat/input-panel/persistent-menu.js.map +1 -1
  464. package/lib/esm/webchat/input-panel/send-button.js +40 -19
  465. package/lib/esm/webchat/input-panel/send-button.js.map +1 -1
  466. package/lib/esm/webchat/input-panel/styles.js +14 -10
  467. package/lib/esm/webchat/input-panel/styles.js.map +1 -1
  468. package/lib/esm/webchat/input-panel/textarea.d.ts +2 -2
  469. package/lib/esm/webchat/input-panel/textarea.js +56 -26
  470. package/lib/esm/webchat/input-panel/textarea.js.map +1 -1
  471. package/lib/esm/webchat/input-panel/typing-network-sender.d.ts +1 -1
  472. package/lib/esm/webchat/input-panel/typing-network-sender.js +57 -38
  473. package/lib/esm/webchat/input-panel/typing-network-sender.js.map +1 -1
  474. package/lib/esm/webchat/input-panel/use-typing-chat-event-sender.d.ts +1 -1
  475. package/lib/esm/webchat/input-panel/use-typing-chat-event-sender.js +32 -21
  476. package/lib/esm/webchat/input-panel/use-typing-chat-event-sender.js.map +1 -1
  477. package/lib/esm/webchat/input-panel/use-typing-session.d.ts +1 -1
  478. package/lib/esm/webchat/input-panel/use-typing-session.js +44 -33
  479. package/lib/esm/webchat/input-panel/use-typing-session.js.map +1 -1
  480. package/lib/esm/webchat/message-list/index.js +118 -58
  481. package/lib/esm/webchat/message-list/index.js.map +1 -1
  482. package/lib/esm/webchat/message-list/intro-message.js +47 -22
  483. package/lib/esm/webchat/message-list/intro-message.js.map +1 -1
  484. package/lib/esm/webchat/message-list/scroll-button.js +35 -16
  485. package/lib/esm/webchat/message-list/scroll-button.js.map +1 -1
  486. package/lib/esm/webchat/message-list/styles.js +13 -11
  487. package/lib/esm/webchat/message-list/styles.js.map +1 -1
  488. package/lib/esm/webchat/message-list/unread-messages-banner.js +43 -16
  489. package/lib/esm/webchat/message-list/unread-messages-banner.js.map +1 -1
  490. package/lib/esm/webchat/message-list/use-debounce.js +11 -8
  491. package/lib/esm/webchat/message-list/use-debounce.js.map +1 -1
  492. package/lib/esm/webchat/message-list/use-notifications.js +21 -14
  493. package/lib/esm/webchat/message-list/use-notifications.js.map +1 -1
  494. package/lib/esm/webchat/replies/index.js +41 -21
  495. package/lib/esm/webchat/replies/index.js.map +1 -1
  496. package/lib/esm/webchat/replies/styles.js +12 -10
  497. package/lib/esm/webchat/replies/styles.js.map +1 -1
  498. package/lib/esm/webchat/session-view.js +106 -41
  499. package/lib/esm/webchat/session-view.js.map +1 -1
  500. package/lib/esm/webchat/styles.js +33 -29
  501. package/lib/esm/webchat/styles.js.map +1 -1
  502. package/lib/esm/webchat/theme/default-theme.d.ts +1 -1
  503. package/lib/esm/webchat/theme/default-theme.js +52 -37
  504. package/lib/esm/webchat/theme/default-theme.js.map +1 -1
  505. package/lib/esm/webchat/theme/theme.d.ts +8 -0
  506. package/lib/esm/webchat/theme/types.d.ts +1 -1
  507. package/lib/esm/webchat/theme/types.js +3 -2
  508. package/lib/esm/webchat/theme/types.js.map +1 -1
  509. package/lib/esm/webchat/tracking.js +23 -15
  510. package/lib/esm/webchat/tracking.js.map +1 -1
  511. package/lib/esm/webchat/trigger-button/index.js +48 -23
  512. package/lib/esm/webchat/trigger-button/index.js.map +1 -1
  513. package/lib/esm/webchat/trigger-button/styles.js +15 -11
  514. package/lib/esm/webchat/trigger-button/styles.js.map +1 -1
  515. package/lib/esm/webchat/typing-indicator/index.js +30 -8
  516. package/lib/esm/webchat/typing-indicator/index.js.map +1 -1
  517. package/lib/esm/webchat/typing-indicator/styles.js +13 -11
  518. package/lib/esm/webchat/typing-indicator/styles.js.map +1 -1
  519. package/lib/esm/webchat/use-storage-state-hook.js +31 -18
  520. package/lib/esm/webchat/use-storage-state-hook.js.map +1 -1
  521. package/lib/esm/webchat/utils.js +9 -7
  522. package/lib/esm/webchat/utils.js.map +1 -1
  523. package/lib/esm/webchat/webchat-dev.js +74 -32
  524. package/lib/esm/webchat/webchat-dev.js.map +1 -1
  525. package/lib/esm/webchat/webchat.d.ts +1 -1
  526. package/lib/esm/webchat/webchat.js +455 -286
  527. package/lib/esm/webchat/webchat.js.map +1 -1
  528. package/lib/esm/webchat/webview/header.js +35 -16
  529. package/lib/esm/webchat/webview/header.js.map +1 -1
  530. package/lib/esm/webchat/webview/index.d.ts +1 -1
  531. package/lib/esm/webchat/webview/index.js +76 -42
  532. package/lib/esm/webchat/webview/index.js.map +1 -1
  533. package/lib/esm/webchat/webview/styles.js +35 -31
  534. package/lib/esm/webchat/webview/styles.js.map +1 -1
  535. package/lib/esm/webchat-app.d.ts +5 -5
  536. package/lib/esm/webchat-app.js +197 -134
  537. package/lib/esm/webchat-app.js.map +1 -1
  538. package/lib/esm/webview-app.js +103 -80
  539. package/lib/esm/webview-app.js.map +1 -1
  540. package/package.json +8 -10
  541. package/src/components/index.ts +17 -13
  542. package/src/components/whatsapp-request-contact-info.tsx +38 -0
  543. package/src/components/whatsapp-template/types.ts +9 -0
  544. package/src/dev-app.jsx +1 -1
  545. package/src/index-types.ts +6 -6
  546. package/src/webchat/context/index.tsx +1 -1
  547. package/src/webchat/index.ts +1 -1
  548. package/lib/cjs/app.d.ts +0 -2
  549. package/lib/cjs/app.js +0 -10
  550. package/lib/cjs/app.js.map +0 -1
  551. package/lib/cjs/assets/arrow-down.svg +0 -3
  552. package/lib/cjs/assets/arrow-scroll-down.svg +0 -3
  553. package/lib/cjs/assets/attachment-icon.svg +0 -7
  554. package/lib/cjs/assets/audio.svg +0 -4
  555. package/lib/cjs/assets/botonic_react_logo100x100.png +0 -0
  556. package/lib/cjs/assets/document.svg +0 -3
  557. package/lib/cjs/assets/emojiButton.svg +0 -6
  558. package/lib/cjs/assets/image.svg +0 -4
  559. package/lib/cjs/assets/leftArrow.svg +0 -3
  560. package/lib/cjs/assets/menuButton.svg +0 -3
  561. package/lib/cjs/assets/rightArrow.svg +0 -3
  562. package/lib/cjs/assets/send-button.svg +0 -1
  563. package/lib/cjs/assets/thumbs-down.svg +0 -3
  564. package/lib/cjs/assets/thumbs-up.svg +0 -3
  565. package/lib/cjs/assets/url-icon.png +0 -0
  566. package/lib/cjs/assets/video.svg +0 -3
  567. package/lib/cjs/botonic-tester.d.ts +0 -30
  568. package/lib/cjs/botonic-tester.js +0 -76
  569. package/lib/cjs/botonic-tester.js.map +0 -1
  570. package/lib/cjs/components/audio.d.ts +0 -9
  571. package/lib/cjs/components/audio.js +0 -27
  572. package/lib/cjs/components/audio.js.map +0 -1
  573. package/lib/cjs/components/button/index.d.ts +0 -17
  574. package/lib/cjs/components/button/index.js +0 -139
  575. package/lib/cjs/components/button/index.js.map +0 -1
  576. package/lib/cjs/components/button/styles.d.ts +0 -2
  577. package/lib/cjs/components/button/styles.js +0 -40
  578. package/lib/cjs/components/button/styles.js.map +0 -1
  579. package/lib/cjs/components/buttons-disabler.d.ts +0 -21
  580. package/lib/cjs/components/buttons-disabler.js +0 -94
  581. package/lib/cjs/components/buttons-disabler.js.map +0 -1
  582. package/lib/cjs/components/carousel.d.ts +0 -10
  583. package/lib/cjs/components/carousel.js +0 -119
  584. package/lib/cjs/components/carousel.js.map +0 -1
  585. package/lib/cjs/components/components.d.ts +0 -12
  586. package/lib/cjs/components/components.js +0 -21
  587. package/lib/cjs/components/components.js.map +0 -1
  588. package/lib/cjs/components/constants.d.ts +0 -11
  589. package/lib/cjs/components/constants.js +0 -15
  590. package/lib/cjs/components/constants.js.map +0 -1
  591. package/lib/cjs/components/custom-message.d.ts +0 -16
  592. package/lib/cjs/components/custom-message.js +0 -60
  593. package/lib/cjs/components/custom-message.js.map +0 -1
  594. package/lib/cjs/components/document.d.ts +0 -9
  595. package/lib/cjs/components/document.js +0 -50
  596. package/lib/cjs/components/document.js.map +0 -1
  597. package/lib/cjs/components/element.d.ts +0 -8
  598. package/lib/cjs/components/element.js +0 -56
  599. package/lib/cjs/components/element.js.map +0 -1
  600. package/lib/cjs/components/handoff.d.ts +0 -1
  601. package/lib/cjs/components/handoff.js +0 -54
  602. package/lib/cjs/components/handoff.js.map +0 -1
  603. package/lib/cjs/components/image.d.ts +0 -9
  604. package/lib/cjs/components/image.js +0 -40
  605. package/lib/cjs/components/image.js.map +0 -1
  606. package/lib/cjs/components/index-types.d.ts +0 -83
  607. package/lib/cjs/components/index-types.js +0 -3
  608. package/lib/cjs/components/index-types.js.map +0 -1
  609. package/lib/cjs/components/index.d.ts +0 -32
  610. package/lib/cjs/components/index.js +0 -69
  611. package/lib/cjs/components/index.js.map +0 -1
  612. package/lib/cjs/components/location.d.ts +0 -11
  613. package/lib/cjs/components/location.js +0 -31
  614. package/lib/cjs/components/location.js.map +0 -1
  615. package/lib/cjs/components/markdown.d.ts +0 -7
  616. package/lib/cjs/components/markdown.js +0 -172
  617. package/lib/cjs/components/markdown.js.map +0 -1
  618. package/lib/cjs/components/message/index.d.ts +0 -1
  619. package/lib/cjs/components/message/index.js +0 -174
  620. package/lib/cjs/components/message/index.js.map +0 -1
  621. package/lib/cjs/components/message/message-footer.d.ts +0 -8
  622. package/lib/cjs/components/message/message-footer.js +0 -20
  623. package/lib/cjs/components/message/message-footer.js.map +0 -1
  624. package/lib/cjs/components/message/message-image.d.ts +0 -7
  625. package/lib/cjs/components/message/message-image.js +0 -26
  626. package/lib/cjs/components/message/message-image.js.map +0 -1
  627. package/lib/cjs/components/message/styles.d.ts +0 -35
  628. package/lib/cjs/components/message/styles.js +0 -123
  629. package/lib/cjs/components/message/styles.js.map +0 -1
  630. package/lib/cjs/components/message/timestamps.d.ts +0 -13
  631. package/lib/cjs/components/message/timestamps.js +0 -45
  632. package/lib/cjs/components/message/timestamps.js.map +0 -1
  633. package/lib/cjs/components/message-template.d.ts +0 -1
  634. package/lib/cjs/components/message-template.js +0 -13
  635. package/lib/cjs/components/message-template.js.map +0 -1
  636. package/lib/cjs/components/multichannel/facebook/facebook.d.ts +0 -17
  637. package/lib/cjs/components/multichannel/facebook/facebook.js +0 -48
  638. package/lib/cjs/components/multichannel/facebook/facebook.js.map +0 -1
  639. package/lib/cjs/components/multichannel/index-types.d.ts +0 -42
  640. package/lib/cjs/components/multichannel/index-types.js +0 -3
  641. package/lib/cjs/components/multichannel/index-types.js.map +0 -1
  642. package/lib/cjs/components/multichannel/index.d.ts +0 -11
  643. package/lib/cjs/components/multichannel/index.js +0 -16
  644. package/lib/cjs/components/multichannel/index.js.map +0 -1
  645. package/lib/cjs/components/multichannel/multichannel-button.d.ts +0 -4
  646. package/lib/cjs/components/multichannel/multichannel-button.js +0 -72
  647. package/lib/cjs/components/multichannel/multichannel-button.js.map +0 -1
  648. package/lib/cjs/components/multichannel/multichannel-carousel.d.ts +0 -1
  649. package/lib/cjs/components/multichannel/multichannel-carousel.js +0 -80
  650. package/lib/cjs/components/multichannel/multichannel-carousel.js.map +0 -1
  651. package/lib/cjs/components/multichannel/multichannel-context.d.ts +0 -8
  652. package/lib/cjs/components/multichannel/multichannel-context.js +0 -13
  653. package/lib/cjs/components/multichannel/multichannel-context.js.map +0 -1
  654. package/lib/cjs/components/multichannel/multichannel-reply.d.ts +0 -4
  655. package/lib/cjs/components/multichannel/multichannel-reply.js +0 -27
  656. package/lib/cjs/components/multichannel/multichannel-reply.js.map +0 -1
  657. package/lib/cjs/components/multichannel/multichannel-text.d.ts +0 -1
  658. package/lib/cjs/components/multichannel/multichannel-text.js +0 -184
  659. package/lib/cjs/components/multichannel/multichannel-text.js.map +0 -1
  660. package/lib/cjs/components/multichannel/multichannel-utils.d.ts +0 -36
  661. package/lib/cjs/components/multichannel/multichannel-utils.js +0 -89
  662. package/lib/cjs/components/multichannel/multichannel-utils.js.map +0 -1
  663. package/lib/cjs/components/multichannel/multichannel.d.ts +0 -1
  664. package/lib/cjs/components/multichannel/multichannel.js +0 -63
  665. package/lib/cjs/components/multichannel/multichannel.js.map +0 -1
  666. package/lib/cjs/components/multichannel/whatsapp/constants.d.ts +0 -12
  667. package/lib/cjs/components/multichannel/whatsapp/constants.js +0 -14
  668. package/lib/cjs/components/multichannel/whatsapp/constants.js.map +0 -1
  669. package/lib/cjs/components/multichannel/whatsapp/markdown-meta.d.ts +0 -1
  670. package/lib/cjs/components/multichannel/whatsapp/markdown-meta.js +0 -41
  671. package/lib/cjs/components/multichannel/whatsapp/markdown-meta.js.map +0 -1
  672. package/lib/cjs/components/pic.d.ts +0 -10
  673. package/lib/cjs/components/pic.js +0 -32
  674. package/lib/cjs/components/pic.js.map +0 -1
  675. package/lib/cjs/components/raw.d.ts +0 -9
  676. package/lib/cjs/components/raw.js +0 -45
  677. package/lib/cjs/components/raw.js.map +0 -1
  678. package/lib/cjs/components/reply.d.ts +0 -11
  679. package/lib/cjs/components/reply.js +0 -66
  680. package/lib/cjs/components/reply.js.map +0 -1
  681. package/lib/cjs/components/share-button.d.ts +0 -1
  682. package/lib/cjs/components/share-button.js +0 -13
  683. package/lib/cjs/components/share-button.js.map +0 -1
  684. package/lib/cjs/components/subtitle.d.ts +0 -11
  685. package/lib/cjs/components/subtitle.js +0 -25
  686. package/lib/cjs/components/subtitle.js.map +0 -1
  687. package/lib/cjs/components/system-debug-trace/debug-message.d.ts +0 -7
  688. package/lib/cjs/components/system-debug-trace/debug-message.js +0 -82
  689. package/lib/cjs/components/system-debug-trace/debug-message.js.map +0 -1
  690. package/lib/cjs/components/system-debug-trace/events/ai-agent/ai-agent.d.ts +0 -4
  691. package/lib/cjs/components/system-debug-trace/events/ai-agent/ai-agent.js +0 -53
  692. package/lib/cjs/components/system-debug-trace/events/ai-agent/ai-agent.js.map +0 -1
  693. package/lib/cjs/components/system-debug-trace/events/ai-agent/executed-tools.d.ts +0 -7
  694. package/lib/cjs/components/system-debug-trace/events/ai-agent/executed-tools.js +0 -21
  695. package/lib/cjs/components/system-debug-trace/events/ai-agent/executed-tools.js.map +0 -1
  696. package/lib/cjs/components/system-debug-trace/events/ai-agent/index.d.ts +0 -2
  697. package/lib/cjs/components/system-debug-trace/events/ai-agent/index.js +0 -6
  698. package/lib/cjs/components/system-debug-trace/events/ai-agent/index.js.map +0 -1
  699. package/lib/cjs/components/system-debug-trace/events/ai-agent/parse-tools.d.ts +0 -9
  700. package/lib/cjs/components/system-debug-trace/events/ai-agent/parse-tools.js +0 -32
  701. package/lib/cjs/components/system-debug-trace/events/ai-agent/parse-tools.js.map +0 -1
  702. package/lib/cjs/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.d.ts +0 -6
  703. package/lib/cjs/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.js +0 -55
  704. package/lib/cjs/components/system-debug-trace/events/ai-agent/rehydrate-ai-agent-event.js.map +0 -1
  705. package/lib/cjs/components/system-debug-trace/events/ai-agent/types.d.ts +0 -23
  706. package/lib/cjs/components/system-debug-trace/events/ai-agent/types.js +0 -3
  707. package/lib/cjs/components/system-debug-trace/events/ai-agent/types.js.map +0 -1
  708. package/lib/cjs/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.d.ts +0 -8
  709. package/lib/cjs/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.js +0 -41
  710. package/lib/cjs/components/system-debug-trace/events/ai-agent/use-rehydrated-ai-agent-event.js.map +0 -1
  711. package/lib/cjs/components/system-debug-trace/events/ai-agent-router/ai-agent-router.d.ts +0 -4
  712. package/lib/cjs/components/system-debug-trace/events/ai-agent-router/ai-agent-router.js +0 -23
  713. package/lib/cjs/components/system-debug-trace/events/ai-agent-router/ai-agent-router.js.map +0 -1
  714. package/lib/cjs/components/system-debug-trace/events/ai-agent-router/index.d.ts +0 -2
  715. package/lib/cjs/components/system-debug-trace/events/ai-agent-router/index.js +0 -6
  716. package/lib/cjs/components/system-debug-trace/events/ai-agent-router/index.js.map +0 -1
  717. package/lib/cjs/components/system-debug-trace/events/ai-agent-router/types.d.ts +0 -23
  718. package/lib/cjs/components/system-debug-trace/events/ai-agent-router/types.js +0 -3
  719. package/lib/cjs/components/system-debug-trace/events/ai-agent-router/types.js.map +0 -1
  720. package/lib/cjs/components/system-debug-trace/events/bot-action.d.ts +0 -7
  721. package/lib/cjs/components/system-debug-trace/events/bot-action.js +0 -18
  722. package/lib/cjs/components/system-debug-trace/events/bot-action.js.map +0 -1
  723. package/lib/cjs/components/system-debug-trace/events/components/guardrail-item.d.ts +0 -14
  724. package/lib/cjs/components/system-debug-trace/events/components/guardrail-item.js +0 -12
  725. package/lib/cjs/components/system-debug-trace/events/components/guardrail-item.js.map +0 -1
  726. package/lib/cjs/components/system-debug-trace/events/components/index.d.ts +0 -2
  727. package/lib/cjs/components/system-debug-trace/events/components/index.js +0 -6
  728. package/lib/cjs/components/system-debug-trace/events/components/index.js.map +0 -1
  729. package/lib/cjs/components/system-debug-trace/events/components/sources-section.d.ts +0 -11
  730. package/lib/cjs/components/system-debug-trace/events/components/sources-section.js +0 -27
  731. package/lib/cjs/components/system-debug-trace/events/components/sources-section.js.map +0 -1
  732. package/lib/cjs/components/system-debug-trace/events/conditional-channel.d.ts +0 -7
  733. package/lib/cjs/components/system-debug-trace/events/conditional-channel.js +0 -18
  734. package/lib/cjs/components/system-debug-trace/events/conditional-channel.js.map +0 -1
  735. package/lib/cjs/components/system-debug-trace/events/conditional-country.d.ts +0 -7
  736. package/lib/cjs/components/system-debug-trace/events/conditional-country.js +0 -18
  737. package/lib/cjs/components/system-debug-trace/events/conditional-country.js.map +0 -1
  738. package/lib/cjs/components/system-debug-trace/events/conditional-custom.d.ts +0 -10
  739. package/lib/cjs/components/system-debug-trace/events/conditional-custom.js +0 -24
  740. package/lib/cjs/components/system-debug-trace/events/conditional-custom.js.map +0 -1
  741. package/lib/cjs/components/system-debug-trace/events/conditional-queue-status.d.ts +0 -11
  742. package/lib/cjs/components/system-debug-trace/events/conditional-queue-status.js +0 -26
  743. package/lib/cjs/components/system-debug-trace/events/conditional-queue-status.js.map +0 -1
  744. package/lib/cjs/components/system-debug-trace/events/constants.d.ts +0 -33
  745. package/lib/cjs/components/system-debug-trace/events/constants.js +0 -37
  746. package/lib/cjs/components/system-debug-trace/events/constants.js.map +0 -1
  747. package/lib/cjs/components/system-debug-trace/events/fallback.d.ts +0 -9
  748. package/lib/cjs/components/system-debug-trace/events/fallback.js +0 -19
  749. package/lib/cjs/components/system-debug-trace/events/fallback.js.map +0 -1
  750. package/lib/cjs/components/system-debug-trace/events/handoff-success.d.ts +0 -11
  751. package/lib/cjs/components/system-debug-trace/events/handoff-success.js +0 -42
  752. package/lib/cjs/components/system-debug-trace/events/handoff-success.js.map +0 -1
  753. package/lib/cjs/components/system-debug-trace/events/index.d.ts +0 -14
  754. package/lib/cjs/components/system-debug-trace/events/index.js +0 -18
  755. package/lib/cjs/components/system-debug-trace/events/index.js.map +0 -1
  756. package/lib/cjs/components/system-debug-trace/events/keyword.d.ts +0 -10
  757. package/lib/cjs/components/system-debug-trace/events/keyword.js +0 -18
  758. package/lib/cjs/components/system-debug-trace/events/keyword.js.map +0 -1
  759. package/lib/cjs/components/system-debug-trace/events/knowledge-bases-types.d.ts +0 -31
  760. package/lib/cjs/components/system-debug-trace/events/knowledge-bases-types.js +0 -3
  761. package/lib/cjs/components/system-debug-trace/events/knowledge-bases-types.js.map +0 -1
  762. package/lib/cjs/components/system-debug-trace/events/redirect-flow.d.ts +0 -10
  763. package/lib/cjs/components/system-debug-trace/events/redirect-flow.js +0 -18
  764. package/lib/cjs/components/system-debug-trace/events/redirect-flow.js.map +0 -1
  765. package/lib/cjs/components/system-debug-trace/events/smart-intent.d.ts +0 -7
  766. package/lib/cjs/components/system-debug-trace/events/smart-intent.js +0 -17
  767. package/lib/cjs/components/system-debug-trace/events/smart-intent.js.map +0 -1
  768. package/lib/cjs/components/system-debug-trace/events/webview-action-triggered.d.ts +0 -10
  769. package/lib/cjs/components/system-debug-trace/events/webview-action-triggered.js +0 -25
  770. package/lib/cjs/components/system-debug-trace/events/webview-action-triggered.js.map +0 -1
  771. package/lib/cjs/components/system-debug-trace/hooks/use-knowledge-base-info.d.ts +0 -16
  772. package/lib/cjs/components/system-debug-trace/hooks/use-knowledge-base-info.js +0 -111
  773. package/lib/cjs/components/system-debug-trace/hooks/use-knowledge-base-info.js.map +0 -1
  774. package/lib/cjs/components/system-debug-trace/hooks/use-last-label-position.d.ts +0 -9
  775. package/lib/cjs/components/system-debug-trace/hooks/use-last-label-position.js +0 -81
  776. package/lib/cjs/components/system-debug-trace/hooks/use-last-label-position.js.map +0 -1
  777. package/lib/cjs/components/system-debug-trace/icons/ai-router.d.ts +0 -1
  778. package/lib/cjs/components/system-debug-trace/icons/ai-router.js +0 -14
  779. package/lib/cjs/components/system-debug-trace/icons/ai-router.js.map +0 -1
  780. package/lib/cjs/components/system-debug-trace/icons/ai-specialist.d.ts +0 -1
  781. package/lib/cjs/components/system-debug-trace/icons/ai-specialist.js +0 -15
  782. package/lib/cjs/components/system-debug-trace/icons/ai-specialist.js.map +0 -1
  783. package/lib/cjs/components/system-debug-trace/icons/arrow-progress.d.ts +0 -2
  784. package/lib/cjs/components/system-debug-trace/icons/arrow-progress.js +0 -12
  785. package/lib/cjs/components/system-debug-trace/icons/arrow-progress.js.map +0 -1
  786. package/lib/cjs/components/system-debug-trace/icons/brain.d.ts +0 -2
  787. package/lib/cjs/components/system-debug-trace/icons/brain.js +0 -12
  788. package/lib/cjs/components/system-debug-trace/icons/brain.js.map +0 -1
  789. package/lib/cjs/components/system-debug-trace/icons/caret-down.d.ts +0 -2
  790. package/lib/cjs/components/system-debug-trace/icons/caret-down.js +0 -12
  791. package/lib/cjs/components/system-debug-trace/icons/caret-down.js.map +0 -1
  792. package/lib/cjs/components/system-debug-trace/icons/caret-up.d.ts +0 -2
  793. package/lib/cjs/components/system-debug-trace/icons/caret-up.js +0 -12
  794. package/lib/cjs/components/system-debug-trace/icons/caret-up.js.map +0 -1
  795. package/lib/cjs/components/system-debug-trace/icons/circle-check.d.ts +0 -2
  796. package/lib/cjs/components/system-debug-trace/icons/circle-check.js +0 -11
  797. package/lib/cjs/components/system-debug-trace/icons/circle-check.js.map +0 -1
  798. package/lib/cjs/components/system-debug-trace/icons/code.d.ts +0 -2
  799. package/lib/cjs/components/system-debug-trace/icons/code.js +0 -11
  800. package/lib/cjs/components/system-debug-trace/icons/code.js.map +0 -1
  801. package/lib/cjs/components/system-debug-trace/icons/file-pdf.d.ts +0 -2
  802. package/lib/cjs/components/system-debug-trace/icons/file-pdf.js +0 -12
  803. package/lib/cjs/components/system-debug-trace/icons/file-pdf.js.map +0 -1
  804. package/lib/cjs/components/system-debug-trace/icons/file-word.d.ts +0 -2
  805. package/lib/cjs/components/system-debug-trace/icons/file-word.js +0 -12
  806. package/lib/cjs/components/system-debug-trace/icons/file-word.js.map +0 -1
  807. package/lib/cjs/components/system-debug-trace/icons/hand.d.ts +0 -2
  808. package/lib/cjs/components/system-debug-trace/icons/hand.js +0 -12
  809. package/lib/cjs/components/system-debug-trace/icons/hand.js.map +0 -1
  810. package/lib/cjs/components/system-debug-trace/icons/head-set.d.ts +0 -2
  811. package/lib/cjs/components/system-debug-trace/icons/head-set.js +0 -12
  812. package/lib/cjs/components/system-debug-trace/icons/head-set.js.map +0 -1
  813. package/lib/cjs/components/system-debug-trace/icons/index.d.ts +0 -16
  814. package/lib/cjs/components/system-debug-trace/icons/index.js +0 -20
  815. package/lib/cjs/components/system-debug-trace/icons/index.js.map +0 -1
  816. package/lib/cjs/components/system-debug-trace/icons/life-ring.d.ts +0 -2
  817. package/lib/cjs/components/system-debug-trace/icons/life-ring.js +0 -12
  818. package/lib/cjs/components/system-debug-trace/icons/life-ring.js.map +0 -1
  819. package/lib/cjs/components/system-debug-trace/icons/link.d.ts +0 -2
  820. package/lib/cjs/components/system-debug-trace/icons/link.js +0 -12
  821. package/lib/cjs/components/system-debug-trace/icons/link.js.map +0 -1
  822. package/lib/cjs/components/system-debug-trace/icons/quote-right.d.ts +0 -2
  823. package/lib/cjs/components/system-debug-trace/icons/quote-right.js +0 -12
  824. package/lib/cjs/components/system-debug-trace/icons/quote-right.js.map +0 -1
  825. package/lib/cjs/components/system-debug-trace/icons/screwdriver-wrench.d.ts +0 -2
  826. package/lib/cjs/components/system-debug-trace/icons/screwdriver-wrench.js +0 -12
  827. package/lib/cjs/components/system-debug-trace/icons/screwdriver-wrench.js.map +0 -1
  828. package/lib/cjs/components/system-debug-trace/icons/split.d.ts +0 -2
  829. package/lib/cjs/components/system-debug-trace/icons/split.js +0 -12
  830. package/lib/cjs/components/system-debug-trace/icons/split.js.map +0 -1
  831. package/lib/cjs/components/system-debug-trace/icons/wand.d.ts +0 -2
  832. package/lib/cjs/components/system-debug-trace/icons/wand.js +0 -12
  833. package/lib/cjs/components/system-debug-trace/icons/wand.js.map +0 -1
  834. package/lib/cjs/components/system-debug-trace/icons/window-restore.d.ts +0 -2
  835. package/lib/cjs/components/system-debug-trace/icons/window-restore.js +0 -12
  836. package/lib/cjs/components/system-debug-trace/icons/window-restore.js.map +0 -1
  837. package/lib/cjs/components/system-debug-trace/index.d.ts +0 -10
  838. package/lib/cjs/components/system-debug-trace/index.js +0 -28
  839. package/lib/cjs/components/system-debug-trace/index.js.map +0 -1
  840. package/lib/cjs/components/system-debug-trace/styles.d.ts +0 -23
  841. package/lib/cjs/components/system-debug-trace/styles.js +0 -286
  842. package/lib/cjs/components/system-debug-trace/styles.js.map +0 -1
  843. package/lib/cjs/components/system-debug-trace/types.d.ts +0 -13
  844. package/lib/cjs/components/system-debug-trace/types.js +0 -3
  845. package/lib/cjs/components/system-debug-trace/types.js.map +0 -1
  846. package/lib/cjs/components/text.d.ts +0 -8
  847. package/lib/cjs/components/text.js +0 -52
  848. package/lib/cjs/components/text.js.map +0 -1
  849. package/lib/cjs/components/title.d.ts +0 -11
  850. package/lib/cjs/components/title.js +0 -23
  851. package/lib/cjs/components/title.js.map +0 -1
  852. package/lib/cjs/components/video.d.ts +0 -9
  853. package/lib/cjs/components/video.js +0 -31
  854. package/lib/cjs/components/video.js.map +0 -1
  855. package/lib/cjs/components/webchat-settings.d.ts +0 -19
  856. package/lib/cjs/components/webchat-settings.js +0 -79
  857. package/lib/cjs/components/webchat-settings.js.map +0 -1
  858. package/lib/cjs/components/whatsapp-button-list.d.ts +0 -20
  859. package/lib/cjs/components/whatsapp-button-list.js +0 -51
  860. package/lib/cjs/components/whatsapp-button-list.js.map +0 -1
  861. package/lib/cjs/components/whatsapp-catalog.d.ts +0 -6
  862. package/lib/cjs/components/whatsapp-catalog.js +0 -25
  863. package/lib/cjs/components/whatsapp-catalog.js.map +0 -1
  864. package/lib/cjs/components/whatsapp-cta-url-button.d.ts +0 -40
  865. package/lib/cjs/components/whatsapp-cta-url-button.js +0 -61
  866. package/lib/cjs/components/whatsapp-cta-url-button.js.map +0 -1
  867. package/lib/cjs/components/whatsapp-interactive-media-carousel.d.ts +0 -31
  868. package/lib/cjs/components/whatsapp-interactive-media-carousel.js +0 -25
  869. package/lib/cjs/components/whatsapp-interactive-media-carousel.js.map +0 -1
  870. package/lib/cjs/components/whatsapp-media-carousel.d.ts +0 -46
  871. package/lib/cjs/components/whatsapp-media-carousel.js +0 -42
  872. package/lib/cjs/components/whatsapp-media-carousel.js.map +0 -1
  873. package/lib/cjs/components/whatsapp-product-carousel.d.ts +0 -32
  874. package/lib/cjs/components/whatsapp-product-carousel.js +0 -34
  875. package/lib/cjs/components/whatsapp-product-carousel.js.map +0 -1
  876. package/lib/cjs/components/whatsapp-product-list.d.ts +0 -15
  877. package/lib/cjs/components/whatsapp-product-list.js +0 -26
  878. package/lib/cjs/components/whatsapp-product-list.js.map +0 -1
  879. package/lib/cjs/components/whatsapp-product.d.ts +0 -7
  880. package/lib/cjs/components/whatsapp-product.js +0 -25
  881. package/lib/cjs/components/whatsapp-product.js.map +0 -1
  882. package/lib/cjs/components/whatsapp-template/index.d.ts +0 -11
  883. package/lib/cjs/components/whatsapp-template/index.js +0 -25
  884. package/lib/cjs/components/whatsapp-template/index.js.map +0 -1
  885. package/lib/cjs/components/whatsapp-template/types.d.ts +0 -107
  886. package/lib/cjs/components/whatsapp-template/types.js +0 -29
  887. package/lib/cjs/components/whatsapp-template/types.js.map +0 -1
  888. package/lib/cjs/constants.d.ts +0 -163
  889. package/lib/cjs/constants.js +0 -189
  890. package/lib/cjs/constants.js.map +0 -1
  891. package/lib/cjs/contexts.d.ts +0 -17
  892. package/lib/cjs/contexts.js +0 -30
  893. package/lib/cjs/contexts.js.map +0 -1
  894. package/lib/cjs/debug-system-messages.d.ts +0 -177
  895. package/lib/cjs/debug-system-messages.js +0 -219
  896. package/lib/cjs/debug-system-messages.js.map +0 -1
  897. package/lib/cjs/dev-app.d.ts +0 -213
  898. package/lib/cjs/dev-app.js +0 -98
  899. package/lib/cjs/dev-app.js.map +0 -1
  900. package/lib/cjs/index-types.d.ts +0 -187
  901. package/lib/cjs/index-types.js +0 -16
  902. package/lib/cjs/index-types.js.map +0 -1
  903. package/lib/cjs/index.d.ts +0 -12
  904. package/lib/cjs/index.js +0 -26
  905. package/lib/cjs/index.js.map +0 -1
  906. package/lib/cjs/message-utils.d.ts +0 -20
  907. package/lib/cjs/message-utils.js +0 -64
  908. package/lib/cjs/message-utils.js.map +0 -1
  909. package/lib/cjs/msg-to-botonic.d.ts +0 -17
  910. package/lib/cjs/msg-to-botonic.js +0 -142
  911. package/lib/cjs/msg-to-botonic.js.map +0 -1
  912. package/lib/cjs/node-app.d.ts +0 -7
  913. package/lib/cjs/node-app.js +0 -23
  914. package/lib/cjs/node-app.js.map +0 -1
  915. package/lib/cjs/react-bot.d.ts +0 -18
  916. package/lib/cjs/react-bot.js +0 -36
  917. package/lib/cjs/react-bot.js.map +0 -1
  918. package/lib/cjs/shared/styles.d.ts +0 -2
  919. package/lib/cjs/shared/styles.js +0 -32
  920. package/lib/cjs/shared/styles.js.map +0 -1
  921. package/lib/cjs/util/dom.d.ts +0 -4
  922. package/lib/cjs/util/dom.js +0 -31
  923. package/lib/cjs/util/dom.js.map +0 -1
  924. package/lib/cjs/util/environment.d.ts +0 -7
  925. package/lib/cjs/util/environment.js +0 -85
  926. package/lib/cjs/util/environment.js.map +0 -1
  927. package/lib/cjs/util/error-boundary.d.ts +0 -7
  928. package/lib/cjs/util/error-boundary.js +0 -32
  929. package/lib/cjs/util/error-boundary.js.map +0 -1
  930. package/lib/cjs/util/functional.d.ts +0 -3
  931. package/lib/cjs/util/functional.js +0 -29
  932. package/lib/cjs/util/functional.js.map +0 -1
  933. package/lib/cjs/util/i18n.d.ts +0 -26
  934. package/lib/cjs/util/i18n.js +0 -165
  935. package/lib/cjs/util/i18n.js.map +0 -1
  936. package/lib/cjs/util/index.d.ts +0 -10
  937. package/lib/cjs/util/index.js +0 -14
  938. package/lib/cjs/util/index.js.map +0 -1
  939. package/lib/cjs/util/logs.d.ts +0 -2
  940. package/lib/cjs/util/logs.js +0 -20
  941. package/lib/cjs/util/logs.js.map +0 -1
  942. package/lib/cjs/util/objects.d.ts +0 -3
  943. package/lib/cjs/util/objects.js +0 -45
  944. package/lib/cjs/util/objects.js.map +0 -1
  945. package/lib/cjs/util/react.d.ts +0 -12
  946. package/lib/cjs/util/react.js +0 -45
  947. package/lib/cjs/util/react.js.map +0 -1
  948. package/lib/cjs/util/regexs.d.ts +0 -2
  949. package/lib/cjs/util/regexs.js +0 -24
  950. package/lib/cjs/util/regexs.js.map +0 -1
  951. package/lib/cjs/util/strings.d.ts +0 -1
  952. package/lib/cjs/util/strings.js +0 -11
  953. package/lib/cjs/util/strings.js.map +0 -1
  954. package/lib/cjs/util/webchat.d.ts +0 -24
  955. package/lib/cjs/util/webchat.js +0 -100
  956. package/lib/cjs/util/webchat.js.map +0 -1
  957. package/lib/cjs/util/webviews.d.ts +0 -2
  958. package/lib/cjs/util/webviews.js +0 -8
  959. package/lib/cjs/util/webviews.js.map +0 -1
  960. package/lib/cjs/webchat/chat-area/index.d.ts +0 -1
  961. package/lib/cjs/webchat/chat-area/index.js +0 -22
  962. package/lib/cjs/webchat/chat-area/index.js.map +0 -1
  963. package/lib/cjs/webchat/chat-area/styles.d.ts +0 -3
  964. package/lib/cjs/webchat/chat-area/styles.js +0 -13
  965. package/lib/cjs/webchat/chat-area/styles.js.map +0 -1
  966. package/lib/cjs/webchat/components/common.d.ts +0 -1
  967. package/lib/cjs/webchat/components/common.js +0 -13
  968. package/lib/cjs/webchat/components/common.js.map +0 -1
  969. package/lib/cjs/webchat/components/conditional-animation.d.ts +0 -1
  970. package/lib/cjs/webchat/components/conditional-animation.js +0 -16
  971. package/lib/cjs/webchat/components/conditional-animation.js.map +0 -1
  972. package/lib/cjs/webchat/components/opened-persistent-menu.d.ts +0 -6
  973. package/lib/cjs/webchat/components/opened-persistent-menu.js +0 -37
  974. package/lib/cjs/webchat/components/opened-persistent-menu.js.map +0 -1
  975. package/lib/cjs/webchat/constants.d.ts +0 -8
  976. package/lib/cjs/webchat/constants.js +0 -13
  977. package/lib/cjs/webchat/constants.js.map +0 -1
  978. package/lib/cjs/webchat/context/actions.d.ts +0 -30
  979. package/lib/cjs/webchat/context/actions.js +0 -36
  980. package/lib/cjs/webchat/context/actions.js.map +0 -1
  981. package/lib/cjs/webchat/context/index.d.ts +0 -4
  982. package/lib/cjs/webchat/context/index.js +0 -102
  983. package/lib/cjs/webchat/context/index.js.map +0 -1
  984. package/lib/cjs/webchat/context/messages-reducer.d.ts +0 -6
  985. package/lib/cjs/webchat/context/messages-reducer.js +0 -175
  986. package/lib/cjs/webchat/context/messages-reducer.js.map +0 -1
  987. package/lib/cjs/webchat/context/types.d.ts +0 -84
  988. package/lib/cjs/webchat/context/types.js +0 -3
  989. package/lib/cjs/webchat/context/types.js.map +0 -1
  990. package/lib/cjs/webchat/context/use-webchat.d.ts +0 -46
  991. package/lib/cjs/webchat/context/use-webchat.js +0 -195
  992. package/lib/cjs/webchat/context/use-webchat.js.map +0 -1
  993. package/lib/cjs/webchat/context/webchat-reducer.d.ts +0 -6
  994. package/lib/cjs/webchat/context/webchat-reducer.js +0 -57
  995. package/lib/cjs/webchat/context/webchat-reducer.js.map +0 -1
  996. package/lib/cjs/webchat/cover-component/index.d.ts +0 -6
  997. package/lib/cjs/webchat/cover-component/index.js +0 -21
  998. package/lib/cjs/webchat/cover-component/index.js.map +0 -1
  999. package/lib/cjs/webchat/custom-messages/index.d.ts +0 -1
  1000. package/lib/cjs/webchat/custom-messages/index.js +0 -7
  1001. package/lib/cjs/webchat/custom-messages/index.js.map +0 -1
  1002. package/lib/cjs/webchat/custom-messages/rating/icons/face-angry.d.ts +0 -3
  1003. package/lib/cjs/webchat/custom-messages/rating/icons/face-angry.js +0 -9
  1004. package/lib/cjs/webchat/custom-messages/rating/icons/face-angry.js.map +0 -1
  1005. package/lib/cjs/webchat/custom-messages/rating/icons/face-frown.d.ts +0 -3
  1006. package/lib/cjs/webchat/custom-messages/rating/icons/face-frown.js +0 -9
  1007. package/lib/cjs/webchat/custom-messages/rating/icons/face-frown.js.map +0 -1
  1008. package/lib/cjs/webchat/custom-messages/rating/icons/face-grin-beam.d.ts +0 -3
  1009. package/lib/cjs/webchat/custom-messages/rating/icons/face-grin-beam.js +0 -9
  1010. package/lib/cjs/webchat/custom-messages/rating/icons/face-grin-beam.js.map +0 -1
  1011. package/lib/cjs/webchat/custom-messages/rating/icons/face-meh.d.ts +0 -3
  1012. package/lib/cjs/webchat/custom-messages/rating/icons/face-meh.js +0 -9
  1013. package/lib/cjs/webchat/custom-messages/rating/icons/face-meh.js.map +0 -1
  1014. package/lib/cjs/webchat/custom-messages/rating/icons/face-smile.d.ts +0 -3
  1015. package/lib/cjs/webchat/custom-messages/rating/icons/face-smile.js +0 -9
  1016. package/lib/cjs/webchat/custom-messages/rating/icons/face-smile.js.map +0 -1
  1017. package/lib/cjs/webchat/custom-messages/rating/icons/index.d.ts +0 -6
  1018. package/lib/cjs/webchat/custom-messages/rating/icons/index.js +0 -10
  1019. package/lib/cjs/webchat/custom-messages/rating/icons/index.js.map +0 -1
  1020. package/lib/cjs/webchat/custom-messages/rating/icons/star.d.ts +0 -3
  1021. package/lib/cjs/webchat/custom-messages/rating/icons/star.js +0 -9
  1022. package/lib/cjs/webchat/custom-messages/rating/icons/star.js.map +0 -1
  1023. package/lib/cjs/webchat/custom-messages/rating/index.d.ts +0 -2
  1024. package/lib/cjs/webchat/custom-messages/rating/index.js +0 -56
  1025. package/lib/cjs/webchat/custom-messages/rating/index.js.map +0 -1
  1026. package/lib/cjs/webchat/custom-messages/rating/rating-selector.d.ts +0 -11
  1027. package/lib/cjs/webchat/custom-messages/rating/rating-selector.js +0 -26
  1028. package/lib/cjs/webchat/custom-messages/rating/rating-selector.js.map +0 -1
  1029. package/lib/cjs/webchat/custom-messages/rating/smileys.d.ts +0 -2
  1030. package/lib/cjs/webchat/custom-messages/rating/smileys.js +0 -19
  1031. package/lib/cjs/webchat/custom-messages/rating/smileys.js.map +0 -1
  1032. package/lib/cjs/webchat/custom-messages/rating/stars.d.ts +0 -2
  1033. package/lib/cjs/webchat/custom-messages/rating/stars.js +0 -11
  1034. package/lib/cjs/webchat/custom-messages/rating/stars.js.map +0 -1
  1035. package/lib/cjs/webchat/custom-messages/rating/styles.d.ts +0 -6
  1036. package/lib/cjs/webchat/custom-messages/rating/styles.js +0 -25
  1037. package/lib/cjs/webchat/custom-messages/rating/styles.js.map +0 -1
  1038. package/lib/cjs/webchat/custom-messages/rating/types.d.ts +0 -13
  1039. package/lib/cjs/webchat/custom-messages/rating/types.js +0 -9
  1040. package/lib/cjs/webchat/custom-messages/rating/types.js.map +0 -1
  1041. package/lib/cjs/webchat/devices/index.d.ts +0 -11
  1042. package/lib/cjs/webchat/devices/index.js +0 -23
  1043. package/lib/cjs/webchat/devices/index.js.map +0 -1
  1044. package/lib/cjs/webchat/header/default-header.d.ts +0 -1
  1045. package/lib/cjs/webchat/header/default-header.js +0 -25
  1046. package/lib/cjs/webchat/header/default-header.js.map +0 -1
  1047. package/lib/cjs/webchat/header/index.d.ts +0 -1
  1048. package/lib/cjs/webchat/header/index.js +0 -23
  1049. package/lib/cjs/webchat/header/index.js.map +0 -1
  1050. package/lib/cjs/webchat/header/styles.d.ts +0 -7
  1051. package/lib/cjs/webchat/header/styles.js +0 -63
  1052. package/lib/cjs/webchat/header/styles.js.map +0 -1
  1053. package/lib/cjs/webchat/hooks/index.d.ts +0 -10
  1054. package/lib/cjs/webchat/hooks/index.js +0 -24
  1055. package/lib/cjs/webchat/hooks/index.js.map +0 -1
  1056. package/lib/cjs/webchat/hooks/use-component-visible.d.ts +0 -7
  1057. package/lib/cjs/webchat/hooks/use-component-visible.js +0 -23
  1058. package/lib/cjs/webchat/hooks/use-component-visible.js.map +0 -1
  1059. package/lib/cjs/webchat/hooks/use-component-will-mount.d.ts +0 -1
  1060. package/lib/cjs/webchat/hooks/use-component-will-mount.js +0 -9
  1061. package/lib/cjs/webchat/hooks/use-component-will-mount.js.map +0 -1
  1062. package/lib/cjs/webchat/hooks/use-device-adapter.d.ts +0 -3
  1063. package/lib/cjs/webchat/hooks/use-device-adapter.js +0 -49
  1064. package/lib/cjs/webchat/hooks/use-device-adapter.js.map +0 -1
  1065. package/lib/cjs/webchat/hooks/use-previous.d.ts +0 -1
  1066. package/lib/cjs/webchat/hooks/use-previous.js +0 -12
  1067. package/lib/cjs/webchat/hooks/use-previous.js.map +0 -1
  1068. package/lib/cjs/webchat/hooks/use-scroll-to-bottom.d.ts +0 -9
  1069. package/lib/cjs/webchat/hooks/use-scroll-to-bottom.js +0 -25
  1070. package/lib/cjs/webchat/hooks/use-scroll-to-bottom.js.map +0 -1
  1071. package/lib/cjs/webchat/hooks/use-scrollbar-controller.d.ts +0 -6
  1072. package/lib/cjs/webchat/hooks/use-scrollbar-controller.js +0 -143
  1073. package/lib/cjs/webchat/hooks/use-scrollbar-controller.js.map +0 -1
  1074. package/lib/cjs/webchat/hooks/use-typing.d.ts +0 -10
  1075. package/lib/cjs/webchat/hooks/use-typing.js +0 -36
  1076. package/lib/cjs/webchat/hooks/use-typing.js.map +0 -1
  1077. package/lib/cjs/webchat/hooks/use-virtual-keyboard-detection.d.ts +0 -3
  1078. package/lib/cjs/webchat/hooks/use-virtual-keyboard-detection.js +0 -26
  1079. package/lib/cjs/webchat/hooks/use-virtual-keyboard-detection.js.map +0 -1
  1080. package/lib/cjs/webchat/hooks/use-webchat-dimensions.d.ts +0 -4
  1081. package/lib/cjs/webchat/hooks/use-webchat-dimensions.js +0 -41
  1082. package/lib/cjs/webchat/hooks/use-webchat-dimensions.js.map +0 -1
  1083. package/lib/cjs/webchat/hooks/use-webchat-resizer.d.ts +0 -4
  1084. package/lib/cjs/webchat/hooks/use-webchat-resizer.js +0 -34
  1085. package/lib/cjs/webchat/hooks/use-webchat-resizer.js.map +0 -1
  1086. package/lib/cjs/webchat/index-types.d.ts +0 -7
  1087. package/lib/cjs/webchat/index-types.js +0 -3
  1088. package/lib/cjs/webchat/index-types.js.map +0 -1
  1089. package/lib/cjs/webchat/index.d.ts +0 -6
  1090. package/lib/cjs/webchat/index.js +0 -20
  1091. package/lib/cjs/webchat/index.js.map +0 -1
  1092. package/lib/cjs/webchat/input-panel/attachment.d.ts +0 -6
  1093. package/lib/cjs/webchat/input-panel/attachment.js +0 -30
  1094. package/lib/cjs/webchat/input-panel/attachment.js.map +0 -1
  1095. package/lib/cjs/webchat/input-panel/emoji-picker.d.ts +0 -5
  1096. package/lib/cjs/webchat/input-panel/emoji-picker.js +0 -29
  1097. package/lib/cjs/webchat/input-panel/emoji-picker.js.map +0 -1
  1098. package/lib/cjs/webchat/input-panel/index.d.ts +0 -9
  1099. package/lib/cjs/webchat/input-panel/index.js +0 -51
  1100. package/lib/cjs/webchat/input-panel/index.js.map +0 -1
  1101. package/lib/cjs/webchat/input-panel/opened-emoji-picker.d.ts +0 -6
  1102. package/lib/cjs/webchat/input-panel/opened-emoji-picker.js +0 -15
  1103. package/lib/cjs/webchat/input-panel/opened-emoji-picker.js.map +0 -1
  1104. package/lib/cjs/webchat/input-panel/persistent-menu.d.ts +0 -5
  1105. package/lib/cjs/webchat/input-panel/persistent-menu.js +0 -21
  1106. package/lib/cjs/webchat/input-panel/persistent-menu.js.map +0 -1
  1107. package/lib/cjs/webchat/input-panel/send-button.d.ts +0 -5
  1108. package/lib/cjs/webchat/input-panel/send-button.js +0 -25
  1109. package/lib/cjs/webchat/input-panel/send-button.js.map +0 -1
  1110. package/lib/cjs/webchat/input-panel/styles.d.ts +0 -3
  1111. package/lib/cjs/webchat/input-panel/styles.js +0 -31
  1112. package/lib/cjs/webchat/input-panel/styles.js.map +0 -1
  1113. package/lib/cjs/webchat/input-panel/textarea.d.ts +0 -10
  1114. package/lib/cjs/webchat/input-panel/textarea.js +0 -52
  1115. package/lib/cjs/webchat/input-panel/textarea.js.map +0 -1
  1116. package/lib/cjs/webchat/input-panel/typing-network-sender.d.ts +0 -52
  1117. package/lib/cjs/webchat/input-panel/typing-network-sender.js +0 -122
  1118. package/lib/cjs/webchat/input-panel/typing-network-sender.js.map +0 -1
  1119. package/lib/cjs/webchat/input-panel/use-typing-chat-event-sender.d.ts +0 -16
  1120. package/lib/cjs/webchat/input-panel/use-typing-chat-event-sender.js +0 -45
  1121. package/lib/cjs/webchat/input-panel/use-typing-chat-event-sender.js.map +0 -1
  1122. package/lib/cjs/webchat/input-panel/use-typing-session.d.ts +0 -15
  1123. package/lib/cjs/webchat/input-panel/use-typing-session.js +0 -98
  1124. package/lib/cjs/webchat/input-panel/use-typing-session.js.map +0 -1
  1125. package/lib/cjs/webchat/message-list/index.d.ts +0 -1
  1126. package/lib/cjs/webchat/message-list/index.js +0 -116
  1127. package/lib/cjs/webchat/message-list/index.js.map +0 -1
  1128. package/lib/cjs/webchat/message-list/intro-message.d.ts +0 -1
  1129. package/lib/cjs/webchat/message-list/intro-message.js +0 -24
  1130. package/lib/cjs/webchat/message-list/intro-message.js.map +0 -1
  1131. package/lib/cjs/webchat/message-list/scroll-button.d.ts +0 -5
  1132. package/lib/cjs/webchat/message-list/scroll-button.js +0 -18
  1133. package/lib/cjs/webchat/message-list/scroll-button.js.map +0 -1
  1134. package/lib/cjs/webchat/message-list/styles.d.ts +0 -9
  1135. package/lib/cjs/webchat/message-list/styles.js +0 -61
  1136. package/lib/cjs/webchat/message-list/styles.js.map +0 -1
  1137. package/lib/cjs/webchat/message-list/unread-messages-banner.d.ts +0 -7
  1138. package/lib/cjs/webchat/message-list/unread-messages-banner.js +0 -18
  1139. package/lib/cjs/webchat/message-list/unread-messages-banner.js.map +0 -1
  1140. package/lib/cjs/webchat/message-list/use-debounce.d.ts +0 -1
  1141. package/lib/cjs/webchat/message-list/use-debounce.js +0 -17
  1142. package/lib/cjs/webchat/message-list/use-debounce.js.map +0 -1
  1143. package/lib/cjs/webchat/message-list/use-notifications.d.ts +0 -7
  1144. package/lib/cjs/webchat/message-list/use-notifications.js +0 -23
  1145. package/lib/cjs/webchat/message-list/use-notifications.js.map +0 -1
  1146. package/lib/cjs/webchat/replies/index.d.ts +0 -1
  1147. package/lib/cjs/webchat/replies/index.js +0 -31
  1148. package/lib/cjs/webchat/replies/index.js.map +0 -1
  1149. package/lib/cjs/webchat/replies/styles.d.ts +0 -8
  1150. package/lib/cjs/webchat/replies/styles.js +0 -25
  1151. package/lib/cjs/webchat/replies/styles.js.map +0 -1
  1152. package/lib/cjs/webchat/session-view.d.ts +0 -1
  1153. package/lib/cjs/webchat/session-view.js +0 -103
  1154. package/lib/cjs/webchat/session-view.js.map +0 -1
  1155. package/lib/cjs/webchat/styles.d.ts +0 -4
  1156. package/lib/cjs/webchat/styles.js +0 -65
  1157. package/lib/cjs/webchat/styles.js.map +0 -1
  1158. package/lib/cjs/webchat/theme/default-theme.d.ts +0 -2
  1159. package/lib/cjs/webchat/theme/default-theme.js +0 -104
  1160. package/lib/cjs/webchat/theme/default-theme.js.map +0 -1
  1161. package/lib/cjs/webchat/theme/types.d.ts +0 -213
  1162. package/lib/cjs/webchat/theme/types.js +0 -3
  1163. package/lib/cjs/webchat/theme/types.js.map +0 -1
  1164. package/lib/cjs/webchat/tracking.d.ts +0 -7
  1165. package/lib/cjs/webchat/tracking.js +0 -39
  1166. package/lib/cjs/webchat/tracking.js.map +0 -1
  1167. package/lib/cjs/webchat/trigger-button/index.d.ts +0 -1
  1168. package/lib/cjs/webchat/trigger-button/index.js +0 -34
  1169. package/lib/cjs/webchat/trigger-button/index.js.map +0 -1
  1170. package/lib/cjs/webchat/trigger-button/styles.d.ts +0 -3
  1171. package/lib/cjs/webchat/trigger-button/styles.js +0 -40
  1172. package/lib/cjs/webchat/trigger-button/styles.js.map +0 -1
  1173. package/lib/cjs/webchat/typing-indicator/index.d.ts +0 -2
  1174. package/lib/cjs/webchat/typing-indicator/index.js +0 -10
  1175. package/lib/cjs/webchat/typing-indicator/index.js.map +0 -1
  1176. package/lib/cjs/webchat/typing-indicator/styles.d.ts +0 -7
  1177. package/lib/cjs/webchat/typing-indicator/styles.js +0 -50
  1178. package/lib/cjs/webchat/typing-indicator/styles.js.map +0 -1
  1179. package/lib/cjs/webchat/use-storage-state-hook.d.ts +0 -1
  1180. package/lib/cjs/webchat/use-storage-state-hook.js +0 -40
  1181. package/lib/cjs/webchat/use-storage-state-hook.js.map +0 -1
  1182. package/lib/cjs/webchat/utils.d.ts +0 -2
  1183. package/lib/cjs/webchat/utils.js +0 -13
  1184. package/lib/cjs/webchat/utils.js.map +0 -1
  1185. package/lib/cjs/webchat/webchat-dev.d.ts +0 -6
  1186. package/lib/cjs/webchat/webchat-dev.js +0 -56
  1187. package/lib/cjs/webchat/webchat-dev.js.map +0 -1
  1188. package/lib/cjs/webchat/webchat.d.ts +0 -3
  1189. package/lib/cjs/webchat/webchat.js +0 -560
  1190. package/lib/cjs/webchat/webchat.js.map +0 -1
  1191. package/lib/cjs/webchat/webview/header.d.ts +0 -1
  1192. package/lib/cjs/webchat/webview/header.js +0 -18
  1193. package/lib/cjs/webchat/webview/header.js.map +0 -1
  1194. package/lib/cjs/webchat/webview/index.d.ts +0 -6
  1195. package/lib/cjs/webchat/webview/index.js +0 -82
  1196. package/lib/cjs/webchat/webview/index.js.map +0 -1
  1197. package/lib/cjs/webchat/webview/styles.d.ts +0 -7
  1198. package/lib/cjs/webchat/webview/styles.js +0 -60
  1199. package/lib/cjs/webchat/webview/styles.js.map +0 -1
  1200. package/lib/cjs/webchat-app.d.ts +0 -114
  1201. package/lib/cjs/webchat-app.js +0 -407
  1202. package/lib/cjs/webchat-app.js.map +0 -1
  1203. package/lib/cjs/webchat.template.html +0 -37
  1204. package/lib/cjs/webview-app.d.ts +0 -7
  1205. package/lib/cjs/webview-app.js +0 -192
  1206. package/lib/cjs/webview-app.js.map +0 -1
  1207. package/lib/cjs/webview.template.html +0 -39
@@ -1,195 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.useWebchat = useWebchat;
4
- const react_1 = require("react");
5
- const default_theme_1 = require("../theme/default-theme");
6
- const actions_1 = require("./actions");
7
- const webchat_reducer_1 = require("./webchat-reducer");
8
- function getWebchatInitialState(initialTheme) {
9
- return {
10
- replies: [],
11
- messagesJSON: [],
12
- messagesComponents: [],
13
- latestInput: {},
14
- typing: false,
15
- webview: undefined,
16
- webviewParams: {},
17
- session: { user: undefined },
18
- lastRoutePath: undefined,
19
- handoff: false,
20
- theme: initialTheme,
21
- themeUpdates: {},
22
- error: {},
23
- online: true,
24
- devSettings: { keepSessionOnReload: false },
25
- isWebchatOpen: false,
26
- isEmojiPickerOpen: false,
27
- isPersistentMenuOpen: false,
28
- isCoverComponentOpen: false,
29
- isCustomComponentRendered: false,
30
- lastMessageUpdate: undefined,
31
- currentAttachment: undefined,
32
- numUnreadMessages: 0,
33
- isLastMessageVisible: true,
34
- isInputFocused: false,
35
- };
36
- }
37
- function useWebchat(theme) {
38
- const initialTheme = theme || default_theme_1.defaultTheme;
39
- const webchatInitialState = getWebchatInitialState(initialTheme);
40
- const [webchatState, webchatDispatch] = (0, react_1.useReducer)(webchat_reducer_1.webchatReducer, webchatInitialState);
41
- const webchatContainerRef = (0, react_1.useRef)(null);
42
- const chatAreaRef = (0, react_1.useRef)(null);
43
- const inputPanelRef = (0, react_1.useRef)(null);
44
- const headerRef = (0, react_1.useRef)(null);
45
- const scrollableMessagesListRef = (0, react_1.useRef)(null);
46
- const repliesRef = (0, react_1.useRef)(null);
47
- const addMessage = (message) => webchatDispatch({ type: actions_1.WebchatAction.ADD_MESSAGE, payload: message });
48
- const addMessageComponent = (message) => webchatDispatch({
49
- type: actions_1.WebchatAction.ADD_MESSAGE_COMPONENT,
50
- payload: message,
51
- });
52
- const updateCustomMessageProps = (props, messageId) => webchatDispatch({
53
- type: actions_1.WebchatAction.UPDATE_CUSTOM_MESSAGE_PROPS,
54
- payload: { messageId, props },
55
- });
56
- const updateMessage = (message) => webchatDispatch({ type: actions_1.WebchatAction.UPDATE_MESSAGE, payload: message });
57
- const updateReplies = (replies) => webchatDispatch({ type: actions_1.WebchatAction.UPDATE_REPLIES, payload: replies });
58
- const removeReplies = () => webchatDispatch({ type: actions_1.WebchatAction.REMOVE_REPLIES, payload: [] });
59
- const updateLatestInput = (input) => webchatDispatch({ type: actions_1.WebchatAction.UPDATE_LATEST_INPUT, payload: input });
60
- const updateTyping = (typing) => webchatDispatch({ type: actions_1.WebchatAction.UPDATE_TYPING, payload: typing });
61
- const updateWebview = (webview, params) => webchatDispatch({
62
- type: actions_1.WebchatAction.UPDATE_WEBVIEW,
63
- payload: { webview, webviewParams: params ?? {} },
64
- });
65
- const removeWebview = () => webchatDispatch({
66
- type: actions_1.WebchatAction.REMOVE_WEBVIEW,
67
- });
68
- const updateSession = (session) => {
69
- webchatDispatch({
70
- type: actions_1.WebchatAction.UPDATE_SESSION,
71
- payload: session,
72
- });
73
- };
74
- const updateLastRoutePath = (path) => webchatDispatch({
75
- type: actions_1.WebchatAction.UPDATE_LAST_ROUTE_PATH,
76
- payload: path,
77
- });
78
- const updateHandoff = (handoff) => webchatDispatch({
79
- type: actions_1.WebchatAction.UPDATE_HANDOFF,
80
- payload: handoff,
81
- });
82
- const updateTheme = (theme, themeUpdates) => {
83
- const payload = themeUpdates !== undefined ? { theme, themeUpdates } : { theme };
84
- webchatDispatch({
85
- type: actions_1.WebchatAction.UPDATE_THEME,
86
- payload,
87
- });
88
- };
89
- const updateDevSettings = (settings) => webchatDispatch({
90
- type: actions_1.WebchatAction.UPDATE_DEV_SETTINGS,
91
- payload: settings,
92
- });
93
- const toggleWebchat = (toggle) => {
94
- webchatDispatch({
95
- type: actions_1.WebchatAction.TOGGLE_WEBCHAT,
96
- payload: toggle,
97
- });
98
- };
99
- const toggleEmojiPicker = (toggle) => webchatDispatch({
100
- type: actions_1.WebchatAction.TOGGLE_EMOJI_PICKER,
101
- payload: toggle,
102
- });
103
- const togglePersistentMenu = (toggle) => webchatDispatch({
104
- type: actions_1.WebchatAction.TOGGLE_PERSISTENT_MENU,
105
- payload: toggle,
106
- });
107
- const toggleCoverComponent = (toggle) => webchatDispatch({
108
- type: actions_1.WebchatAction.TOGGLE_COVER_COMPONENT,
109
- payload: toggle,
110
- });
111
- const doRenderCustomComponent = (toggle) => webchatDispatch({
112
- type: actions_1.WebchatAction.DO_RENDER_CUSTOM_COMPONENT,
113
- payload: toggle,
114
- });
115
- const setError = (error) => webchatDispatch({
116
- type: actions_1.WebchatAction.SET_ERROR,
117
- payload: error,
118
- });
119
- const setOnline = (online) => webchatDispatch({
120
- type: actions_1.WebchatAction.SET_ONLINE,
121
- payload: online,
122
- });
123
- const clearMessages = () => {
124
- webchatDispatch({
125
- type: actions_1.WebchatAction.CLEAR_MESSAGES,
126
- });
127
- };
128
- const updateLastMessageDate = (date) => {
129
- webchatDispatch({
130
- type: actions_1.WebchatAction.UPDATE_LAST_MESSAGE_DATE,
131
- payload: date,
132
- });
133
- };
134
- const setCurrentAttachment = (attachment) => {
135
- webchatDispatch({
136
- type: actions_1.WebchatAction.SET_CURRENT_ATTACHMENT,
137
- payload: attachment,
138
- });
139
- };
140
- const resetUnreadMessages = () => {
141
- webchatDispatch({
142
- type: actions_1.WebchatAction.RESET_UNREAD_MESSAGES,
143
- });
144
- };
145
- const setLastMessageVisible = (isLastMessageVisible) => {
146
- webchatDispatch({
147
- type: actions_1.WebchatAction.SET_LAST_MESSAGE_VISIBLE,
148
- payload: isLastMessageVisible,
149
- });
150
- };
151
- const setIsInputFocused = (isInputFocused) => {
152
- webchatDispatch({
153
- type: actions_1.WebchatAction.SET_IS_INPUT_FOCUSED,
154
- payload: isInputFocused,
155
- });
156
- };
157
- return {
158
- addMessage,
159
- addMessageComponent,
160
- clearMessages,
161
- doRenderCustomComponent,
162
- resetUnreadMessages,
163
- setCurrentAttachment,
164
- setError,
165
- setIsInputFocused,
166
- setLastMessageVisible,
167
- setOnline,
168
- toggleCoverComponent,
169
- toggleEmojiPicker,
170
- togglePersistentMenu,
171
- toggleWebchat,
172
- updateCustomMessageProps,
173
- updateDevSettings,
174
- updateHandoff,
175
- updateLastMessageDate,
176
- updateLastRoutePath,
177
- updateLatestInput,
178
- updateMessage,
179
- updateReplies,
180
- updateSession,
181
- updateTheme,
182
- updateTyping,
183
- updateWebview,
184
- removeReplies,
185
- removeWebview,
186
- webchatState,
187
- webchatContainerRef,
188
- headerRef,
189
- chatAreaRef,
190
- scrollableMessagesListRef,
191
- repliesRef,
192
- inputPanelRef,
193
- };
194
- }
195
- //# sourceMappingURL=use-webchat.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"use-webchat.js","sourceRoot":"","sources":["../../../../src/webchat/context/use-webchat.ts"],"names":[],"mappings":";;AAwFA,gCAsNC;AA7SD,iCAA0C;AAK1C,0DAAqD;AAErD,uCAAyC;AAOzC,uDAAkD;AAElD,SAAS,sBAAsB,CAAC,YAA0B;IACxD,OAAO;QACL,OAAO,EAAE,EAAE;QACX,YAAY,EAAE,EAAE;QAChB,kBAAkB,EAAE,EAAE;QACtB,WAAW,EAAE,EAAE;QACf,MAAM,EAAE,KAAK;QACb,OAAO,EAAE,SAAS;QAClB,aAAa,EAAE,EAAE;QACjB,OAAO,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;QAC5B,aAAa,EAAE,SAAS;QACxB,OAAO,EAAE,KAAK;QACd,KAAK,EAAE,YAAY;QACnB,YAAY,EAAE,EAAE;QAChB,KAAK,EAAE,EAAE;QACT,MAAM,EAAE,IAAI;QACZ,WAAW,EAAE,EAAE,mBAAmB,EAAE,KAAK,EAAE;QAC3C,aAAa,EAAE,KAAK;QACpB,iBAAiB,EAAE,KAAK;QACxB,oBAAoB,EAAE,KAAK;QAC3B,oBAAoB,EAAE,KAAK;QAC3B,yBAAyB,EAAE,KAAK;QAChC,iBAAiB,EAAE,SAAS;QAC5B,iBAAiB,EAAE,SAAS;QAC5B,iBAAiB,EAAE,CAAC;QACpB,oBAAoB,EAAE,IAAI;QAC1B,cAAc,EAAE,KAAK;KACtB,CAAA;AACH,CAAC;AA2CD,SAAgB,UAAU,CAAC,KAAoB;IAC7C,MAAM,YAAY,GAAG,KAAK,IAAI,4BAAY,CAAA;IAC1C,MAAM,mBAAmB,GAAG,sBAAsB,CAAC,YAAY,CAAC,CAAA;IAEhE,MAAM,CAAC,YAAY,EAAE,eAAe,CAAC,GAAG,IAAA,kBAAU,EAChD,gCAAc,EACd,mBAAmB,CACpB,CAAA;IAED,MAAM,mBAAmB,GAAG,IAAA,cAAM,EAAwB,IAAI,CAAC,CAAA;IAC/D,MAAM,WAAW,GAAG,IAAA,cAAM,EAAwB,IAAI,CAAC,CAAA;IACvD,MAAM,aAAa,GAAG,IAAA,cAAM,EAAwB,IAAI,CAAC,CAAA;IACzD,MAAM,SAAS,GAAG,IAAA,cAAM,EAAwB,IAAI,CAAC,CAAA;IACrD,MAAM,yBAAyB,GAAG,IAAA,cAAM,EAAwB,IAAI,CAAC,CAAA;IACrE,MAAM,UAAU,GAAG,IAAA,cAAM,EAAwB,IAAI,CAAC,CAAA;IAEtD,MAAM,UAAU,GAAG,CAAC,OAAuB,EAAE,EAAE,CAC7C,eAAe,CAAC,EAAE,IAAI,EAAE,uBAAa,CAAC,WAAW,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC,CAAA;IAExE,MAAM,mBAAmB,GAAG,CAAC,OAAkC,EAAE,EAAE,CACjE,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,qBAAqB;QACzC,OAAO,EAAE,OAAO;KACjB,CAAC,CAAA;IAEJ,MAAM,wBAAwB,GAAG,CAC/B,KAA0B,EAC1B,SAAkB,EAClB,EAAE,CACF,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,2BAA2B;QAC/C,OAAO,EAAE,EAAE,SAAS,EAAE,KAAK,EAAE;KAC9B,CAAC,CAAA;IAEJ,MAAM,aAAa,GAAG,CAAC,OAAuB,EAAE,EAAE,CAChD,eAAe,CAAC,EAAE,IAAI,EAAE,uBAAa,CAAC,cAAc,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC,CAAA;IAE3E,MAAM,aAAa,GAAG,CAAC,OAAyB,EAAE,EAAE,CAClD,eAAe,CAAC,EAAE,IAAI,EAAE,uBAAa,CAAC,cAAc,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC,CAAA;IAE3E,MAAM,aAAa,GAAG,GAAG,EAAE,CACzB,eAAe,CAAC,EAAE,IAAI,EAAE,uBAAa,CAAC,cAAc,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CAAA;IAEtE,MAAM,iBAAiB,GAAG,CAAC,KAAkB,EAAE,EAAE,CAC/C,eAAe,CAAC,EAAE,IAAI,EAAE,uBAAa,CAAC,mBAAmB,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC,CAAA;IAE9E,MAAM,YAAY,GAAG,CAAC,MAAe,EAAE,EAAE,CACvC,eAAe,CAAC,EAAE,IAAI,EAAE,uBAAa,CAAC,aAAa,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC,CAAA;IAEzE,MAAM,aAAa,GAAG,CAAC,OAAgB,EAAE,MAA+B,EAAE,EAAE,CAC1E,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,cAAc;QAClC,OAAO,EAAE,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,IAAI,EAAE,EAAE;KAClD,CAAC,CAAA;IAEJ,MAAM,aAAa,GAAG,GAAG,EAAE,CACzB,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,cAAc;KACnC,CAAC,CAAA;IAEJ,MAAM,aAAa,GAAG,CAAC,OAAyB,EAAE,EAAE;QAClD,eAAe,CAAC;YACd,IAAI,EAAE,uBAAa,CAAC,cAAc;YAClC,OAAO,EAAE,OAAO;SACjB,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,MAAM,mBAAmB,GAAG,CAAC,IAAY,EAAE,EAAE,CAC3C,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,sBAAsB;QAC1C,OAAO,EAAE,IAAI;KACd,CAAC,CAAA;IAEJ,MAAM,aAAa,GAAG,CAAC,OAAgB,EAAE,EAAE,CACzC,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,cAAc;QAClC,OAAO,EAAE,OAAO;KACjB,CAAC,CAAA;IAEJ,MAAM,WAAW,GAAG,CAAC,KAAmB,EAAE,YAA2B,EAAE,EAAE;QACvE,MAAM,OAAO,GACX,YAAY,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,YAAY,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,CAAA;QAClE,eAAe,CAAC;YACd,IAAI,EAAE,uBAAa,CAAC,YAAY;YAChC,OAAO;SACR,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,MAAM,iBAAiB,GAAG,CAAC,QAAqB,EAAE,EAAE,CAClD,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,mBAAmB;QACvC,OAAO,EAAE,QAAQ;KAClB,CAAC,CAAA;IAEJ,MAAM,aAAa,GAAG,CAAC,MAAe,EAAE,EAAE;QACxC,eAAe,CAAC;YACd,IAAI,EAAE,uBAAa,CAAC,cAAc;YAClC,OAAO,EAAE,MAAM;SAChB,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,MAAM,iBAAiB,GAAG,CAAC,MAAe,EAAE,EAAE,CAC5C,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,mBAAmB;QACvC,OAAO,EAAE,MAAM;KAChB,CAAC,CAAA;IAEJ,MAAM,oBAAoB,GAAG,CAAC,MAAe,EAAE,EAAE,CAC/C,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,sBAAsB;QAC1C,OAAO,EAAE,MAAM;KAChB,CAAC,CAAA;IAEJ,MAAM,oBAAoB,GAAG,CAAC,MAAe,EAAE,EAAE,CAC/C,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,sBAAsB;QAC1C,OAAO,EAAE,MAAM;KAChB,CAAC,CAAA;IAEJ,MAAM,uBAAuB,GAAG,CAAC,MAAe,EAAE,EAAE,CAClD,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,0BAA0B;QAC9C,OAAO,EAAE,MAAM;KAChB,CAAC,CAAA;IAEJ,MAAM,QAAQ,GAAG,CAAC,KAAoB,EAAE,EAAE,CACxC,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,SAAS;QAC7B,OAAO,EAAE,KAAK;KACf,CAAC,CAAA;IAEJ,MAAM,SAAS,GAAG,CAAC,MAAe,EAAE,EAAE,CACpC,eAAe,CAAC;QACd,IAAI,EAAE,uBAAa,CAAC,UAAU;QAC9B,OAAO,EAAE,MAAM;KAChB,CAAC,CAAA;IAEJ,MAAM,aAAa,GAAG,GAAG,EAAE;QACzB,eAAe,CAAC;YACd,IAAI,EAAE,uBAAa,CAAC,cAAc;SACnC,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,MAAM,qBAAqB,GAAG,CAAC,IAAY,EAAE,EAAE;QAC7C,eAAe,CAAC;YACd,IAAI,EAAE,uBAAa,CAAC,wBAAwB;YAC5C,OAAO,EAAE,IAAI;SACd,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,MAAM,oBAAoB,GAAG,CAAC,UAAiB,EAAE,EAAE;QACjD,eAAe,CAAC;YACd,IAAI,EAAE,uBAAa,CAAC,sBAAsB;YAC1C,OAAO,EAAE,UAAU;SACpB,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,MAAM,mBAAmB,GAAG,GAAG,EAAE;QAC/B,eAAe,CAAC;YACd,IAAI,EAAE,uBAAa,CAAC,qBAAqB;SAC1C,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,MAAM,qBAAqB,GAAG,CAAC,oBAA6B,EAAE,EAAE;QAC9D,eAAe,CAAC;YACd,IAAI,EAAE,uBAAa,CAAC,wBAAwB;YAC5C,OAAO,EAAE,oBAAoB;SAC9B,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,MAAM,iBAAiB,GAAG,CAAC,cAAuB,EAAE,EAAE;QACpD,eAAe,CAAC;YACd,IAAI,EAAE,uBAAa,CAAC,oBAAoB;YACxC,OAAO,EAAE,cAAc;SACxB,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,OAAO;QACL,UAAU;QACV,mBAAmB;QACnB,aAAa;QACb,uBAAuB;QACvB,mBAAmB;QACnB,oBAAoB;QACpB,QAAQ;QACR,iBAAiB;QACjB,qBAAqB;QACrB,SAAS;QACT,oBAAoB;QACpB,iBAAiB;QACjB,oBAAoB;QACpB,aAAa;QACb,wBAAwB;QACxB,iBAAiB;QACjB,aAAa;QACb,qBAAqB;QACrB,mBAAmB;QACnB,iBAAiB;QACjB,aAAa;QACb,aAAa;QACb,aAAa;QACb,WAAW;QACX,YAAY;QACZ,aAAa;QACb,aAAa;QACb,aAAa;QACb,YAAY;QACZ,mBAAmB;QACnB,SAAS;QACT,WAAW;QACX,yBAAyB;QACzB,UAAU;QACV,aAAa;KACd,CAAA;AACH,CAAC"}
@@ -1,6 +0,0 @@
1
- import { WebchatAction } from './actions';
2
- import type { WebchatState } from './types';
3
- export declare function webchatReducer(state: WebchatState, action: {
4
- type: WebchatAction;
5
- payload?: any;
6
- }): WebchatState;
@@ -1,57 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.webchatReducer = webchatReducer;
4
- const actions_1 = require("./actions");
5
- const messages_reducer_1 = require("./messages-reducer");
6
- // eslint-disable-next-line complexity
7
- function webchatReducer(state, action) {
8
- switch (action.type) {
9
- case actions_1.WebchatAction.UPDATE_WEBVIEW:
10
- return { ...state, ...action.payload };
11
- case actions_1.WebchatAction.REMOVE_WEBVIEW:
12
- return { ...state, webview: undefined, webviewParams: {} };
13
- case actions_1.WebchatAction.UPDATE_SESSION:
14
- return { ...state, session: { ...action.payload } };
15
- case actions_1.WebchatAction.UPDATE_TYPING:
16
- return { ...state, typing: action.payload };
17
- case actions_1.WebchatAction.UPDATE_THEME:
18
- return {
19
- ...state,
20
- ...action.payload,
21
- };
22
- case actions_1.WebchatAction.UPDATE_HANDOFF:
23
- return { ...state, handoff: action.payload };
24
- case actions_1.WebchatAction.TOGGLE_WEBCHAT: {
25
- const isWebchatOpen = action.payload;
26
- return {
27
- ...state,
28
- isWebchatOpen,
29
- };
30
- }
31
- case actions_1.WebchatAction.TOGGLE_EMOJI_PICKER:
32
- return { ...state, isEmojiPickerOpen: action.payload };
33
- case actions_1.WebchatAction.TOGGLE_PERSISTENT_MENU:
34
- return { ...state, isPersistentMenuOpen: action.payload };
35
- case actions_1.WebchatAction.TOGGLE_COVER_COMPONENT:
36
- return { ...state, isCoverComponentOpen: action.payload };
37
- case actions_1.WebchatAction.DO_RENDER_CUSTOM_COMPONENT:
38
- return { ...state, isCustomComponentRendered: action.payload };
39
- case actions_1.WebchatAction.SET_ERROR:
40
- return { ...state, error: action.payload || {} };
41
- case actions_1.WebchatAction.SET_ONLINE:
42
- return { ...state, online: action.payload };
43
- case actions_1.WebchatAction.UPDATE_DEV_SETTINGS:
44
- return { ...state, devSettings: { ...action.payload } };
45
- case actions_1.WebchatAction.UPDATE_LATEST_INPUT:
46
- return { ...state, latestInput: action.payload };
47
- case actions_1.WebchatAction.UPDATE_LAST_ROUTE_PATH:
48
- return { ...state, lastRoutePath: action.payload };
49
- case actions_1.WebchatAction.SET_CURRENT_ATTACHMENT:
50
- return { ...state, currentAttachment: action.payload };
51
- case actions_1.WebchatAction.SET_IS_INPUT_FOCUSED:
52
- return { ...state, isInputFocused: action.payload };
53
- default:
54
- return (0, messages_reducer_1.messagesReducer)(state, action);
55
- }
56
- }
57
- //# sourceMappingURL=webchat-reducer.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"webchat-reducer.js","sourceRoot":"","sources":["../../../../src/webchat/context/webchat-reducer.ts"],"names":[],"mappings":";;AAKA,wCAoDC;AAzDD,uCAAyC;AACzC,yDAAoD;AAGpD,sCAAsC;AACtC,SAAgB,cAAc,CAC5B,KAAmB,EACnB,MAA8C;IAE9C,QAAQ,MAAM,CAAC,IAAI,EAAE,CAAC;QACpB,KAAK,uBAAa,CAAC,cAAc;YAC/B,OAAO,EAAE,GAAG,KAAK,EAAE,GAAG,MAAM,CAAC,OAAO,EAAE,CAAA;QACxC,KAAK,uBAAa,CAAC,cAAc;YAC/B,OAAO,EAAE,GAAG,KAAK,EAAE,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,EAAE,EAAE,CAAA;QAC5D,KAAK,uBAAa,CAAC,cAAc;YAC/B,OAAO,EAAE,GAAG,KAAK,EAAE,OAAO,EAAE,EAAE,GAAG,MAAM,CAAC,OAAO,EAAE,EAAE,CAAA;QACrD,KAAK,uBAAa,CAAC,aAAa;YAC9B,OAAO,EAAE,GAAG,KAAK,EAAE,MAAM,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QAC7C,KAAK,uBAAa,CAAC,YAAY;YAC7B,OAAO;gBACL,GAAG,KAAK;gBACR,GAAG,MAAM,CAAC,OAAO;aAClB,CAAA;QACH,KAAK,uBAAa,CAAC,cAAc;YAC/B,OAAO,EAAE,GAAG,KAAK,EAAE,OAAO,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QAC9C,KAAK,uBAAa,CAAC,cAAc,CAAC,CAAC,CAAC;YAClC,MAAM,aAAa,GAAG,MAAM,CAAC,OAAO,CAAA;YACpC,OAAO;gBACL,GAAG,KAAK;gBACR,aAAa;aACd,CAAA;QACH,CAAC;QACD,KAAK,uBAAa,CAAC,mBAAmB;YACpC,OAAO,EAAE,GAAG,KAAK,EAAE,iBAAiB,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QACxD,KAAK,uBAAa,CAAC,sBAAsB;YACvC,OAAO,EAAE,GAAG,KAAK,EAAE,oBAAoB,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QAC3D,KAAK,uBAAa,CAAC,sBAAsB;YACvC,OAAO,EAAE,GAAG,KAAK,EAAE,oBAAoB,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QAC3D,KAAK,uBAAa,CAAC,0BAA0B;YAC3C,OAAO,EAAE,GAAG,KAAK,EAAE,yBAAyB,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QAChE,KAAK,uBAAa,CAAC,SAAS;YAC1B,OAAO,EAAE,GAAG,KAAK,EAAE,KAAK,EAAE,MAAM,CAAC,OAAO,IAAI,EAAE,EAAE,CAAA;QAClD,KAAK,uBAAa,CAAC,UAAU;YAC3B,OAAO,EAAE,GAAG,KAAK,EAAE,MAAM,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QAC7C,KAAK,uBAAa,CAAC,mBAAmB;YACpC,OAAO,EAAE,GAAG,KAAK,EAAE,WAAW,EAAE,EAAE,GAAG,MAAM,CAAC,OAAO,EAAE,EAAE,CAAA;QACzD,KAAK,uBAAa,CAAC,mBAAmB;YACpC,OAAO,EAAE,GAAG,KAAK,EAAE,WAAW,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QAClD,KAAK,uBAAa,CAAC,sBAAsB;YACvC,OAAO,EAAE,GAAG,KAAK,EAAE,aAAa,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QACpD,KAAK,uBAAa,CAAC,sBAAsB;YACvC,OAAO,EAAE,GAAG,KAAK,EAAE,iBAAiB,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QACxD,KAAK,uBAAa,CAAC,oBAAoB;YACrC,OAAO,EAAE,GAAG,KAAK,EAAE,cAAc,EAAE,MAAM,CAAC,OAAO,EAAE,CAAA;QACrD;YACE,OAAO,IAAA,kCAAe,EAAC,KAAK,EAAE,MAAM,CAAC,CAAA;IACzC,CAAC;AACH,CAAC"}
@@ -1,6 +0,0 @@
1
- interface Props {
2
- component: any;
3
- componentProps: any;
4
- }
5
- export declare const CoverComponent: ({ component, componentProps }: Props) => import("react/jsx-runtime").JSX.Element | null;
6
- export {};
@@ -1,21 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.CoverComponent = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const react_1 = require("react");
6
- const constants_1 = require("../../constants");
7
- const context_1 = require("../context");
8
- const CoverComponent = ({ component, componentProps }) => {
9
- const { getThemeProperty, toggleCoverComponent, webchatState } = (0, react_1.useContext)(context_1.WebchatContext);
10
- const Cover = component;
11
- const coverComponentProps = getThemeProperty(constants_1.WEBCHAT.CUSTOM_PROPERTIES.coverComponentProps, componentProps);
12
- const closeCoverComponent = () => {
13
- toggleCoverComponent(false);
14
- };
15
- if (!Cover || !webchatState.isCoverComponentOpen) {
16
- return null;
17
- }
18
- return (0, jsx_runtime_1.jsx)(Cover, { closeComponent: closeCoverComponent, ...coverComponentProps });
19
- };
20
- exports.CoverComponent = CoverComponent;
21
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/webchat/cover-component/index.tsx"],"names":[],"mappings":";;;;AAAA,iCAAkC;AAElC,+CAAyC;AACzC,wCAA2C;AAOpC,MAAM,cAAc,GAAG,CAAC,EAAE,SAAS,EAAE,cAAc,EAAS,EAAE,EAAE;IACrE,MAAM,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,YAAY,EAAE,GAC5D,IAAA,kBAAU,EAAC,wBAAc,CAAC,CAAA;IAE5B,MAAM,KAAK,GAAG,SAAS,CAAA;IAEvB,MAAM,mBAAmB,GAAG,gBAAgB,CAC1C,mBAAO,CAAC,iBAAiB,CAAC,mBAAmB,EAC7C,cAAc,CACf,CAAA;IAED,MAAM,mBAAmB,GAAG,GAAG,EAAE;QAC/B,oBAAoB,CAAC,KAAK,CAAC,CAAA;IAC7B,CAAC,CAAA;IAED,IAAI,CAAC,KAAK,IAAI,CAAC,YAAY,CAAC,oBAAoB,EAAE,CAAC;QACjD,OAAO,IAAI,CAAA;IACb,CAAC;IAED,OAAO,uBAAC,KAAK,IAAC,cAAc,EAAE,mBAAmB,KAAM,mBAAmB,GAAI,CAAA;AAChF,CAAC,CAAA;AApBY,QAAA,cAAc,kBAoB1B"}
@@ -1 +0,0 @@
1
- export { default as CustomRatingMessage } from './rating';
@@ -1,7 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.CustomRatingMessage = void 0;
4
- const tslib_1 = require("tslib");
5
- var rating_1 = require("./rating");
6
- Object.defineProperty(exports, "CustomRatingMessage", { enumerable: true, get: function () { return tslib_1.__importDefault(rating_1).default; } });
7
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/webchat/custom-messages/index.ts"],"names":[],"mappings":";;;;AAAA,mCAAyD;AAAhD,sIAAA,OAAO,OAAuB"}
@@ -1,3 +0,0 @@
1
- /** biome-ignore-all lint/a11y/noSvgWithoutTitle: This is a SVG icon */
2
- import type { RatingIconProps } from '../types';
3
- export declare const FaceAngrySvg: ({ color, selected }: RatingIconProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FaceAngrySvg = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const FaceAngrySvg = ({ color, selected }) => {
6
- return selected ? ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256zM338.7 395.9c6.6-5.9 7.1-16 1.2-22.6C323.8 355.4 295.7 336 256 336s-67.8 19.4-83.9 37.3c-5.9 6.6-5.4 16.7 1.2 22.6s16.7 5.4 22.6-1.2c11.7-13 31.6-26.7 60.1-26.7s48.4 13.7 60.1 26.7c5.9 6.6 16 7.1 22.6 1.2zM176.4 272c17.7 0 32-14.3 32-32c0-1.5-.1-3-.3-4.4l10.9 3.6c8.4 2.8 17.4-1.7 20.2-10.1s-1.7-17.4-10.1-20.2l-96-32c-8.4-2.8-17.4 1.7-20.2 10.1s1.7 17.4 10.1 20.2l30.7 10.2c-5.8 5.8-9.3 13.8-9.3 22.6c0 17.7 14.3 32 32 32zm192-32c0-8.9-3.6-17-9.5-22.8l30.2-10.1c8.4-2.8 12.9-11.9 10.1-20.2s-11.9-12.9-20.2-10.1l-96 32c-8.4 2.8-12.9 11.9-10.1 20.2s11.9 12.9 20.2 10.1l11.7-3.9c-.2 1.5-.3 3.1-.3 4.7c0 17.7 14.3 32 32 32s32-14.3 32-32z', fill: 'currentColor' }) })) : ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M256 48a208 208 0 1 1 0 416 208 208 0 1 1 0-416zm0 464A256 256 0 1 0 256 0a256 256 0 1 0 0 512zm72.4-118.5c9.7-9 10.2-24.2 1.2-33.9C315.3 344.3 290.6 328 256 328s-59.3 16.3-73.5 31.6c-9 9.7-8.5 24.9 1.2 33.9s24.9 8.5 33.9-1.2c7.4-7.9 20-16.4 38.5-16.4s31.1 8.5 38.5 16.4c9 9.7 24.2 10.2 33.9 1.2zM176.4 272c17.7 0 32-14.3 32-32c0-1.5-.1-3-.3-4.4l10.9 3.6c8.4 2.8 17.4-1.7 20.2-10.1s-1.7-17.4-10.1-20.2l-96-32c-8.4-2.8-17.4 1.7-20.2 10.1s1.7 17.4 10.1 20.2l30.7 10.2c-5.8 5.8-9.3 13.8-9.3 22.6c0 17.7 14.3 32 32 32zm192-32c0-8.9-3.6-17-9.5-22.8l30.2-10.1c8.4-2.8 12.9-11.9 10.1-20.2s-11.9-12.9-20.2-10.1l-96 32c-8.4 2.8-12.9 11.9-10.1 20.2s11.9 12.9 20.2 10.1l11.7-3.9c-.2 1.5-.3 3.1-.3 4.7c0 17.7 14.3 32 32 32s32-14.3 32-32z', fill: 'currentColor' }) }));
7
- };
8
- exports.FaceAngrySvg = FaceAngrySvg;
9
- //# sourceMappingURL=face-angry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"face-angry.js","sourceRoot":"","sources":["../../../../../../src/webchat/custom-messages/rating/icons/face-angry.tsx"],"names":[],"mappings":";;;;AAGO,MAAM,YAAY,GAAG,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAmB,EAAE,EAAE;IACnE,OAAO,QAAQ,CAAC,CAAC,CAAC,CAChB,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,2qBAA2qB,EAC7qB,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAC,CAAC,CAAC,CACF,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,utBAAutB,EACztB,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAA;AACH,CAAC,CAAA;AAhBY,QAAA,YAAY,gBAgBxB"}
@@ -1,3 +0,0 @@
1
- /** biome-ignore-all lint/a11y/noSvgWithoutTitle: This is a SVG icon */
2
- import type { RatingIconProps } from '../types';
3
- export declare const FaceFrownSvg: ({ color, selected }: RatingIconProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FaceFrownSvg = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const FaceFrownSvg = ({ color, selected }) => {
6
- return selected ? ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM159.3 388.7c-2.6 8.4-11.6 13.2-20 10.5s-13.2-11.6-10.5-20C145.2 326.1 196.3 288 256 288s110.8 38.1 127.3 91.3c2.6 8.4-2.1 17.4-10.5 20s-17.4-2.1-20-10.5C340.5 349.4 302.1 320 256 320s-84.5 29.4-96.7 68.7zM144.4 208a32 32 0 1 1 64 0 32 32 0 1 1 -64 0zm192-32a32 32 0 1 1 0 64 32 32 0 1 1 0-64z', fill: 'currentColor' }) })) : ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M464 256A208 208 0 1 0 48 256a208 208 0 1 0 416 0zM0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256zM174.6 384.1c-4.5 12.5-18.2 18.9-30.7 14.4s-18.9-18.2-14.4-30.7C146.9 319.4 198.9 288 256 288s109.1 31.4 126.6 79.9c4.5 12.5-2 26.2-14.4 30.7s-26.2-2-30.7-14.4C328.2 358.5 297.2 336 256 336s-72.2 22.5-81.4 48.1zM144.4 208a32 32 0 1 1 64 0 32 32 0 1 1 -64 0zm192-32a32 32 0 1 1 0 64 32 32 0 1 1 0-64z', fill: 'currentColor' }) }));
7
- };
8
- exports.FaceFrownSvg = FaceFrownSvg;
9
- //# sourceMappingURL=face-frown.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"face-frown.js","sourceRoot":"","sources":["../../../../../../src/webchat/custom-messages/rating/icons/face-frown.tsx"],"names":[],"mappings":";;;;AAGO,MAAM,YAAY,GAAG,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAmB,EAAE,EAAE;IACnE,OAAO,QAAQ,CAAC,CAAC,CAAC,CAChB,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,wVAAwV,EAC1V,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAC,CAAC,CAAC,CACF,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,8YAA8Y,EAChZ,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAA;AACH,CAAC,CAAA;AAhBY,QAAA,YAAY,gBAgBxB"}
@@ -1,3 +0,0 @@
1
- /** biome-ignore-all lint/a11y/noSvgWithoutTitle: This is a SVG icon */
2
- import type { RatingIconProps } from '../types';
3
- export declare const FaceGrinBeamSvg: ({ color, selected }: RatingIconProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FaceGrinBeamSvg = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const FaceGrinBeamSvg = ({ color, selected }) => {
6
- return selected ? ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM388.1 312.8c12.3-3.8 24.3 6.9 19.3 18.7C382.4 390.6 324.2 432 256.3 432s-126.2-41.4-151.1-100.5c-5-11.8 7-22.5 19.3-18.7c39.7 12.2 84.5 19 131.8 19s92.1-6.8 131.8-19zm-170.5-84s0 0 0 0c0 0 0 0 0 0l-.2-.2c-.2-.2-.4-.5-.7-.9c-.6-.8-1.6-2-2.8-3.4c-2.5-2.8-6-6.6-10.2-10.3c-8.8-7.8-18.8-14-27.7-14s-18.9 6.2-27.7 14c-4.2 3.7-7.7 7.5-10.2 10.3c-1.2 1.4-2.2 2.6-2.8 3.4c-.3 .4-.6 .7-.7 .9l-.2 .2c0 0 0 0 0 0c0 0 0 0 0 0s0 0 0 0c-2.1 2.8-5.7 3.9-8.9 2.8s-5.5-4.1-5.5-7.6c0-17.9 6.7-35.6 16.6-48.8c9.8-13 23.9-23.2 39.4-23.2s29.6 10.2 39.4 23.2c9.9 13.2 16.6 30.9 16.6 48.8c0 3.4-2.2 6.5-5.5 7.6s-6.9 0-8.9-2.8c0 0 0 0 0 0s0 0 0 0zm160 0c0 0 0 0 0 0l-.2-.2c-.2-.2-.4-.5-.7-.9c-.6-.8-1.6-2-2.8-3.4c-2.5-2.8-6-6.6-10.2-10.3c-8.8-7.8-18.8-14-27.7-14s-18.9 6.2-27.7 14c-4.2 3.7-7.7 7.5-10.2 10.3c-1.2 1.4-2.2 2.6-2.8 3.4c-.3 .4-.6 .7-.7 .9l-.2 .2c0 0 0 0 0 0c0 0 0 0 0 0s0 0 0 0c-2.1 2.8-5.7 3.9-8.9 2.8s-5.5-4.1-5.5-7.6c0-17.9 6.7-35.6 16.6-48.8c9.8-13 23.9-23.2 39.4-23.2s29.6 10.2 39.4 23.2c9.9 13.2 16.6 30.9 16.6 48.8c0 3.4-2.2 6.5-5.5 7.6s-6.9 0-8.9-2.8c0 0 0 0 0 0s0 0 0 0s0 0 0 0z', fill: 'currentColor' }) })) : ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M464 256A208 208 0 1 0 48 256a208 208 0 1 0 416 0zM0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256zm349.5 52.4c18.7-4.4 35.9 12 25.5 28.1C350.4 374.6 306.3 400 255.9 400s-94.5-25.4-119.1-63.5c-10.4-16.1 6.8-32.5 25.5-28.1c28.9 6.8 60.5 10.5 93.6 10.5s64.7-3.7 93.6-10.5zM217.6 228.8s0 0 0 0c0 0 0 0 0 0l-.2-.2c-.2-.2-.4-.5-.7-.9c-.6-.8-1.6-2-2.8-3.4c-2.5-2.8-6-6.6-10.2-10.3c-8.8-7.8-18.8-14-27.7-14s-18.9 6.2-27.7 14c-4.2 3.7-7.7 7.5-10.2 10.3c-1.2 1.4-2.2 2.6-2.8 3.4c-.3 .4-.6 .7-.7 .9l-.2 .2c0 0 0 0 0 0c0 0 0 0 0 0s0 0 0 0c-2.1 2.8-5.7 3.9-8.9 2.8s-5.5-4.1-5.5-7.6c0-17.9 6.7-35.6 16.6-48.8c9.8-13 23.9-23.2 39.4-23.2s29.6 10.2 39.4 23.2c9.9 13.2 16.6 30.9 16.6 48.8c0 3.4-2.2 6.5-5.5 7.6s-6.9 0-8.9-2.8c0 0 0 0 0 0s0 0 0 0zm160 0c0 0 0 0 0 0l-.2-.2c-.2-.2-.4-.5-.7-.9c-.6-.8-1.6-2-2.8-3.4c-2.5-2.8-6-6.6-10.2-10.3c-8.8-7.8-18.8-14-27.7-14s-18.9 6.2-27.7 14c-4.2 3.7-7.7 7.5-10.2 10.3c-1.2 1.4-2.2 2.6-2.8 3.4c-.3 .4-.6 .7-.7 .9l-.2 .2c0 0 0 0 0 0c0 0 0 0 0 0s0 0 0 0c-2.1 2.8-5.7 3.9-8.9 2.8s-5.5-4.1-5.5-7.6c0-17.9 6.7-35.6 16.6-48.8c9.8-13 23.9-23.2 39.4-23.2s29.6 10.2 39.4 23.2c9.9 13.2 16.6 30.9 16.6 48.8c0 3.4-2.2 6.5-5.5 7.6s-6.9 0-8.9-2.8c0 0 0 0 0 0s0 0 0 0s0 0 0 0z', fill: 'currentColor' }) }));
7
- };
8
- exports.FaceGrinBeamSvg = FaceGrinBeamSvg;
9
- //# sourceMappingURL=face-grin-beam.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"face-grin-beam.js","sourceRoot":"","sources":["../../../../../../src/webchat/custom-messages/rating/icons/face-grin-beam.tsx"],"names":[],"mappings":";;;;AAGO,MAAM,eAAe,GAAG,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAmB,EAAE,EAAE;IACtE,OAAO,QAAQ,CAAC,CAAC,CAAC,CAChB,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,wmCAAwmC,EAC1mC,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAC,CAAC,CAAC,CACF,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,8pCAA8pC,EAChqC,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAA;AACH,CAAC,CAAA;AAhBY,QAAA,eAAe,mBAgB3B"}
@@ -1,3 +0,0 @@
1
- /** biome-ignore-all lint/a11y/noSvgWithoutTitle: we don't need a title for the svg */
2
- import type { RatingIconProps } from '../types';
3
- export declare const FaceMehSvg: ({ color, selected }: RatingIconProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FaceMehSvg = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const FaceMehSvg = ({ color, selected }) => {
6
- return selected ? ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM176.4 176a32 32 0 1 1 0 64 32 32 0 1 1 0-64zm128 32a32 32 0 1 1 64 0 32 32 0 1 1 -64 0zM160 336l192 0c8.8 0 16 7.2 16 16s-7.2 16-16 16l-192 0c-8.8 0-16-7.2-16-16s7.2-16 16-16z', fill: 'currentColor' }) })) : ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M464 256A208 208 0 1 1 48 256a208 208 0 1 1 416 0zM256 0a256 256 0 1 0 0 512A256 256 0 1 0 256 0zM176.4 240a32 32 0 1 0 0-64 32 32 0 1 0 0 64zm192-32a32 32 0 1 0 -64 0 32 32 0 1 0 64 0zM184 328c-13.3 0-24 10.7-24 24s10.7 24 24 24l144 0c13.3 0 24-10.7 24-24s-10.7-24-24-24l-144 0z', fill: 'currentColor' }) }));
7
- };
8
- exports.FaceMehSvg = FaceMehSvg;
9
- //# sourceMappingURL=face-meh.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"face-meh.js","sourceRoot":"","sources":["../../../../../../src/webchat/custom-messages/rating/icons/face-meh.tsx"],"names":[],"mappings":";;;;AAGO,MAAM,UAAU,GAAG,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAmB,EAAE,EAAE;IACjE,OAAO,QAAQ,CAAC,CAAC,CAAC,CAChB,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,mOAAmO,EACrO,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAC,CAAC,CAAC,CACF,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,yRAAyR,EAC3R,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAA;AACH,CAAC,CAAA;AAhBY,QAAA,UAAU,cAgBtB"}
@@ -1,3 +0,0 @@
1
- /** biome-ignore-all lint/a11y/noSvgWithoutTitle: This is a SVG icon */
2
- import type { RatingIconProps } from '../types';
3
- export declare const FaceSmileSvg: ({ color, selected }: RatingIconProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FaceSmileSvg = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const FaceSmileSvg = ({ color, selected }) => {
6
- return selected ? ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM164.1 325.5C182 346.2 212.6 368 256 368s74-21.8 91.9-42.5c5.8-6.7 15.9-7.4 22.6-1.6s7.4 15.9 1.6 22.6C349.8 372.1 311.1 400 256 400s-93.8-27.9-116.1-53.5c-5.8-6.7-5.1-16.8 1.6-22.6s16.8-5.1 22.6 1.6zM144.4 208a32 32 0 1 1 64 0 32 32 0 1 1 -64 0zm192-32a32 32 0 1 1 0 64 32 32 0 1 1 0-64z', fill: 'currentColor' }) })) : ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 512 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M464 256A208 208 0 1 0 48 256a208 208 0 1 0 416 0zM0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256zm177.6 62.1C192.8 334.5 218.8 352 256 352s63.2-17.5 78.4-33.9c9-9.7 24.2-10.4 33.9-1.4s10.4 24.2 1.4 33.9c-22 23.8-60 49.4-113.6 49.4s-91.7-25.5-113.6-49.4c-9-9.7-8.4-24.9 1.4-33.9s24.9-8.4 33.9 1.4zM144.4 208a32 32 0 1 1 64 0 32 32 0 1 1 -64 0zm192-32a32 32 0 1 1 0 64 32 32 0 1 1 0-64z', fill: 'currentColor' }) }));
7
- };
8
- exports.FaceSmileSvg = FaceSmileSvg;
9
- //# sourceMappingURL=face-smile.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"face-smile.js","sourceRoot":"","sources":["../../../../../../src/webchat/custom-messages/rating/icons/face-smile.tsx"],"names":[],"mappings":";;;;AAGO,MAAM,YAAY,GAAG,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAmB,EAAE,EAAE;IACnE,OAAO,QAAQ,CAAC,CAAC,CAAC,CAChB,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,mVAAmV,EACrV,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAC,CAAC,CAAC,CACF,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,kYAAkY,EACpY,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAA;AACH,CAAC,CAAA;AAhBY,QAAA,YAAY,gBAgBxB"}
@@ -1,6 +0,0 @@
1
- export * from './face-angry';
2
- export * from './face-frown';
3
- export * from './face-grin-beam';
4
- export * from './face-meh';
5
- export * from './face-smile';
6
- export * from './star';
@@ -1,10 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- tslib_1.__exportStar(require("./face-angry"), exports);
5
- tslib_1.__exportStar(require("./face-frown"), exports);
6
- tslib_1.__exportStar(require("./face-grin-beam"), exports);
7
- tslib_1.__exportStar(require("./face-meh"), exports);
8
- tslib_1.__exportStar(require("./face-smile"), exports);
9
- tslib_1.__exportStar(require("./star"), exports);
10
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/webchat/custom-messages/rating/icons/index.ts"],"names":[],"mappings":";;;AAAA,uDAA4B;AAC5B,uDAA4B;AAC5B,2DAAgC;AAChC,qDAA0B;AAC1B,uDAA4B;AAC5B,iDAAsB"}
@@ -1,3 +0,0 @@
1
- /** biome-ignore-all lint/a11y/noSvgWithoutTitle: This is a SVG icon */
2
- import type { RatingIconProps } from '../types';
3
- export declare const StarSvg: ({ color, selected }: RatingIconProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.StarSvg = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const StarSvg = ({ color, selected }) => {
6
- return selected ? ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 576 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M316.9 18C311.6 7 300.4 0 288.1 0s-23.4 7-28.8 18L195 150.3 51.4 171.5c-12 1.8-22 10.2-25.7 21.7s-.7 24.2 7.9 32.7L137.8 329 113.2 474.7c-2 12 3 24.2 12.9 31.3s23 8 33.8 2.3l128.3-68.5 128.3 68.5c10.8 5.7 23.9 4.9 33.8-2.3s14.9-19.3 12.9-31.3L438.5 329 542.7 225.9c8.6-8.5 11.7-21.2 7.9-32.7s-13.7-19.9-25.7-21.7L381.2 150.3 316.9 18z', fill: 'currentColor' }) })) : ((0, jsx_runtime_1.jsx)("svg", { xmlns: 'http://www.w3.org/2000/svg', viewBox: '0 0 576 512', color: color, children: (0, jsx_runtime_1.jsx)("path", { d: 'M287.9 0c9.2 0 17.6 5.2 21.6 13.5l68.6 141.3 153.2 22.6c9 1.3 16.5 7.6 19.3 16.3s.5 18.1-5.9 24.5L433.6 328.4l26.2 155.6c1.5 9-2.2 18.1-9.7 23.5s-17.3 6-25.3 1.7l-137-73.2L151 509.1c-8.1 4.3-17.9 3.7-25.3-1.7s-11.2-14.5-9.7-23.5l26.2-155.6L31.1 218.2c-6.5-6.4-8.7-15.9-5.9-24.5s10.3-14.9 19.3-16.3l153.2-22.6L266.3 13.5C270.4 5.2 278.7 0 287.9 0zm0 79L235.4 187.2c-3.5 7.1-10.2 12.1-18.1 13.3L99 217.9 184.9 303c5.5 5.5 8.1 13.3 6.8 21L171.4 443.7l105.2-56.2c7.1-3.8 15.6-3.8 22.6 0l105.2 56.2L384.2 324.1c-1.3-7.7 1.2-15.5 6.8-21l85.9-85.1L358.6 200.5c-7.8-1.2-14.6-6.1-18.1-13.3L287.9 79z', fill: 'currentColor' }) }));
7
- };
8
- exports.StarSvg = StarSvg;
9
- //# sourceMappingURL=star.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"star.js","sourceRoot":"","sources":["../../../../../../src/webchat/custom-messages/rating/icons/star.tsx"],"names":[],"mappings":";;;;AAGO,MAAM,OAAO,GAAG,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAmB,EAAE,EAAE;IAC9D,OAAO,QAAQ,CAAC,CAAC,CAAC,CAChB,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,gVAAgV,EAClV,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAC,CAAC,CAAC,CACF,gCAAK,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAC,aAAa,EAAC,KAAK,EAAE,KAAK,YACxE,iCACE,CAAC,EAAC,glBAAglB,EACllB,IAAI,EAAC,cAAc,GACnB,GACE,CACP,CAAA;AACH,CAAC,CAAA;AAhBY,QAAA,OAAO,WAgBnB"}
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../components").CustomMessageType;
2
- export default _default;
@@ -1,56 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const jsx_runtime_1 = require("react/jsx-runtime");
4
- const core_1 = require("@botonic/core");
5
- const react_1 = require("react");
6
- const styled_components_1 = require("styled-components");
7
- const components_1 = require("../../../components");
8
- const context_1 = require("../../context");
9
- const rating_selector_1 = require("./rating-selector");
10
- const styles_1 = require("./styles");
11
- const types_1 = require("./types");
12
- const ratingValues = {
13
- [types_1.RatingType.Stars]: [
14
- '⭐'.repeat(1),
15
- '⭐'.repeat(2),
16
- '⭐'.repeat(3),
17
- '⭐'.repeat(4),
18
- '⭐'.repeat(5),
19
- ],
20
- [types_1.RatingType.Smileys]: ['😠', '🙁', '😐', '🙂', '😄'],
21
- };
22
- const CustomRatingMessage = props => {
23
- const { payloads, messageText, buttonText, ratingType, id, valueSent } = props;
24
- const { updateCustomMessageProps, sendInput } = (0, react_1.useContext)(context_1.WebchatContext);
25
- const theme = (0, react_1.useContext)(styled_components_1.ThemeContext);
26
- const color = theme?.brand?.color ?? '';
27
- const [ratingValue, setRatingValue] = (0, react_1.useState)(valueSent ? valueSent : -1);
28
- const [showRating, setShowRating] = (0, react_1.useState)(true);
29
- const ratingChanged = (newRating) => {
30
- setRatingValue(newRating);
31
- };
32
- const handleButtonSend = () => {
33
- if (ratingValue === -1) {
34
- return;
35
- }
36
- const json = {
37
- valueSent: ratingValue,
38
- };
39
- updateCustomMessageProps(json, id);
40
- setShowRating(false);
41
- const payload = payloads[ratingValue - 1];
42
- const input = {
43
- type: core_1.INPUT.POSTBACK,
44
- payload,
45
- referral: ratingValues[ratingType][ratingValue - 1],
46
- };
47
- void sendInput(input);
48
- };
49
- const disabled = ratingValue === -1;
50
- return ((0, jsx_runtime_1.jsxs)("div", { className: 'rating-message-container', children: [(0, jsx_runtime_1.jsxs)(styles_1.MessageBubble, { className: 'rating-message-bubble', children: [messageText, (0, jsx_runtime_1.jsx)(rating_selector_1.RatingSelector, { color: color, onRatingChange: ratingChanged, ratingValue: ratingValue, ratingType: ratingType, valueSent: valueSent })] }), !props?.valueSent && showRating && ((0, jsx_runtime_1.jsx)(components_1.Button, { autodisable: true, disabled: disabled, onClick: handleButtonSend, children: buttonText }))] }));
51
- };
52
- exports.default = (0, components_1.customMessage)({
53
- name: 'custom-rating',
54
- component: CustomRatingMessage,
55
- });
56
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/webchat/custom-messages/rating/index.tsx"],"names":[],"mappings":";;;AAAA,wCAAqD;AAErD,iCAA4C;AAC5C,yDAAgD;AAEhD,oDAA2D;AAC3D,2CAA8C;AAC9C,uDAAkD;AAClD,qCAAwC;AACxC,mCAAoC;AAWpC,MAAM,YAAY,GAAG;IACnB,CAAC,kBAAU,CAAC,KAAK,CAAC,EAAE;QAClB,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC;QACb,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC;QACb,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC;QACb,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC;QACb,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC;KACd;IACD,CAAC,kBAAU,CAAC,OAAO,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC;CAC5C,CAAA;AAEV,MAAM,mBAAmB,GAAuC,KAAK,CAAC,EAAE;IACtE,MAAM,EAAE,QAAQ,EAAE,WAAW,EAAE,UAAU,EAAE,UAAU,EAAE,EAAE,EAAE,SAAS,EAAE,GAAG,KAAK,CAAA;IAC9E,MAAM,EAAE,wBAAwB,EAAE,SAAS,EAAE,GAAG,IAAA,kBAAU,EAAC,wBAAc,CAAC,CAAA;IAE1E,MAAM,KAAK,GAAG,IAAA,kBAAU,EAAC,gCAAY,CAAC,CAAA;IACtC,MAAM,KAAK,GAAG,KAAK,EAAE,KAAK,EAAE,KAAK,IAAI,EAAE,CAAA;IAEvC,MAAM,CAAC,WAAW,EAAE,cAAc,CAAC,GAAG,IAAA,gBAAQ,EAAC,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IAC1E,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,IAAA,gBAAQ,EAAC,IAAI,CAAC,CAAA;IAElD,MAAM,aAAa,GAAG,CAAC,SAAiB,EAAE,EAAE;QAC1C,cAAc,CAAC,SAAS,CAAC,CAAA;IAC3B,CAAC,CAAA;IAED,MAAM,gBAAgB,GAAG,GAAG,EAAE;QAC5B,IAAI,WAAW,KAAK,CAAC,CAAC,EAAE,CAAC;YACvB,OAAM;QACR,CAAC;QAED,MAAM,IAAI,GAAG;YACX,SAAS,EAAE,WAAW;SACvB,CAAA;QACD,wBAAwB,CAAC,IAAI,EAAE,EAAE,CAAC,CAAA;QAElC,aAAa,CAAC,KAAK,CAAC,CAAA;QACpB,MAAM,OAAO,GAAG,QAAQ,CAAC,WAAW,GAAG,CAAC,CAAC,CAAA;QAEzC,MAAM,KAAK,GAAG;YACZ,IAAI,EAAE,YAAK,CAAC,QAAqB;YACjC,OAAO;YACP,QAAQ,EAAE,YAAY,CAAC,UAAU,CAAC,CAAC,WAAW,GAAG,CAAC,CAAC;SACpD,CAAA;QACD,KAAK,SAAS,CAAC,KAAK,CAAC,CAAA;IACvB,CAAC,CAAA;IAED,MAAM,QAAQ,GAAG,WAAW,KAAK,CAAC,CAAC,CAAA;IAEnC,OAAO,CACL,iCAAK,SAAS,EAAC,0BAA0B,aACvC,wBAAC,sBAAa,IAAC,SAAS,EAAC,uBAAuB,aAC7C,WAAW,EACZ,uBAAC,gCAAc,IACb,KAAK,EAAE,KAAK,EACZ,cAAc,EAAE,aAAa,EAC7B,WAAW,EAAE,WAAW,EACxB,UAAU,EAAE,UAAU,EACtB,SAAS,EAAE,SAAS,GACpB,IACY,EACf,CAAC,KAAK,EAAE,SAAS,IAAI,UAAU,IAAI,CAClC,uBAAC,mBAAM,IACL,WAAW,EAAE,IAAI,EACjB,QAAQ,EAAE,QAAQ,EAClB,OAAO,EAAE,gBAAgB,YAExB,UAAU,GACJ,CACV,IACG,CACP,CAAA;AACH,CAAC,CAAA;AAED,kBAAe,IAAA,0BAAa,EAAC;IAC3B,IAAI,EAAE,eAAe;IACrB,SAAS,EAAE,mBAAmB;CAC/B,CAAC,CAAA"}
@@ -1,11 +0,0 @@
1
- import { RatingType } from './types';
2
- interface RatingSelectorProps {
3
- color: string;
4
- isSent?: boolean;
5
- onRatingChange: (newRating: number) => void;
6
- ratingValue: number;
7
- ratingType: RatingType;
8
- valueSent?: number;
9
- }
10
- export declare const RatingSelector: ({ color, isSent, onRatingChange, ratingValue, ratingType, valueSent, }: RatingSelectorProps) => import("react/jsx-runtime").JSX.Element;
11
- export {};
@@ -1,26 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.RatingSelector = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- /** biome-ignore-all lint/a11y/noStaticElementInteractions: we need to use static elements for the rating selector */
6
- /** biome-ignore-all lint/a11y/useKeyWithClickEvents: we need to use key with click events for the rating selector */
7
- const react_1 = require("react");
8
- const smileys_1 = require("./smileys");
9
- const stars_1 = require("./stars");
10
- const styles_1 = require("./styles");
11
- const types_1 = require("./types");
12
- const NUMBER_OF_RATING_BUTTONS = 5;
13
- const RatingSelector = ({ color, isSent, onRatingChange, ratingValue, ratingType, valueSent, }) => {
14
- const [hover, setHover] = (0, react_1.useState)(valueSent ? valueSent : -1);
15
- const onHover = (ratingNumber) => {
16
- if (!valueSent) {
17
- setHover(ratingNumber);
18
- }
19
- };
20
- return ((0, jsx_runtime_1.jsx)(styles_1.RatingSelectorContainer, { isSent: isSent, children: Array.from({ length: NUMBER_OF_RATING_BUTTONS }, (_star, i) => {
21
- const ratingNumber = i + 1;
22
- return ((0, jsx_runtime_1.jsxs)("div", { onMouseEnter: () => onHover(ratingNumber), onMouseLeave: () => onHover(ratingValue), onClick: () => onRatingChange(ratingNumber), children: [ratingType === types_1.RatingType.Stars && ((0, jsx_runtime_1.jsx)(stars_1.Stars, { color: color, ratingNumber: ratingNumber, hover: hover })), ratingType === types_1.RatingType.Smileys && ((0, jsx_runtime_1.jsx)(smileys_1.Smileys, { color: color, ratingNumber: ratingNumber, hover: hover }))] }, ratingNumber));
23
- }) }));
24
- };
25
- exports.RatingSelector = RatingSelector;
26
- //# sourceMappingURL=rating-selector.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"rating-selector.js","sourceRoot":"","sources":["../../../../../src/webchat/custom-messages/rating/rating-selector.tsx"],"names":[],"mappings":";;;;AAAA,qHAAqH;AACrH,qHAAqH;AACrH,iCAAgC;AAEhC,uCAAmC;AACnC,mCAA+B;AAC/B,qCAAkD;AAClD,mCAAoC;AAEpC,MAAM,wBAAwB,GAAG,CAAC,CAAA;AAU3B,MAAM,cAAc,GAAG,CAAC,EAC7B,KAAK,EACL,MAAM,EACN,cAAc,EACd,WAAW,EACX,UAAU,EACV,SAAS,GACW,EAAE,EAAE;IACxB,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,IAAA,gBAAQ,EAAS,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IAEtE,MAAM,OAAO,GAAG,CAAC,YAAoB,EAAE,EAAE;QACvC,IAAI,CAAC,SAAS,EAAE,CAAC;YACf,QAAQ,CAAC,YAAY,CAAC,CAAA;QACxB,CAAC;IACH,CAAC,CAAA;IAED,OAAO,CACL,uBAAC,gCAAuB,IAAC,MAAM,EAAE,MAAM,YACpC,KAAK,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,wBAAwB,EAAE,EAAE,CAAC,KAAK,EAAE,CAAC,EAAE,EAAE;YAC7D,MAAM,YAAY,GAAG,CAAC,GAAG,CAAC,CAAA;YAE1B,OAAO,CACL,iCAEE,YAAY,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,YAAY,CAAC,EACzC,YAAY,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,WAAW,CAAC,EACxC,OAAO,EAAE,GAAG,EAAE,CAAC,cAAc,CAAC,YAAY,CAAC,aAE1C,UAAU,KAAK,kBAAU,CAAC,KAAK,IAAI,CAClC,uBAAC,aAAK,IAAC,KAAK,EAAE,KAAK,EAAE,YAAY,EAAE,YAAY,EAAE,KAAK,EAAE,KAAK,GAAI,CAClE,EACA,UAAU,KAAK,kBAAU,CAAC,OAAO,IAAI,CACpC,uBAAC,iBAAO,IACN,KAAK,EAAE,KAAK,EACZ,YAAY,EAAE,YAAY,EAC1B,KAAK,EAAE,KAAK,GACZ,CACH,KAdI,YAAY,CAeb,CACP,CAAA;QACH,CAAC,CAAC,GACsB,CAC3B,CAAA;AACH,CAAC,CAAA;AA3CY,QAAA,cAAc,kBA2C1B"}
@@ -1,2 +0,0 @@
1
- import type { RatingItemProps } from './types';
2
- export declare const Smileys: ({ color, ratingNumber, hover }: RatingItemProps) => import("react/jsx-runtime").JSX.Element | null;