@magmamath/students-features 0.1.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 (405) hide show
  1. package/README.md +33 -0
  2. package/dist/commonjs/features/chatbot/components/Alternatives/Alternatives.js +60 -0
  3. package/dist/commonjs/features/chatbot/components/Alternatives/Alternatives.js.map +1 -0
  4. package/dist/commonjs/features/chatbot/components/Alternatives/HelpRequestOption.js +96 -0
  5. package/dist/commonjs/features/chatbot/components/Alternatives/HelpRequestOption.js.map +1 -0
  6. package/dist/commonjs/features/chatbot/components/ChatControls/ChatControls.js +97 -0
  7. package/dist/commonjs/features/chatbot/components/ChatControls/ChatControls.js.map +1 -0
  8. package/dist/commonjs/features/chatbot/components/ChatMessage/ChatMessage.js +27 -0
  9. package/dist/commonjs/features/chatbot/components/ChatMessage/ChatMessage.js.map +1 -0
  10. package/dist/commonjs/features/chatbot/components/ChatMessage/MessageLoader.js +56 -0
  11. package/dist/commonjs/features/chatbot/components/ChatMessage/MessageLoader.js.map +1 -0
  12. package/dist/commonjs/features/chatbot/components/ChatMessage/MessageTextToSpeech.js +88 -0
  13. package/dist/commonjs/features/chatbot/components/ChatMessage/MessageTextToSpeech.js.map +1 -0
  14. package/dist/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.js +87 -0
  15. package/dist/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.js.map +1 -0
  16. package/dist/commonjs/features/chatbot/components/ChatMessage/SentMessage.js +43 -0
  17. package/dist/commonjs/features/chatbot/components/ChatMessage/SentMessage.js.map +1 -0
  18. package/dist/commonjs/features/chatbot/components/ChatMessages/ChatbotMessages.js +130 -0
  19. package/dist/commonjs/features/chatbot/components/ChatMessages/ChatbotMessages.js.map +1 -0
  20. package/dist/commonjs/features/chatbot/components/Chatbot.js +69 -0
  21. package/dist/commonjs/features/chatbot/components/Chatbot.js.map +1 -0
  22. package/dist/commonjs/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.js +65 -0
  23. package/dist/commonjs/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.js.map +1 -0
  24. package/dist/commonjs/features/chatbot/constants.js +31 -0
  25. package/dist/commonjs/features/chatbot/constants.js.map +1 -0
  26. package/dist/commonjs/features/chatbot/helpers.js +12 -0
  27. package/dist/commonjs/features/chatbot/helpers.js.map +1 -0
  28. package/dist/commonjs/features/chatbot/index.js +34 -0
  29. package/dist/commonjs/features/chatbot/index.js.map +1 -0
  30. package/dist/commonjs/features/chatbot/model/api.js +18 -0
  31. package/dist/commonjs/features/chatbot/model/api.js.map +1 -0
  32. package/dist/commonjs/features/chatbot/model/model.js +244 -0
  33. package/dist/commonjs/features/chatbot/model/model.js.map +1 -0
  34. package/dist/commonjs/features/chatbot/model/t2s.js +104 -0
  35. package/dist/commonjs/features/chatbot/model/t2s.js.map +1 -0
  36. package/dist/commonjs/features/chatbot/model/translation.js +203 -0
  37. package/dist/commonjs/features/chatbot/model/translation.js.map +1 -0
  38. package/dist/commonjs/features/chatbot/types/api.types.js +2 -0
  39. package/dist/commonjs/features/chatbot/types/api.types.js.map +1 -0
  40. package/dist/commonjs/features/chatbot/types/model.types.js +12 -0
  41. package/dist/commonjs/features/chatbot/types/model.types.js.map +1 -0
  42. package/dist/commonjs/features/chatbot/types/t2s.types.js +13 -0
  43. package/dist/commonjs/features/chatbot/types/t2s.types.js.map +1 -0
  44. package/dist/commonjs/features/chatbot/types/translation.types.js +6 -0
  45. package/dist/commonjs/features/chatbot/types/translation.types.js.map +1 -0
  46. package/dist/commonjs/index.js +42 -0
  47. package/dist/commonjs/index.js.map +1 -0
  48. package/dist/commonjs/lib/createFeature/createFeature.js +28 -0
  49. package/dist/commonjs/lib/createFeature/createFeature.js.map +1 -0
  50. package/dist/commonjs/lib/effector/createControllerEffect.js +51 -0
  51. package/dist/commonjs/lib/effector/createControllerEffect.js.map +1 -0
  52. package/dist/commonjs/lib/effector/createEntityFieldStore.js +42 -0
  53. package/dist/commonjs/lib/effector/createEntityFieldStore.js.map +1 -0
  54. package/dist/commonjs/lib/effector/index.js +20 -0
  55. package/dist/commonjs/lib/effector/index.js.map +1 -0
  56. package/dist/commonjs/lib/helpers/helpers.js +9 -0
  57. package/dist/commonjs/lib/helpers/helpers.js.map +1 -0
  58. package/dist/commonjs/lib/localization/en.json +2 -0
  59. package/dist/commonjs/lib/localization/gb.json +2 -0
  60. package/dist/commonjs/lib/localization/sw.json +2 -0
  61. package/dist/commonjs/shared/hooks/useDebounce.js +21 -0
  62. package/dist/commonjs/shared/hooks/useDebounce.js.map +1 -0
  63. package/dist/commonjs/shared/icons/ArrowRightIcon.js +30 -0
  64. package/dist/commonjs/shared/icons/ArrowRightIcon.js.map +1 -0
  65. package/dist/commonjs/shared/icons/ChatbotIcon.js +148 -0
  66. package/dist/commonjs/shared/icons/ChatbotIcon.js.map +1 -0
  67. package/dist/commonjs/shared/icons/CloseIcon.js +28 -0
  68. package/dist/commonjs/shared/icons/CloseIcon.js.map +1 -0
  69. package/dist/commonjs/shared/icons/GlobeIcon.js +30 -0
  70. package/dist/commonjs/shared/icons/GlobeIcon.js.map +1 -0
  71. package/dist/commonjs/shared/icons/PauseIcon.js +32 -0
  72. package/dist/commonjs/shared/icons/PauseIcon.js.map +1 -0
  73. package/dist/commonjs/shared/icons/PlayIcon.js +32 -0
  74. package/dist/commonjs/shared/icons/PlayIcon.js.map +1 -0
  75. package/dist/commonjs/shared/icons/SpeakerIcon.js +37 -0
  76. package/dist/commonjs/shared/icons/SpeakerIcon.js.map +1 -0
  77. package/dist/commonjs/shared/icons/icon.types.js +2 -0
  78. package/dist/commonjs/shared/icons/icon.types.js.map +1 -0
  79. package/dist/commonjs/shared/translation/constants.js +17 -0
  80. package/dist/commonjs/shared/translation/constants.js.map +1 -0
  81. package/dist/commonjs/shared/translation/helpers.js +31 -0
  82. package/dist/commonjs/shared/translation/helpers.js.map +1 -0
  83. package/dist/commonjs/shared/translation/hooks.js +28 -0
  84. package/dist/commonjs/shared/translation/hooks.js.map +1 -0
  85. package/dist/commonjs/shared/translation/index.js +52 -0
  86. package/dist/commonjs/shared/translation/index.js.map +1 -0
  87. package/dist/commonjs/shared/translation/model.js +15 -0
  88. package/dist/commonjs/shared/translation/model.js.map +1 -0
  89. package/dist/commonjs/shared/translation/types.js +13 -0
  90. package/dist/commonjs/shared/translation/types.js.map +1 -0
  91. package/dist/commonjs/types/types.d.js +2 -0
  92. package/dist/commonjs/types/types.d.js.map +1 -0
  93. package/dist/module/features/chatbot/components/Alternatives/Alternatives.js +54 -0
  94. package/dist/module/features/chatbot/components/Alternatives/Alternatives.js.map +1 -0
  95. package/dist/module/features/chatbot/components/Alternatives/HelpRequestOption.js +90 -0
  96. package/dist/module/features/chatbot/components/Alternatives/HelpRequestOption.js.map +1 -0
  97. package/dist/module/features/chatbot/components/ChatControls/ChatControls.js +91 -0
  98. package/dist/module/features/chatbot/components/ChatControls/ChatControls.js.map +1 -0
  99. package/dist/module/features/chatbot/components/ChatMessage/ChatMessage.js +21 -0
  100. package/dist/module/features/chatbot/components/ChatMessage/ChatMessage.js.map +1 -0
  101. package/dist/module/features/chatbot/components/ChatMessage/MessageLoader.js +50 -0
  102. package/dist/module/features/chatbot/components/ChatMessage/MessageLoader.js.map +1 -0
  103. package/dist/module/features/chatbot/components/ChatMessage/MessageTextToSpeech.js +82 -0
  104. package/dist/module/features/chatbot/components/ChatMessage/MessageTextToSpeech.js.map +1 -0
  105. package/dist/module/features/chatbot/components/ChatMessage/ReceivedMessage.js +81 -0
  106. package/dist/module/features/chatbot/components/ChatMessage/ReceivedMessage.js.map +1 -0
  107. package/dist/module/features/chatbot/components/ChatMessage/SentMessage.js +37 -0
  108. package/dist/module/features/chatbot/components/ChatMessage/SentMessage.js.map +1 -0
  109. package/dist/module/features/chatbot/components/ChatMessages/ChatbotMessages.js +123 -0
  110. package/dist/module/features/chatbot/components/ChatMessages/ChatbotMessages.js.map +1 -0
  111. package/dist/module/features/chatbot/components/Chatbot.js +63 -0
  112. package/dist/module/features/chatbot/components/Chatbot.js.map +1 -0
  113. package/dist/module/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.js +59 -0
  114. package/dist/module/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.js.map +1 -0
  115. package/dist/module/features/chatbot/constants.js +27 -0
  116. package/dist/module/features/chatbot/constants.js.map +1 -0
  117. package/dist/module/features/chatbot/helpers.js +7 -0
  118. package/dist/module/features/chatbot/helpers.js.map +1 -0
  119. package/dist/module/features/chatbot/index.js +7 -0
  120. package/dist/module/features/chatbot/index.js.map +1 -0
  121. package/dist/module/features/chatbot/model/api.js +13 -0
  122. package/dist/module/features/chatbot/model/api.js.map +1 -0
  123. package/dist/module/features/chatbot/model/model.js +239 -0
  124. package/dist/module/features/chatbot/model/model.js.map +1 -0
  125. package/dist/module/features/chatbot/model/t2s.js +99 -0
  126. package/dist/module/features/chatbot/model/t2s.js.map +1 -0
  127. package/dist/module/features/chatbot/model/translation.js +198 -0
  128. package/dist/module/features/chatbot/model/translation.js.map +1 -0
  129. package/dist/module/features/chatbot/types/api.types.js +2 -0
  130. package/dist/module/features/chatbot/types/api.types.js.map +1 -0
  131. package/dist/module/features/chatbot/types/model.types.js +8 -0
  132. package/dist/module/features/chatbot/types/model.types.js.map +1 -0
  133. package/dist/module/features/chatbot/types/t2s.types.js +9 -0
  134. package/dist/module/features/chatbot/types/t2s.types.js.map +1 -0
  135. package/dist/module/features/chatbot/types/translation.types.js +4 -0
  136. package/dist/module/features/chatbot/types/translation.types.js.map +1 -0
  137. package/dist/module/index.js +5 -0
  138. package/dist/module/index.js.map +1 -0
  139. package/dist/module/lib/createFeature/createFeature.js +22 -0
  140. package/dist/module/lib/createFeature/createFeature.js.map +1 -0
  141. package/dist/module/lib/effector/createControllerEffect.js +45 -0
  142. package/dist/module/lib/effector/createControllerEffect.js.map +1 -0
  143. package/dist/module/lib/effector/createEntityFieldStore.js +38 -0
  144. package/dist/module/lib/effector/createEntityFieldStore.js.map +1 -0
  145. package/dist/module/lib/effector/index.js +5 -0
  146. package/dist/module/lib/effector/index.js.map +1 -0
  147. package/dist/module/lib/helpers/helpers.js +4 -0
  148. package/dist/module/lib/helpers/helpers.js.map +1 -0
  149. package/dist/module/lib/localization/en.json +2 -0
  150. package/dist/module/lib/localization/gb.json +2 -0
  151. package/dist/module/lib/localization/sw.json +2 -0
  152. package/dist/module/shared/hooks/useDebounce.js +16 -0
  153. package/dist/module/shared/hooks/useDebounce.js.map +1 -0
  154. package/dist/module/shared/icons/ArrowRightIcon.js +22 -0
  155. package/dist/module/shared/icons/ArrowRightIcon.js.map +1 -0
  156. package/dist/module/shared/icons/ChatbotIcon.js +140 -0
  157. package/dist/module/shared/icons/ChatbotIcon.js.map +1 -0
  158. package/dist/module/shared/icons/CloseIcon.js +20 -0
  159. package/dist/module/shared/icons/CloseIcon.js.map +1 -0
  160. package/dist/module/shared/icons/GlobeIcon.js +22 -0
  161. package/dist/module/shared/icons/GlobeIcon.js.map +1 -0
  162. package/dist/module/shared/icons/PauseIcon.js +24 -0
  163. package/dist/module/shared/icons/PauseIcon.js.map +1 -0
  164. package/dist/module/shared/icons/PlayIcon.js +24 -0
  165. package/dist/module/shared/icons/PlayIcon.js.map +1 -0
  166. package/dist/module/shared/icons/SpeakerIcon.js +29 -0
  167. package/dist/module/shared/icons/SpeakerIcon.js.map +1 -0
  168. package/dist/module/shared/icons/icon.types.js +2 -0
  169. package/dist/module/shared/icons/icon.types.js.map +1 -0
  170. package/dist/module/shared/translation/constants.js +12 -0
  171. package/dist/module/shared/translation/constants.js.map +1 -0
  172. package/dist/module/shared/translation/helpers.js +24 -0
  173. package/dist/module/shared/translation/helpers.js.map +1 -0
  174. package/dist/module/shared/translation/hooks.js +22 -0
  175. package/dist/module/shared/translation/hooks.js.map +1 -0
  176. package/dist/module/shared/translation/index.js +7 -0
  177. package/dist/module/shared/translation/index.js.map +1 -0
  178. package/dist/module/shared/translation/model.js +11 -0
  179. package/dist/module/shared/translation/model.js.map +1 -0
  180. package/dist/module/shared/translation/types.js +9 -0
  181. package/dist/module/shared/translation/types.js.map +1 -0
  182. package/dist/module/types/types.d.js +2 -0
  183. package/dist/module/types/types.d.js.map +1 -0
  184. package/dist/typescript/commonjs/features/chatbot/components/Alternatives/Alternatives.d.ts +11 -0
  185. package/dist/typescript/commonjs/features/chatbot/components/Alternatives/Alternatives.d.ts.map +1 -0
  186. package/dist/typescript/commonjs/features/chatbot/components/Alternatives/HelpRequestOption.d.ts +9 -0
  187. package/dist/typescript/commonjs/features/chatbot/components/Alternatives/HelpRequestOption.d.ts.map +1 -0
  188. package/dist/typescript/commonjs/features/chatbot/components/ChatControls/ChatControls.d.ts +14 -0
  189. package/dist/typescript/commonjs/features/chatbot/components/ChatControls/ChatControls.d.ts.map +1 -0
  190. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ChatMessage.d.ts +17 -0
  191. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ChatMessage.d.ts.map +1 -0
  192. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageLoader.d.ts +3 -0
  193. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageLoader.d.ts.map +1 -0
  194. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageTextToSpeech.d.ts +12 -0
  195. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageTextToSpeech.d.ts.map +1 -0
  196. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.d.ts +4 -0
  197. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.d.ts.map +1 -0
  198. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/SentMessage.d.ts +4 -0
  199. package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/SentMessage.d.ts.map +1 -0
  200. package/dist/typescript/commonjs/features/chatbot/components/ChatMessages/ChatbotMessages.d.ts +21 -0
  201. package/dist/typescript/commonjs/features/chatbot/components/ChatMessages/ChatbotMessages.d.ts.map +1 -0
  202. package/dist/typescript/commonjs/features/chatbot/components/Chatbot.d.ts +25 -0
  203. package/dist/typescript/commonjs/features/chatbot/components/Chatbot.d.ts.map +1 -0
  204. package/dist/typescript/commonjs/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.d.ts +9 -0
  205. package/dist/typescript/commonjs/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.d.ts.map +1 -0
  206. package/dist/typescript/commonjs/features/chatbot/constants.d.ts +21 -0
  207. package/dist/typescript/commonjs/features/chatbot/constants.d.ts.map +1 -0
  208. package/dist/typescript/commonjs/features/chatbot/helpers.d.ts +2 -0
  209. package/dist/typescript/commonjs/features/chatbot/helpers.d.ts.map +1 -0
  210. package/dist/typescript/commonjs/features/chatbot/index.d.ts +5 -0
  211. package/dist/typescript/commonjs/features/chatbot/index.d.ts.map +1 -0
  212. package/dist/typescript/commonjs/features/chatbot/model/api.d.ts +12 -0
  213. package/dist/typescript/commonjs/features/chatbot/model/api.d.ts.map +1 -0
  214. package/dist/typescript/commonjs/features/chatbot/model/model.d.ts +73 -0
  215. package/dist/typescript/commonjs/features/chatbot/model/model.d.ts.map +1 -0
  216. package/dist/typescript/commonjs/features/chatbot/model/t2s.d.ts +18 -0
  217. package/dist/typescript/commonjs/features/chatbot/model/t2s.d.ts.map +1 -0
  218. package/dist/typescript/commonjs/features/chatbot/model/translation.d.ts +22 -0
  219. package/dist/typescript/commonjs/features/chatbot/model/translation.d.ts.map +1 -0
  220. package/dist/typescript/commonjs/features/chatbot/types/api.types.d.ts +60 -0
  221. package/dist/typescript/commonjs/features/chatbot/types/api.types.d.ts.map +1 -0
  222. package/dist/typescript/commonjs/features/chatbot/types/model.types.d.ts +64 -0
  223. package/dist/typescript/commonjs/features/chatbot/types/model.types.d.ts.map +1 -0
  224. package/dist/typescript/commonjs/features/chatbot/types/t2s.types.d.ts +22 -0
  225. package/dist/typescript/commonjs/features/chatbot/types/t2s.types.d.ts.map +1 -0
  226. package/dist/typescript/commonjs/features/chatbot/types/translation.types.d.ts +23 -0
  227. package/dist/typescript/commonjs/features/chatbot/types/translation.types.d.ts.map +1 -0
  228. package/dist/typescript/commonjs/index.d.ts +4 -0
  229. package/dist/typescript/commonjs/index.d.ts.map +1 -0
  230. package/dist/typescript/commonjs/lib/createFeature/createFeature.d.ts +7 -0
  231. package/dist/typescript/commonjs/lib/createFeature/createFeature.d.ts.map +1 -0
  232. package/dist/typescript/commonjs/lib/effector/createControllerEffect.d.ts +16 -0
  233. package/dist/typescript/commonjs/lib/effector/createControllerEffect.d.ts.map +1 -0
  234. package/dist/typescript/commonjs/lib/effector/createEntityFieldStore.d.ts +16 -0
  235. package/dist/typescript/commonjs/lib/effector/createEntityFieldStore.d.ts.map +1 -0
  236. package/dist/typescript/commonjs/lib/effector/index.d.ts +3 -0
  237. package/dist/typescript/commonjs/lib/effector/index.d.ts.map +1 -0
  238. package/dist/typescript/commonjs/lib/helpers/helpers.d.ts +2 -0
  239. package/dist/typescript/commonjs/lib/helpers/helpers.d.ts.map +1 -0
  240. package/dist/typescript/commonjs/package.json +1 -0
  241. package/dist/typescript/commonjs/shared/hooks/useDebounce.d.ts +2 -0
  242. package/dist/typescript/commonjs/shared/hooks/useDebounce.d.ts.map +1 -0
  243. package/dist/typescript/commonjs/shared/icons/ArrowRightIcon.d.ts +4 -0
  244. package/dist/typescript/commonjs/shared/icons/ArrowRightIcon.d.ts.map +1 -0
  245. package/dist/typescript/commonjs/shared/icons/ChatbotIcon.d.ts +4 -0
  246. package/dist/typescript/commonjs/shared/icons/ChatbotIcon.d.ts.map +1 -0
  247. package/dist/typescript/commonjs/shared/icons/CloseIcon.d.ts +4 -0
  248. package/dist/typescript/commonjs/shared/icons/CloseIcon.d.ts.map +1 -0
  249. package/dist/typescript/commonjs/shared/icons/GlobeIcon.d.ts +4 -0
  250. package/dist/typescript/commonjs/shared/icons/GlobeIcon.d.ts.map +1 -0
  251. package/dist/typescript/commonjs/shared/icons/PauseIcon.d.ts +4 -0
  252. package/dist/typescript/commonjs/shared/icons/PauseIcon.d.ts.map +1 -0
  253. package/dist/typescript/commonjs/shared/icons/PlayIcon.d.ts +4 -0
  254. package/dist/typescript/commonjs/shared/icons/PlayIcon.d.ts.map +1 -0
  255. package/dist/typescript/commonjs/shared/icons/SpeakerIcon.d.ts +4 -0
  256. package/dist/typescript/commonjs/shared/icons/SpeakerIcon.d.ts.map +1 -0
  257. package/dist/typescript/commonjs/shared/icons/icon.types.d.ts +9 -0
  258. package/dist/typescript/commonjs/shared/icons/icon.types.d.ts.map +1 -0
  259. package/dist/typescript/commonjs/shared/translation/constants.d.ts +6 -0
  260. package/dist/typescript/commonjs/shared/translation/constants.d.ts.map +1 -0
  261. package/dist/typescript/commonjs/shared/translation/helpers.d.ts +6 -0
  262. package/dist/typescript/commonjs/shared/translation/helpers.d.ts.map +1 -0
  263. package/dist/typescript/commonjs/shared/translation/hooks.d.ts +5 -0
  264. package/dist/typescript/commonjs/shared/translation/hooks.d.ts.map +1 -0
  265. package/dist/typescript/commonjs/shared/translation/index.d.ts +6 -0
  266. package/dist/typescript/commonjs/shared/translation/index.d.ts.map +1 -0
  267. package/dist/typescript/commonjs/shared/translation/model.d.ts +5 -0
  268. package/dist/typescript/commonjs/shared/translation/model.d.ts.map +1 -0
  269. package/dist/typescript/commonjs/shared/translation/types.d.ts +8 -0
  270. package/dist/typescript/commonjs/shared/translation/types.d.ts.map +1 -0
  271. package/dist/typescript/module/features/chatbot/components/Alternatives/Alternatives.d.ts +11 -0
  272. package/dist/typescript/module/features/chatbot/components/Alternatives/Alternatives.d.ts.map +1 -0
  273. package/dist/typescript/module/features/chatbot/components/Alternatives/HelpRequestOption.d.ts +9 -0
  274. package/dist/typescript/module/features/chatbot/components/Alternatives/HelpRequestOption.d.ts.map +1 -0
  275. package/dist/typescript/module/features/chatbot/components/ChatControls/ChatControls.d.ts +14 -0
  276. package/dist/typescript/module/features/chatbot/components/ChatControls/ChatControls.d.ts.map +1 -0
  277. package/dist/typescript/module/features/chatbot/components/ChatMessage/ChatMessage.d.ts +17 -0
  278. package/dist/typescript/module/features/chatbot/components/ChatMessage/ChatMessage.d.ts.map +1 -0
  279. package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageLoader.d.ts +3 -0
  280. package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageLoader.d.ts.map +1 -0
  281. package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageTextToSpeech.d.ts +12 -0
  282. package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageTextToSpeech.d.ts.map +1 -0
  283. package/dist/typescript/module/features/chatbot/components/ChatMessage/ReceivedMessage.d.ts +4 -0
  284. package/dist/typescript/module/features/chatbot/components/ChatMessage/ReceivedMessage.d.ts.map +1 -0
  285. package/dist/typescript/module/features/chatbot/components/ChatMessage/SentMessage.d.ts +4 -0
  286. package/dist/typescript/module/features/chatbot/components/ChatMessage/SentMessage.d.ts.map +1 -0
  287. package/dist/typescript/module/features/chatbot/components/ChatMessages/ChatbotMessages.d.ts +21 -0
  288. package/dist/typescript/module/features/chatbot/components/ChatMessages/ChatbotMessages.d.ts.map +1 -0
  289. package/dist/typescript/module/features/chatbot/components/Chatbot.d.ts +25 -0
  290. package/dist/typescript/module/features/chatbot/components/Chatbot.d.ts.map +1 -0
  291. package/dist/typescript/module/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.d.ts +9 -0
  292. package/dist/typescript/module/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.d.ts.map +1 -0
  293. package/dist/typescript/module/features/chatbot/constants.d.ts +21 -0
  294. package/dist/typescript/module/features/chatbot/constants.d.ts.map +1 -0
  295. package/dist/typescript/module/features/chatbot/helpers.d.ts +2 -0
  296. package/dist/typescript/module/features/chatbot/helpers.d.ts.map +1 -0
  297. package/dist/typescript/module/features/chatbot/index.d.ts +5 -0
  298. package/dist/typescript/module/features/chatbot/index.d.ts.map +1 -0
  299. package/dist/typescript/module/features/chatbot/model/api.d.ts +12 -0
  300. package/dist/typescript/module/features/chatbot/model/api.d.ts.map +1 -0
  301. package/dist/typescript/module/features/chatbot/model/model.d.ts +73 -0
  302. package/dist/typescript/module/features/chatbot/model/model.d.ts.map +1 -0
  303. package/dist/typescript/module/features/chatbot/model/t2s.d.ts +18 -0
  304. package/dist/typescript/module/features/chatbot/model/t2s.d.ts.map +1 -0
  305. package/dist/typescript/module/features/chatbot/model/translation.d.ts +22 -0
  306. package/dist/typescript/module/features/chatbot/model/translation.d.ts.map +1 -0
  307. package/dist/typescript/module/features/chatbot/types/api.types.d.ts +60 -0
  308. package/dist/typescript/module/features/chatbot/types/api.types.d.ts.map +1 -0
  309. package/dist/typescript/module/features/chatbot/types/model.types.d.ts +64 -0
  310. package/dist/typescript/module/features/chatbot/types/model.types.d.ts.map +1 -0
  311. package/dist/typescript/module/features/chatbot/types/t2s.types.d.ts +22 -0
  312. package/dist/typescript/module/features/chatbot/types/t2s.types.d.ts.map +1 -0
  313. package/dist/typescript/module/features/chatbot/types/translation.types.d.ts +23 -0
  314. package/dist/typescript/module/features/chatbot/types/translation.types.d.ts.map +1 -0
  315. package/dist/typescript/module/index.d.ts +4 -0
  316. package/dist/typescript/module/index.d.ts.map +1 -0
  317. package/dist/typescript/module/lib/createFeature/createFeature.d.ts +7 -0
  318. package/dist/typescript/module/lib/createFeature/createFeature.d.ts.map +1 -0
  319. package/dist/typescript/module/lib/effector/createControllerEffect.d.ts +16 -0
  320. package/dist/typescript/module/lib/effector/createControllerEffect.d.ts.map +1 -0
  321. package/dist/typescript/module/lib/effector/createEntityFieldStore.d.ts +16 -0
  322. package/dist/typescript/module/lib/effector/createEntityFieldStore.d.ts.map +1 -0
  323. package/dist/typescript/module/lib/effector/index.d.ts +3 -0
  324. package/dist/typescript/module/lib/effector/index.d.ts.map +1 -0
  325. package/dist/typescript/module/lib/helpers/helpers.d.ts +2 -0
  326. package/dist/typescript/module/lib/helpers/helpers.d.ts.map +1 -0
  327. package/dist/typescript/module/package.json +1 -0
  328. package/dist/typescript/module/shared/hooks/useDebounce.d.ts +2 -0
  329. package/dist/typescript/module/shared/hooks/useDebounce.d.ts.map +1 -0
  330. package/dist/typescript/module/shared/icons/ArrowRightIcon.d.ts +4 -0
  331. package/dist/typescript/module/shared/icons/ArrowRightIcon.d.ts.map +1 -0
  332. package/dist/typescript/module/shared/icons/ChatbotIcon.d.ts +4 -0
  333. package/dist/typescript/module/shared/icons/ChatbotIcon.d.ts.map +1 -0
  334. package/dist/typescript/module/shared/icons/CloseIcon.d.ts +4 -0
  335. package/dist/typescript/module/shared/icons/CloseIcon.d.ts.map +1 -0
  336. package/dist/typescript/module/shared/icons/GlobeIcon.d.ts +4 -0
  337. package/dist/typescript/module/shared/icons/GlobeIcon.d.ts.map +1 -0
  338. package/dist/typescript/module/shared/icons/PauseIcon.d.ts +4 -0
  339. package/dist/typescript/module/shared/icons/PauseIcon.d.ts.map +1 -0
  340. package/dist/typescript/module/shared/icons/PlayIcon.d.ts +4 -0
  341. package/dist/typescript/module/shared/icons/PlayIcon.d.ts.map +1 -0
  342. package/dist/typescript/module/shared/icons/SpeakerIcon.d.ts +4 -0
  343. package/dist/typescript/module/shared/icons/SpeakerIcon.d.ts.map +1 -0
  344. package/dist/typescript/module/shared/icons/icon.types.d.ts +9 -0
  345. package/dist/typescript/module/shared/icons/icon.types.d.ts.map +1 -0
  346. package/dist/typescript/module/shared/translation/constants.d.ts +6 -0
  347. package/dist/typescript/module/shared/translation/constants.d.ts.map +1 -0
  348. package/dist/typescript/module/shared/translation/helpers.d.ts +6 -0
  349. package/dist/typescript/module/shared/translation/helpers.d.ts.map +1 -0
  350. package/dist/typescript/module/shared/translation/hooks.d.ts +5 -0
  351. package/dist/typescript/module/shared/translation/hooks.d.ts.map +1 -0
  352. package/dist/typescript/module/shared/translation/index.d.ts +6 -0
  353. package/dist/typescript/module/shared/translation/index.d.ts.map +1 -0
  354. package/dist/typescript/module/shared/translation/model.d.ts +5 -0
  355. package/dist/typescript/module/shared/translation/model.d.ts.map +1 -0
  356. package/dist/typescript/module/shared/translation/types.d.ts +8 -0
  357. package/dist/typescript/module/shared/translation/types.d.ts.map +1 -0
  358. package/package.json +73 -0
  359. package/src/features/chatbot/components/Alternatives/Alternatives.tsx +64 -0
  360. package/src/features/chatbot/components/Alternatives/HelpRequestOption.tsx +92 -0
  361. package/src/features/chatbot/components/ChatControls/ChatControls.tsx +103 -0
  362. package/src/features/chatbot/components/ChatMessage/ChatMessage.tsx +28 -0
  363. package/src/features/chatbot/components/ChatMessage/MessageLoader.tsx +42 -0
  364. package/src/features/chatbot/components/ChatMessage/MessageTextToSpeech.tsx +78 -0
  365. package/src/features/chatbot/components/ChatMessage/ReceivedMessage.tsx +73 -0
  366. package/src/features/chatbot/components/ChatMessage/SentMessage.tsx +31 -0
  367. package/src/features/chatbot/components/ChatMessages/ChatbotMessages.tsx +148 -0
  368. package/src/features/chatbot/components/Chatbot.tsx +92 -0
  369. package/src/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.tsx +77 -0
  370. package/src/features/chatbot/constants.ts +30 -0
  371. package/src/features/chatbot/helpers.ts +4 -0
  372. package/src/features/chatbot/index.ts +4 -0
  373. package/src/features/chatbot/model/api.ts +28 -0
  374. package/src/features/chatbot/model/model.ts +277 -0
  375. package/src/features/chatbot/model/t2s.ts +107 -0
  376. package/src/features/chatbot/model/translation.ts +231 -0
  377. package/src/features/chatbot/types/api.types.ts +59 -0
  378. package/src/features/chatbot/types/model.types.ts +73 -0
  379. package/src/features/chatbot/types/t2s.types.ts +24 -0
  380. package/src/features/chatbot/types/translation.types.ts +23 -0
  381. package/src/index.ts +3 -0
  382. package/src/lib/createFeature/createFeature.tsx +21 -0
  383. package/src/lib/effector/createControllerEffect.ts +66 -0
  384. package/src/lib/effector/createEntityFieldStore.ts +43 -0
  385. package/src/lib/effector/index.ts +2 -0
  386. package/src/lib/helpers/helpers.ts +2 -0
  387. package/src/lib/localization/en.json +2 -0
  388. package/src/lib/localization/gb.json +2 -0
  389. package/src/lib/localization/sw.json +2 -0
  390. package/src/shared/hooks/useDebounce.ts +17 -0
  391. package/src/shared/icons/ArrowRightIcon.tsx +14 -0
  392. package/src/shared/icons/ChatbotIcon.tsx +109 -0
  393. package/src/shared/icons/CloseIcon.tsx +12 -0
  394. package/src/shared/icons/GlobeIcon.tsx +14 -0
  395. package/src/shared/icons/PauseIcon.tsx +16 -0
  396. package/src/shared/icons/PlayIcon.tsx +16 -0
  397. package/src/shared/icons/SpeakerIcon.tsx +22 -0
  398. package/src/shared/icons/icon.types.ts +8 -0
  399. package/src/shared/translation/constants.ts +10 -0
  400. package/src/shared/translation/helpers.ts +34 -0
  401. package/src/shared/translation/hooks.ts +28 -0
  402. package/src/shared/translation/index.ts +5 -0
  403. package/src/shared/translation/model.ts +15 -0
  404. package/src/shared/translation/types.ts +9 -0
  405. package/src/types/types.d.ts +4 -0
@@ -0,0 +1,16 @@
1
+ type UpdateField<T> = {
2
+ entityId: string;
3
+ fieldId: string;
4
+ data: T;
5
+ };
6
+ type CreateEntityFieldStoreSettings<T, U> = {
7
+ mapper?: (value: U) => UpdateField<T>;
8
+ };
9
+ export declare function createEntityFieldStore<T, U = UpdateField<T>>({ mapper, }?: CreateEntityFieldStoreSettings<T, U>): {
10
+ $state: import("effector").StoreWritable<Record<string, Record<string, T>>>;
11
+ setField: (value: U) => void;
12
+ fieldAdded: import("effector").EventCallable<UpdateField<T>>;
13
+ reset: import("effector").EventCallable<void>;
14
+ };
15
+ export {};
16
+ //# sourceMappingURL=createEntityFieldStore.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createEntityFieldStore.d.ts","sourceRoot":"","sources":["../../../../../src/lib/effector/createEntityFieldStore.ts"],"names":[],"mappings":"AAEA,KAAK,WAAW,CAAC,CAAC,IAAI;IAClB,QAAQ,EAAE,MAAM,CAAA;IAChB,OAAO,EAAE,MAAM,CAAA;IACf,IAAI,EAAE,CAAC,CAAA;CACV,CAAA;AAED,KAAK,8BAA8B,CAAC,CAAC,EAAE,CAAC,IAAI;IACxC,MAAM,CAAC,EAAE,CAAC,KAAK,EAAE,CAAC,KAAK,WAAW,CAAC,CAAC,CAAC,CAAA;CACxC,CAAA;AAED,wBAAgB,sBAAsB,CAAC,CAAC,EAAE,CAAC,GAAG,WAAW,CAAC,CAAC,CAAC,EAAE,EAC1D,MAA8B,GACjC,GAAE,8BAA8B,CAAC,CAAC,EAAE,CAAC,CAAM;;sBAKf,CAAC;;;EAuB7B"}
@@ -0,0 +1,3 @@
1
+ export { createEntityFieldStore } from './createEntityFieldStore';
2
+ export { createControllerEffect } from './createControllerEffect';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/effector/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AACjE,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA"}
@@ -0,0 +1,2 @@
1
+ export declare const generateRandomId: () => string;
2
+ //# sourceMappingURL=helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../src/lib/helpers/helpers.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB,cACsC,CAAA"}
@@ -0,0 +1 @@
1
+ {"type":"commonjs"}
@@ -0,0 +1,2 @@
1
+ export declare const useDebounce: <T>(value: T, delay?: number) => T;
2
+ //# sourceMappingURL=useDebounce.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useDebounce.d.ts","sourceRoot":"","sources":["../../../../../src/shared/hooks/useDebounce.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,WAAW,GAAI,CAAC,SAAS,CAAC,UAAU,MAAM,KAAG,CAczD,CAAA"}
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { IconProps } from './icon.types';
3
+ export declare const ArrowRightIcon: ({ width, height, color }: IconProps) => React.JSX.Element;
4
+ //# sourceMappingURL=ArrowRightIcon.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ArrowRightIcon.d.ts","sourceRoot":"","sources":["../../../../../src/shared/icons/ArrowRightIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,eAAO,MAAM,cAAc,6BAAoD,SAAS,sBASvF,CAAA"}
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { IconProps } from './icon.types';
3
+ export declare const ChatbotIcon: ({ width, height }: IconProps) => React.JSX.Element;
4
+ //# sourceMappingURL=ChatbotIcon.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatbotIcon.d.ts","sourceRoot":"","sources":["../../../../../src/shared/icons/ChatbotIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,eAAO,MAAM,WAAW,sBAAiC,SAAS,sBAwGjE,CAAA"}
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { IconProps } from './icon.types';
3
+ export declare const CloseIcon: ({ width, height, color }: IconProps) => React.JSX.Element;
4
+ //# sourceMappingURL=CloseIcon.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CloseIcon.d.ts","sourceRoot":"","sources":["../../../../../src/shared/icons/CloseIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,eAAO,MAAM,SAAS,6BAAoD,SAAS,sBAOlF,CAAA"}
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { IconProps } from './icon.types';
3
+ export declare const GlobeIcon: ({ width, height, color }: IconProps) => React.JSX.Element;
4
+ //# sourceMappingURL=GlobeIcon.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GlobeIcon.d.ts","sourceRoot":"","sources":["../../../../../src/shared/icons/GlobeIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,eAAO,MAAM,SAAS,6BAAoD,SAAS,sBASlF,CAAA"}
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { IconProps } from './icon.types';
3
+ export declare const PauseIcon: ({ color, height, width }: IconProps) => React.JSX.Element;
4
+ //# sourceMappingURL=PauseIcon.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PauseIcon.d.ts","sourceRoot":"","sources":["../../../../../src/shared/icons/PauseIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,eAAO,MAAM,SAAS,6BAAoD,SAAS,sBAWlF,CAAA"}
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { IconProps } from './icon.types';
3
+ export declare const PlayIcon: ({ color, height, width }: IconProps) => React.JSX.Element;
4
+ //# sourceMappingURL=PlayIcon.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PlayIcon.d.ts","sourceRoot":"","sources":["../../../../../src/shared/icons/PlayIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,eAAO,MAAM,QAAQ,6BAAoD,SAAS,sBAWjF,CAAA"}
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { IconProps } from './icon.types';
3
+ export declare const SpeakerIcon: ({ width, height, color }: IconProps) => React.JSX.Element;
4
+ //# sourceMappingURL=SpeakerIcon.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SpeakerIcon.d.ts","sourceRoot":"","sources":["../../../../../src/shared/icons/SpeakerIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,eAAO,MAAM,WAAW,6BAAoD,SAAS,sBAiBpF,CAAA"}
@@ -0,0 +1,9 @@
1
+ export type IconProps = {
2
+ color?: string;
3
+ className?: string;
4
+ size?: number;
5
+ strokeWidth?: string;
6
+ width?: number;
7
+ height?: number;
8
+ };
9
+ //# sourceMappingURL=icon.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"icon.types.d.ts","sourceRoot":"","sources":["../../../../../src/shared/icons/icon.types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,SAAS,GAAG;IACpB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,CAAC,EAAE,MAAM,CAAA;CAClB,CAAA"}
@@ -0,0 +1,6 @@
1
+ export declare const LOCALIZATION_CONFIGS: {
2
+ "en-SE": {};
3
+ "en-GB": {};
4
+ "sv-SE": {};
5
+ };
6
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/constants.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,oBAAoB;;;;CAIhC,CAAA"}
@@ -0,0 +1,6 @@
1
+ import { LOCALIZATION_CONFIGS } from './constants';
2
+ import { GetText, LocalizationConfig } from './types';
3
+ export declare const getSubstitutedString: (str: string, substitutions?: Record<string, string>) => string;
4
+ export declare const getText: GetText;
5
+ export declare const setFeaturesLocalization: (generator: ((config: typeof LOCALIZATION_CONFIGS) => LocalizationConfig) | LocalizationConfig) => void;
6
+ //# sourceMappingURL=helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/helpers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAElD,OAAO,EAAE,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAErD,eAAO,MAAM,oBAAoB,QAAS,MAAM,kBAAiB,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,WAWtF,CAAA;AAED,eAAO,MAAM,OAAO,EAAE,OAUrB,CAAA;AAED,eAAO,MAAM,uBAAuB,cACrB,CAAC,CAAC,MAAM,EAAE,OAAO,oBAAoB,KAAK,kBAAkB,CAAC,GAAG,kBAAkB,SAGhG,CAAA"}
@@ -0,0 +1,5 @@
1
+ import { GetText, LocalizationConfig } from './types';
2
+ import { LOCALIZATION_CONFIGS } from './constants';
3
+ export declare const useText: () => GetText;
4
+ export declare const useFeaturesLocalization: (generator: ((config: typeof LOCALIZATION_CONFIGS) => LocalizationConfig) | LocalizationConfig) => void;
5
+ //# sourceMappingURL=hooks.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/hooks.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAErD,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAGlD,eAAO,MAAM,OAAO,QAAO,OAY1B,CAAA;AAED,eAAO,MAAM,uBAAuB,cACrB,CAAC,CAAC,MAAM,EAAE,OAAO,oBAAoB,KAAK,kBAAkB,CAAC,GAAG,kBAAkB,SAKhG,CAAA"}
@@ -0,0 +1,6 @@
1
+ export { useFeaturesLocalization, useText } from './hooks';
2
+ export { setFeaturesLocalization, getText as t } from './helpers';
3
+ export { $localization, setLocalization } from './model';
4
+ export { Locale } from './types';
5
+ export type { LocalizationConfig } from './types';
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,OAAO,EAAE,MAAM,SAAS,CAAA;AAC1D,OAAO,EAAE,uBAAuB,EAAE,OAAO,IAAI,CAAC,EAAE,MAAM,WAAW,CAAA;AACjE,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,SAAS,CAAA;AACxD,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAA;AAChC,YAAY,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAA"}
@@ -0,0 +1,5 @@
1
+ import { LocalizationConfig } from './types';
2
+ import { LOCALIZATION_CONFIGS } from './constants';
3
+ export declare const setLocalization: import("effector").EventCallable<LocalizationConfig | ((config: typeof LOCALIZATION_CONFIGS) => LocalizationConfig)>;
4
+ export declare const $localization: import("effector").StoreWritable<LocalizationConfig>;
5
+ //# sourceMappingURL=model.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/model.ts"],"names":[],"mappings":"AACA,OAAO,EAAU,kBAAkB,EAAE,MAAM,SAAS,CAAA;AACpD,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAElD,eAAO,MAAM,eAAe,kEACO,OAAO,oBAAoB,KAAK,kBAAkB,EAClF,CAAA;AAEH,eAAO,MAAM,aAAa,sDAMzB,CAAA"}
@@ -0,0 +1,8 @@
1
+ export type GetText = (key: string, args?: Record<string, string> | null) => string;
2
+ export declare enum Locale {
3
+ EN = "en-SE",
4
+ SW = "sv-SE",
5
+ GB = "en-GB"
6
+ }
7
+ export type LocalizationConfig = Record<string, string>;
8
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,OAAO,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,IAAI,KAAK,MAAM,CAAA;AAEnF,oBAAY,MAAM;IACd,EAAE,UAAU;IACZ,EAAE,UAAU;IACZ,EAAE,UAAU;CACf;AAED,MAAM,MAAM,kBAAkB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA"}
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import { ChatbotModel } from '../../model/model';
3
+ type AlternativesProps = {
4
+ model: ChatbotModel;
5
+ onPressAlternative: (message: string, promptKey: string, translatedMessage?: string) => void;
6
+ hasMessages: boolean;
7
+ isHintFeedback: boolean;
8
+ };
9
+ export declare const Alternatives: ({ model, onPressAlternative, hasMessages, isHintFeedback, }: AlternativesProps) => React.JSX.Element;
10
+ export {};
11
+ //# sourceMappingURL=Alternatives.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Alternatives.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/Alternatives/Alternatives.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAKzB,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAGhD,KAAK,iBAAiB,GAAG;IACvB,KAAK,EAAE,YAAY,CAAA;IACnB,kBAAkB,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,iBAAiB,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;IAC5F,WAAW,EAAE,OAAO,CAAA;IACpB,cAAc,EAAE,OAAO,CAAA;CACxB,CAAA;AAED,eAAO,MAAM,YAAY,gEAKtB,iBAAiB,sBAkCnB,CAAA"}
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ type HelpRequestOptionProps = {
3
+ onPress: () => void;
4
+ message: string;
5
+ disabled: boolean;
6
+ };
7
+ export declare const HelpRequestOption: ({ onPress, message, disabled, }: HelpRequestOptionProps) => React.JSX.Element;
8
+ export {};
9
+ //# sourceMappingURL=HelpRequestOption.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"HelpRequestOption.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/Alternatives/HelpRequestOption.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAYzB,KAAK,sBAAsB,GAAG;IAC5B,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,OAAO,EAAE,MAAM,CAAA;IACf,QAAQ,EAAE,OAAO,CAAA;CAClB,CAAA;AAED,eAAO,MAAM,iBAAiB,oCAI3B,sBAAsB,sBAoCxB,CAAA"}
@@ -0,0 +1,14 @@
1
+ import React from 'react';
2
+ import { ComponentType, PropsWithChildren } from 'react';
3
+ import { ChatbotModel } from '../../model/model';
4
+ type ChatControlsProps = {
5
+ model: ChatbotModel;
6
+ onPressTranslate: () => void;
7
+ onPressChatIcon: () => void;
8
+ onPressClose: () => void;
9
+ isTranslationEnabled: boolean;
10
+ ButtonWrapper: ComponentType<PropsWithChildren>;
11
+ };
12
+ export declare const ChatControls: ({ model, onPressTranslate, onPressChatIcon, onPressClose, isTranslationEnabled, ButtonWrapper, }: ChatControlsProps) => React.JSX.Element;
13
+ export {};
14
+ //# sourceMappingURL=ChatControls.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatControls.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/ChatControls/ChatControls.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAA;AAIxD,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAKhD,KAAK,iBAAiB,GAAG;IACvB,KAAK,EAAE,YAAY,CAAA;IACnB,gBAAgB,EAAE,MAAM,IAAI,CAAA;IAC5B,eAAe,EAAE,MAAM,IAAI,CAAA;IAC3B,YAAY,EAAE,MAAM,IAAI,CAAA;IACxB,oBAAoB,EAAE,OAAO,CAAA;IAC7B,aAAa,EAAE,aAAa,CAAC,iBAAiB,CAAC,CAAA;CAChD,CAAA;AAED,eAAO,MAAM,YAAY,qGAOtB,iBAAiB,sBA+CnB,CAAA"}
@@ -0,0 +1,17 @@
1
+ import React, { ReactNode } from 'react';
2
+ import { AudioStatus } from '../../types/t2s.types';
3
+ import { MessageVariant, ChatbotRenderer } from '../../types/model.types';
4
+ type ChatMessageProps = {
5
+ variant: MessageVariant;
6
+ message: string;
7
+ onPressTextToSpeech: () => void;
8
+ isTextToSpeechPending: boolean;
9
+ isActive: boolean;
10
+ withTextToSpeech?: boolean;
11
+ audioStatus: AudioStatus;
12
+ renderer?: (props: ChatbotRenderer) => ReactNode;
13
+ };
14
+ export type VariantProps = Omit<ChatMessageProps, 'variant'>;
15
+ export declare const ChatMessage: ({ variant, ...props }: ChatMessageProps) => React.JSX.Element;
16
+ export {};
17
+ //# sourceMappingURL=ChatMessage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatMessage.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/ChatMessage/ChatMessage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAiB,SAAS,EAAE,MAAM,OAAO,CAAA;AAGvD,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;AACnD,OAAO,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAA;AAEzE,KAAK,gBAAgB,GAAG;IACtB,OAAO,EAAE,cAAc,CAAA;IACvB,OAAO,EAAE,MAAM,CAAA;IACf,mBAAmB,EAAE,MAAM,IAAI,CAAA;IAC/B,qBAAqB,EAAE,OAAO,CAAA;IAC9B,QAAQ,EAAE,OAAO,CAAA;IACjB,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,WAAW,EAAE,WAAW,CAAA;IACxB,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,SAAS,CAAA;CACjD,CAAA;AAED,MAAM,MAAM,YAAY,GAAG,IAAI,CAAC,gBAAgB,EAAE,SAAS,CAAC,CAAA;AAO5D,eAAO,MAAM,WAAW,0BAA2B,gBAAgB,sBAGlE,CAAA"}
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ export declare const MessageLoader: () => React.JSX.Element;
3
+ //# sourceMappingURL=MessageLoader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MessageLoader.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/ChatMessage/MessageLoader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAKzB,eAAO,MAAM,aAAa,yBASzB,CAAA"}
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { AudioStatus } from '../../types/t2s.types';
3
+ type MessageTextToSpeechProps = {
4
+ status: AudioStatus;
5
+ disabled: boolean;
6
+ isActive: boolean;
7
+ isLoading: boolean;
8
+ onPress: () => void;
9
+ };
10
+ export declare const MessageTextToSpeech: ({ status, disabled, isActive, isLoading, onPress, }: MessageTextToSpeechProps) => React.JSX.Element;
11
+ export {};
12
+ //# sourceMappingURL=MessageTextToSpeech.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MessageTextToSpeech.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/ChatMessage/MessageTextToSpeech.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAKzB,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;AAsBnD,KAAK,wBAAwB,GAAG;IAC9B,MAAM,EAAE,WAAW,CAAA;IACnB,QAAQ,EAAE,OAAO,CAAA;IACjB,QAAQ,EAAE,OAAO,CAAA;IACjB,SAAS,EAAE,OAAO,CAAA;IAClB,OAAO,EAAE,MAAM,IAAI,CAAA;CACpB,CAAA;AAED,eAAO,MAAM,mBAAmB,wDAM7B,wBAAwB,sBAU1B,CAAA"}
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { VariantProps } from './ChatMessage';
3
+ export declare const ReceivedMessage: ({ message, onPressTextToSpeech, isTextToSpeechPending, isActive, audioStatus, renderer, withTextToSpeech, }: VariantProps) => React.JSX.Element;
4
+ //# sourceMappingURL=ReceivedMessage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ReceivedMessage.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/ChatMessage/ReceivedMessage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAA;AAK5C,eAAO,MAAM,eAAe,gHAQzB,YAAY,sBAuBd,CAAA"}
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { VariantProps } from './ChatMessage';
3
+ export declare const SentMessage: ({ message, renderer }: VariantProps) => React.JSX.Element;
4
+ //# sourceMappingURL=SentMessage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SentMessage.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/ChatMessage/SentMessage.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAA;AAG5C,eAAO,MAAM,WAAW,0BAA2B,YAAY,sBAQ9D,CAAA"}
@@ -0,0 +1,21 @@
1
+ import React, { ReactNode } from 'react';
2
+ import { ChatbotModel } from '../../model/model';
3
+ import { PostMessagePayload } from '../../types/api.types';
4
+ import { AUDIO_CONFIG, DEFAULT_VOICE } from '../../constants';
5
+ import { ChatbotRenderer } from '../../types/model.types';
6
+ type ChatbotMessagesProps = {
7
+ model: ChatbotModel;
8
+ isHintFeedback: boolean;
9
+ sendHelpRequestPayload: Omit<PostMessagePayload, 'type'>;
10
+ translationTargetLanguage: string;
11
+ sanitizeSpeechInput: (speech: string) => string;
12
+ isTextToSpeechEnabled: boolean;
13
+ textToSpeechConfig?: {
14
+ voice: typeof DEFAULT_VOICE;
15
+ audioConfig: typeof AUDIO_CONFIG;
16
+ };
17
+ renderer?: (props: ChatbotRenderer) => ReactNode;
18
+ };
19
+ export declare const ChatbotMessages: ({ model, isHintFeedback, sendHelpRequestPayload, translationTargetLanguage, sanitizeSpeechInput, isTextToSpeechEnabled, textToSpeechConfig, renderer, }: ChatbotMessagesProps) => React.JSX.Element;
20
+ export {};
21
+ //# sourceMappingURL=ChatbotMessages.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatbotMessages.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/ChatMessages/ChatbotMessages.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAU,MAAM,OAAO,CAAA;AAGhD,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAIhD,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAA;AAC1D,OAAO,EAAE,YAAY,EAAE,aAAa,EAAyB,MAAM,iBAAiB,CAAA;AACpF,OAAO,EAAkB,eAAe,EAAE,MAAM,yBAAyB,CAAA;AAEzE,KAAK,oBAAoB,GAAG;IAC1B,KAAK,EAAE,YAAY,CAAA;IACnB,cAAc,EAAE,OAAO,CAAA;IACvB,sBAAsB,EAAE,IAAI,CAAC,kBAAkB,EAAE,MAAM,CAAC,CAAA;IACxD,yBAAyB,EAAE,MAAM,CAAA;IACjC,mBAAmB,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,MAAM,CAAA;IAC/C,qBAAqB,EAAE,OAAO,CAAA;IAC9B,kBAAkB,CAAC,EAAE;QACnB,KAAK,EAAE,OAAO,aAAa,CAAA;QAC3B,WAAW,EAAE,OAAO,YAAY,CAAA;KACjC,CAAA;IACD,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,SAAS,CAAA;CACjD,CAAA;AAKD,eAAO,MAAM,eAAe,4JASzB,oBAAoB,sBA6FtB,CAAA"}
@@ -0,0 +1,25 @@
1
+ import { ComponentType, PropsWithChildren, ReactNode } from 'react';
2
+ import { ChatbotModel } from '../model/model';
3
+ import { PostMessagePayload } from '../types/api.types';
4
+ import { AUDIO_CONFIG, DEFAULT_VOICE } from '../constants';
5
+ import { ChatbotRenderer } from '../types/model.types';
6
+ import React from 'react';
7
+ type ChatbotProps = {
8
+ model: ChatbotModel;
9
+ translationTargetLanguage: string;
10
+ isEnabled: boolean;
11
+ isHintFeedback: boolean;
12
+ sendHelpRequestPayload: Omit<PostMessagePayload, 'type'>;
13
+ sanitizeSpeechInput: (speech: string) => string;
14
+ isTextToSpeechEnabled: boolean;
15
+ isTranslationEnabled: boolean;
16
+ textToSpeechConfig?: {
17
+ voice: typeof DEFAULT_VOICE;
18
+ audioConfig: typeof AUDIO_CONFIG;
19
+ };
20
+ ButtonWrapper: ComponentType<PropsWithChildren>;
21
+ renderer?: (props: ChatbotRenderer) => ReactNode;
22
+ };
23
+ export declare const Chatbot: ({ model, translationTargetLanguage, isEnabled, isHintFeedback, sendHelpRequestPayload, sanitizeSpeechInput, isTextToSpeechEnabled, textToSpeechConfig, isTranslationEnabled, renderer, ButtonWrapper, }: ChatbotProps) => React.JSX.Element | null;
24
+ export {};
25
+ //# sourceMappingURL=Chatbot.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Chatbot.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chatbot/components/Chatbot.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,SAAS,EAAa,MAAM,OAAO,CAAA;AAG9E,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;AAG7C,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAA;AACvD,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AAC1D,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAA;AACtD,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,KAAK,YAAY,GAAG;IAClB,KAAK,EAAE,YAAY,CAAA;IACnB,yBAAyB,EAAE,MAAM,CAAA;IACjC,SAAS,EAAE,OAAO,CAAA;IAClB,cAAc,EAAE,OAAO,CAAA;IACvB,sBAAsB,EAAE,IAAI,CAAC,kBAAkB,EAAE,MAAM,CAAC,CAAA;IACxD,mBAAmB,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,MAAM,CAAA;IAC/C,qBAAqB,EAAE,OAAO,CAAA;IAC9B,oBAAoB,EAAE,OAAO,CAAA;IAC7B,kBAAkB,CAAC,EAAE;QACnB,KAAK,EAAE,OAAO,aAAa,CAAA;QAC3B,WAAW,EAAE,OAAO,YAAY,CAAA;KACjC,CAAA;IACD,aAAa,EAAE,aAAa,CAAC,iBAAiB,CAAC,CAAA;IAC/C,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,SAAS,CAAA;CACjD,CAAA;AAED,eAAO,MAAM,OAAO,4MAYjB,YAAY,6BAmDd,CAAA"}
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ type ChatLoaderProps = {
3
+ dotsCount?: number;
4
+ animationDuration?: number;
5
+ backgroundColor?: string;
6
+ };
7
+ export declare const ThreeDotsLoader: ({ dotsCount, animationDuration, backgroundColor, }: ChatLoaderProps) => React.JSX.Element;
8
+ export {};
9
+ //# sourceMappingURL=ThreeDotsLoader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ThreeDotsLoader.d.ts","sourceRoot":"","sources":["../../../../../../../src/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAIzB,KAAK,eAAe,GAAG;IACrB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,eAAe,CAAC,EAAE,MAAM,CAAA;CACzB,CAAA;AAED,eAAO,MAAM,eAAe,uDAIzB,eAAe,sBAgDjB,CAAA"}
@@ -0,0 +1,21 @@
1
+ export declare const AUDIO_CONFIG: {
2
+ audioEncoding: string;
3
+ pitch: number;
4
+ speakingRate: number;
5
+ };
6
+ export declare const DEFAULT_VOICE: {
7
+ languageCode: string;
8
+ name: string;
9
+ };
10
+ export declare const TEXT_TO_SPEECH_CONFIG: {
11
+ audioConfig: {
12
+ audioEncoding: string;
13
+ pitch: number;
14
+ speakingRate: number;
15
+ };
16
+ voice: {
17
+ languageCode: string;
18
+ name: string;
19
+ };
20
+ };
21
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/features/chatbot/constants.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,YAAY;;;;CAIxB,CAAA;AAED,eAAO,MAAM,aAAa;;;CAGzB,CAAA;AAED,eAAO,MAAM,qBAAqB;;;;;;;;;;CAgBvB,CAAA"}
@@ -0,0 +1,2 @@
1
+ export declare const decodeHTMLEntities: (input: string) => string;
2
+ //# sourceMappingURL=helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../src/features/chatbot/helpers.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,kBAAkB,UAAW,MAAM,WAE/C,CAAA"}
@@ -0,0 +1,5 @@
1
+ export { Chatbot } from './components/Chatbot';
2
+ export { ChatbotModel } from './model/model';
3
+ export { AudioStatus, type AudioProvider } from './types/t2s.types';
4
+ export { MessageVariant, type ConversationMessage, type ChatbotRenderer } from './types/model.types';
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/features/chatbot/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAA;AAC5C,OAAO,EAAE,WAAW,EAAE,KAAK,aAAa,EAAE,MAAM,mBAAmB,CAAA;AACnE,OAAO,EAAE,cAAc,EAAE,KAAK,mBAAmB,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAA"}
@@ -0,0 +1,12 @@
1
+ import { Effect } from 'effector';
2
+ import { ControlledEffect } from '../../../lib/effector/createControllerEffect';
3
+ import { ChatbotModelProps } from '../types/model.types';
4
+ import { GetAlternativesResponse, PostMessagePayload, PostMessageResponse, GoogleTranslatePayload, GoogleTranslateResponse, GoogleText2SpeechPayload, GoogleText2SpeechResponse } from '../types/api.types';
5
+ export declare class ChatbotAPI {
6
+ postMessageFx: ControlledEffect<PostMessagePayload, PostMessageResponse>;
7
+ getAlternativesFx: Effect<void, GetAlternativesResponse>;
8
+ translateTextFx: Effect<GoogleTranslatePayload, GoogleTranslateResponse>;
9
+ textToSpeechTextFx: Effect<GoogleText2SpeechPayload, GoogleText2SpeechResponse>;
10
+ constructor(api: ChatbotModelProps['api']);
11
+ }
12
+ //# sourceMappingURL=api.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chatbot/model/api.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,MAAM,EAAE,MAAM,UAAU,CAAA;AAG/C,OAAO,EAAE,gBAAgB,EAAE,MAAM,8CAA8C,CAAA;AAC/E,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAA;AACxD,OAAO,EACH,uBAAuB,EACvB,kBAAkB,EAClB,mBAAmB,EACnB,sBAAsB,EACtB,uBAAuB,EACvB,wBAAwB,EACxB,yBAAyB,EAC5B,MAAM,oBAAoB,CAAA;AAE3B,qBAAa,UAAU;IACnB,aAAa,EAAE,gBAAgB,CAAC,kBAAkB,EAAE,mBAAmB,CAAC,CAAA;IACxE,iBAAiB,EAAE,MAAM,CAAC,IAAI,EAAE,uBAAuB,CAAC,CAAA;IACxD,eAAe,EAAE,MAAM,CAAC,sBAAsB,EAAE,uBAAuB,CAAC,CAAA;IACxE,kBAAkB,EAAE,MAAM,CAAC,wBAAwB,EAAE,yBAAyB,CAAC,CAAA;gBAEnE,GAAG,EAAE,iBAAiB,CAAC,KAAK,CAAC;CAM5C"}
@@ -0,0 +1,73 @@
1
+ import { type Store, type Effect } from 'effector';
2
+ import { AvailableChatsModel, ChatbotModelProps, ChatMessagesModel, ConversationMessage, EntityIds, SendHelpParams, SetHintMessageProps, ThreadIdsModel } from '../types/model.types';
3
+ import { GetAlternativesResponse, PostMessageResponse } from '../types/api.types';
4
+ import { ChatbotAPI } from './api';
5
+ import { ChatbotTranslation } from './translation';
6
+ import { ChatTextToSpeech } from './t2s';
7
+ export declare class ChatbotModel {
8
+ readonly api: ChatbotAPI;
9
+ readonly translation: ChatbotTranslation;
10
+ readonly t2s: ChatTextToSpeech;
11
+ readonly credits: ChatbotModelProps['credits'];
12
+ readonly resetAlternatives: import("effector").EventCallable<void>;
13
+ readonly setAlternatives: import("effector").EventCallable<GetAlternativesResponse | null>;
14
+ readonly $alternatives: Store<GetAlternativesResponse | null>;
15
+ readonly setIsOpen: import("effector").EventCallable<boolean>;
16
+ readonly toggleOpen: import("effector").EventCallable<void>;
17
+ readonly $isOpen: import("effector").StoreWritable<boolean>;
18
+ readonly removeLastMessage: import("effector").EventCallable<void>;
19
+ readonly setLastMessageIds: import("effector").EventCallable<EntityIds | null>;
20
+ readonly $lastMessageIds: import("effector").StoreWritable<EntityIds | null>;
21
+ readonly setScrollActive: import("effector").EventCallable<boolean>;
22
+ readonly $isScrollActive: import("effector").StoreWritable<boolean>;
23
+ readonly sendHelpRequestFx: Effect<SendHelpParams, PostMessageResponse | ConversationMessage>;
24
+ readonly defaultMessages: ChatbotModelProps['messages'];
25
+ constructor({ credits, api, messages, }: ChatbotModelProps);
26
+ readonly messages: {
27
+ $state: import("effector").StoreWritable<Record<string, Record<string, {
28
+ messages: ConversationMessage[];
29
+ }>>>;
30
+ setField: (value: ChatMessagesModel) => void;
31
+ fieldAdded: import("effector").EventCallable<{
32
+ entityId: string;
33
+ fieldId: string;
34
+ data: {
35
+ messages: ConversationMessage[];
36
+ };
37
+ }>;
38
+ reset: import("effector").EventCallable<void>;
39
+ };
40
+ readonly threadIds: {
41
+ $state: import("effector").StoreWritable<Record<string, Record<string, {
42
+ threadId: string;
43
+ }>>>;
44
+ setField: (value: ThreadIdsModel) => void;
45
+ fieldAdded: import("effector").EventCallable<{
46
+ entityId: string;
47
+ fieldId: string;
48
+ data: {
49
+ threadId: string;
50
+ };
51
+ }>;
52
+ reset: import("effector").EventCallable<void>;
53
+ };
54
+ readonly availableChats: {
55
+ $state: import("effector").StoreWritable<Record<string, Record<string, {
56
+ isAvailable: boolean;
57
+ }>>>;
58
+ setField: (value: AvailableChatsModel) => void;
59
+ fieldAdded: import("effector").EventCallable<{
60
+ entityId: string;
61
+ fieldId: string;
62
+ data: {
63
+ isAvailable: boolean;
64
+ };
65
+ }>;
66
+ reset: import("effector").EventCallable<void>;
67
+ };
68
+ private createSendHelpRequestFx;
69
+ private initChatReplyWatcher;
70
+ startConversation(): void;
71
+ setHintMessage({ entityId, fieldId, ...message }: SetHintMessageProps): void;
72
+ }
73
+ //# sourceMappingURL=model.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chatbot/model/model.ts"],"names":[],"mappings":"AAAA,OAAO,EAAwC,KAAK,KAAK,EAAE,KAAK,MAAM,EAAE,MAAM,UAAU,CAAA;AAGxF,OAAO,EACH,mBAAmB,EACnB,iBAAiB,EACjB,iBAAiB,EACjB,mBAAmB,EACnB,SAAS,EACT,cAAc,EAEd,mBAAmB,EACnB,cAAc,EACjB,MAAM,sBAAsB,CAAA;AAC7B,OAAO,EAAE,uBAAuB,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAA;AAGjF,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAClC,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AAClD,OAAO,EAAE,gBAAgB,EAAE,MAAM,OAAO,CAAA;AAExC,qBAAa,YAAY;IACrB,QAAQ,CAAC,GAAG,EAAE,UAAU,CAAA;IACxB,QAAQ,CAAC,WAAW,EAAE,kBAAkB,CAAA;IACxC,QAAQ,CAAC,GAAG,EAAE,gBAAgB,CAAA;IAE9B,QAAQ,CAAC,OAAO,EAAE,iBAAiB,CAAC,SAAS,CAAC,CAAA;IAE9C,QAAQ,CAAC,iBAAiB,yCAAgB;IAC1C,QAAQ,CAAC,eAAe,mEAAgD;IACxE,QAAQ,CAAC,aAAa,EAAE,KAAK,CAAC,uBAAuB,GAAG,IAAI,CAAC,CAAA;IAE7D,QAAQ,CAAC,SAAS,4CAAyB;IAC3C,QAAQ,CAAC,UAAU,yCAAgB;IACnC,QAAQ,CAAC,OAAO,4CAAwE;IAGxF,QAAQ,CAAC,iBAAiB,yCAAgB;IAC1C,QAAQ,CAAC,iBAAiB,qDAAkC;IAC5D,QAAQ,CAAC,eAAe,qDAAwC;IAEhE,QAAQ,CAAC,eAAe,4CAAyB;IACjD,QAAQ,CAAC,eAAe,4CAAuC;IAE/D,QAAQ,CAAC,iBAAiB,EAAE,MAAM,CAAC,cAAc,EAAE,mBAAmB,GAAG,mBAAmB,CAAC,CAAA;IAE7F,QAAQ,CAAC,eAAe,EAAE,iBAAiB,CAAC,UAAU,CAAC,CAAA;gBAE3C,EACR,OAAO,EACP,GAAG,EACH,QAAQ,GACX,EAAE,iBAAiB;IAkBpB,QAAQ,CAAC,QAAQ;;;;;;;;;;;;;MAMf;IAEF,QAAQ,CAAC,SAAS;;;;;;;;;;;;;MAMhB;IAEF,QAAQ,CAAC,cAAc;;;;;;;;;;;;;MAMrB;IAEF,OAAO,CAAC,uBAAuB;IAsE/B,OAAO,CAAC,oBAAoB;IA6ErB,iBAAiB;IAoBjB,cAAc,CAAC,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,OAAO,EAAE,EAAE,mBAAmB;CAe/E"}
@@ -0,0 +1,18 @@
1
+ import { ChatbotModel } from './model';
2
+ import { AudioProvider, AudioStatus, PlayTextToSpeechProps } from '../types/t2s.types';
3
+ export declare class ChatTextToSpeech {
4
+ private readonly model;
5
+ private readonly audioCache;
6
+ private audioProvider;
7
+ readonly setCurrentPlayingId: import("effector").EventCallable<string | null>;
8
+ readonly $currentPlayingId: import("effector").StoreWritable<string | null>;
9
+ readonly setStatus: import("effector").EventCallable<AudioStatus>;
10
+ readonly $status: import("effector").StoreWritable<AudioStatus>;
11
+ constructor(chatbotModel: ChatbotModel);
12
+ setAudioProvider(audioProvider: AudioProvider): void;
13
+ private getCacheKey;
14
+ play({ text, messageId, isTranslated, config }: PlayTextToSpeechProps): Promise<void>;
15
+ stop(): void;
16
+ reset(): void;
17
+ }
18
+ //# sourceMappingURL=t2s.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"t2s.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chatbot/model/t2s.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAA;AAGtC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAA;AAEtF,qBAAa,gBAAgB;IACzB,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAc;IACpC,OAAO,CAAC,QAAQ,CAAC,UAAU,CAA6B;IACxD,OAAO,CAAC,aAAa,CAA6B;IAElD,QAAQ,CAAC,mBAAmB,kDAA+B;IAC3D,QAAQ,CAAC,iBAAiB,kDAA0C;IACpE,QAAQ,CAAC,SAAS,gDAA6B;IAC/C,QAAQ,CAAC,OAAO,gDAA+C;gBAEnD,YAAY,EAAE,YAAY;IAQ/B,gBAAgB,CAAC,aAAa,EAAE,aAAa;IAIpD,OAAO,CAAC,WAAW,CAElB;IAEK,IAAI,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,EAAE,EAAE,qBAAqB;IA0DpE,IAAI;IAYJ,KAAK;CAKf"}
@@ -0,0 +1,22 @@
1
+ import { type Effect } from 'effector';
2
+ import { ChatbotModel } from './model';
3
+ import { TranslateAlternativesFxProps, TranslateBatchFxProps, TranslateMessageFxProps } from '../types/translation.types';
4
+ import { ConversationMessage } from '../types/model.types';
5
+ import { GetAlternativesResponse } from '../types/api.types';
6
+ export declare class ChatbotTranslation {
7
+ private readonly model;
8
+ readonly setIsTranslated: import("effector").EventCallable<boolean>;
9
+ readonly $isTranslated: import("effector").StoreWritable<boolean>;
10
+ readonly translateMessageFx: Effect<TranslateMessageFxProps, ConversationMessage>;
11
+ readonly translateBatchFx: Effect<TranslateBatchFxProps['params'], ConversationMessage[]>;
12
+ readonly translateAlternativesFx: Effect<TranslateAlternativesFxProps['params'], GetAlternativesResponse | null>;
13
+ constructor(chatbotModel: ChatbotModel);
14
+ private shouldSkipTranslation;
15
+ private initTranslationSamples;
16
+ private createTranslateAlternativesEffect;
17
+ private createTranslateMessageEffect;
18
+ private createTranslateBatchEffect;
19
+ private translateMessageOptions;
20
+ reset(): void;
21
+ }
22
+ //# sourceMappingURL=translation.d.ts.map