@sapia-ai/chatbot 2.31.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 (344) hide show
  1. package/CHANGELOG.md +865 -0
  2. package/README.md +366 -0
  3. package/RootApp.d.ts +2 -0
  4. package/apis/FIApis.d.ts +152 -0
  5. package/apis/hooks/useGetApplicationJobRequisition.d.ts +12 -0
  6. package/apis/hooks/useGetJobRequisition.d.ts +10 -0
  7. package/apis/types/apiRequest.d.ts +1 -0
  8. package/apis/types/apiResponse.d.ts +16 -0
  9. package/apis/types/branding.d.ts +17 -0
  10. package/apis/types/jobRequisition.d.ts +20 -0
  11. package/commitlint.config.js +1 -0
  12. package/components/AccessVerificationForm/__tests__/AccessVerificationForm.test.d.ts +1 -0
  13. package/components/AccessVerificationForm/index.d.ts +1 -0
  14. package/components/AccessVerificationForm/view.d.ts +11 -0
  15. package/components/AgcWarningModal/__tests__/AGCWarningModal.test.d.ts +1 -0
  16. package/components/AgcWarningModal/index.d.ts +1 -0
  17. package/components/AgcWarningModal/view.d.ts +7 -0
  18. package/components/AssessmentProgressBar/__tests__/AssessmentProgressBar.test.d.ts +1 -0
  19. package/components/AssessmentProgressBar/index.d.ts +7 -0
  20. package/components/AssessmentProgressBar/view.d.ts +2 -0
  21. package/components/AutoScrollText/__tests__/AutoScrollText.test.d.ts +1 -0
  22. package/components/AutoScrollText/__tests__/useAutoScrollText.test.d.ts +1 -0
  23. package/components/AutoScrollText/useAutoScrollText.d.ts +7 -0
  24. package/components/AutoScrollText/view.d.ts +4 -0
  25. package/components/ButtonGroup/index.d.ts +1 -0
  26. package/components/ButtonGroup/view.d.ts +10 -0
  27. package/components/CancelEditButton/index.d.ts +1 -0
  28. package/components/CancelEditButton/view.d.ts +7 -0
  29. package/components/ChatbotApp/index.d.ts +1 -0
  30. package/components/ChatbotApp/view.d.ts +10 -0
  31. package/components/Dropdown/index.d.ts +3 -0
  32. package/components/Dropdown/view.d.ts +10 -0
  33. package/components/EditButton/__tests__/EditButton.test.d.ts +1 -0
  34. package/components/EditButton/index.d.ts +3 -0
  35. package/components/EditButton/view.d.ts +10 -0
  36. package/components/FTQResponse/__tests__/FTQResponse.test.d.ts +1 -0
  37. package/components/FTQResponse/index.d.ts +3 -0
  38. package/components/FTQResponse/view.d.ts +11 -0
  39. package/components/FullScreenSpinner/__tests__/FullScreenSpinner.test.d.ts +1 -0
  40. package/components/FullScreenSpinner/index.d.ts +1 -0
  41. package/components/FullScreenSpinner/view.d.ts +2 -0
  42. package/components/Icons/Close/Close.d.ts +5 -0
  43. package/components/Icons/Close/index.d.ts +1 -0
  44. package/components/Icons/DislikeEmoji/DislikeEmoji.d.ts +5 -0
  45. package/components/Icons/DislikeEmoji/index.d.ts +1 -0
  46. package/components/Icons/Error/index.d.ts +1 -0
  47. package/components/Icons/Error/view.d.ts +6 -0
  48. package/components/Icons/LikeEmoji/LikeEmoji.d.ts +5 -0
  49. package/components/Icons/LikeEmoji/index.d.ts +1 -0
  50. package/components/Icons/Pause/Pause.d.ts +6 -0
  51. package/components/Icons/Pause/index.d.ts +1 -0
  52. package/components/Icons/Play/Play.d.ts +6 -0
  53. package/components/Icons/Play/index.d.ts +1 -0
  54. package/components/Icons/Question/Question.d.ts +6 -0
  55. package/components/Icons/Question/index.d.ts +1 -0
  56. package/components/Icons/ReRecord/ReRecord.d.ts +5 -0
  57. package/components/Icons/ReRecord/index.d.ts +1 -0
  58. package/components/Icons/Record/Record.d.ts +6 -0
  59. package/components/Icons/Record/index.d.ts +1 -0
  60. package/components/Icons/RecordingTip/RecordingTip.d.ts +6 -0
  61. package/components/Icons/RecordingTip/index.d.ts +1 -0
  62. package/components/Icons/Retry/Retry.d.ts +6 -0
  63. package/components/Icons/Retry/index.d.ts +1 -0
  64. package/components/Icons/Save/Save.d.ts +5 -0
  65. package/components/Icons/Save/index.d.ts +1 -0
  66. package/components/Icons/Stop/Stop.d.ts +6 -0
  67. package/components/Icons/Stop/index.d.ts +1 -0
  68. package/components/Icons/index.d.ts +13 -0
  69. package/components/IosChromeError/index.d.ts +7 -0
  70. package/components/IosChromeError/view.d.ts +3 -0
  71. package/components/Loading/index.d.ts +3 -0
  72. package/components/Loading/view.d.ts +9 -0
  73. package/components/NameEditor/NameEditor.d.ts +26 -0
  74. package/components/NameEditor/__tests__/NameEditor.FirstName.test.d.ts +1 -0
  75. package/components/NameEditor/__tests__/NameEditor.FullName.test.d.ts +1 -0
  76. package/components/NameEditor/__tests__/NameEditor.LastName.test.d.ts +1 -0
  77. package/components/NameEditor/__tests__/NameEditor.test.d.ts +1 -0
  78. package/components/NameEditor/__tests__/useHumanNameExtraction.FirstName.test.d.ts +1 -0
  79. package/components/NameEditor/__tests__/useHumanNameExtraction.FullName.test.d.ts +1 -0
  80. package/components/NameEditor/__tests__/useHumanNameExtraction.LastName.test.d.ts +1 -0
  81. package/components/NameEditor/__tests__/useHumanNameExtraction.test.d.ts +1 -0
  82. package/components/NameEditor/useHumanNameExtraction.d.ts +22 -0
  83. package/components/NameExtractionConfirmModal/__tests__/NameExtractionConfirmModal.test.d.ts +1 -0
  84. package/components/NameExtractionConfirmModal/index.d.ts +1 -0
  85. package/components/NameExtractionConfirmModal/view.d.ts +15 -0
  86. package/components/OptionList/index.d.ts +3 -0
  87. package/components/OptionList/view.d.ts +11 -0
  88. package/components/PHEditor/DesktopQuillEditor/index.d.ts +1 -0
  89. package/components/PHEditor/DesktopQuillEditor/view.d.ts +37 -0
  90. package/components/PHEditor/MobileEditor/ClickableBar.d.ts +7 -0
  91. package/components/PHEditor/MobileEditor/__tests__/ClickableBar.test.d.ts +1 -0
  92. package/components/PHEditor/MobileEditor/view.d.ts +28 -0
  93. package/components/PHEditor/PlainTextEditor/index.d.ts +3 -0
  94. package/components/PHEditor/PlainTextEditor/view.d.ts +26 -0
  95. package/components/PHEditor/TextDictationModal/index.d.ts +1 -0
  96. package/components/PHEditor/TextDictationModal/view.d.ts +6 -0
  97. package/components/PHEditor/TextDictationTip/index.d.ts +1 -0
  98. package/components/PHEditor/TextDictationTip/view.d.ts +4 -0
  99. package/components/PHEditor/WordCount/index.d.ts +1 -0
  100. package/components/PHEditor/WordCount/view.d.ts +12 -0
  101. package/components/PHEditor/__tests__/DesktopQuillEditor.test.d.ts +1 -0
  102. package/components/PHEditor/__tests__/PlainTextEditor.test.d.ts +1 -0
  103. package/components/PHEditor/__tests__/utils.test.d.ts +1 -0
  104. package/components/PHEditor/index.d.ts +2 -0
  105. package/components/PHEditor/types.d.ts +8 -0
  106. package/components/PHEditor/utils.d.ts +20 -0
  107. package/components/PHError/index.d.ts +7 -0
  108. package/components/PHError/view.d.ts +4 -0
  109. package/components/PHIconFont/index.d.ts +7 -0
  110. package/components/PHIconFont/view.d.ts +2 -0
  111. package/components/PHSelect/__tests__/PHSelect.test.d.ts +1 -0
  112. package/components/PHSelect/index.d.ts +1 -0
  113. package/components/PHSelect/view.d.ts +8 -0
  114. package/components/PHVideo/DesktopVideo/__tests__/utils/formatTime.test.d.ts +1 -0
  115. package/components/PHVideo/DesktopVideo/components/Video/index.d.ts +3 -0
  116. package/components/PHVideo/DesktopVideo/components/Video/view.d.ts +42 -0
  117. package/components/PHVideo/DesktopVideo/components/VideoPreviewControls/index.d.ts +3 -0
  118. package/components/PHVideo/DesktopVideo/components/VideoPreviewControls/view.d.ts +10 -0
  119. package/components/PHVideo/DesktopVideo/index.d.ts +3 -0
  120. package/components/PHVideo/DesktopVideo/utils.d.ts +1 -0
  121. package/components/PHVideo/DesktopVideo/view.d.ts +10 -0
  122. package/components/PHVideo/MobileVideo/index.d.ts +3 -0
  123. package/components/PHVideo/MobileVideo/view.d.ts +9 -0
  124. package/components/PhoneCodeSelect/__tests__/PhoneCodeSelect.test.d.ts +1 -0
  125. package/components/PhoneCodeSelect/index.d.ts +1 -0
  126. package/components/PhoneCodeSelect/sources.d.ts +8 -0
  127. package/components/PhoneCodeSelect/view.d.ts +6 -0
  128. package/components/PhoneEditor/__tests__/PhoneEditor.test.d.ts +1 -0
  129. package/components/PhoneEditor/index.d.ts +3 -0
  130. package/components/PhoneEditor/view.d.ts +16 -0
  131. package/components/PlacesAutoComplete/api.d.ts +17 -0
  132. package/components/PlacesAutoComplete/constants.d.ts +8 -0
  133. package/components/PlacesAutoComplete/hooks/usePlacesAutoComplete.d.ts +21 -0
  134. package/components/PlacesAutoComplete/index.d.ts +6 -0
  135. package/components/PlacesAutoComplete/types.d.ts +53 -0
  136. package/components/PlacesAutoComplete/view.d.ts +16 -0
  137. package/components/ReRecordVideoButton/index.d.ts +3 -0
  138. package/components/ReRecordVideoButton/view.d.ts +7 -0
  139. package/components/ReciteMeWrapper/ReciteMeWrapper.d.ts +16 -0
  140. package/components/ReciteMeWrapper/index.d.ts +1 -0
  141. package/components/SendAnswerFailedModal/index.d.ts +1 -0
  142. package/components/SendAnswerFailedModal/view.d.ts +6 -0
  143. package/components/SendCircleButton/__tests__/SendCircleButton.test.d.ts +1 -0
  144. package/components/SendCircleButton/index.d.ts +3 -0
  145. package/components/SendCircleButton/view.d.ts +11 -0
  146. package/components/Slider/__tests__/Slider.test.d.ts +1 -0
  147. package/components/Slider/index.d.ts +3 -0
  148. package/components/Slider/view.d.ts +9 -0
  149. package/components/TextBubble/__tests__/TextBubble.test.d.ts +1 -0
  150. package/components/TextBubble/index.d.ts +3 -0
  151. package/components/TextBubble/view.d.ts +23 -0
  152. package/components/Tooltip/index.d.ts +3 -0
  153. package/components/Tooltip/view.d.ts +6 -0
  154. package/components/UnsupportedBrowserGuard/index.d.ts +3 -0
  155. package/components/UnsupportedBrowserGuard/view.d.ts +5 -0
  156. package/components/UploadVideoFailedMessage/index.d.ts +9 -0
  157. package/components/UploadVideoFailedMessage/view.d.ts +4 -0
  158. package/components/UploadVideoProgressBar/index.d.ts +9 -0
  159. package/components/UploadVideoProgressBar/view.d.ts +4 -0
  160. package/components/VideoPlayer/index.d.ts +3 -0
  161. package/components/VideoPlayer/view.d.ts +7 -0
  162. package/components/VideoResponse/index.d.ts +3 -0
  163. package/components/VideoResponse/view.d.ts +5 -0
  164. package/components/WarningButton/index.d.ts +3 -0
  165. package/components/WarningButton/view.d.ts +4 -0
  166. package/components/WarningModal/index.d.ts +3 -0
  167. package/components/WarningModal/view.d.ts +10 -0
  168. package/components/hooks/useCharacterCountLimit.d.ts +3 -0
  169. package/components/hooks/useCheckScreenSize.d.ts +3 -0
  170. package/components/hooks/useSubmitShortcut.d.ts +1 -0
  171. package/components/hooks/useWordCountLimit.d.ts +4 -0
  172. package/config.d.ts +16 -0
  173. package/constants/browser.d.ts +7 -0
  174. package/constants/common.d.ts +48 -0
  175. package/constants/mockDataForDemo.d.ts +14 -0
  176. package/constants/theme.d.ts +10 -0
  177. package/contexts/AssessmentStateContext/AssessmentStateContext.d.ts +6 -0
  178. package/contexts/AssessmentStateContext/__tests__/AssessmentStateContext.test.d.ts +1 -0
  179. package/contexts/AssessmentStateContext/assessmentStateReducer/__tests__/action.test.d.ts +1 -0
  180. package/contexts/AssessmentStateContext/assessmentStateReducer/__tests__/assessmentStateReducer.test.d.ts +1 -0
  181. package/contexts/AssessmentStateContext/assessmentStateReducer/action.d.ts +3 -0
  182. package/contexts/AssessmentStateContext/assessmentStateReducer/assessmentStateReducer.d.ts +2 -0
  183. package/contexts/AssessmentStateContext/type.d.ts +22 -0
  184. package/contexts/ChatbotStateContext/ChatbotStateContext.d.ts +12 -0
  185. package/contexts/ChatbotStateContext/__tests__/ChatbotStateContext/ChatbotStateContext-render-error.test.d.ts +1 -0
  186. package/contexts/ChatbotStateContext/__tests__/ChatbotStateContext/ChatbotStateContext-render-normal.test.d.ts +1 -0
  187. package/contexts/ChatbotStateContext/__tests__/ChatbotStateContext/handleEditAnswer.test.d.ts +1 -0
  188. package/contexts/ChatbotStateContext/__tests__/ChatbotStateContext/handleExitEditAnswer.test.d.ts +1 -0
  189. package/contexts/ChatbotStateContext/__tests__/ChatbotStateContext/handleSelectOption.test.d.ts +1 -0
  190. package/contexts/ChatbotStateContext/__tests__/ChatbotStateContext/handleSubmitRating.test.d.ts +1 -0
  191. package/contexts/ChatbotStateContext/__tests__/ChatbotStateContext/handleUploadDataVideo.test.d.ts +1 -0
  192. package/contexts/ChatbotStateContext/__tests__/bubble-util/addCandidateResponseMessageBubble.test.d.ts +1 -0
  193. package/contexts/ChatbotStateContext/__tests__/bubble-util/checkShouldLoadNext.test.d.ts +1 -0
  194. package/contexts/ChatbotStateContext/__tests__/bubble-util/convertMessageBubbles.test.d.ts +1 -0
  195. package/contexts/ChatbotStateContext/__tests__/bubble-util/convertRawAgentResponseToMessageBubble.test.d.ts +1 -0
  196. package/contexts/ChatbotStateContext/__tests__/bubble-util/convertRawCandidateResponseToMessageBubble.test.d.ts +1 -0
  197. package/contexts/ChatbotStateContext/__tests__/bubble-util/convertRawResponseToMessageBubble.test.d.ts +1 -0
  198. package/contexts/ChatbotStateContext/__tests__/bubble-util/updateAnswerForCandidateMessageBubble.test.d.ts +1 -0
  199. package/contexts/ChatbotStateContext/__tests__/bubble-util/updateMessageBubbleStatus.test.d.ts +1 -0
  200. package/contexts/ChatbotStateContext/__tests__/bubble-util/updateMessageBubbleStatusInList.test.d.ts +1 -0
  201. package/contexts/ChatbotStateContext/__tests__/useOrder.test.d.ts +1 -0
  202. package/contexts/ChatbotStateContext/__tests__/useUploadVideo/getDisplayVideoUrl.test.d.ts +1 -0
  203. package/contexts/ChatbotStateContext/__tests__/useUploadVideo/getVideoRetryNum.test.d.ts +1 -0
  204. package/contexts/ChatbotStateContext/__tests__/useUploadVideo/uploadDataVideo.test.d.ts +1 -0
  205. package/contexts/ChatbotStateContext/bubble-util.d.ts +193 -0
  206. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/addAgentBubbleActionFn.test.d.ts +1 -0
  207. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/addCandidateResponseMessageBubbleActionFn.test.d.ts +1 -0
  208. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/addVideoUploadStatusBubbleActionFn.test.d.ts +1 -0
  209. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/agentNextResponseCompletedActionFn.test.d.ts +1 -0
  210. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/agentNextResponseStartingActionFn.test.d.ts +1 -0
  211. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/chatLogsLoadCompletedActionFn.test.d.ts +1 -0
  212. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/checkAgcCompletedActionFn.test.d.ts +1 -0
  213. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/convertRawBrandingTheme.test.d.ts +1 -0
  214. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/editAnswerRequestCompletedActionFn.test.d.ts +1 -0
  215. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/editModeEnterActionFn.test.d.ts +1 -0
  216. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/editModeExitActionFn.test.d.ts +1 -0
  217. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/removeFailedMessageBubbleActionFn.test.d.ts +1 -0
  218. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/renderCandidateBubbleManuallyActionFn.test.d.ts +1 -0
  219. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/replaceVideoUploadStatusBubbleActionFn.test.d.ts +1 -0
  220. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/updateCandidateMessageBubbleStatusActionFn.test.d.ts +1 -0
  221. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/updateRecordedVideoInfoActionFn.test.d.ts +1 -0
  222. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/action/updateRerecordVideoInfoActionFn.test.d.ts +1 -0
  223. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-ADD_AGENT_BUBBLE.test.d.ts +1 -0
  224. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-ADD_CANDIDATE_RESPONSE_BUBBLE.test.d.ts +1 -0
  225. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-ADD_VIDEO_UPLOAD_STATUS_BUBBLE.test.d.ts +1 -0
  226. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-AGENT_NEXT_RESPONSE_COMPLETED.test.d.ts +1 -0
  227. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-AGENT_NEXT_RESPONSE_STARTING.test.d.ts +1 -0
  228. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-CHATLOGS_LOAD_COMPLETED.test.d.ts +1 -0
  229. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-DETECT_AGC_COMPLETED.test.d.ts +1 -0
  230. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-EDIT_ANSWER_REQUEST_COMPLETED.test.d.ts +1 -0
  231. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-EDIT_MODE_ENTER.test.d.ts +1 -0
  232. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-EDIT_MODE_EXIT.test.d.ts +1 -0
  233. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-REMOVE_FAILED_MESSAGE_BUBBLE.test.d.ts +1 -0
  234. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-RENDER_CANDIDATE_BUBBLE_MANUALLY.test.d.ts +1 -0
  235. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-REPLACE_VIDEO_UPLOAD_STATUS_BUBBLE.test.d.ts +1 -0
  236. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-UPDATE_CANDIDATE_MESSAGE_BUBBLE_STATUS.test.d.ts +1 -0
  237. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-UPDATE_RECORDED_VIDEO_INFO.test.d.ts +1 -0
  238. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/chatbotStateReducer/chatbotStateReducer-UPDATE_RERECORD_VIDEO_INFO.test.d.ts +1 -0
  239. package/contexts/ChatbotStateContext/chatbotStateReducer/__tests__/util/phChatbotCbCallbackExecutor.test.d.ts +1 -0
  240. package/contexts/ChatbotStateContext/chatbotStateReducer/action.d.ts +23 -0
  241. package/contexts/ChatbotStateContext/chatbotStateReducer/chatbotStateReducer.d.ts +2 -0
  242. package/contexts/ChatbotStateContext/chatbotStateReducer/util.d.ts +13 -0
  243. package/contexts/ChatbotStateContext/type.d.ts +289 -0
  244. package/contexts/ChatbotStateContext/useDetectAgc/__tests__/useDetectAgc.test.d.ts +1 -0
  245. package/contexts/ChatbotStateContext/useDetectAgc/useDetectAgc.d.ts +17 -0
  246. package/contexts/ChatbotStateContext/useLoadNext/__tests__/helper/loadMessage.test.d.ts +1 -0
  247. package/contexts/ChatbotStateContext/useLoadNext/__tests__/helper/onloadNextSuccess.test.d.ts +1 -0
  248. package/contexts/ChatbotStateContext/useLoadNext/__tests__/useLoadNext.test.d.ts +1 -0
  249. package/contexts/ChatbotStateContext/useLoadNext/helper.d.ts +37 -0
  250. package/contexts/ChatbotStateContext/useLoadNext/useLoadNext.d.ts +31 -0
  251. package/contexts/ChatbotStateContext/useOrder.d.ts +31 -0
  252. package/contexts/ChatbotStateContext/useSubmitEditedAnswer/__tests__/useSubmitEditedAnswer.test.d.ts +1 -0
  253. package/contexts/ChatbotStateContext/useSubmitEditedAnswer/index.d.ts +1 -0
  254. package/contexts/ChatbotStateContext/useSubmitEditedAnswer/useSubmitEditedAnswer.d.ts +21 -0
  255. package/contexts/ChatbotStateContext/useUploadVideo.d.ts +29 -0
  256. package/features/AccessVerification/__tests__/AccessVerification.test.d.ts +1 -0
  257. package/features/AccessVerification/index.d.ts +1 -0
  258. package/features/AccessVerification/view.d.ts +10 -0
  259. package/features/AgentMessageBubble/index.d.ts +3 -0
  260. package/features/AgentMessageBubble/view.d.ts +5 -0
  261. package/features/Assessment/__tests__/Assessment.test.d.ts +1 -0
  262. package/features/Assessment/index.d.ts +3 -0
  263. package/features/Assessment/view.d.ts +2 -0
  264. package/features/AssessmentDialogFlow/index.d.ts +3 -0
  265. package/features/AssessmentDialogFlow/view.d.ts +7 -0
  266. package/features/AssessmentResponseFlow/index.d.ts +3 -0
  267. package/features/AssessmentResponseFlow/view.d.ts +5 -0
  268. package/features/CandidateMessageBubble/index.d.ts +3 -0
  269. package/features/CandidateMessageBubble/view.d.ts +8 -0
  270. package/features/Header/__tests__/Header.test.d.ts +1 -0
  271. package/features/Header/index.d.ts +3 -0
  272. package/features/Header/view.d.ts +2 -0
  273. package/features/Introduce/index.d.ts +3 -0
  274. package/features/Introduce/utils.d.ts +190 -0
  275. package/features/Introduce/view.d.ts +2 -0
  276. package/features/Layout/__tests__/Layout.test.d.ts +1 -0
  277. package/features/Layout/index.d.ts +3 -0
  278. package/features/Layout/view.d.ts +4 -0
  279. package/hooks/__tests__/useAccessManagement.test.d.ts +1 -0
  280. package/hooks/__tests__/useAccessVerification.test.d.ts +1 -0
  281. package/hooks/__tests__/useChatbotStatesContext.test.d.ts +1 -0
  282. package/hooks/__tests__/useExtractHumanName.test.d.ts +1 -0
  283. package/hooks/__tests__/useLocalStorage.test.d.ts +1 -0
  284. package/hooks/__tests__/useVerifyAccess.test.d.ts +1 -0
  285. package/hooks/useAccessManagement.d.ts +12 -0
  286. package/hooks/useAccessVerification.d.ts +13 -0
  287. package/hooks/useAssessmentStateContext.d.ts +2 -0
  288. package/hooks/useBeforeUnload.d.ts +2 -0
  289. package/hooks/useChatbotStatesContext.d.ts +2 -0
  290. package/hooks/useExtractHumanName.d.ts +15 -0
  291. package/hooks/useHandleEditorHeightChange.d.ts +7 -0
  292. package/hooks/useLocalStorage.d.ts +24 -0
  293. package/hooks/useQuery.d.ts +3 -0
  294. package/hooks/useVerifyAccess.d.ts +10 -0
  295. package/index.d.ts +1 -0
  296. package/package.json +172 -0
  297. package/pages/App/App.d.ts +11 -0
  298. package/pages/App/index.d.ts +2 -0
  299. package/pages/Chatbot/Chatbot.d.ts +3 -0
  300. package/pages/Chatbot/index.d.ts +2 -0
  301. package/pages/Home/Home.d.ts +3 -0
  302. package/pages/Home/index.d.ts +3 -0
  303. package/pages/LanguageSelectionPage/ApplicationLanguageSelectionPage.d.ts +6 -0
  304. package/pages/LanguageSelectionPage/GenericLanguageSelectionPage.d.ts +6 -0
  305. package/pages/LanguageSelectionPage/LanguageSelection.d.ts +13 -0
  306. package/pages/LanguageSelectionPage/__tests__/LanguageSelection.test.d.ts +1 -0
  307. package/pages/LanguageSelectionPage/index.d.ts +3 -0
  308. package/pages/LanguageSelectionPage/useLanguageSelection.d.ts +19 -0
  309. package/pages/OrderAssessment/OrderAssessment.d.ts +4 -0
  310. package/pages/OrderAssessment/index.d.ts +1 -0
  311. package/postcss.config.js +5 -0
  312. package/predictivehire.d.ts +45 -0
  313. package/predictivehire.js +71047 -0
  314. package/predictivehire.umd.js +382 -0
  315. package/serviceWorker.d.ts +7 -0
  316. package/static/favicon.ico +0 -0
  317. package/static/favicon.png +0 -0
  318. package/static/manifest.json +20 -0
  319. package/static/reciteme_button.png +0 -0
  320. package/static/robots.txt +3 -0
  321. package/tsconfig.build.json +5 -0
  322. package/types/Api.d.ts +25 -0
  323. package/types/AtsInformation.d.ts +52 -0
  324. package/types/ChatBot.d.ts +60 -0
  325. package/types/Next.d.ts +278 -0
  326. package/types/UrlParamKey.d.ts +6 -0
  327. package/utils/TestWrapper.d.ts +32 -0
  328. package/utils/__tests__/defaultLanguage.test.d.ts +1 -0
  329. package/utils/__tests__/getEnv.test.d.ts +1 -0
  330. package/utils/__tests__/messageBubble.test.d.ts +1 -0
  331. package/utils/__tests__/mockTranslationSource.d.ts +117 -0
  332. package/utils/__tests__/setTranslationSource.test.d.ts +1 -0
  333. package/utils/__tests__/translate.test.d.ts +1 -0
  334. package/utils/convertTheme.d.ts +39 -0
  335. package/utils/defaultLanguage.d.ts +6 -0
  336. package/utils/messageBubble.d.ts +11 -0
  337. package/utils/testUtils.d.ts +6 -0
  338. package/utils/translation/constants.d.ts +10 -0
  339. package/utils/translation/fallBackTranslation.d.ts +136 -0
  340. package/utils/translation/translation.d.ts +25 -0
  341. package/utils/utils.d.ts +16 -0
  342. package/vite.chatbot.config.js +90 -0
  343. package/vite.config.js +77 -0
  344. package/vitest.setup.d.ts +1 -0
@@ -0,0 +1,7 @@
1
+ declare type Config = {
2
+ onSuccess?: (registration: ServiceWorkerRegistration) => void;
3
+ onUpdate?: (registration: ServiceWorkerRegistration) => void;
4
+ };
5
+ export declare function register(config?: Config): void;
6
+ export declare function unregister(): Promise<void>;
7
+ export {};
Binary file
Binary file
@@ -0,0 +1,20 @@
1
+ {
2
+ "short_name": "React App",
3
+ "name": "Create React App Sample",
4
+ "icons": [
5
+ {
6
+ "src": "favicon.ico",
7
+ "sizes": "64x64 32x32 24x24 16x16",
8
+ "type": "image/x-icon"
9
+ },
10
+ {
11
+ "src": "favicon.png",
12
+ "type": "image/png",
13
+ "sizes": "47x47"
14
+ }
15
+ ],
16
+ "start_url": ".",
17
+ "display": "standalone",
18
+ "theme_color": "#000000",
19
+ "background_color": "#ffffff"
20
+ }
Binary file
@@ -0,0 +1,3 @@
1
+ # https://www.robotstxt.org/robotstxt.html
2
+ User-agent: *
3
+ Disallow:
@@ -0,0 +1,5 @@
1
+ {
2
+ "extends": "./tsconfig.json",
3
+ // Only include include src folder in build chatbot to have right dis-chatbot folder structure
4
+ "include": ["src"]
5
+ }
package/types/Api.d.ts ADDED
@@ -0,0 +1,25 @@
1
+ export declare enum Domain {
2
+ localhost = "http://fi.localhost.com:5004",
3
+ dev = "https://fi-api.dev.predictivehire.com",
4
+ qa = "https://fi-api.qa.predictivehire.com",
5
+ sandbox = "https://fi-api.sandbox.predictivehire.com",
6
+ product = "https://fi-api.product.predictivehire.com"
7
+ }
8
+ export declare type ApiResponse<T> = {
9
+ /**
10
+ * e.g 200, 404
11
+ */
12
+ status: number;
13
+ data: T;
14
+ };
15
+ export declare type ErrorResponse = {
16
+ /**
17
+ * e.g: 200, 404
18
+ */
19
+ code?: number;
20
+ message?: string;
21
+ };
22
+ export declare type FiToken = {
23
+ name: string;
24
+ value: string;
25
+ };
@@ -0,0 +1,52 @@
1
+ export declare type AtsCohortManager = {
2
+ externalId?: string;
3
+ email?: string;
4
+ firstName: string;
5
+ lastName: string;
6
+ };
7
+ declare type AtsCohort = {
8
+ customerId: string;
9
+ ownerUserId: string;
10
+ externalId: string;
11
+ title: string;
12
+ description?: string;
13
+ managers?: AtsCohortManager[];
14
+ };
15
+ export declare type AtsPersonalInformation = {
16
+ firstName: string;
17
+ lastName: string;
18
+ email: string;
19
+ phoneNumber: string;
20
+ };
21
+ export declare type AtsDemographic = {
22
+ name: string;
23
+ type: string;
24
+ value: Record<string, unknown>;
25
+ };
26
+ export declare type AtsLocation = {
27
+ address: string;
28
+ coordinate: {
29
+ lat: string;
30
+ lng: string;
31
+ };
32
+ };
33
+ declare type AtsCandidate = {
34
+ personalInformation: AtsPersonalInformation;
35
+ demographics?: AtsDemographic[];
36
+ location?: AtsLocation;
37
+ };
38
+ export declare type AtsInfo = {
39
+ name: string;
40
+ metaData?: Record<string, unknown>;
41
+ };
42
+ export declare type AtsApplicationInfo = {
43
+ cohortInfo: AtsCohort;
44
+ candidateInfo: AtsCandidate;
45
+ predictorMasterId: string;
46
+ predictorVersion?: number;
47
+ externalApplicantId: string;
48
+ externalAssessmentId: string;
49
+ externalApplicationId: string;
50
+ atsInfo: AtsInfo;
51
+ };
52
+ export {};
@@ -0,0 +1,60 @@
1
+ import { ThemeElement } from "@/apis/types/branding";
2
+ export declare type PHChatbotErrorCallPayload = {
3
+ chatbotErrorType: PHChatBotErrorType;
4
+ params: unknown;
5
+ error: Error;
6
+ };
7
+ export declare type PHChatbotLogCallPayload = {
8
+ chatbotLogType: PHChatBotLogType;
9
+ params: unknown;
10
+ };
11
+ export declare enum PHChatBotLogType {
12
+ INVALID_REDIRECT_URL = "INVALID_REDIRECT_URL",
13
+ INVALID_PHONE_NUMBER = "INVALID_PHONE_NUMBER",
14
+ INVALID_PASTE_ANSWER_ACTION = "INVALID_PASTE_ANSWER_ACTION"
15
+ }
16
+ export declare enum PHChatBotErrorType {
17
+ FI_ORDER_ASSESSMENT_FAILED = "FI_ORDER_ASSESSMENT_FAILED",
18
+ FI_LOAD_NEXT_FAILED = "FI_LOAD_NEXT_FAILED",
19
+ FI_EDIT_ANSWER_FAILED = "FI_EDIT_ANSWER_FAILED",
20
+ SUBMIT_VIDEO_ANSWER_FAILED = "SUBMIT_VIDEO_ANSWER_FAILED",
21
+ GET_DISPLAY_VIDEO_URL_FAILED = "GET_DISPLAY_VIDEO_URL_FAILED",
22
+ FI_DETECT_AGC_FAILED = "FI_DETECT_AGC_FAILED",
23
+ FI_GET_ACCESS_MANAGEMENT_FAILED = "FI_GET_ACCESS_MANAGEMENT_FAILED",
24
+ FI_VERIFY_ACCESS_FAILED = "FI_VERIFY_ACCESS_FAILED",
25
+ FI_GET_JOB_REQUISITION = "FI_GET_JOB_REQUISITION",
26
+ FI_GET_APPLICATION_JOB_REQUISITION = "FI_GET_JOB_REQUISITION",
27
+ FI_EXTRACT_HUMAN_NAME_FAILED = "FI_EXTRACT_HUMAN_NAME_FAILED",
28
+ FI_GET_TRANSLATION_FAILED = "FI_GET_TRANSLATION_FAILED"
29
+ }
30
+ export declare enum PHChatBotCallbackFunction {
31
+ FI_ASSESSMENT_ANSWER_SAVED = "FI_ASSESSMENT_ANSWER_SAVED",
32
+ FI_ASSESSMENT_ANSWER_EDITED = "FI_ASSESSMENT_ANSWER_EDITED",
33
+ FI_ASSESSMENT_STARTED = "FI_ASSESSMENT_STARTED",
34
+ FI_ASSESSMENT_ENDED = "FI_ASSESSMENT_ENDED",
35
+ FI_ASSESSMENT_DUPLICATED = "FI_ASSESSMENT_DUPLICATED",
36
+ CHATBOT_ERROR = "CHATBOT_ERROR",
37
+ CHATBOT_LOG = "CHATBOT_LOG"
38
+ }
39
+ export declare type FIAssessmentDuplicatedCallbackPayload = {
40
+ duplicatedWithAssessmentLink: string;
41
+ };
42
+ export declare type PHChatBotCallback = {
43
+ [PHChatBotCallbackFunction.FI_ASSESSMENT_ANSWER_SAVED]?: (payload?: unknown) => void;
44
+ [PHChatBotCallbackFunction.FI_ASSESSMENT_ANSWER_EDITED]?: (payload?: unknown) => void;
45
+ [PHChatBotCallbackFunction.FI_ASSESSMENT_STARTED]?: (payload?: unknown) => void;
46
+ [PHChatBotCallbackFunction.FI_ASSESSMENT_ENDED]?: (payload?: unknown) => void;
47
+ [PHChatBotCallbackFunction.FI_ASSESSMENT_DUPLICATED]?: (payload?: FIAssessmentDuplicatedCallbackPayload) => void;
48
+ [PHChatBotCallbackFunction.CHATBOT_ERROR]?: (payload?: PHChatbotErrorCallPayload) => void;
49
+ [PHChatBotCallbackFunction.CHATBOT_LOG]?: (payload?: unknown) => void;
50
+ };
51
+ export declare type Theme = {
52
+ header?: ThemeElement;
53
+ hint?: ThemeElement;
54
+ question?: ThemeElement;
55
+ response?: ThemeElement;
56
+ selectedItem?: ThemeElement;
57
+ listItem?: ThemeElement;
58
+ button?: ThemeElement;
59
+ progressBar?: ThemeElement;
60
+ };
@@ -0,0 +1,278 @@
1
+ export declare enum RuleName {
2
+ MAX_TEXT_LENGTH = "maxTextLength",
3
+ MIN_TEXT_LENGTH = "minTextLength",
4
+ RECOMMENDED_TEXT_LENGTH = "recommendedTextLength",
5
+ MAX_VOICE_SECONDS = "maxVoiceSeconds",
6
+ MIN_VOICE_SECONDS = "minVoiceSeconds",
7
+ RECOMMENDED_VOICE_SECONDS = "recommendedVoiceSeconds"
8
+ }
9
+ export declare enum BubbleStatus {
10
+ ANSWERED = "ANSWERED",
11
+ ANSWERING = "ANSWERING",
12
+ EDITING = "EDITING",
13
+ PENDING = "PENDING",
14
+ FAILED = "FAILED"
15
+ }
16
+ export declare enum MessageSender {
17
+ AGENT = "AGENT",
18
+ CANDIDATE = "CANDIDATE"
19
+ }
20
+ export declare enum QuestionType {
21
+ HINT = "HINT",
22
+ FTQ = "FTQ",
23
+ MCQ = "MCQ",
24
+ VOICE = "VOICE",
25
+ VIDEO = "VIDEO",
26
+ SLIDER = "SLIDER",
27
+ DROPDOWN = "DROPDOWN",
28
+ BGQ = "BUTTON_GROUP_QUESTION"
29
+ }
30
+ export declare enum ContentType {
31
+ TEXT = "TEXT",
32
+ VOICE = "VOICE",
33
+ VIDEO = "VIDEO",
34
+ SLIDER = "SLIDER"
35
+ }
36
+ export declare enum PHService {
37
+ GENERAL_PY = "GENERAL_PY",
38
+ CUSTOMER_SATISFACTION = "CUSTOMER_SATISFACTION",
39
+ PII = "PII",
40
+ SENSITIVE = "SENSITIVE",
41
+ DISPLAY_IN_TI = "DISPLAY_IN_TI",
42
+ HEXACO_PERSONALITY_TEST = "HEXACO_PERSONALITY_TEST"
43
+ }
44
+ /**
45
+ * Enum contain all valid pii question type
46
+ * PII question type is specific type of PII question which is identify in tags
47
+ *
48
+ * Example: PII question
49
+ * ```js
50
+ * {
51
+ * // ....question fields
52
+ * tags: [
53
+ * {
54
+ * name: "PII_TYPE",
55
+ * value: "first_name" // value from piiQuestionTypeObj
56
+ * }
57
+ * ]
58
+ * }
59
+ * ```
60
+ */
61
+ export declare enum PiiQuestionType {
62
+ FULL_NAME = "fullName",
63
+ FIRST_NAME = "first_name",
64
+ LAST_NAME = "last_name",
65
+ EMAIL = "email",
66
+ PHONE_NUMBER = "phoneNumber",
67
+ LOCATION = "location"
68
+ }
69
+ export declare type PiiNameQuestionType = PiiQuestionType.FIRST_NAME | PiiQuestionType.LAST_NAME | PiiQuestionType.FULL_NAME;
70
+ export declare enum ButtonType {
71
+ PRIMARY = "PRIMARY",
72
+ SECONDARY = "SECONDARY",
73
+ DEFAULT = "DEFAULT"
74
+ }
75
+ export declare enum MessageIdentifier {
76
+ "FIRST_NAME_QUESTION_MESSAGE" = "FIRST_NAME_QUESTION_MESSAGE",
77
+ "LAST_NAME_QUESTION_MESSAGE" = "LAST_NAME_QUESTION_MESSAGE",
78
+ "FULL_NAME_QUESTION_MESSAGE" = "FULL_NAME_QUESTION_MESSAGE",
79
+ "EMAIL_QUESTION_MESSAGE" = "EMAIL_QUESTION_MESSAGE",
80
+ "SMS_CONSENT_QUESTION_MESSAGE" = "SMS_CONSENT_QUESTION_MESSAGE",
81
+ "PHONE_QUESTION_MESSAGE" = "PHONE_QUESTION_MESSAGE",
82
+ "TERMS_AND_CONDITIONS_CONSENT_QUESTION_MESSAGE" = "TERMS_AND_CONDITIONS_CONSENT_QUESTION_MESSAGE",
83
+ "HINT_QUESTION_MESSAGE" = "HINT_QUESTION_MESSAGE",
84
+ "FTQ_QUESTION_MESSAGE" = "FTQ_QUESTION_MESSAGE",
85
+ "MCQ_QUESTION_MESSAGE" = "MCQ_QUESTION_MESSAGE",
86
+ "VIDEO_QUESTION_MESSAGE" = "VIDEO_QUESTION_MESSAGE",
87
+ "SUBMIT_QUESTION_MESSAGE" = "SUBMIT_QUESTION_MESSAGE",
88
+ "FEEDBACK_CUSTOMER_SATISFACTION_QUESTION_MESSAGE" = "FEEDBACK_CUSTOMER_SATISFACTION_QUESTION_MESSAGE",
89
+ "RATING_CUSTOMER_SATISFACTION_QUESTION_MESSAGE" = "RATING_CUSTOMER_SATISFACTION_QUESTION_MESSAGE",
90
+ "HEXACO_QUESTION_MESSAGE" = "HEXACO_QUESTION_MESSAGE",
91
+ "FIRST_NAME_ANSWER_MESSAGE" = "FIRST_NAME_ANSWER_MESSAGE",
92
+ "LAST_NAME_ANSWER_MESSAGE" = "LAST_NAME_ANSWER_MESSAGE",
93
+ "FULL_NAME_ANSWER_MESSAGE" = "FULL_NAME_ANSWER_MESSAGE",
94
+ "EMAIL_ANSWER_MESSAGE" = "EMAIL_ANSWER_MESSAGE",
95
+ "SMS_CONSENT_ANSWER_MESSAGE" = "SMS_CONSENT_ANSWER_MESSAGE",
96
+ "PHONE_ANSWER_MESSAGE" = "PHONE_ANSWER_MESSAGE",
97
+ "TERMS_AND_CONDITIONS_CONSENT_ANSWER_MESSAGE" = "TERMS_AND_CONDITIONS_CONSENT_ANSWER_MESSAGE",
98
+ "HINT_ANSWER_MESSAGE" = "HINT_ANSWER_MESSAGE",
99
+ "FTQ_ANSWER_MESSAGE" = "FTQ_ANSWER_MESSAGE",
100
+ "MCQ_ANSWER_MESSAGE" = "MCQ_ANSWER_MESSAGE",
101
+ "VIDEO_ANSWER_MESSAGE" = "VIDEO_ANSWER_MESSAGE",
102
+ "SUBMIT_ANSWER_MESSAGE" = "SUBMIT_ANSWER_MESSAGE",
103
+ "FEEDBACK_CUSTOMER_SATISFACTION_ANSWER_MESSAGE" = "FEEDBACK_CUSTOMER_SATISFACTION_ANSWER_MESSAGE",
104
+ "RATING_CUSTOMER_SATISFACTION_ANSWER_MESSAGE" = "RATING_CUSTOMER_SATISFACTION_ANSWER_MESSAGE",
105
+ "HEXACO_ANSWER_MESSAGE" = "HEXACO_ANSWER_MESSAGE"
106
+ }
107
+ export declare type Trigger = {
108
+ action: string;
109
+ };
110
+ export declare type Style = {
111
+ buttonType: ButtonType;
112
+ };
113
+ export declare type Content = {
114
+ value: string;
115
+ text: string;
116
+ id: string;
117
+ };
118
+ export declare type ButtonGroupContent = Content & {
119
+ triggers: Trigger[];
120
+ style: Style;
121
+ };
122
+ export declare type AnswerContent = {
123
+ text: string;
124
+ value: string;
125
+ triggers?: Trigger[];
126
+ style?: Style;
127
+ };
128
+ export declare type MessageItem = {
129
+ id: string;
130
+ types: ContentType[];
131
+ contents: Content[] | ButtonGroupContent[];
132
+ };
133
+ /**
134
+ * for candidate mcq bubble:
135
+ * {
136
+ * messageItems: [{
137
+ * id: "messageItemId",
138
+ * types: [ContentType.TEXT],
139
+ * contents: [{
140
+ * value: "1",
141
+ * text: "Yes",
142
+ * id: "A"
143
+ * },{
144
+ * value: "2",
145
+ * text: "No",
146
+ * id: "B"
147
+ * }]
148
+ * }],
149
+ * answer: {
150
+ * value: "1",
151
+ * text: "Yes"
152
+ * }
153
+ * }
154
+ * ----------------------------------------
155
+ * for candidate text bubble:
156
+ * {
157
+ * messageItems: [{
158
+ * types: [ContentType.TEXT],
159
+ * contents: [{
160
+ * value: "FTQ answer",
161
+ * text: "FTQ answer",
162
+ * id: "answer1"
163
+ * }]
164
+ * }]
165
+ * }
166
+ * =============================================
167
+ * for agent bubble:
168
+ * {
169
+ * messageItems: [{
170
+ * id: "messageItemId",
171
+ * types: [ContentType.TEXT],
172
+ * contents: [{
173
+ * value: "Hello xxx",
174
+ * text: "Hello xxx",
175
+ * id: "content1"
176
+ * }]
177
+ * }, {
178
+ * id: "messageItemId",
179
+ * types: [ContentType.TEXT],
180
+ * contents: [{
181
+ * value: "Let's go",
182
+ * text: "Let's go",
183
+ * id: "content2"
184
+ * }]
185
+ * }]
186
+ * }
187
+ */
188
+ export declare type MessageBubbleData = {
189
+ messageItems: MessageItem[];
190
+ answer?: AnswerContent;
191
+ rules?: QuestionRule[];
192
+ tags?: Tag[];
193
+ };
194
+ export declare type MessageBubble = {
195
+ status: BubbleStatus;
196
+ sender: MessageSender;
197
+ messageIdentifier?: MessageIdentifier;
198
+ id: string;
199
+ types: QuestionType[];
200
+ usageWhitelist: PHService[];
201
+ questionId: string;
202
+ data: MessageBubbleData;
203
+ masterId?: string;
204
+ piiQuestionType?: PiiQuestionType;
205
+ videoQuestionType?: VideoQuestionType;
206
+ };
207
+ export declare enum VideoQuestionType {
208
+ TEST_CAMERA = "test_camera"
209
+ }
210
+ export declare type MCQQuestionOption = {
211
+ id: string;
212
+ text: string;
213
+ value: string;
214
+ };
215
+ export declare type Tag = {
216
+ name: string;
217
+ value: string;
218
+ };
219
+ export declare type DropdownOption = MCQQuestionOption;
220
+ export declare type BGQButton = MCQQuestionOption & {
221
+ triggers: Trigger[];
222
+ style: Style;
223
+ };
224
+ export declare type BubbleContent = {
225
+ value: string;
226
+ types: ContentType[];
227
+ };
228
+ export declare type QuestionRule = {
229
+ name: RuleName;
230
+ type: string;
231
+ value: number | string;
232
+ };
233
+ export declare type Question = {
234
+ masterId?: string;
235
+ /**
236
+ * type can be string "HINT", or array of string ["HINT", "FTQ"]
237
+ */
238
+ types: QuestionType[];
239
+ rules?: QuestionRule[];
240
+ contents: BubbleContent[];
241
+ options?: MCQQuestionOption[] | BGQButton[];
242
+ usageWhitelist?: PHService[];
243
+ _id: string;
244
+ tags?: Tag[];
245
+ };
246
+ export declare type Answer = {
247
+ _id: string;
248
+ question: Question;
249
+ text: string;
250
+ value: string;
251
+ };
252
+ export interface Message<T> {
253
+ id: string;
254
+ sender: MessageSender;
255
+ messageIdentifier?: MessageIdentifier;
256
+ data: T;
257
+ }
258
+ export declare type CandidateResponse = Message<Answer>;
259
+ export declare type AgentResponse = Message<Question>;
260
+ export declare type CandidateResponseInput = {
261
+ userAgent: string;
262
+ questionId: string;
263
+ answer?: AnswerContent;
264
+ };
265
+ export declare type EditCandidateResponseInput = Required<Omit<CandidateResponseInput, "userAgent">>;
266
+ export declare enum AssessmentStatus {
267
+ FI_ATS_ASSESSMENT_ORDER_COMPLETED = "FI_ATS_ASSESSMENT_ORDER_COMPLETED",
268
+ FI_ASSESSMENT_STARTED = "FI_ASSESSMENT_STARTED",
269
+ FI_ASSESSMENT_PII_SAVED = "FI_ASSESSMENT_PII_SAVED",
270
+ FI_ASSESSMENT_PII_COMPLETED = "FI_ASSESSMENT_PII_COMPLETED",
271
+ FI_ASSESSMENT_INPROGRESS = "FI_ASSESSMENT_INPROGRESS",
272
+ FI_ASSESSMENT_COMPLETED = "FI_ASSESSMENT_COMPLETED",
273
+ FI_ASSESSMENT_ENDED = "FI_ASSESSMENT_ENDED",
274
+ FI_ASSESSMENT_DROPPED_OUT = "FI_ASSESSMENT_DROPPED_OUT",
275
+ FI_PREDICTION_STARTED = "FI_PREDICTION_STARTED",
276
+ FI_PREDICTION_COMPLETED = "FI_PREDICTION_COMPLETED",
277
+ FI_ASSESSMENT_DUPLICATED = "FI_ASSESSMENT_DUPLICATED"
278
+ }
@@ -0,0 +1,6 @@
1
+ export declare enum UrlParamKey {
2
+ REDIRECT = "redirect",
3
+ INTERNAL_USER = "internalUser",
4
+ TRACK_CODE = "t",
5
+ ACCESS_TYPE = "o"
6
+ }
@@ -0,0 +1,32 @@
1
+ import { RenderOptions } from "@testing-library/react";
2
+ import * as React from "react";
3
+ import { AssessmentStatus, ContentType, MessageSender, QuestionType } from "@/types/Next";
4
+ declare type ContextParams = Record<string, unknown>;
5
+ export declare const assessmentId = "6000f17bcc18f80041c18251";
6
+ export declare const cohortId = "6110abad489dce0011982aea";
7
+ export declare const mockStartAssessmentResponse: {
8
+ assessmentId: string;
9
+ assessmentStatus: AssessmentStatus;
10
+ chatLogs: {
11
+ id: string;
12
+ sender: MessageSender;
13
+ data: {
14
+ _id: string;
15
+ types: QuestionType[];
16
+ contents: {
17
+ value: string;
18
+ types: ContentType[];
19
+ }[];
20
+ };
21
+ }[];
22
+ numOfNormalQuestion: number;
23
+ numOfNormalAnswer: number;
24
+ fiToken: {
25
+ name: string;
26
+ value: string;
27
+ };
28
+ language: string;
29
+ };
30
+ declare const customRender: (ui: React.ReactElement, _contextParams?: ContextParams, options?: RenderOptions) => any;
31
+ export * from "@testing-library/react";
32
+ export { customRender as render };
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,117 @@
1
+ export declare const mockTranslationSource: {
2
+ fi_label_typing: string;
3
+ fi_label_enterResponse: string;
4
+ fi_error_notEnoughWords: string;
5
+ fi_error_notEnoughtWordsMin: string;
6
+ fi_error_notEnoughWordsEdit: string;
7
+ fi_error_notEnoughWordsEditNow: string;
8
+ fi_button_edit: string;
9
+ fi_button_continue: string;
10
+ fi_check_dontShow: string;
11
+ fi_alt_shortResponse: string;
12
+ fi_alt_goodResponse: string;
13
+ fi_alt_maxWords: string;
14
+ fi_button_recordVideo: string;
15
+ fi_button_record: string;
16
+ fi_button_play: string;
17
+ fi_button_retry: string;
18
+ fi_button_save: string;
19
+ fi_button_pause: string;
20
+ fi_button_help: string;
21
+ fi_button_stop: string;
22
+ fi_error_unsuccessfulRecord: string;
23
+ fi_button_ok: string;
24
+ fi_label_uploading: string;
25
+ fi_label_dontClose: string;
26
+ fi_toolTip_retry: string;
27
+ fi_error_finalRetry: string;
28
+ fi_error_noChances: string;
29
+ fi_button_cancel: string;
30
+ fi_toolTip_noRetry: string;
31
+ fi_label_editing: string;
32
+ fi_label_errorTitle: string;
33
+ fi_label_errorMessageInstruction: string;
34
+ fi_label_errorMessageUnsupportedBrowser: string;
35
+ fi_placeholder_demoNameInput: string;
36
+ fi_placeholder_demoEmailInput: string;
37
+ fi_label_demoWelcome: string;
38
+ fi_label_demoSapiaDescription: string;
39
+ fi_label_demoTestDescription: string;
40
+ fi_button_demoCI: string;
41
+ fi_button_demoCoachingInsights: string;
42
+ fi_button_demoVi: string;
43
+ fi_placeholder_dropdown: string;
44
+ fi_error_piiEmail: string;
45
+ fi_error_piiFullName: string;
46
+ fi_error_piiFirstName: string;
47
+ fi_error_piiLastName: string;
48
+ fi_error_piiPhoneNumber: string;
49
+ fi_label_cancelEditMobile: string;
50
+ fi_label_cancelEditDesktop: string;
51
+ fi_error_iosChromeNotSupport: string;
52
+ fi_error_iosChromeCopyLink: string;
53
+ fi_error_iosChromeOpenEmail: string;
54
+ fi_error_thankCustomer: string;
55
+ fi_tooltip_copiedUrl: string;
56
+ fi_button_copyUrl: string;
57
+ fi_error_mulTabsWarning: string;
58
+ fi_label_refreshBrowser: string;
59
+ fi_label_contactSupport: string;
60
+ fi_label_noRetry: string;
61
+ fi_label_webcamNotReady: string;
62
+ fi_label_recordRetryInstruction: string;
63
+ fi_label_stopRecordBeforePlay: string;
64
+ fi_error_playVideo: string;
65
+ fi_label_stopRecordBeforeSubmit: string;
66
+ fi_error_submitVideo: string;
67
+ fi_label_stopRecordBeforeRetry: string;
68
+ fi_label_warningCloseRecordModalTitle: string;
69
+ fi_label_warningCloseRecordModalMessage: string;
70
+ fi_button_confirmCloseRecord: string;
71
+ fi_button_cancelCloseRecord: string;
72
+ fi_label_uploadFailed: string;
73
+ fi_label_checkInternetCon: string;
74
+ fi_button_tryAgain: string;
75
+ fi_label_noRecordRemaining: string;
76
+ fi_label_completedAssessment: string;
77
+ fi_label_saveRecordMessage: string;
78
+ fi_error_editAnswerFailed: string;
79
+ fi_error_sendAnswerFailed: string;
80
+ fi_label_ratingMessage: string;
81
+ fi_button_submitRating: string;
82
+ fi_label_warningModalTitle: string;
83
+ fi_button_close: string;
84
+ fi_label_multiTabsWarning: string;
85
+ fi_error_startedAssessment: string;
86
+ fi_error_roleClosed: string;
87
+ fi_error_reuseComplete: string;
88
+ fi_label_unsupportedBrowserTitle: string;
89
+ fi_error_cohortClosedTitle: string;
90
+ fi_error_cohortClosedMessage: string;
91
+ fi_error_videoPlayback: string;
92
+ fi_label_tabClose: string;
93
+ fi_error_notEnoughWordsMin: string;
94
+ fi_error_notEnoughWordsAim: string;
95
+ fi_label_words_one: string;
96
+ fi_label_words_other: string;
97
+ fi_label_missingCohortId: string;
98
+ fi_error_agcTitle: string;
99
+ fi_error_agcFirstMessage: string;
100
+ fi_error_agcSecondMessage: string;
101
+ fi_error_generalErrorTitle: string;
102
+ fi_label_enterOrPasteResponse: string;
103
+ fi_label_welcomeBack: string;
104
+ fi_label_modalDescription: string;
105
+ fi_input_email: string;
106
+ fi_button_confirm: string;
107
+ fi_error_emailDoesNotMatch: string;
108
+ fi_label_languageSelectionWarning: string;
109
+ fi_placeholder_selectLanguage: string;
110
+ fi_label_languageSelectionWelcome: string;
111
+ fi_button_startMyInterview: string;
112
+ fi_alt_fullName: string;
113
+ fi_button_ignore: string;
114
+ fi_button_correct: string;
115
+ fi_alt_firstName: string;
116
+ fi_alt_lastName: string;
117
+ };
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,39 @@
1
+ import { ThemeProperty } from "@/apis/types/branding";
2
+ import { Theme } from "@/types/ChatBot";
3
+ /**
4
+ * Convert raw theme array which response from api to theme object which can be easily used in application
5
+ * @param rawTheme
6
+ * @example
7
+ * [
8
+ * {
9
+ * "name": "header",
10
+ * "type": "object",
11
+ * "value": {
12
+ * "backgroundColor": "#ffffff",
13
+ * "fontColor": "#00404A"
14
+ * }
15
+ * },
16
+ * {
17
+ * "name": "progressBar",
18
+ * "type": "object",
19
+ * "value": {
20
+ * "backgroundColor": "#029977",
21
+ * "fontColor": "#fecb00"
22
+ * }
23
+ * }
24
+ * ]
25
+ *
26
+ * @returns Theme Object
27
+ * @example
28
+ * {
29
+ * header: {
30
+ * "backgroundColor": "#ffffff",
31
+ * "fontColor": "#00404A"
32
+ * },
33
+ * progressBar: {
34
+ * "backgroundColor": "#029977",
35
+ * "fontColor": "#fecb00"
36
+ * }
37
+ * }
38
+ */
39
+ export declare const convertRawBrandingTheme: (rawTheme: ThemeProperty[]) => Theme;
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Get the default language
3
+ */
4
+ export declare const getDefaultLanguage: () => string;
5
+ export declare const getBrowserLanguage: () => string;
6
+ export declare const checkIfBrowserLanguageIsSupported: () => boolean;