@magmamath/students-features 0.10.0 → 0.11.0-rc.10
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.
- package/dist/commonjs/features/celebrations/helpers.js +4 -1
- package/dist/commonjs/features/celebrations/helpers.js.map +1 -1
- package/dist/commonjs/features/chatbot/TTS_HIGHLIGHTING.md +120 -0
- package/dist/commonjs/features/chatbot/components/Chat/Chat.js +229 -45
- package/dist/commonjs/features/chatbot/components/Chat/Chat.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/Chat/CloseButton.js +39 -0
- package/dist/commonjs/features/chatbot/components/Chat/CloseButton.js.map +1 -0
- package/dist/commonjs/features/chatbot/components/Chat/GradientFade.js +44 -0
- package/dist/commonjs/features/chatbot/components/Chat/GradientFade.js.map +1 -0
- package/dist/commonjs/features/chatbot/components/ChatControls/ChatControls.js +46 -54
- package/dist/commonjs/features/chatbot/components/ChatControls/ChatControls.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatInput/ChatInput.js +1 -1
- package/dist/commonjs/features/chatbot/components/ChatInput/ChatInput.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatInput/FreeText/ChatTextInput.js +2 -2
- package/dist/commonjs/features/chatbot/components/ChatInput/FreeText/ChatTextInput.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatInput/FreeText/SendMessageButton.js +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/AnimatedMessage.js +41 -0
- package/dist/commonjs/features/chatbot/components/ChatMessage/AnimatedMessage.js.map +1 -0
- package/dist/commonjs/features/chatbot/components/ChatMessage/ChatMessage.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageContent.js +16 -4
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageContent.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageLoader.js +14 -34
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageLoader.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.js +20 -15
- package/dist/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/SentMessage.js +1 -1
- package/dist/commonjs/features/chatbot/components/Chatbot.js +30 -7
- package/dist/commonjs/features/chatbot/components/Chatbot.js.map +1 -1
- package/dist/commonjs/features/chatbot/constants.js +2 -1
- package/dist/commonjs/features/chatbot/constants.js.map +1 -1
- package/dist/commonjs/features/chatbot/helpers/ttsHighlight.js +29 -0
- package/dist/commonjs/features/chatbot/helpers/ttsHighlight.js.map +1 -0
- package/dist/commonjs/features/chatbot/helpers.js +19 -2
- package/dist/commonjs/features/chatbot/helpers.js.map +1 -1
- package/dist/commonjs/features/chatbot/index.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatBotModel.js +65 -17
- package/dist/commonjs/features/chatbot/model/ChatBotModel.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatBotThreadManager.js +2 -2
- package/dist/commonjs/features/chatbot/model/ChatBotThreadManager.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatBoxTextManager.js +2 -1
- package/dist/commonjs/features/chatbot/model/ChatBoxTextManager.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatTTSHighlightModel.js +56 -0
- package/dist/commonjs/features/chatbot/model/ChatTTSHighlightModel.js.map +1 -0
- package/dist/commonjs/features/chatbot/model/ChatTTSModel.js +154 -0
- package/dist/commonjs/features/chatbot/model/ChatTTSModel.js.map +1 -0
- package/dist/commonjs/features/chatbot/model/ChatbotApi.js +1 -1
- package/dist/commonjs/features/chatbot/model/ChatbotApi.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatbotTranslation.js +1 -1
- package/dist/commonjs/features/chatbot/model/ChatbotTranslation.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatsCacheModel.js +9 -0
- package/dist/commonjs/features/chatbot/model/ChatsCacheModel.js.map +1 -1
- package/dist/commonjs/features/chatbot/types/model.types.js.map +1 -1
- package/dist/commonjs/features/chatbot/types/t2s.types.js.map +1 -1
- package/dist/commonjs/features/feedback/model/model.js.map +1 -1
- package/dist/commonjs/features/feedback/model/sockets.js +8 -5
- package/dist/commonjs/features/feedback/model/sockets.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/AlgebraLayout/AlgebraLayout.js +2 -2
- package/dist/commonjs/features/keyboard/components/AlgebraLayout/AlgebraLayout.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/BasicLayout/BasicLayout.js +2 -2
- package/dist/commonjs/features/keyboard/components/BasicLayout/BasicLayout.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/BasicPlusLayout/keyboardGroups.js +4 -4
- package/dist/commonjs/features/keyboard/components/BasicPlusLayout/keyboardGroups.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/BasicPlusPlusLayout/BasicPlusPlusLayout.js +2 -2
- package/dist/commonjs/features/keyboard/components/BasicPlusPlusLayout/BasicPlusPlusLayout.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/BasicPlusPlusLayout/keyboardGroups.js +4 -4
- package/dist/commonjs/features/keyboard/components/BasicPlusPlusLayout/keyboardGroups.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/Keyboard.js +4 -2
- package/dist/commonjs/features/keyboard/components/Keyboard.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/MainLayout/MainLayout.js +1 -6
- package/dist/commonjs/features/keyboard/components/MainLayout/MainLayout.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/UnitsLayout/UnitTabs.js +1 -1
- package/dist/commonjs/features/keyboard/components/UnitsLayout/helpers.js +3 -1
- package/dist/commonjs/features/keyboard/components/UnitsLayout/helpers.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/UnitsLayout/hooks/useUnitTabs.js +27 -6
- package/dist/commonjs/features/keyboard/components/UnitsLayout/hooks/useUnitTabs.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/UnitsLayout/keyboardGroups.js +9 -1
- package/dist/commonjs/features/keyboard/components/UnitsLayout/keyboardGroups.js.map +1 -1
- package/dist/commonjs/features/keyboard/components/UnitsLayout/types.js +1 -0
- package/dist/commonjs/features/keyboard/components/UnitsLayout/types.js.map +1 -1
- package/dist/commonjs/features/keyboard/constants/constants.js +1 -1
- package/dist/commonjs/features/keyboard/constants/keyboardGroupsByLocale.js +2 -1
- package/dist/commonjs/features/keyboard/constants/keyboardGroupsByLocale.js.map +1 -1
- package/dist/commonjs/features/keyboard/constants/keyboardLayouts.js +20 -4
- package/dist/commonjs/features/keyboard/constants/keyboardLayouts.js.map +1 -1
- package/dist/commonjs/features/keyboard/helpers.js +7 -0
- package/dist/commonjs/features/keyboard/helpers.js.map +1 -1
- package/dist/commonjs/features/keyboard/types/MathKeysGroups/basicOperators.js +20 -3
- package/dist/commonjs/features/keyboard/types/MathKeysGroups/basicOperators.js.map +1 -1
- package/dist/commonjs/features/keyboard/types/MathKeysGroups/units.js +6 -3
- package/dist/commonjs/features/keyboard/types/MathKeysGroups/units.js.map +1 -1
- package/dist/commonjs/features/openEnded/components/OpenEndedAttemptsLimit.js +34 -0
- package/dist/commonjs/features/openEnded/components/OpenEndedAttemptsLimit.js.map +1 -0
- package/dist/commonjs/features/openEnded/components/OpenEndedScoreLabel.js +77 -0
- package/dist/commonjs/features/openEnded/components/OpenEndedScoreLabel.js.map +1 -0
- package/dist/commonjs/features/openEnded/index.js +48 -0
- package/dist/commonjs/features/openEnded/index.js.map +1 -0
- package/dist/commonjs/features/openEnded/oe.helpers.js +26 -0
- package/dist/commonjs/features/openEnded/oe.helpers.js.map +1 -0
- package/dist/commonjs/features/openEnded/oe.types.js +14 -0
- package/dist/commonjs/features/openEnded/oe.types.js.map +1 -0
- package/dist/commonjs/index.js +13 -1
- package/dist/commonjs/index.js.map +1 -1
- package/dist/commonjs/lib/components/ConditionalWrapper.js +23 -0
- package/dist/commonjs/lib/components/ConditionalWrapper.js.map +1 -0
- package/dist/commonjs/shared/common.constants.js +9 -0
- package/dist/commonjs/shared/common.constants.js.map +1 -0
- package/dist/commonjs/shared/icons/TimeIcon.js +37 -0
- package/dist/commonjs/shared/icons/TimeIcon.js.map +1 -0
- package/dist/commonjs/shared/icons/keyboard/CDotIcon/CDotIcon.js +4 -4
- package/dist/commonjs/shared/icons/keyboard/CDotIcon/CDotIcon.js.map +1 -1
- package/dist/commonjs/shared/icons/keyboard/RoundBracketLeftIcon/RoundBracketLeftIcon.js +32 -0
- package/dist/commonjs/shared/icons/keyboard/RoundBracketLeftIcon/RoundBracketLeftIcon.js.map +1 -0
- package/dist/commonjs/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.js +32 -0
- package/dist/commonjs/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.js.map +1 -0
- package/dist/commonjs/shared/translation/localization/ca.json +4 -2
- package/dist/commonjs/shared/translation/localization/de.json +4 -2
- package/dist/commonjs/shared/translation/localization/en.json +4 -2
- package/dist/commonjs/shared/translation/localization/gb.json +4 -2
- package/dist/commonjs/shared/translation/localization/sct.json +4 -2
- package/dist/commonjs/shared/translation/localization/sw.json +4 -2
- package/dist/commonjs/types/common.types.js +4 -0
- package/dist/module/features/celebrations/helpers.js +4 -1
- package/dist/module/features/celebrations/helpers.js.map +1 -1
- package/dist/module/features/chatbot/TTS_HIGHLIGHTING.md +120 -0
- package/dist/module/features/chatbot/components/Chat/Chat.js +231 -47
- package/dist/module/features/chatbot/components/Chat/Chat.js.map +1 -1
- package/dist/module/features/chatbot/components/Chat/CloseButton.js +33 -0
- package/dist/module/features/chatbot/components/Chat/CloseButton.js.map +1 -0
- package/dist/module/features/chatbot/components/Chat/GradientFade.js +39 -0
- package/dist/module/features/chatbot/components/Chat/GradientFade.js.map +1 -0
- package/dist/module/features/chatbot/components/ChatControls/ChatControls.js +46 -55
- package/dist/module/features/chatbot/components/ChatControls/ChatControls.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatInput/ChatInput.js +1 -1
- package/dist/module/features/chatbot/components/ChatInput/ChatInput.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatInput/FreeText/ChatTextInput.js +2 -2
- package/dist/module/features/chatbot/components/ChatInput/FreeText/ChatTextInput.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatInput/FreeText/SendMessageButton.js +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/AnimatedMessage.js +34 -0
- package/dist/module/features/chatbot/components/ChatMessage/AnimatedMessage.js.map +1 -0
- package/dist/module/features/chatbot/components/ChatMessage/ChatMessage.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/MessageContent.js +16 -4
- package/dist/module/features/chatbot/components/ChatMessage/MessageContent.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/MessageLoader.js +17 -36
- package/dist/module/features/chatbot/components/ChatMessage/MessageLoader.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/ReceivedMessage.js +19 -14
- package/dist/module/features/chatbot/components/ChatMessage/ReceivedMessage.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/SentMessage.js +1 -1
- package/dist/module/features/chatbot/components/Chatbot.js +28 -6
- package/dist/module/features/chatbot/components/Chatbot.js.map +1 -1
- package/dist/module/features/chatbot/constants.js +1 -0
- package/dist/module/features/chatbot/constants.js.map +1 -1
- package/dist/module/features/chatbot/helpers/ttsHighlight.js +23 -0
- package/dist/module/features/chatbot/helpers/ttsHighlight.js.map +1 -0
- package/dist/module/features/chatbot/helpers.js +19 -2
- package/dist/module/features/chatbot/helpers.js.map +1 -1
- package/dist/module/features/chatbot/index.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatBotModel.js +65 -17
- package/dist/module/features/chatbot/model/ChatBotModel.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatBotThreadManager.js +2 -2
- package/dist/module/features/chatbot/model/ChatBotThreadManager.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatBoxTextManager.js +2 -1
- package/dist/module/features/chatbot/model/ChatBoxTextManager.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatTTSHighlightModel.js +52 -0
- package/dist/module/features/chatbot/model/ChatTTSHighlightModel.js.map +1 -0
- package/dist/module/features/chatbot/model/ChatTTSModel.js +149 -0
- package/dist/module/features/chatbot/model/ChatTTSModel.js.map +1 -0
- package/dist/module/features/chatbot/model/ChatbotApi.js +1 -1
- package/dist/module/features/chatbot/model/ChatbotApi.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatbotTranslation.js +1 -1
- package/dist/module/features/chatbot/model/ChatbotTranslation.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatsCacheModel.js +9 -0
- package/dist/module/features/chatbot/model/ChatsCacheModel.js.map +1 -1
- package/dist/module/features/chatbot/types/model.types.js.map +1 -1
- package/dist/module/features/chatbot/types/t2s.types.js.map +1 -1
- package/dist/module/features/feedback/model/model.js.map +1 -1
- package/dist/module/features/feedback/model/sockets.js +8 -5
- package/dist/module/features/feedback/model/sockets.js.map +1 -1
- package/dist/module/features/keyboard/components/AlgebraLayout/AlgebraLayout.js +3 -3
- package/dist/module/features/keyboard/components/AlgebraLayout/AlgebraLayout.js.map +1 -1
- package/dist/module/features/keyboard/components/BasicLayout/BasicLayout.js +2 -2
- package/dist/module/features/keyboard/components/BasicLayout/BasicLayout.js.map +1 -1
- package/dist/module/features/keyboard/components/BasicPlusLayout/keyboardGroups.js +4 -4
- package/dist/module/features/keyboard/components/BasicPlusLayout/keyboardGroups.js.map +1 -1
- package/dist/module/features/keyboard/components/BasicPlusPlusLayout/BasicPlusPlusLayout.js +2 -2
- package/dist/module/features/keyboard/components/BasicPlusPlusLayout/BasicPlusPlusLayout.js.map +1 -1
- package/dist/module/features/keyboard/components/BasicPlusPlusLayout/keyboardGroups.js +4 -4
- package/dist/module/features/keyboard/components/BasicPlusPlusLayout/keyboardGroups.js.map +1 -1
- package/dist/module/features/keyboard/components/Keyboard.js +4 -2
- package/dist/module/features/keyboard/components/Keyboard.js.map +1 -1
- package/dist/module/features/keyboard/components/KeysList/KeysList.js.map +1 -1
- package/dist/module/features/keyboard/components/MainLayout/MainLayout.js +2 -7
- package/dist/module/features/keyboard/components/MainLayout/MainLayout.js.map +1 -1
- package/dist/module/features/keyboard/components/UnitsLayout/UnitTabs.js +1 -1
- package/dist/module/features/keyboard/components/UnitsLayout/helpers.js +2 -1
- package/dist/module/features/keyboard/components/UnitsLayout/helpers.js.map +1 -1
- package/dist/module/features/keyboard/components/UnitsLayout/hooks/useUnitTabs.js +27 -6
- package/dist/module/features/keyboard/components/UnitsLayout/hooks/useUnitTabs.js.map +1 -1
- package/dist/module/features/keyboard/components/UnitsLayout/keyboardGroups.js +9 -1
- package/dist/module/features/keyboard/components/UnitsLayout/keyboardGroups.js.map +1 -1
- package/dist/module/features/keyboard/components/UnitsLayout/types.js +1 -0
- package/dist/module/features/keyboard/components/UnitsLayout/types.js.map +1 -1
- package/dist/module/features/keyboard/constants/constants.js +1 -1
- package/dist/module/features/keyboard/constants/keyboardGroupsByLocale.js +3 -2
- package/dist/module/features/keyboard/constants/keyboardGroupsByLocale.js.map +1 -1
- package/dist/module/features/keyboard/constants/keyboardLayouts.js +19 -4
- package/dist/module/features/keyboard/constants/keyboardLayouts.js.map +1 -1
- package/dist/module/features/keyboard/helpers.js +5 -0
- package/dist/module/features/keyboard/helpers.js.map +1 -1
- package/dist/module/features/keyboard/types/MathKeysGroups/basicOperators.js +20 -3
- package/dist/module/features/keyboard/types/MathKeysGroups/basicOperators.js.map +1 -1
- package/dist/module/features/keyboard/types/MathKeysGroups/units.js +6 -3
- package/dist/module/features/keyboard/types/MathKeysGroups/units.js.map +1 -1
- package/dist/module/features/openEnded/components/OpenEndedAttemptsLimit.js +28 -0
- package/dist/module/features/openEnded/components/OpenEndedAttemptsLimit.js.map +1 -0
- package/dist/module/features/openEnded/components/OpenEndedScoreLabel.js +71 -0
- package/dist/module/features/openEnded/components/OpenEndedScoreLabel.js.map +1 -0
- package/dist/module/features/openEnded/index.js +7 -0
- package/dist/module/features/openEnded/index.js.map +1 -0
- package/dist/module/features/openEnded/oe.helpers.js +21 -0
- package/dist/module/features/openEnded/oe.helpers.js.map +1 -0
- package/dist/module/features/openEnded/oe.types.js +10 -0
- package/dist/module/features/openEnded/oe.types.js.map +1 -0
- package/dist/module/index.js +1 -0
- package/dist/module/index.js.map +1 -1
- package/dist/module/lib/components/ConditionalWrapper.js +17 -0
- package/dist/module/lib/components/ConditionalWrapper.js.map +1 -0
- package/dist/module/shared/common.constants.js +5 -0
- package/dist/module/shared/common.constants.js.map +1 -0
- package/dist/module/shared/icons/TimeIcon.js +29 -0
- package/dist/module/shared/icons/TimeIcon.js.map +1 -0
- package/dist/module/shared/icons/keyboard/CDotIcon/CDotIcon.js +4 -4
- package/dist/module/shared/icons/keyboard/CDotIcon/CDotIcon.js.map +1 -1
- package/dist/module/shared/icons/keyboard/RoundBracketLeftIcon/RoundBracketLeftIcon.js +24 -0
- package/dist/module/shared/icons/keyboard/RoundBracketLeftIcon/RoundBracketLeftIcon.js.map +1 -0
- package/dist/module/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.js +24 -0
- package/dist/module/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.js.map +1 -0
- package/dist/module/shared/translation/localization/ca.json +4 -2
- package/dist/module/shared/translation/localization/de.json +4 -2
- package/dist/module/shared/translation/localization/en.json +4 -2
- package/dist/module/shared/translation/localization/gb.json +4 -2
- package/dist/module/shared/translation/localization/sct.json +4 -2
- package/dist/module/shared/translation/localization/sw.json +4 -2
- package/dist/module/types/common.types.js +2 -0
- package/dist/typescript/commonjs/features/celebrations/helpers.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/Chat/Chat.d.ts +7 -2
- package/dist/typescript/commonjs/features/chatbot/components/Chat/Chat.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/Chat/CloseButton.d.ts +7 -0
- package/dist/typescript/commonjs/features/chatbot/components/Chat/CloseButton.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/chatbot/components/Chat/GradientFade.d.ts +10 -0
- package/dist/typescript/commonjs/features/chatbot/components/Chat/GradientFade.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/chatbot/components/ChatControls/ChatControls.d.ts +3 -2
- package/dist/typescript/commonjs/features/chatbot/components/ChatControls/ChatControls.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatInput/ChatInput.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/AnimatedMessage.d.ts +7 -0
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/AnimatedMessage.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ChatMessage.d.ts +4 -2
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ChatMessage.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageContent.d.ts +4 -2
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageContent.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageLoader.d.ts +2 -3
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageLoader.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.d.ts +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/Chatbot.d.ts +5 -1
- package/dist/typescript/commonjs/features/chatbot/components/Chatbot.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/constants.d.ts +1 -0
- package/dist/typescript/commonjs/features/chatbot/constants.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/helpers/ttsHighlight.d.ts +8 -0
- package/dist/typescript/commonjs/features/chatbot/helpers/ttsHighlight.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/chatbot/helpers.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/index.d.ts +3 -2
- package/dist/typescript/commonjs/features/chatbot/index.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/ChatBotModel.d.ts +6 -3
- package/dist/typescript/commonjs/features/chatbot/model/ChatBotModel.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/ChatBotThreadManager.d.ts +4 -3
- package/dist/typescript/commonjs/features/chatbot/model/ChatBotThreadManager.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/ChatBoxTextManager.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/ChatTTSHighlightModel.d.ts +25 -0
- package/dist/typescript/commonjs/features/chatbot/model/ChatTTSHighlightModel.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/chatbot/model/ChatTTSModel.d.ts +38 -0
- package/dist/typescript/commonjs/features/chatbot/model/ChatTTSModel.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/chatbot/model/ChatsCacheModel.d.ts +1 -0
- package/dist/typescript/commonjs/features/chatbot/model/ChatsCacheModel.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/types/api.types.d.ts +28 -16
- package/dist/typescript/commonjs/features/chatbot/types/api.types.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/types/model.types.d.ts +15 -11
- package/dist/typescript/commonjs/features/chatbot/types/model.types.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/types/t2s.types.d.ts +25 -0
- package/dist/typescript/commonjs/features/chatbot/types/t2s.types.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/types/units.types.d.ts +1 -0
- package/dist/typescript/commonjs/features/chatbot/types/units.types.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/feedback/model/model.d.ts +4 -1
- package/dist/typescript/commonjs/features/feedback/model/model.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/feedback/model/sockets.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/AlgebraLayout/AlgebraLayout.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/BasicPlusLayout/keyboardGroups.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/BasicPlusPlusLayout/BasicPlusPlusLayout.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/BasicPlusPlusLayout/keyboardGroups.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/Keyboard.d.ts +2 -1
- package/dist/typescript/commonjs/features/keyboard/components/Keyboard.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/MainLayout/MainLayout.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/UnitsLayout/helpers.d.ts +1 -0
- package/dist/typescript/commonjs/features/keyboard/components/UnitsLayout/helpers.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/UnitsLayout/hooks/useUnitTabs.d.ts +4 -7
- package/dist/typescript/commonjs/features/keyboard/components/UnitsLayout/hooks/useUnitTabs.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/UnitsLayout/keyboardGroups.d.ts +1 -0
- package/dist/typescript/commonjs/features/keyboard/components/UnitsLayout/keyboardGroups.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/components/UnitsLayout/types.d.ts +7 -1
- package/dist/typescript/commonjs/features/keyboard/components/UnitsLayout/types.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/constants/constants.d.ts +1 -1
- package/dist/typescript/commonjs/features/keyboard/constants/keyboardGroupsByLocale.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/constants/keyboardLayouts.d.ts +4 -0
- package/dist/typescript/commonjs/features/keyboard/constants/keyboardLayouts.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/helpers.d.ts +1 -0
- package/dist/typescript/commonjs/features/keyboard/helpers.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/types/MathKeysGroups/basicOperators.d.ts +10 -0
- package/dist/typescript/commonjs/features/keyboard/types/MathKeysGroups/basicOperators.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/keyboard/types/MathKeysGroups/units.d.ts +36 -0
- package/dist/typescript/commonjs/features/keyboard/types/MathKeysGroups/units.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/openEnded/components/OpenEndedAttemptsLimit.d.ts +7 -0
- package/dist/typescript/commonjs/features/openEnded/components/OpenEndedAttemptsLimit.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/openEnded/components/OpenEndedScoreLabel.d.ts +12 -0
- package/dist/typescript/commonjs/features/openEnded/components/OpenEndedScoreLabel.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/openEnded/index.d.ts +5 -0
- package/dist/typescript/commonjs/features/openEnded/index.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/openEnded/oe.helpers.d.ts +13 -0
- package/dist/typescript/commonjs/features/openEnded/oe.helpers.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/openEnded/oe.types.d.ts +7 -0
- package/dist/typescript/commonjs/features/openEnded/oe.types.d.ts.map +1 -0
- package/dist/typescript/commonjs/index.d.ts +1 -0
- package/dist/typescript/commonjs/index.d.ts.map +1 -1
- package/dist/typescript/commonjs/lib/components/ConditionalWrapper.d.ts +9 -0
- package/dist/typescript/commonjs/lib/components/ConditionalWrapper.d.ts.map +1 -0
- package/dist/typescript/commonjs/lib/effector/createControllerEffect.d.ts +1 -1
- package/dist/typescript/commonjs/lib/effector/createControllerEffect.d.ts.map +1 -1
- package/dist/typescript/commonjs/shared/common.constants.d.ts +2 -0
- package/dist/typescript/commonjs/shared/common.constants.d.ts.map +1 -0
- package/dist/typescript/commonjs/shared/icons/TimeIcon.d.ts +4 -0
- package/dist/typescript/commonjs/shared/icons/TimeIcon.d.ts.map +1 -0
- package/dist/typescript/commonjs/shared/icons/keyboard/RoundBracketLeftIcon/RoundBracketLeftIcon.d.ts +4 -0
- package/dist/typescript/commonjs/shared/icons/keyboard/RoundBracketLeftIcon/RoundBracketLeftIcon.d.ts.map +1 -0
- package/dist/typescript/commonjs/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.d.ts +4 -0
- package/dist/typescript/commonjs/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.d.ts.map +1 -0
- package/dist/typescript/commonjs/shared/translation/constants.d.ts +12 -0
- package/dist/typescript/commonjs/shared/translation/constants.d.ts.map +1 -1
- package/dist/typescript/commonjs/shared/translation/model.d.ts +4 -0
- package/dist/typescript/commonjs/shared/translation/model.d.ts.map +1 -1
- package/dist/typescript/commonjs/types/common.types.d.ts +2 -0
- package/dist/typescript/commonjs/types/common.types.d.ts.map +1 -1
- package/dist/typescript/module/features/celebrations/helpers.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/Chat/Chat.d.ts +7 -2
- package/dist/typescript/module/features/chatbot/components/Chat/Chat.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/Chat/CloseButton.d.ts +7 -0
- package/dist/typescript/module/features/chatbot/components/Chat/CloseButton.d.ts.map +1 -0
- package/dist/typescript/module/features/chatbot/components/Chat/GradientFade.d.ts +10 -0
- package/dist/typescript/module/features/chatbot/components/Chat/GradientFade.d.ts.map +1 -0
- package/dist/typescript/module/features/chatbot/components/ChatControls/ChatControls.d.ts +3 -2
- package/dist/typescript/module/features/chatbot/components/ChatControls/ChatControls.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatInput/ChatInput.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/AnimatedMessage.d.ts +7 -0
- package/dist/typescript/module/features/chatbot/components/ChatMessage/AnimatedMessage.d.ts.map +1 -0
- package/dist/typescript/module/features/chatbot/components/ChatMessage/ChatMessage.d.ts +4 -2
- package/dist/typescript/module/features/chatbot/components/ChatMessage/ChatMessage.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageContent.d.ts +4 -2
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageContent.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageLoader.d.ts +2 -3
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageLoader.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/ReceivedMessage.d.ts +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/ReceivedMessage.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/Chatbot.d.ts +5 -1
- package/dist/typescript/module/features/chatbot/components/Chatbot.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/constants.d.ts +1 -0
- package/dist/typescript/module/features/chatbot/constants.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/helpers/ttsHighlight.d.ts +8 -0
- package/dist/typescript/module/features/chatbot/helpers/ttsHighlight.d.ts.map +1 -0
- package/dist/typescript/module/features/chatbot/helpers.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/index.d.ts +3 -2
- package/dist/typescript/module/features/chatbot/index.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/ChatBotModel.d.ts +6 -3
- package/dist/typescript/module/features/chatbot/model/ChatBotModel.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/ChatBotThreadManager.d.ts +4 -3
- package/dist/typescript/module/features/chatbot/model/ChatBotThreadManager.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/ChatBoxTextManager.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/ChatTTSHighlightModel.d.ts +25 -0
- package/dist/typescript/module/features/chatbot/model/ChatTTSHighlightModel.d.ts.map +1 -0
- package/dist/typescript/module/features/chatbot/model/ChatTTSModel.d.ts +38 -0
- package/dist/typescript/module/features/chatbot/model/ChatTTSModel.d.ts.map +1 -0
- package/dist/typescript/module/features/chatbot/model/ChatsCacheModel.d.ts +1 -0
- package/dist/typescript/module/features/chatbot/model/ChatsCacheModel.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/types/api.types.d.ts +28 -16
- package/dist/typescript/module/features/chatbot/types/api.types.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/types/model.types.d.ts +15 -11
- package/dist/typescript/module/features/chatbot/types/model.types.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/types/t2s.types.d.ts +25 -0
- package/dist/typescript/module/features/chatbot/types/t2s.types.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/types/units.types.d.ts +1 -0
- package/dist/typescript/module/features/chatbot/types/units.types.d.ts.map +1 -1
- package/dist/typescript/module/features/feedback/model/model.d.ts +4 -1
- package/dist/typescript/module/features/feedback/model/model.d.ts.map +1 -1
- package/dist/typescript/module/features/feedback/model/sockets.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/AlgebraLayout/AlgebraLayout.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/BasicPlusLayout/keyboardGroups.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/BasicPlusPlusLayout/BasicPlusPlusLayout.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/BasicPlusPlusLayout/keyboardGroups.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/Keyboard.d.ts +2 -1
- package/dist/typescript/module/features/keyboard/components/Keyboard.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/MainLayout/MainLayout.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/UnitsLayout/helpers.d.ts +1 -0
- package/dist/typescript/module/features/keyboard/components/UnitsLayout/helpers.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/UnitsLayout/hooks/useUnitTabs.d.ts +4 -7
- package/dist/typescript/module/features/keyboard/components/UnitsLayout/hooks/useUnitTabs.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/UnitsLayout/keyboardGroups.d.ts +1 -0
- package/dist/typescript/module/features/keyboard/components/UnitsLayout/keyboardGroups.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/components/UnitsLayout/types.d.ts +7 -1
- package/dist/typescript/module/features/keyboard/components/UnitsLayout/types.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/constants/constants.d.ts +1 -1
- package/dist/typescript/module/features/keyboard/constants/keyboardGroupsByLocale.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/constants/keyboardLayouts.d.ts +4 -0
- package/dist/typescript/module/features/keyboard/constants/keyboardLayouts.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/helpers.d.ts +1 -0
- package/dist/typescript/module/features/keyboard/helpers.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/types/MathKeysGroups/basicOperators.d.ts +10 -0
- package/dist/typescript/module/features/keyboard/types/MathKeysGroups/basicOperators.d.ts.map +1 -1
- package/dist/typescript/module/features/keyboard/types/MathKeysGroups/units.d.ts +36 -0
- package/dist/typescript/module/features/keyboard/types/MathKeysGroups/units.d.ts.map +1 -1
- package/dist/typescript/module/features/openEnded/components/OpenEndedAttemptsLimit.d.ts +7 -0
- package/dist/typescript/module/features/openEnded/components/OpenEndedAttemptsLimit.d.ts.map +1 -0
- package/dist/typescript/module/features/openEnded/components/OpenEndedScoreLabel.d.ts +12 -0
- package/dist/typescript/module/features/openEnded/components/OpenEndedScoreLabel.d.ts.map +1 -0
- package/dist/typescript/module/features/openEnded/index.d.ts +5 -0
- package/dist/typescript/module/features/openEnded/index.d.ts.map +1 -0
- package/dist/typescript/module/features/openEnded/oe.helpers.d.ts +13 -0
- package/dist/typescript/module/features/openEnded/oe.helpers.d.ts.map +1 -0
- package/dist/typescript/module/features/openEnded/oe.types.d.ts +7 -0
- package/dist/typescript/module/features/openEnded/oe.types.d.ts.map +1 -0
- package/dist/typescript/module/index.d.ts +1 -0
- package/dist/typescript/module/index.d.ts.map +1 -1
- package/dist/typescript/module/lib/components/ConditionalWrapper.d.ts +9 -0
- package/dist/typescript/module/lib/components/ConditionalWrapper.d.ts.map +1 -0
- package/dist/typescript/module/lib/effector/createControllerEffect.d.ts +1 -1
- package/dist/typescript/module/lib/effector/createControllerEffect.d.ts.map +1 -1
- package/dist/typescript/module/shared/common.constants.d.ts +2 -0
- package/dist/typescript/module/shared/common.constants.d.ts.map +1 -0
- package/dist/typescript/module/shared/icons/TimeIcon.d.ts +4 -0
- package/dist/typescript/module/shared/icons/TimeIcon.d.ts.map +1 -0
- package/dist/typescript/module/shared/icons/keyboard/RoundBracketLeftIcon/RoundBracketLeftIcon.d.ts +4 -0
- package/dist/typescript/module/shared/icons/keyboard/RoundBracketLeftIcon/RoundBracketLeftIcon.d.ts.map +1 -0
- package/dist/typescript/module/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.d.ts +4 -0
- package/dist/typescript/module/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.d.ts.map +1 -0
- package/dist/typescript/module/shared/translation/constants.d.ts +12 -0
- package/dist/typescript/module/shared/translation/constants.d.ts.map +1 -1
- package/dist/typescript/module/shared/translation/model.d.ts +4 -0
- package/dist/typescript/module/shared/translation/model.d.ts.map +1 -1
- package/dist/typescript/module/types/common.types.d.ts +2 -0
- package/dist/typescript/module/types/common.types.d.ts.map +1 -1
- package/package.json +3 -1
- package/src/features/celebrations/helpers.ts +35 -33
- package/src/features/chatbot/TTS_HIGHLIGHTING.md +120 -0
- package/src/features/chatbot/components/Chat/Chat.tsx +301 -57
- package/src/features/chatbot/components/Chat/CloseButton.tsx +31 -0
- package/src/features/chatbot/components/Chat/GradientFade.tsx +43 -0
- package/src/features/chatbot/components/ChatControls/ChatControls.tsx +47 -60
- package/src/features/chatbot/components/ChatInput/ChatInput.tsx +2 -1
- package/src/features/chatbot/components/ChatInput/FreeText/ChatTextInput.tsx +2 -2
- package/src/features/chatbot/components/ChatInput/FreeText/SendMessageButton.tsx +1 -1
- package/src/features/chatbot/components/ChatMessage/AnimatedMessage.tsx +30 -0
- package/src/features/chatbot/components/ChatMessage/ChatMessage.tsx +4 -2
- package/src/features/chatbot/components/ChatMessage/MessageContent.tsx +25 -3
- package/src/features/chatbot/components/ChatMessage/MessageLoader.tsx +17 -33
- package/src/features/chatbot/components/ChatMessage/ReceivedMessage.tsx +17 -12
- package/src/features/chatbot/components/ChatMessage/SentMessage.tsx +1 -1
- package/src/features/chatbot/components/Chatbot.tsx +30 -3
- package/src/features/chatbot/constants.ts +2 -0
- package/src/features/chatbot/helpers/ttsHighlight.ts +25 -0
- package/src/features/chatbot/helpers.ts +14 -1
- package/src/features/chatbot/index.ts +17 -2
- package/src/features/chatbot/model/ChatBotModel.ts +74 -16
- package/src/features/chatbot/model/ChatBotThreadManager.ts +12 -4
- package/src/features/chatbot/model/ChatBoxTextManager.ts +1 -0
- package/src/features/chatbot/model/ChatTTSHighlightModel.ts +64 -0
- package/src/features/chatbot/model/ChatTTSModel.ts +168 -0
- package/src/features/chatbot/model/ChatbotApi.ts +1 -1
- package/src/features/chatbot/model/ChatbotTranslation.ts +1 -1
- package/src/features/chatbot/model/ChatsCacheModel.ts +11 -0
- package/src/features/chatbot/types/api.types.ts +25 -19
- package/src/features/chatbot/types/model.types.ts +24 -12
- package/src/features/chatbot/types/t2s.types.ts +33 -0
- package/src/features/chatbot/types/units.types.ts +1 -0
- package/src/features/feedback/model/model.ts +4 -1
- package/src/features/feedback/model/sockets.ts +8 -6
- package/src/features/keyboard/components/AlgebraLayout/AlgebraLayout.tsx +4 -3
- package/src/features/keyboard/components/BasicLayout/BasicLayout.tsx +2 -2
- package/src/features/keyboard/components/BasicPlusLayout/keyboardGroups.ts +27 -17
- package/src/features/keyboard/components/BasicPlusPlusLayout/BasicPlusPlusLayout.tsx +3 -2
- package/src/features/keyboard/components/BasicPlusPlusLayout/keyboardGroups.ts +30 -24
- package/src/features/keyboard/components/Keyboard.tsx +14 -4
- package/src/features/keyboard/components/KeysList/KeysList.tsx +1 -1
- package/src/features/keyboard/components/MainLayout/MainLayout.tsx +2 -6
- package/src/features/keyboard/components/UnitsLayout/UnitTabs.tsx +1 -1
- package/src/features/keyboard/components/UnitsLayout/helpers.tsx +3 -0
- package/src/features/keyboard/components/UnitsLayout/hooks/useUnitTabs.ts +36 -22
- package/src/features/keyboard/components/UnitsLayout/keyboardGroups.ts +11 -0
- package/src/features/keyboard/components/UnitsLayout/types.ts +7 -0
- package/src/features/keyboard/constants/constants.ts +1 -1
- package/src/features/keyboard/constants/keyboardGroupsByLocale.ts +2 -0
- package/src/features/keyboard/constants/keyboardLayouts.ts +18 -1
- package/src/features/keyboard/helpers.ts +6 -0
- package/src/features/keyboard/types/MathKeysGroups/basicOperators.tsx +15 -3
- package/src/features/keyboard/types/MathKeysGroups/units.tsx +3 -0
- package/src/features/openEnded/components/OpenEndedAttemptsLimit.tsx +26 -0
- package/src/features/openEnded/components/OpenEndedScoreLabel.tsx +81 -0
- package/src/features/openEnded/index.ts +4 -0
- package/src/features/openEnded/oe.helpers.ts +31 -0
- package/src/features/openEnded/oe.types.ts +6 -0
- package/src/index.ts +1 -0
- package/src/lib/components/ConditionalWrapper.tsx +15 -0
- package/src/lib/effector/createControllerEffect.ts +1 -1
- package/src/shared/common.constants.ts +3 -0
- package/src/shared/icons/TimeIcon.tsx +23 -0
- package/src/shared/icons/keyboard/CDotIcon/CDotIcon.tsx +2 -2
- package/src/shared/icons/keyboard/RoundBracketLeftIcon/RoundBracketLeftIcon.tsx +18 -0
- package/src/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.tsx +18 -0
- package/src/shared/translation/localization/ca.json +4 -2
- package/src/shared/translation/localization/de.json +4 -2
- package/src/shared/translation/localization/en.json +4 -2
- package/src/shared/translation/localization/gb.json +4 -2
- package/src/shared/translation/localization/sct.json +4 -2
- package/src/shared/translation/localization/sw.json +4 -2
- package/src/types/common.types.ts +4 -0
- package/dist/commonjs/features/chatbot/model/t2s.js +0 -107
- package/dist/commonjs/features/chatbot/model/t2s.js.map +0 -1
- package/dist/module/features/chatbot/model/t2s.js +0 -102
- package/dist/module/features/chatbot/model/t2s.js.map +0 -1
- package/dist/typescript/commonjs/features/chatbot/model/t2s.d.ts +0 -34
- package/dist/typescript/commonjs/features/chatbot/model/t2s.d.ts.map +0 -1
- package/dist/typescript/module/features/chatbot/model/t2s.d.ts +0 -34
- package/dist/typescript/module/features/chatbot/model/t2s.d.ts.map +0 -1
- package/src/features/chatbot/model/t2s.ts +0 -123
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.RoundBracketRightIcon = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _reactNativeSvg = _interopRequireWildcard(require("react-native-svg"));
|
|
9
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
10
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
11
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
12
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
|
+
const ASPECT_RATIO = 5 / 14;
|
|
14
|
+
const RoundBracketRightIcon = ({
|
|
15
|
+
size = 20,
|
|
16
|
+
color
|
|
17
|
+
}) => {
|
|
18
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeSvg.default, {
|
|
19
|
+
width: size * ASPECT_RATIO,
|
|
20
|
+
height: size,
|
|
21
|
+
viewBox: "0 0 5 14",
|
|
22
|
+
fill: "none",
|
|
23
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeSvg.Path, {
|
|
24
|
+
fillRule: "evenodd",
|
|
25
|
+
clipRule: "evenodd",
|
|
26
|
+
d: "M0.219696 0.21967C-0.0731974 0.512563 -0.0731974 0.987437 0.219696 1.28033C3.45142 4.51206 3.3881 10.001 0.261932 12.6806C-0.0525622 12.9501 -0.0889835 13.4236 0.180583 13.7381C0.45015 14.0526 0.923625 14.089 1.23812 13.8194C5.11195 10.499 5.04863 3.98794 1.28036 0.21967C0.987463 -0.0732233 0.512589 -0.0732233 0.219696 0.21967Z",
|
|
27
|
+
fill: color
|
|
28
|
+
})
|
|
29
|
+
});
|
|
30
|
+
};
|
|
31
|
+
exports.RoundBracketRightIcon = RoundBracketRightIcon;
|
|
32
|
+
//# sourceMappingURL=RoundBracketRightIcon.js.map
|
package/dist/commonjs/shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNativeSvg","_interopRequireWildcard","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","ASPECT_RATIO","RoundBracketRightIcon","size","color","jsx","width","height","viewBox","fill","children","Path","fillRule","clipRule","d","exports"],"sourceRoot":"../../../../../../src","sources":["shared/icons/keyboard/RoundBracketRightIcon/RoundBracketRightIcon.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AAEA,IAAAC,eAAA,GAAAC,uBAAA,CAAAF,OAAA;AAA4C,IAAAG,WAAA,GAAAH,OAAA;AAAA,SAAAI,yBAAAC,CAAA,6BAAAC,OAAA,mBAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,CAAA,WAAAA,CAAA,GAAAG,CAAA,GAAAD,CAAA,KAAAF,CAAA;AAAA,SAAAH,wBAAAG,CAAA,EAAAE,CAAA,SAAAA,CAAA,IAAAF,CAAA,IAAAA,CAAA,CAAAI,UAAA,SAAAJ,CAAA,eAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,WAAAK,OAAA,EAAAL,CAAA,QAAAG,CAAA,GAAAJ,wBAAA,CAAAG,CAAA,OAAAC,CAAA,IAAAA,CAAA,CAAAG,GAAA,CAAAN,CAAA,UAAAG,CAAA,CAAAI,GAAA,CAAAP,CAAA,OAAAQ,CAAA,KAAAC,SAAA,UAAAC,CAAA,GAAAC,MAAA,CAAAC,cAAA,IAAAD,MAAA,CAAAE,wBAAA,WAAAC,CAAA,IAAAd,CAAA,oBAAAc,CAAA,OAAAC,cAAA,CAAAC,IAAA,CAAAhB,CAAA,EAAAc,CAAA,SAAAG,CAAA,GAAAP,CAAA,GAAAC,MAAA,CAAAE,wBAAA,CAAAb,CAAA,EAAAc,CAAA,UAAAG,CAAA,KAAAA,CAAA,CAAAV,GAAA,IAAAU,CAAA,CAAAC,GAAA,IAAAP,MAAA,CAAAC,cAAA,CAAAJ,CAAA,EAAAM,CAAA,EAAAG,CAAA,IAAAT,CAAA,CAAAM,CAAA,IAAAd,CAAA,CAAAc,CAAA,YAAAN,CAAA,CAAAH,OAAA,GAAAL,CAAA,EAAAG,CAAA,IAAAA,CAAA,CAAAe,GAAA,CAAAlB,CAAA,EAAAQ,CAAA,GAAAA,CAAA;AAAA,SAAAd,uBAAAM,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAI,UAAA,GAAAJ,CAAA,KAAAK,OAAA,EAAAL,CAAA;AAE5C,MAAMmB,YAAY,GAAG,CAAC,GAAG,EAAE;AAEpB,MAAMC,qBAAqB,GAAGA,CAAC;EAAEC,IAAI,GAAG,EAAE;EAAEC;AAAiB,CAAC,KAAK;EACxE,oBACE,IAAAxB,WAAA,CAAAyB,GAAA,EAAC3B,eAAA,CAAAS,OAAG;IAACmB,KAAK,EAAEH,IAAI,GAAGF,YAAa;IAACM,MAAM,EAAEJ,IAAK;IAACK,OAAO,EAAC,UAAU;IAACC,IAAI,EAAC,MAAM;IAAAC,QAAA,eAC3E,IAAA9B,WAAA,CAAAyB,GAAA,EAAC3B,eAAA,CAAAiC,IAAI;MACHC,QAAQ,EAAC,SAAS;MAClBC,QAAQ,EAAC,SAAS;MAClBC,CAAC,EAAC,2UAA2U;MAC7UL,IAAI,EAAEL;IAAM,CACb;EAAC,CACC,CAAC;AAEV,CAAC;AAAAW,OAAA,CAAAb,qBAAA,GAAAA,qBAAA","ignoreList":[]}
|
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
"errorMessage": "Something went wrong! Try again",
|
|
21
21
|
"howCanIHelp": "Hi! Do you want help?",
|
|
22
22
|
"showError": "Show error",
|
|
23
|
-
"inputPlaceholder": "Type..."
|
|
23
|
+
"inputPlaceholder": "Type...",
|
|
24
|
+
"wantHelp": "Want some help?"
|
|
24
25
|
},
|
|
25
26
|
"gifCelebrations": {
|
|
26
27
|
"greatStart": "Great start!",
|
|
@@ -37,6 +38,7 @@
|
|
|
37
38
|
"length": "Length",
|
|
38
39
|
"area": "Area",
|
|
39
40
|
"volume": "Volume",
|
|
40
|
-
"weight": "Weight"
|
|
41
|
+
"weight": "Weight",
|
|
42
|
+
"time": "Time"
|
|
41
43
|
}
|
|
42
44
|
}
|
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
"errorMessage": "Etwas ist schiefgelaufen! Versuch es erneut",
|
|
21
21
|
"howCanIHelp": "Hi! Möchtest du Hilfe?",
|
|
22
22
|
"showError": "Fehler anzeigen",
|
|
23
|
-
"inputPlaceholder": "Tippe..."
|
|
23
|
+
"inputPlaceholder": "Tippe...",
|
|
24
|
+
"wantHelp": "Brauchst du Hilfe?"
|
|
24
25
|
},
|
|
25
26
|
"gifCelebrations": {
|
|
26
27
|
"greatStart": "Toller Start!",
|
|
@@ -37,6 +38,7 @@
|
|
|
37
38
|
"length": "Länge",
|
|
38
39
|
"area": "Fläche",
|
|
39
40
|
"volume": "Volumen",
|
|
40
|
-
"weight": "Gewicht"
|
|
41
|
+
"weight": "Gewicht",
|
|
42
|
+
"time": "Zeit"
|
|
41
43
|
}
|
|
42
44
|
}
|
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
"errorMessage": "Something went wrong! Try again",
|
|
21
21
|
"howCanIHelp": "Hi! Do you want help?",
|
|
22
22
|
"showError": "Show error",
|
|
23
|
-
"inputPlaceholder": "Type..."
|
|
23
|
+
"inputPlaceholder": "Type...",
|
|
24
|
+
"wantHelp": "Want some help?"
|
|
24
25
|
},
|
|
25
26
|
"gifCelebrations": {
|
|
26
27
|
"greatStart": "Great start!",
|
|
@@ -37,6 +38,7 @@
|
|
|
37
38
|
"length": "Length",
|
|
38
39
|
"area": "Area",
|
|
39
40
|
"volume": "Volume",
|
|
40
|
-
"weight": "Weight"
|
|
41
|
+
"weight": "Weight",
|
|
42
|
+
"time": "Time"
|
|
41
43
|
}
|
|
42
44
|
}
|
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
"errorMessage": "Something went wrong! Try again",
|
|
21
21
|
"howCanIHelp": "Hi! Do you want help?",
|
|
22
22
|
"showError": "Show error",
|
|
23
|
-
"inputPlaceholder": "Type..."
|
|
23
|
+
"inputPlaceholder": "Type...",
|
|
24
|
+
"wantHelp": "Want some help?"
|
|
24
25
|
},
|
|
25
26
|
"gifCelebrations": {
|
|
26
27
|
"greatStart": "Great start!",
|
|
@@ -37,6 +38,7 @@
|
|
|
37
38
|
"length": "Length",
|
|
38
39
|
"area": "Area",
|
|
39
40
|
"volume": "Volume",
|
|
40
|
-
"weight": "Weight"
|
|
41
|
+
"weight": "Weight",
|
|
42
|
+
"time": "Time"
|
|
41
43
|
}
|
|
42
44
|
}
|
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
"errorMessage": "Something went wrong! Try again",
|
|
21
21
|
"howCanIHelp": "Hi! Do you want help?",
|
|
22
22
|
"showError": "Show error",
|
|
23
|
-
"inputPlaceholder": "Type..."
|
|
23
|
+
"inputPlaceholder": "Type...",
|
|
24
|
+
"wantHelp": "Want some help?"
|
|
24
25
|
},
|
|
25
26
|
"gifCelebrations": {
|
|
26
27
|
"greatStart": "Great start!",
|
|
@@ -37,6 +38,7 @@
|
|
|
37
38
|
"length": "Length",
|
|
38
39
|
"area": "Area",
|
|
39
40
|
"volume": "Volume",
|
|
40
|
-
"weight": "Weight"
|
|
41
|
+
"weight": "Weight",
|
|
42
|
+
"time": "Time"
|
|
41
43
|
}
|
|
42
44
|
}
|
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
"errorMessage": "Något gick snett! Försök igen",
|
|
21
21
|
"howCanIHelp": "Hej! Hur kan jag hjälpa dig?",
|
|
22
22
|
"showError": "Visa fel",
|
|
23
|
-
"inputPlaceholder": "Skriv..."
|
|
23
|
+
"inputPlaceholder": "Skriv...",
|
|
24
|
+
"wantHelp": "Vill du ha hjälp?"
|
|
24
25
|
},
|
|
25
26
|
"gifCelebrations": {
|
|
26
27
|
"greatStart": "Bra start!",
|
|
@@ -37,6 +38,7 @@
|
|
|
37
38
|
"length": "Längd",
|
|
38
39
|
"area": "Area",
|
|
39
40
|
"volume": "Volym",
|
|
40
|
-
"weight": "Vikt"
|
|
41
|
+
"weight": "Vikt",
|
|
42
|
+
"time": "Tid"
|
|
41
43
|
}
|
|
42
44
|
}
|
|
@@ -8,7 +8,10 @@ const isDateInRange = (currentDate, startDateStr, endDateStr) => {
|
|
|
8
8
|
const [endDay, endMonth] = endDateStr.split('-').map(Number);
|
|
9
9
|
const currentYear = currentDate.getFullYear();
|
|
10
10
|
const startDate = new Date(currentYear, startMonth - 1, startDay);
|
|
11
|
-
|
|
11
|
+
|
|
12
|
+
// If end month is earlier than start month, it spans to next year
|
|
13
|
+
const endYear = endMonth < startMonth ? currentYear + 1 : currentYear;
|
|
14
|
+
const endDate = new Date(endYear, endMonth - 1, endDay + 1);
|
|
12
15
|
return currentDate >= startDate && currentDate <= endDate;
|
|
13
16
|
};
|
|
14
17
|
export const getIconForCurrentDate = () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Spark","CELEBRATION_ICON_CONFIG","CELEBRATION_VARIANTS","randomRange","min","max","Math","random","isDateInRange","currentDate","startDateStr","endDateStr","startDay","startMonth","split","map","Number","endDay","endMonth","currentYear","getFullYear","startDate","Date","endDate","getIconForCurrentDate","celebration","activePeriod","start","end","Icon","MainIcon","generateParticle","variant","elementsCount","angle","rotation","sparkSize","mainSize","velocityMultiplier","friction","life","angularAcceleration","speedRange","sparkSpeedMin","spark","sparkSpeedMax","mainSpeedMin","main","mainSpeedMax","particles","i","randomAngle","from","PI","to","randomSpeed","randomAngularAcceleration","push","id","size","type","velocity","x","cos","y","sin","rotationSpeed","Component","star"],"sourceRoot":"../../../../src","sources":["features/celebrations/helpers.ts"],"mappings":";;AACA,SAASA,KAAK,QAAQ,uBAAoB;AAC1C,SAASC,uBAAuB,EAAEC,oBAAoB,QAAQ,aAAU;AAGxE,OAAO,MAAMC,WAAW,GAAGA,CAACC,GAAW,EAAEC,GAAW,KAAKC,IAAI,CAACC,MAAM,CAAC,CAAC,IAAIF,GAAG,GAAGD,GAAG,CAAC,GAAGA,GAAG;AAE1F,MAAMI,aAAa,GAAGA,CAACC,WAAiB,EAAEC,YAAoB,EAAEC,UAAkB,KAAK;EACrF,MAAM,CAACC,QAAQ,EAAEC,UAAU,CAAC,GAAGH,YAAY,CAACI,KAAK,CAAC,GAAG,CAAC,CAACC,GAAG,CAACC,MAAM,CAAC;EAClE,MAAM,CAACC,MAAM,EAAEC,QAAQ,CAAC,GAAGP,UAAU,CAACG,KAAK,CAAC,GAAG,CAAC,CAACC,GAAG,CAACC,MAAM,CAAC;EAE5D,MAAMG,WAAW,GAAGV,WAAW,CAACW,WAAW,CAAC,CAAC;EAC7C,MAAMC,SAAS,GAAG,IAAIC,IAAI,CAACH,WAAW,EAAEN,UAAU,GAAG,CAAC,EAAED,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"names":["Spark","CELEBRATION_ICON_CONFIG","CELEBRATION_VARIANTS","randomRange","min","max","Math","random","isDateInRange","currentDate","startDateStr","endDateStr","startDay","startMonth","split","map","Number","endDay","endMonth","currentYear","getFullYear","startDate","Date","endYear","endDate","getIconForCurrentDate","celebration","activePeriod","start","end","Icon","MainIcon","generateParticle","variant","elementsCount","angle","rotation","sparkSize","mainSize","velocityMultiplier","friction","life","angularAcceleration","speedRange","sparkSpeedMin","spark","sparkSpeedMax","mainSpeedMin","main","mainSpeedMax","particles","i","randomAngle","from","PI","to","randomSpeed","randomAngularAcceleration","push","id","size","type","velocity","x","cos","y","sin","rotationSpeed","Component","star"],"sourceRoot":"../../../../src","sources":["features/celebrations/helpers.ts"],"mappings":"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","ignoreList":[]}
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
# TTS Word-by-Word Highlighting
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
Word-by-word text highlighting synchronized with text-to-speech playback in the chatbot. The feature is optional and enabled via `isWordHighlightEnabled` config flag.
|
|
6
|
+
|
|
7
|
+
## How It Works
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
11
|
+
│ 1. User clicks TTS button on a message │
|
|
12
|
+
│ ↓ │
|
|
13
|
+
│ 2. Text is converted to SSML with word marks │
|
|
14
|
+
│ "Hello world" → <speak><mark name="w_0"/>Hello │
|
|
15
|
+
│ <mark name="w_1"/>world</speak> │
|
|
16
|
+
│ ↓ │
|
|
17
|
+
│ 3. Google TTS API returns audio + timepoints │
|
|
18
|
+
│ [{ markName: "w_0", timeSeconds: 0.0 }, │
|
|
19
|
+
│ { markName: "w_1", timeSeconds: 0.5 }] │
|
|
20
|
+
│ ↓ │
|
|
21
|
+
│ 4. Audio plays, onTimeUpdate fires via RAF loop │
|
|
22
|
+
│ ↓ │
|
|
23
|
+
│ 5. Current time → find matching timepoint → word index │
|
|
24
|
+
│ ↓ │
|
|
25
|
+
│ 6. $highlightedWordIndex updates → UI re-renders highlighted │
|
|
26
|
+
└─────────────────────────────────────────────────────────────────┘
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## Usage
|
|
30
|
+
|
|
31
|
+
```tsx
|
|
32
|
+
// In students-web model setup
|
|
33
|
+
chatModel.bot.setUpT2S({
|
|
34
|
+
audioProvider: createT2SAudioProvider(),
|
|
35
|
+
textSanitizer: removeKatexPartFromTextToSpeech,
|
|
36
|
+
isWordHighlightEnabled: true,
|
|
37
|
+
})
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## Architecture
|
|
41
|
+
|
|
42
|
+
### ChatTTSModel (ChatTTSModel.ts)
|
|
43
|
+
|
|
44
|
+
Handles TTS playback and word highlighting. Key design decisions:
|
|
45
|
+
|
|
46
|
+
- **Map-based cache** — `audioCache: Map<string, AudioCache>` stores both `audioPath` and `timepoints` per message. When highlighting is off, `timepoints` is `[]`. Cache lives for the model's lifetime (cleared when user leaves the problem).
|
|
47
|
+
- **`fetchAudio()` method** — encapsulates API call + audioContent decoding. Highlight vs non-highlight differences are ternaries (SSML vs plain text, `enableTimePointing`).
|
|
48
|
+
- **`play()` is linear** — cache lookup → fetch if miss → store → activate highlight if enabled → play audio. No branching between highlight/non-highlight paths.
|
|
49
|
+
- **Pause/resume guards** — `wordHighlightEnabled` check before toggling `setIsActive(false)`/`setIsActive(true)` on pause/resume.
|
|
50
|
+
- **`wordHighlightEnabled` (private)** — stored result of `!!isWordHighlightEnabled && !!audioProvider.onTimeUpdate`. Set once at `setConfig`.
|
|
51
|
+
- **`isWordHighlightEnabled` (public getter)** — read-only access for external consumers (e.g. `Chat.tsx`).
|
|
52
|
+
|
|
53
|
+
### AudioProvider type
|
|
54
|
+
|
|
55
|
+
```typescript
|
|
56
|
+
type AudioProvider = {
|
|
57
|
+
play: (audioPath: string, onPlaybackComplete: () => void) => Promise<void>
|
|
58
|
+
pause: () => void
|
|
59
|
+
resume: () => void
|
|
60
|
+
stop: () => void
|
|
61
|
+
onTimeUpdate?: OnTimeUpdate // optional — presence enables highlight capability
|
|
62
|
+
}
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
`onTimeUpdate` is optional. It's the mechanism that syncs audio playback time with word highlights via a RAF loop. If the provider doesn't have it, highlighting won't activate even if `isWordHighlightEnabled: true`.
|
|
66
|
+
|
|
67
|
+
### ChatTTSHighlightModel (ChatTTSHighlightModel.ts)
|
|
68
|
+
|
|
69
|
+
Manages highlight state using Effector stores with declarative reset. Receives `OnTimeUpdate` callback directly (not the whole `AudioProvider`).
|
|
70
|
+
|
|
71
|
+
- **`$isActive`** — gates `$highlightedWordIndex` computation. Toggled on pause/resume without resetting timepoints.
|
|
72
|
+
- **`$highlightedWordIndex`** — derived store, returns `-1` when inactive or no match. Parses mark name via `WORD_MARK_REGEX`.
|
|
73
|
+
- **`activate(timepoints, onTimeUpdate)`** — sets timepoints, enables highlighting, registers time update callback. Only triggers store updates when the highlighted word actually changes (`lastMark` comparison).
|
|
74
|
+
- **`deactivate(onTimeUpdate)`** — stops listening, resets all state via declarative `.reset()` chain.
|
|
75
|
+
- **All stores use `.reset(this.reset)`** — single `reset` event clears `$time`, `$timepoints`, and `$isActive`.
|
|
76
|
+
|
|
77
|
+
### Helpers (helpers/ttsHighlight.ts)
|
|
78
|
+
|
|
79
|
+
- **`textToSSML(text)`** — converts plain text to SSML with `<mark>` tags for word timing.
|
|
80
|
+
- **`findCurrentMark(timepoints, time)`** — iterates backwards through timepoints to find the current mark. Efficient for linear playback.
|
|
81
|
+
|
|
82
|
+
### Constants (constants.ts)
|
|
83
|
+
|
|
84
|
+
- **`WORD_MARK_REGEX`** — `/^w_(\d+)$/` — extracts word index from mark names like `w_0`, `w_1`.
|
|
85
|
+
|
|
86
|
+
### Naming conventions
|
|
87
|
+
|
|
88
|
+
| Name | Scope | Purpose |
|
|
89
|
+
|------|-------|---------|
|
|
90
|
+
| `wordHighlight` | public instance | `ChatTTSHighlightModel` instance on `ChatTTSModel` |
|
|
91
|
+
| `wordHighlightEnabled` | private field | Whether highlighting is active (set once at config) |
|
|
92
|
+
| `isWordHighlightEnabled` | public getter | Read-only access to `wordHighlightEnabled` for external consumers |
|
|
93
|
+
| `isWordHighlightEnabled` | T2SConfig field | Config flag passed to `setUpT2S()` |
|
|
94
|
+
|
|
95
|
+
## Data Flow
|
|
96
|
+
|
|
97
|
+
```
|
|
98
|
+
AudioProvider.onTimeUpdate(callback)
|
|
99
|
+
↓
|
|
100
|
+
ChatTTSHighlightModel.activate(timepoints, onTimeUpdate)
|
|
101
|
+
↓
|
|
102
|
+
RAF loop → audio.currentTime → findCurrentMark() → only updates when mark changes
|
|
103
|
+
↓
|
|
104
|
+
$highlightedWordIndex = parse mark name "w_N" → N (or -1 if inactive/no match)
|
|
105
|
+
↓
|
|
106
|
+
Chat.tsx: model.t2s.isWordHighlightEnabled && isPlayingMessage ? highlightedWordIndex : -1
|
|
107
|
+
↓
|
|
108
|
+
ChatMessage → MessageContent → TTSHighlightRenderer({ text, highlightedIndex })
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
## Key Files
|
|
112
|
+
|
|
113
|
+
| File | Purpose |
|
|
114
|
+
|------|---------|
|
|
115
|
+
| `model/ChatTTSModel.ts` | `ChatTTSModel` — TTS playback, caching, highlight orchestration |
|
|
116
|
+
| `model/ChatTTSHighlightModel.ts` | Highlight state — timepoints, current time, `$isActive`, derived word index |
|
|
117
|
+
| `helpers/ttsHighlight.ts` | `textToSSML` + `findCurrentMark` — SSML conversion and playback position lookup |
|
|
118
|
+
| `constants.ts` | `WORD_MARK_REGEX` and audio config defaults |
|
|
119
|
+
| `types/t2s.types.ts` | `AudioProvider`, `OnTimeUpdate`, `AudioStatus`, `AudioCache`, `TTSHighlightRendererProps` types |
|
|
120
|
+
| `components/Chat/Chat.tsx` | Reads `isWordHighlightEnabled` and `$highlightedWordIndex`, passes to messages |
|
|
@@ -1,95 +1,279 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
import React, { useRef } from 'react';
|
|
4
|
-
import {
|
|
3
|
+
import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
|
4
|
+
import { FlatList, Platform, StyleSheet, useWindowDimensions, View } from 'react-native';
|
|
5
5
|
import { useStoreMap, useUnit } from 'effector-react';
|
|
6
|
+
import { SPACING } from '@magmamath/react-native-ui';
|
|
7
|
+
import { ChatbotIcon } from "../../../../shared/icons/ChatbotIcon.js";
|
|
8
|
+
import { LavaIconInGlasses } from "../../../../shared/icons/LavaIconInGlasses.js";
|
|
9
|
+
import { AnimatedMessage } from "../ChatMessage/AnimatedMessage.js";
|
|
6
10
|
import { ChatMessage } from "../ChatMessage/ChatMessage.js";
|
|
7
11
|
import { MessageLoader } from "../ChatMessage/MessageLoader.js";
|
|
8
12
|
import { ChatInput } from "../ChatInput/ChatInput.js";
|
|
13
|
+
import { CloseButton } from "./CloseButton.js";
|
|
9
14
|
import { MessageVariant } from "../../types/model.types.js";
|
|
10
15
|
import { ColorScheme } from "../../types/style.types.js";
|
|
16
|
+
import { ConditionalWrapper } from "../../../../lib/components/ConditionalWrapper.js";
|
|
11
17
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
18
|
+
const SCROLL_BOTTOM_THRESHOLD = 1;
|
|
12
19
|
const TOOLBAR_HEIGHT = 140;
|
|
13
20
|
const BOTTOM_OFFSET = Platform.select({
|
|
14
21
|
web: 265,
|
|
15
22
|
default: 294
|
|
16
23
|
});
|
|
24
|
+
const TOP_FADE_MASK = Platform.select({
|
|
25
|
+
web: {
|
|
26
|
+
maskImage: 'linear-gradient(to top, transparent, black 10%, black)'
|
|
27
|
+
},
|
|
28
|
+
default: undefined
|
|
29
|
+
});
|
|
30
|
+
const Separator = () => /*#__PURE__*/_jsx(View, {
|
|
31
|
+
style: styles.separator
|
|
32
|
+
});
|
|
33
|
+
const BottomFade = ({
|
|
34
|
+
visible
|
|
35
|
+
}) => /*#__PURE__*/_jsx(View, {
|
|
36
|
+
style: [styles.bottomFade, {
|
|
37
|
+
opacity: visible ? 1 : 0
|
|
38
|
+
}],
|
|
39
|
+
pointerEvents: "none"
|
|
40
|
+
});
|
|
41
|
+
const ChatIcon = ({
|
|
42
|
+
isLoading
|
|
43
|
+
}) => /*#__PURE__*/_jsx(View, {
|
|
44
|
+
style: styles.iconAbsolute,
|
|
45
|
+
children: isLoading ? /*#__PURE__*/_jsx(LavaIconInGlasses, {
|
|
46
|
+
width: 53,
|
|
47
|
+
height: 73
|
|
48
|
+
}) : /*#__PURE__*/_jsx(ChatbotIcon, {
|
|
49
|
+
width: 53,
|
|
50
|
+
height: 73,
|
|
51
|
+
color: 'blue'
|
|
52
|
+
})
|
|
53
|
+
});
|
|
54
|
+
const ChatFooter = ({
|
|
55
|
+
isHintFeedback,
|
|
56
|
+
isInputDisabled,
|
|
57
|
+
colorScheme,
|
|
58
|
+
hasMessages,
|
|
59
|
+
onPressClose
|
|
60
|
+
}) => /*#__PURE__*/_jsxs(View, {
|
|
61
|
+
style: styles.inputRow,
|
|
62
|
+
children: [/*#__PURE__*/_jsx(CloseButton, {
|
|
63
|
+
onPress: onPressClose
|
|
64
|
+
}), !isInputDisabled && /*#__PURE__*/_jsx(ChatInput, {
|
|
65
|
+
isHintFeedback: isHintFeedback,
|
|
66
|
+
colorScheme: colorScheme,
|
|
67
|
+
hasMessages: hasMessages
|
|
68
|
+
})]
|
|
69
|
+
});
|
|
17
70
|
export const Chat = ({
|
|
18
71
|
model,
|
|
19
72
|
isHintFeedback,
|
|
20
73
|
isTextToSpeechEnabled,
|
|
21
|
-
|
|
74
|
+
isInputDisabled,
|
|
75
|
+
colorScheme = ColorScheme.Blue,
|
|
76
|
+
MessageWrapper,
|
|
77
|
+
TTSHighlightRenderer,
|
|
78
|
+
onPressClose
|
|
22
79
|
}) => {
|
|
23
|
-
const dimensions = useWindowDimensions();
|
|
24
80
|
const ref = useRef(null);
|
|
81
|
+
const maxHeightRef = useRef(0);
|
|
82
|
+
const dimensions = useWindowDimensions();
|
|
25
83
|
const isOpen = useUnit(model.$isOpen);
|
|
26
84
|
const isHelpRequestPending = useUnit(model.sendHelpRequestFx.pending);
|
|
27
85
|
const isTextToSpeechPending = useUnit(model.api.textToSpeechTextFx.pending);
|
|
86
|
+
const audioStatus = useUnit(model.t2s.$status);
|
|
28
87
|
const currentPlayingId = useUnit(model.t2s.$currentPlayingId);
|
|
88
|
+
const highlightedWordIndex = useUnit(model.t2s.wordHighlight.$highlightedWordIndex);
|
|
29
89
|
const isTranslated = useUnit(model.translation.$isTranslated);
|
|
30
|
-
const audioStatus = useUnit(model.t2s.$status);
|
|
31
90
|
const errorSpottingEnabled = useUnit(model.errorSpotting.$isEnabled);
|
|
32
91
|
const messages = useStoreMap(model.$currentChatData, ({
|
|
33
92
|
messages
|
|
34
93
|
}) => messages);
|
|
35
|
-
const
|
|
94
|
+
const lastBotMessageId = messages.findLast(m => !m.isOwnMessage)?.id;
|
|
36
95
|
const MAX_HEIGHT = dimensions.height - TOOLBAR_HEIGHT - BOTTOM_OFFSET;
|
|
37
|
-
|
|
96
|
+
maxHeightRef.current = MAX_HEIGHT;
|
|
97
|
+
const [isScrollable, setIsScrollable] = useState(false);
|
|
98
|
+
const [showBottomFade, setShowBottomFade] = useState(false);
|
|
99
|
+
useEffect(() => {
|
|
100
|
+
if (!isOpen) {
|
|
101
|
+
setIsScrollable(false);
|
|
102
|
+
setShowBottomFade(false);
|
|
103
|
+
}
|
|
104
|
+
}, [isOpen]);
|
|
105
|
+
const handleScroll = useCallback(e => {
|
|
106
|
+
const {
|
|
107
|
+
contentOffset
|
|
108
|
+
} = e.nativeEvent;
|
|
109
|
+
setShowBottomFade(contentOffset.y > SCROLL_BOTTOM_THRESHOLD);
|
|
110
|
+
}, []);
|
|
111
|
+
const handleContentSizeChange = useCallback((_, contentHeight) => {
|
|
112
|
+
setIsScrollable(contentHeight >= maxHeightRef.current);
|
|
113
|
+
}, []);
|
|
114
|
+
const shouldWrapMessage = MessageWrapper && isInputDisabled && messages.length === 1;
|
|
115
|
+
const reversedMessages = useMemo(() => [...messages].reverse(), [messages]);
|
|
116
|
+
const showAbsoluteIcon = !showBottomFade && !isInputDisabled;
|
|
117
|
+
const renderMessage = useCallback(({
|
|
118
|
+
item: message
|
|
119
|
+
}) => {
|
|
120
|
+
const isPlayingMessage = message.id === currentPlayingId;
|
|
121
|
+
const messageHighlightIndex = model.t2s.isWordHighlightEnabled && isPlayingMessage ? highlightedWordIndex : -1;
|
|
122
|
+
const showInlineIcon = showBottomFade && !message.isOwnMessage && message.id === lastBotMessageId;
|
|
123
|
+
return /*#__PURE__*/_jsx(MessageItem, {
|
|
124
|
+
message: message,
|
|
125
|
+
showInlineIcon: showInlineIcon,
|
|
126
|
+
animate: !isInputDisabled,
|
|
127
|
+
shouldWrapMessage: !!shouldWrapMessage,
|
|
128
|
+
MessageWrapper: MessageWrapper,
|
|
129
|
+
isTranslated: isTranslated,
|
|
130
|
+
colorScheme: colorScheme,
|
|
131
|
+
withIcon: isInputDisabled,
|
|
132
|
+
withErrorSpotting: errorSpottingEnabled && !message.isOwnMessage,
|
|
133
|
+
highlightedWordIndex: messageHighlightIndex,
|
|
134
|
+
TTSHighlightRenderer: TTSHighlightRenderer,
|
|
135
|
+
isTextToSpeechEnabled: isTextToSpeechEnabled && !message.isOwnMessage,
|
|
136
|
+
isPlayingMessage: isPlayingMessage,
|
|
137
|
+
isTextToSpeechPending: isTextToSpeechPending,
|
|
138
|
+
audioStatus: audioStatus
|
|
139
|
+
});
|
|
140
|
+
}, [currentPlayingId, highlightedWordIndex, showBottomFade, lastBotMessageId, shouldWrapMessage, isTranslated, colorScheme, errorSpottingEnabled, isTextToSpeechEnabled, isTextToSpeechPending, audioStatus]);
|
|
141
|
+
if (!isOpen) return null;
|
|
142
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
38
143
|
style: [styles.container, {
|
|
39
144
|
maxHeight: MAX_HEIGHT
|
|
40
145
|
}],
|
|
41
|
-
children: /*#__PURE__*/
|
|
146
|
+
children: [/*#__PURE__*/_jsx(FlatList, {
|
|
42
147
|
ref: ref,
|
|
148
|
+
inverted: true,
|
|
43
149
|
bounces: false,
|
|
150
|
+
style: [styles.flatList, isScrollable && TOP_FADE_MASK],
|
|
151
|
+
data: reversedMessages,
|
|
152
|
+
keyExtractor: keyExtractor,
|
|
153
|
+
renderItem: renderMessage,
|
|
44
154
|
contentContainerStyle: styles.list,
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
},
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
isLoading: isTextToSpeechPending,
|
|
64
|
-
status: audioStatus,
|
|
65
|
-
disabled: isTextToSpeechPending
|
|
66
|
-
}
|
|
67
|
-
}, message.id)), isHelpRequestPending && /*#__PURE__*/_jsx(MessageLoader, {
|
|
68
|
-
colorScheme: colorScheme
|
|
69
|
-
})]
|
|
70
|
-
}), isOpen && /*#__PURE__*/_jsx(ChatInput, {
|
|
71
|
-
isHintFeedback: isHintFeedback,
|
|
72
|
-
colorScheme: colorScheme,
|
|
73
|
-
hasMessages: messages.length > 1
|
|
74
|
-
})]
|
|
75
|
-
})
|
|
155
|
+
onScroll: handleScroll,
|
|
156
|
+
scrollEventThrottle: 16,
|
|
157
|
+
onContentSizeChange: handleContentSizeChange,
|
|
158
|
+
ListHeaderComponent: /*#__PURE__*/_jsx(MessageLoader, {
|
|
159
|
+
isLoading: isHelpRequestPending
|
|
160
|
+
}),
|
|
161
|
+
ItemSeparatorComponent: Separator
|
|
162
|
+
}), /*#__PURE__*/_jsx(BottomFade, {
|
|
163
|
+
visible: showBottomFade
|
|
164
|
+
}), showAbsoluteIcon && /*#__PURE__*/_jsx(ChatIcon, {
|
|
165
|
+
isLoading: isHelpRequestPending
|
|
166
|
+
}), /*#__PURE__*/_jsx(ChatFooter, {
|
|
167
|
+
isHintFeedback: isHintFeedback,
|
|
168
|
+
isInputDisabled: isInputDisabled,
|
|
169
|
+
colorScheme: colorScheme,
|
|
170
|
+
hasMessages: messages.length > 1,
|
|
171
|
+
onPressClose: onPressClose
|
|
172
|
+
})]
|
|
76
173
|
});
|
|
77
174
|
};
|
|
175
|
+
const keyExtractor = (item, index) => `${item.id}-${index}`;
|
|
176
|
+
const MessageItem = ({
|
|
177
|
+
message,
|
|
178
|
+
showInlineIcon,
|
|
179
|
+
animate,
|
|
180
|
+
shouldWrapMessage,
|
|
181
|
+
MessageWrapper,
|
|
182
|
+
isTranslated,
|
|
183
|
+
colorScheme,
|
|
184
|
+
withIcon,
|
|
185
|
+
withErrorSpotting,
|
|
186
|
+
highlightedWordIndex,
|
|
187
|
+
TTSHighlightRenderer,
|
|
188
|
+
isTextToSpeechEnabled,
|
|
189
|
+
isPlayingMessage,
|
|
190
|
+
isTextToSpeechPending,
|
|
191
|
+
audioStatus
|
|
192
|
+
}) => /*#__PURE__*/_jsxs(View, {
|
|
193
|
+
style: [styles.messageItem, showInlineIcon && styles.messageWithIcon],
|
|
194
|
+
children: [showInlineIcon && /*#__PURE__*/_jsx(View, {
|
|
195
|
+
style: styles.inlineIcon,
|
|
196
|
+
children: /*#__PURE__*/_jsx(ChatbotIcon, {
|
|
197
|
+
width: 53,
|
|
198
|
+
height: 73
|
|
199
|
+
})
|
|
200
|
+
}), /*#__PURE__*/_jsx(AnimatedMessage, {
|
|
201
|
+
animate: animate,
|
|
202
|
+
children: /*#__PURE__*/_jsx(ConditionalWrapper, {
|
|
203
|
+
withWrapper: shouldWrapMessage,
|
|
204
|
+
Wrapper: MessageWrapper,
|
|
205
|
+
children: /*#__PURE__*/_jsx(ChatMessage, {
|
|
206
|
+
withIcon: withIcon,
|
|
207
|
+
isTranslated: isTranslated,
|
|
208
|
+
message: message,
|
|
209
|
+
variant: message.isOwnMessage ? MessageVariant.SENT : MessageVariant.RECEIVED,
|
|
210
|
+
colorScheme: colorScheme,
|
|
211
|
+
withErrorSpotting: withErrorSpotting,
|
|
212
|
+
highlightedWordIndex: highlightedWordIndex,
|
|
213
|
+
TTSHighlightRenderer: TTSHighlightRenderer,
|
|
214
|
+
t2sState: {
|
|
215
|
+
isEnabled: isTextToSpeechEnabled,
|
|
216
|
+
isActive: isPlayingMessage,
|
|
217
|
+
isLoading: isTextToSpeechPending,
|
|
218
|
+
status: audioStatus,
|
|
219
|
+
disabled: isTextToSpeechPending
|
|
220
|
+
}
|
|
221
|
+
})
|
|
222
|
+
})
|
|
223
|
+
})]
|
|
224
|
+
});
|
|
78
225
|
const styles = StyleSheet.create({
|
|
79
226
|
container: {
|
|
80
227
|
flex: 1,
|
|
81
228
|
alignItems: 'flex-end',
|
|
82
|
-
width:
|
|
83
|
-
height: '100%'
|
|
229
|
+
width: 374,
|
|
230
|
+
height: '100%',
|
|
231
|
+
paddingRight: SPACING['100']
|
|
232
|
+
},
|
|
233
|
+
flatList: {
|
|
234
|
+
alignSelf: 'stretch',
|
|
235
|
+
paddingTop: SPACING['300']
|
|
84
236
|
},
|
|
85
237
|
list: {
|
|
86
|
-
|
|
87
|
-
paddingVertical: 2,
|
|
88
|
-
paddingRight: 6
|
|
238
|
+
paddingVertical: 2
|
|
89
239
|
},
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
240
|
+
inputRow: {
|
|
241
|
+
flexDirection: 'row',
|
|
242
|
+
alignItems: 'center',
|
|
243
|
+
gap: SPACING['200'],
|
|
244
|
+
minHeight: 52
|
|
245
|
+
},
|
|
246
|
+
bottomFade: {
|
|
247
|
+
position: 'absolute',
|
|
248
|
+
bottom: 52,
|
|
249
|
+
right: 0,
|
|
250
|
+
width: 370,
|
|
251
|
+
height: 40,
|
|
252
|
+
transition: 'opacity 0.2s ease-in-out',
|
|
253
|
+
...Platform.select({
|
|
254
|
+
web: {
|
|
255
|
+
backgroundImage: 'linear-gradient(to top, rgba(255,255,255,1) 10%, rgba(255,255,255,0.8) 40%, transparent 100%)'
|
|
256
|
+
},
|
|
257
|
+
default: {}
|
|
258
|
+
})
|
|
259
|
+
},
|
|
260
|
+
iconAbsolute: {
|
|
261
|
+
position: 'absolute',
|
|
262
|
+
bottom: 65,
|
|
263
|
+
left: 4
|
|
264
|
+
},
|
|
265
|
+
messageItem: {
|
|
266
|
+
alignSelf: 'flex-end'
|
|
267
|
+
},
|
|
268
|
+
messageWithIcon: {
|
|
269
|
+
flexDirection: 'row',
|
|
270
|
+
alignItems: 'flex-end'
|
|
271
|
+
},
|
|
272
|
+
inlineIcon: {
|
|
273
|
+
marginRight: 8
|
|
274
|
+
},
|
|
275
|
+
separator: {
|
|
276
|
+
height: SPACING['200']
|
|
93
277
|
}
|
|
94
278
|
});
|
|
95
279
|
//# sourceMappingURL=Chat.js.map
|