@magmamath/students-features 0.6.0 → 0.6.1-2.rc-2
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/README.md +14 -5
- package/dist/commonjs/features/chatbot/components/Alternatives/Alternatives.js +6 -2
- package/dist/commonjs/features/chatbot/components/Alternatives/Alternatives.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/Alternatives/HelpRequestOption.js +27 -24
- package/dist/commonjs/features/chatbot/components/Alternatives/HelpRequestOption.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/ChatMessage.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageButtonsBlock.js +9 -4
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageButtonsBlock.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageContent.js +18 -5
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageContent.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageLoader.js +10 -3
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageLoader.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageTextToSpeech.js +16 -12
- package/dist/commonjs/features/chatbot/components/ChatMessage/MessageTextToSpeech.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.js +13 -4
- package/dist/commonjs/features/chatbot/components/ChatMessage/ReceivedMessage.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessage/SentMessage.js +14 -8
- package/dist/commonjs/features/chatbot/components/ChatMessage/SentMessage.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ChatMessages/ChatbotMessages.js +14 -4
- package/dist/commonjs/features/chatbot/components/ChatMessages/ChatbotMessages.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/Chatbot.js +5 -2
- package/dist/commonjs/features/chatbot/components/Chatbot.js.map +1 -1
- package/dist/commonjs/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.js +2 -1
- package/dist/commonjs/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.js.map +1 -1
- package/dist/commonjs/features/chatbot/constants.js +36 -1
- package/dist/commonjs/features/chatbot/constants.js.map +1 -1
- package/dist/commonjs/features/chatbot/errorSpotting/ErrorSpottingModel.js +8 -0
- package/dist/commonjs/features/chatbot/errorSpotting/ErrorSpottingModel.js.map +1 -1
- package/dist/commonjs/features/chatbot/index.js +7 -0
- package/dist/commonjs/features/chatbot/index.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatBotModel.js +67 -39
- package/dist/commonjs/features/chatbot/model/ChatBotModel.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatBotThreadManager.js +3 -8
- package/dist/commonjs/features/chatbot/model/ChatBotThreadManager.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/ChatBoxTextManager.js +12 -1
- package/dist/commonjs/features/chatbot/model/ChatBoxTextManager.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/DefaultMessageCreator.js +4 -2
- package/dist/commonjs/features/chatbot/model/DefaultMessageCreator.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/constants.js.map +1 -1
- package/dist/commonjs/features/chatbot/model/translation.js +9 -1
- package/dist/commonjs/features/chatbot/model/translation.js.map +1 -1
- package/dist/commonjs/features/chatbot/types/model.types.js.map +1 -1
- package/dist/commonjs/features/chatbot/types/style.types.js +12 -0
- package/dist/commonjs/features/chatbot/types/style.types.js.map +1 -0
- package/dist/commonjs/features/endOfAssignment/components/Modal/Modal.js +2 -0
- package/dist/commonjs/features/endOfAssignment/components/Modal/Modal.js.map +1 -1
- package/dist/commonjs/features/exampleSolution/ExampleSolutionModal.js +31 -0
- package/dist/commonjs/features/exampleSolution/ExampleSolutionModal.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/assets/grid.png +0 -0
- package/dist/commonjs/features/exampleSolution/components/ExampleSolutionModalContent.js +97 -0
- package/dist/commonjs/features/exampleSolution/components/ExampleSolutionModalContent.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/components/LavaIcon.js +43 -0
- package/dist/commonjs/features/exampleSolution/components/LavaIcon.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/components/MessageBlock.js +61 -0
- package/dist/commonjs/features/exampleSolution/components/MessageBlock.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/components/QuestionSection.js +68 -0
- package/dist/commonjs/features/exampleSolution/components/QuestionSection.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/components/SolutionSection.js +75 -0
- package/dist/commonjs/features/exampleSolution/components/SolutionSection.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/components/index.js +2 -0
- package/dist/commonjs/features/exampleSolution/components/index.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/constants.js +13 -0
- package/dist/commonjs/features/exampleSolution/constants.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/hooks/useExampleSolution.js +54 -0
- package/dist/commonjs/features/exampleSolution/hooks/useExampleSolution.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/index.js +39 -0
- package/dist/commonjs/features/exampleSolution/index.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/model/ExampleSolution.model.js +22 -0
- package/dist/commonjs/features/exampleSolution/model/ExampleSolution.model.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/model/ExampleSolutionApi.js +24 -0
- package/dist/commonjs/features/exampleSolution/model/ExampleSolutionApi.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/model/ExampleSolutionCache.js +19 -0
- package/dist/commonjs/features/exampleSolution/model/ExampleSolutionCache.js.map +1 -0
- package/dist/commonjs/features/exampleSolution/types.js +6 -0
- package/dist/commonjs/features/exampleSolution/types.js.map +1 -0
- package/dist/commonjs/features/feedback/model/comments.js +5 -3
- package/dist/commonjs/features/feedback/model/comments.js.map +1 -1
- package/dist/commonjs/features/feedback/model/model.js +7 -9
- package/dist/commonjs/features/feedback/model/model.js.map +1 -1
- package/dist/commonjs/features/gifCelebrations/GifCelebrations.js +62 -0
- package/dist/commonjs/features/gifCelebrations/GifCelebrations.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/assets/confetti.webp +0 -0
- package/dist/commonjs/features/gifCelebrations/assets/gifFallback.gif +0 -0
- package/dist/commonjs/features/gifCelebrations/components/Backdrop.js +44 -0
- package/dist/commonjs/features/gifCelebrations/components/Backdrop.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/components/ContentContainer.js +46 -0
- package/dist/commonjs/features/gifCelebrations/components/ContentContainer.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/components/Gif.js +90 -0
- package/dist/commonjs/features/gifCelebrations/components/Gif.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/components/Progress.js +96 -0
- package/dist/commonjs/features/gifCelebrations/components/Progress.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/constants.js +34 -0
- package/dist/commonjs/features/gifCelebrations/constants.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/helpers.js +114 -0
- package/dist/commonjs/features/gifCelebrations/helpers.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/index.js +20 -0
- package/dist/commonjs/features/gifCelebrations/index.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/model/GifCelebrations.model.js +136 -0
- package/dist/commonjs/features/gifCelebrations/model/GifCelebrations.model.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/model/GifCelebrationsApi.js +27 -0
- package/dist/commonjs/features/gifCelebrations/model/GifCelebrationsApi.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/model/GifCelebrationsCache.js +30 -0
- package/dist/commonjs/features/gifCelebrations/model/GifCelebrationsCache.js.map +1 -0
- package/dist/commonjs/features/gifCelebrations/types/model.types.js +6 -0
- package/dist/commonjs/features/gifCelebrations/types/model.types.js.map +1 -0
- package/dist/commonjs/features/problemSelector/components/ProblemSelectorButton.js +12 -9
- package/dist/commonjs/features/problemSelector/components/ProblemSelectorButton.js.map +1 -1
- package/dist/commonjs/features/problemSelector/constants.js +3 -6
- package/dist/commonjs/features/problemSelector/constants.js.map +1 -1
- package/dist/commonjs/index.js +36 -0
- package/dist/commonjs/index.js.map +1 -1
- package/dist/commonjs/lib/effector/ControlledSample.js +40 -0
- package/dist/commonjs/lib/effector/ControlledSample.js.map +1 -0
- package/dist/commonjs/lib/effector/createControllerEffect.js.map +1 -1
- package/dist/commonjs/lib/helpers/helpers.js.map +1 -1
- package/dist/commonjs/react-app-env.d.js +2 -0
- package/dist/commonjs/react-app-env.d.js.map +1 -0
- package/dist/commonjs/shared/icons/ExcitedLavaIcon.js +681 -0
- package/dist/commonjs/shared/icons/ExcitedLavaIcon.js.map +1 -0
- package/dist/commonjs/shared/icons/LavaIconInGlasses.js +616 -0
- package/dist/commonjs/shared/icons/LavaIconInGlasses.js.map +1 -0
- package/dist/commonjs/shared/icons/index.js +204 -0
- package/dist/commonjs/shared/icons/index.js.map +1 -0
- package/dist/commonjs/shared/translation/constants.js +5 -1
- package/dist/commonjs/shared/translation/constants.js.map +1 -1
- package/dist/commonjs/shared/translation/localization/ca.json +33 -0
- package/dist/commonjs/shared/translation/localization/en.json +13 -1
- package/dist/commonjs/shared/translation/localization/gb.json +13 -1
- package/dist/commonjs/shared/translation/localization/sct.json +33 -0
- package/dist/commonjs/shared/translation/localization/sw.json +13 -1
- package/dist/commonjs/shared/translation/types.js +2 -0
- package/dist/commonjs/shared/translation/types.js.map +1 -1
- package/dist/commonjs/types/common.types.js +2 -0
- package/dist/commonjs/types/common.types.js.map +1 -0
- package/dist/module/features/chatbot/components/Alternatives/Alternatives.js +6 -2
- package/dist/module/features/chatbot/components/Alternatives/Alternatives.js.map +1 -1
- package/dist/module/features/chatbot/components/Alternatives/HelpRequestOption.js +29 -27
- package/dist/module/features/chatbot/components/Alternatives/HelpRequestOption.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/ChatMessage.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/MessageButtonsBlock.js +9 -4
- package/dist/module/features/chatbot/components/ChatMessage/MessageButtonsBlock.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/MessageContent.js +18 -5
- package/dist/module/features/chatbot/components/ChatMessage/MessageContent.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/MessageLoader.js +10 -3
- package/dist/module/features/chatbot/components/ChatMessage/MessageLoader.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/MessageTextToSpeech.js +16 -12
- package/dist/module/features/chatbot/components/ChatMessage/MessageTextToSpeech.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/ReceivedMessage.js +13 -4
- package/dist/module/features/chatbot/components/ChatMessage/ReceivedMessage.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessage/SentMessage.js +14 -8
- package/dist/module/features/chatbot/components/ChatMessage/SentMessage.js.map +1 -1
- package/dist/module/features/chatbot/components/ChatMessages/ChatbotMessages.js +14 -4
- package/dist/module/features/chatbot/components/ChatMessages/ChatbotMessages.js.map +1 -1
- package/dist/module/features/chatbot/components/Chatbot.js +5 -2
- package/dist/module/features/chatbot/components/Chatbot.js.map +1 -1
- package/dist/module/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.js +3 -3
- package/dist/module/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.js.map +1 -1
- package/dist/module/features/chatbot/constants.js +35 -0
- package/dist/module/features/chatbot/constants.js.map +1 -1
- package/dist/module/features/chatbot/errorSpotting/ErrorSpottingModel.js +9 -1
- package/dist/module/features/chatbot/errorSpotting/ErrorSpottingModel.js.map +1 -1
- package/dist/module/features/chatbot/index.js +1 -0
- package/dist/module/features/chatbot/index.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatBotModel.js +68 -40
- package/dist/module/features/chatbot/model/ChatBotModel.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatBotThreadManager.js +3 -8
- package/dist/module/features/chatbot/model/ChatBotThreadManager.js.map +1 -1
- package/dist/module/features/chatbot/model/ChatBoxTextManager.js +12 -1
- package/dist/module/features/chatbot/model/ChatBoxTextManager.js.map +1 -1
- package/dist/module/features/chatbot/model/DefaultMessageCreator.js +4 -2
- package/dist/module/features/chatbot/model/DefaultMessageCreator.js.map +1 -1
- package/dist/module/features/chatbot/model/constants.js.map +1 -1
- package/dist/module/features/chatbot/model/translation.js +9 -1
- package/dist/module/features/chatbot/model/translation.js.map +1 -1
- package/dist/module/features/chatbot/types/model.types.js.map +1 -1
- package/dist/module/features/chatbot/types/style.types.js +8 -0
- package/dist/module/features/chatbot/types/style.types.js.map +1 -0
- package/dist/module/features/endOfAssignment/components/Modal/Modal.js +3 -1
- package/dist/module/features/endOfAssignment/components/Modal/Modal.js.map +1 -1
- package/dist/module/features/exampleSolution/ExampleSolutionModal.js +25 -0
- package/dist/module/features/exampleSolution/ExampleSolutionModal.js.map +1 -0
- package/dist/module/features/exampleSolution/assets/grid.png +0 -0
- package/dist/module/features/exampleSolution/components/ExampleSolutionModalContent.js +91 -0
- package/dist/module/features/exampleSolution/components/ExampleSolutionModalContent.js.map +1 -0
- package/dist/module/features/exampleSolution/components/LavaIcon.js +35 -0
- package/dist/module/features/exampleSolution/components/LavaIcon.js.map +1 -0
- package/dist/module/features/exampleSolution/components/MessageBlock.js +53 -0
- package/dist/module/features/exampleSolution/components/MessageBlock.js.map +1 -0
- package/dist/module/features/exampleSolution/components/QuestionSection.js +60 -0
- package/dist/module/features/exampleSolution/components/QuestionSection.js.map +1 -0
- package/dist/module/features/exampleSolution/components/SolutionSection.js +67 -0
- package/dist/module/features/exampleSolution/components/SolutionSection.js.map +1 -0
- package/dist/module/features/exampleSolution/components/index.js +2 -0
- package/dist/module/features/exampleSolution/components/index.js.map +1 -0
- package/dist/module/features/exampleSolution/constants.js +9 -0
- package/dist/module/features/exampleSolution/constants.js.map +1 -0
- package/dist/module/features/exampleSolution/hooks/useExampleSolution.js +49 -0
- package/dist/module/features/exampleSolution/hooks/useExampleSolution.js.map +1 -0
- package/dist/module/features/exampleSolution/index.js +6 -0
- package/dist/module/features/exampleSolution/index.js.map +1 -0
- package/dist/module/features/exampleSolution/model/ExampleSolution.model.js +17 -0
- package/dist/module/features/exampleSolution/model/ExampleSolution.model.js.map +1 -0
- package/dist/module/features/exampleSolution/model/ExampleSolutionApi.js +19 -0
- package/dist/module/features/exampleSolution/model/ExampleSolutionApi.js.map +1 -0
- package/dist/module/features/exampleSolution/model/ExampleSolutionCache.js +14 -0
- package/dist/module/features/exampleSolution/model/ExampleSolutionCache.js.map +1 -0
- package/dist/module/features/exampleSolution/types.js +4 -0
- package/dist/module/features/exampleSolution/types.js.map +1 -0
- package/dist/module/features/feedback/model/comments.js +5 -3
- package/dist/module/features/feedback/model/comments.js.map +1 -1
- package/dist/module/features/feedback/model/model.js +7 -9
- package/dist/module/features/feedback/model/model.js.map +1 -1
- package/dist/module/features/gifCelebrations/GifCelebrations.js +55 -0
- package/dist/module/features/gifCelebrations/GifCelebrations.js.map +1 -0
- package/dist/module/features/gifCelebrations/assets/confetti.webp +0 -0
- package/dist/module/features/gifCelebrations/assets/gifFallback.gif +0 -0
- package/dist/module/features/gifCelebrations/components/Backdrop.js +36 -0
- package/dist/module/features/gifCelebrations/components/Backdrop.js.map +1 -0
- package/dist/module/features/gifCelebrations/components/ContentContainer.js +38 -0
- package/dist/module/features/gifCelebrations/components/ContentContainer.js.map +1 -0
- package/dist/module/features/gifCelebrations/components/Gif.js +82 -0
- package/dist/module/features/gifCelebrations/components/Gif.js.map +1 -0
- package/dist/module/features/gifCelebrations/components/Progress.js +88 -0
- package/dist/module/features/gifCelebrations/components/Progress.js.map +1 -0
- package/dist/module/features/gifCelebrations/constants.js +30 -0
- package/dist/module/features/gifCelebrations/constants.js.map +1 -0
- package/dist/module/features/gifCelebrations/helpers.js +103 -0
- package/dist/module/features/gifCelebrations/helpers.js.map +1 -0
- package/dist/module/features/gifCelebrations/index.js +5 -0
- package/dist/module/features/gifCelebrations/index.js.map +1 -0
- package/dist/module/features/gifCelebrations/model/GifCelebrations.model.js +131 -0
- package/dist/module/features/gifCelebrations/model/GifCelebrations.model.js.map +1 -0
- package/dist/module/features/gifCelebrations/model/GifCelebrationsApi.js +22 -0
- package/dist/module/features/gifCelebrations/model/GifCelebrationsApi.js.map +1 -0
- package/dist/module/features/gifCelebrations/model/GifCelebrationsCache.js +25 -0
- package/dist/module/features/gifCelebrations/model/GifCelebrationsCache.js.map +1 -0
- package/dist/module/features/gifCelebrations/types/model.types.js +4 -0
- package/dist/module/features/gifCelebrations/types/model.types.js.map +1 -0
- package/dist/module/features/problemSelector/components/ProblemSelectorButton.js +13 -10
- package/dist/module/features/problemSelector/components/ProblemSelectorButton.js.map +1 -1
- package/dist/module/features/problemSelector/constants.js +2 -5
- package/dist/module/features/problemSelector/constants.js.map +1 -1
- package/dist/module/index.js +3 -0
- package/dist/module/index.js.map +1 -1
- package/dist/module/lib/effector/ControlledSample.js +35 -0
- package/dist/module/lib/effector/ControlledSample.js.map +1 -0
- package/dist/module/lib/effector/createControllerEffect.js.map +1 -1
- package/dist/module/react-app-env.d.js +2 -0
- package/dist/module/react-app-env.d.js.map +1 -0
- package/dist/module/shared/icons/ExcitedLavaIcon.js +673 -0
- package/dist/module/shared/icons/ExcitedLavaIcon.js.map +1 -0
- package/dist/module/shared/icons/LavaIconInGlasses.js +608 -0
- package/dist/module/shared/icons/LavaIconInGlasses.js.map +1 -0
- package/dist/module/shared/icons/index.js +21 -0
- package/dist/module/shared/icons/index.js.map +1 -0
- package/dist/module/shared/translation/constants.js +5 -1
- package/dist/module/shared/translation/constants.js.map +1 -1
- package/dist/module/shared/translation/localization/ca.json +33 -0
- package/dist/module/shared/translation/localization/en.json +13 -1
- package/dist/module/shared/translation/localization/gb.json +13 -1
- package/dist/module/shared/translation/localization/sct.json +33 -0
- package/dist/module/shared/translation/localization/sw.json +13 -1
- package/dist/module/shared/translation/types.js +2 -0
- package/dist/module/shared/translation/types.js.map +1 -1
- package/dist/module/types/common.types.js +2 -0
- package/dist/module/types/common.types.js.map +1 -0
- package/dist/typescript/commonjs/features/chatbot/components/Alternatives/Alternatives.d.ts +3 -1
- package/dist/typescript/commonjs/features/chatbot/components/Alternatives/Alternatives.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/Alternatives/HelpRequestOption.d.ts +2 -1
- package/dist/typescript/commonjs/features/chatbot/components/Alternatives/HelpRequestOption.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ChatMessage.d.ts +5 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/ChatMessage.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageButtonsBlock.d.ts +6 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageButtonsBlock.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageContent.d.ts +7 -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 +6 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageLoader.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageTextToSpeech.d.ts +5 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/MessageTextToSpeech.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/ChatMessage/SentMessage.d.ts +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessage/SentMessage.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessages/ChatbotMessages.d.ts +3 -1
- package/dist/typescript/commonjs/features/chatbot/components/ChatMessages/ChatbotMessages.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/Chatbot.d.ts +4 -3
- package/dist/typescript/commonjs/features/chatbot/components/Chatbot.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/constants.d.ts +33 -0
- package/dist/typescript/commonjs/features/chatbot/constants.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/errorSpotting/ErrorSpottingModel.d.ts +4 -0
- package/dist/typescript/commonjs/features/chatbot/errorSpotting/ErrorSpottingModel.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/index.d.ts +1 -0
- package/dist/typescript/commonjs/features/chatbot/index.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/ChatBotModel.d.ts +7 -2
- package/dist/typescript/commonjs/features/chatbot/model/ChatBotModel.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/ChatBotThreadManager.d.ts +1 -3
- package/dist/typescript/commonjs/features/chatbot/model/ChatBotThreadManager.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/ChatBoxTextManager.d.ts +5 -0
- package/dist/typescript/commonjs/features/chatbot/model/ChatBoxTextManager.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/DefaultMessageCreator.d.ts +2 -1
- package/dist/typescript/commonjs/features/chatbot/model/DefaultMessageCreator.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/constants.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/model/translation.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/types/model.types.d.ts +5 -2
- package/dist/typescript/commonjs/features/chatbot/types/model.types.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/chatbot/types/style.types.d.ts +5 -0
- package/dist/typescript/commonjs/features/chatbot/types/style.types.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/endOfAssignment/components/Modal/Modal.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/exampleSolution/ExampleSolutionModal.d.ts +11 -0
- package/dist/typescript/commonjs/features/exampleSolution/ExampleSolutionModal.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/ExampleSolutionModalContent.d.ts +11 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/ExampleSolutionModalContent.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/LavaIcon.d.ts +10 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/LavaIcon.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/MessageBlock.d.ts +10 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/MessageBlock.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/QuestionSection.d.ts +9 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/QuestionSection.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/SolutionSection.d.ts +9 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/SolutionSection.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/index.d.ts +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/components/index.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/constants.d.ts +6 -0
- package/dist/typescript/commonjs/features/exampleSolution/constants.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/hooks/useExampleSolution.d.ts +15 -0
- package/dist/typescript/commonjs/features/exampleSolution/hooks/useExampleSolution.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/index.d.ts +4 -0
- package/dist/typescript/commonjs/features/exampleSolution/index.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/model/ExampleSolution.model.d.ts +9 -0
- package/dist/typescript/commonjs/features/exampleSolution/model/ExampleSolution.model.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/model/ExampleSolutionApi.d.ts +11 -0
- package/dist/typescript/commonjs/features/exampleSolution/model/ExampleSolutionApi.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/model/ExampleSolutionCache.d.ts +12 -0
- package/dist/typescript/commonjs/features/exampleSolution/model/ExampleSolutionCache.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/exampleSolution/types.d.ts +25 -0
- package/dist/typescript/commonjs/features/exampleSolution/types.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/GifCelebrations.d.ts +10 -0
- package/dist/typescript/commonjs/features/gifCelebrations/GifCelebrations.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/components/Backdrop.d.ts +10 -0
- package/dist/typescript/commonjs/features/gifCelebrations/components/Backdrop.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/components/ContentContainer.d.ts +10 -0
- package/dist/typescript/commonjs/features/gifCelebrations/components/ContentContainer.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/components/Gif.d.ts +10 -0
- package/dist/typescript/commonjs/features/gifCelebrations/components/Gif.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/components/Progress.d.ts +10 -0
- package/dist/typescript/commonjs/features/gifCelebrations/components/Progress.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/constants.d.ts +26 -0
- package/dist/typescript/commonjs/features/gifCelebrations/constants.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/helpers.d.ts +29 -0
- package/dist/typescript/commonjs/features/gifCelebrations/helpers.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/index.d.ts +3 -0
- package/dist/typescript/commonjs/features/gifCelebrations/index.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/model/GifCelebrations.model.d.ts +25 -0
- package/dist/typescript/commonjs/features/gifCelebrations/model/GifCelebrations.model.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/model/GifCelebrationsApi.d.ts +7 -0
- package/dist/typescript/commonjs/features/gifCelebrations/model/GifCelebrationsApi.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/model/GifCelebrationsCache.d.ts +18 -0
- package/dist/typescript/commonjs/features/gifCelebrations/model/GifCelebrationsCache.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/gifCelebrations/types/model.types.d.ts +45 -0
- package/dist/typescript/commonjs/features/gifCelebrations/types/model.types.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/problemSelector/components/ProblemSelectorButton.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/problemSelector/constants.d.ts +2 -5
- package/dist/typescript/commonjs/features/problemSelector/constants.d.ts.map +1 -1
- package/dist/typescript/commonjs/index.d.ts +3 -0
- package/dist/typescript/commonjs/index.d.ts.map +1 -1
- package/dist/typescript/commonjs/lib/effector/ControlledSample.d.ts +17 -0
- package/dist/typescript/commonjs/lib/effector/ControlledSample.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/lib/helpers/helpers.d.ts.map +1 -1
- package/dist/typescript/commonjs/shared/icons/ExcitedLavaIcon.d.ts +4 -0
- package/dist/typescript/commonjs/shared/icons/ExcitedLavaIcon.d.ts.map +1 -0
- package/dist/typescript/commonjs/shared/icons/LavaIconInGlasses.d.ts +4 -0
- package/dist/typescript/commonjs/shared/icons/LavaIconInGlasses.d.ts.map +1 -0
- package/dist/typescript/commonjs/shared/icons/index.d.ts +19 -0
- package/dist/typescript/commonjs/shared/icons/index.d.ts.map +1 -0
- package/dist/typescript/commonjs/shared/translation/constants.d.ts +102 -0
- package/dist/typescript/commonjs/shared/translation/constants.d.ts.map +1 -1
- package/dist/typescript/commonjs/shared/translation/model.d.ts +24 -0
- package/dist/typescript/commonjs/shared/translation/model.d.ts.map +1 -1
- package/dist/typescript/commonjs/shared/translation/types.d.ts +3 -1
- package/dist/typescript/commonjs/shared/translation/types.d.ts.map +1 -1
- package/dist/typescript/commonjs/shared/translation/validation.types.d.ts +5 -1
- package/dist/typescript/commonjs/shared/translation/validation.types.d.ts.map +1 -1
- package/dist/typescript/commonjs/types/common.types.d.ts +5 -0
- package/dist/typescript/commonjs/types/common.types.d.ts.map +1 -0
- package/dist/typescript/module/features/chatbot/components/Alternatives/Alternatives.d.ts +3 -1
- package/dist/typescript/module/features/chatbot/components/Alternatives/Alternatives.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/Alternatives/HelpRequestOption.d.ts +2 -1
- package/dist/typescript/module/features/chatbot/components/Alternatives/HelpRequestOption.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/ChatMessage.d.ts +5 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/ChatMessage.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageButtonsBlock.d.ts +6 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageButtonsBlock.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageContent.d.ts +7 -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 +6 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageLoader.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageTextToSpeech.d.ts +5 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/MessageTextToSpeech.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/ChatMessage/SentMessage.d.ts +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessage/SentMessage.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessages/ChatbotMessages.d.ts +3 -1
- package/dist/typescript/module/features/chatbot/components/ChatMessages/ChatbotMessages.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/Chatbot.d.ts +4 -3
- package/dist/typescript/module/features/chatbot/components/Chatbot.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/constants.d.ts +33 -0
- package/dist/typescript/module/features/chatbot/constants.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/errorSpotting/ErrorSpottingModel.d.ts +4 -0
- package/dist/typescript/module/features/chatbot/errorSpotting/ErrorSpottingModel.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/index.d.ts +1 -0
- package/dist/typescript/module/features/chatbot/index.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/ChatBotModel.d.ts +7 -2
- package/dist/typescript/module/features/chatbot/model/ChatBotModel.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/ChatBotThreadManager.d.ts +1 -3
- package/dist/typescript/module/features/chatbot/model/ChatBotThreadManager.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/ChatBoxTextManager.d.ts +5 -0
- package/dist/typescript/module/features/chatbot/model/ChatBoxTextManager.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/DefaultMessageCreator.d.ts +2 -1
- package/dist/typescript/module/features/chatbot/model/DefaultMessageCreator.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/constants.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/model/translation.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/types/model.types.d.ts +5 -2
- package/dist/typescript/module/features/chatbot/types/model.types.d.ts.map +1 -1
- package/dist/typescript/module/features/chatbot/types/style.types.d.ts +5 -0
- package/dist/typescript/module/features/chatbot/types/style.types.d.ts.map +1 -0
- package/dist/typescript/module/features/endOfAssignment/components/Modal/Modal.d.ts.map +1 -1
- package/dist/typescript/module/features/exampleSolution/ExampleSolutionModal.d.ts +11 -0
- package/dist/typescript/module/features/exampleSolution/ExampleSolutionModal.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/components/ExampleSolutionModalContent.d.ts +11 -0
- package/dist/typescript/module/features/exampleSolution/components/ExampleSolutionModalContent.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/components/LavaIcon.d.ts +10 -0
- package/dist/typescript/module/features/exampleSolution/components/LavaIcon.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/components/MessageBlock.d.ts +10 -0
- package/dist/typescript/module/features/exampleSolution/components/MessageBlock.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/components/QuestionSection.d.ts +9 -0
- package/dist/typescript/module/features/exampleSolution/components/QuestionSection.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/components/SolutionSection.d.ts +9 -0
- package/dist/typescript/module/features/exampleSolution/components/SolutionSection.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/components/index.d.ts +1 -0
- package/dist/typescript/module/features/exampleSolution/components/index.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/constants.d.ts +6 -0
- package/dist/typescript/module/features/exampleSolution/constants.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/hooks/useExampleSolution.d.ts +15 -0
- package/dist/typescript/module/features/exampleSolution/hooks/useExampleSolution.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/index.d.ts +4 -0
- package/dist/typescript/module/features/exampleSolution/index.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/model/ExampleSolution.model.d.ts +9 -0
- package/dist/typescript/module/features/exampleSolution/model/ExampleSolution.model.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/model/ExampleSolutionApi.d.ts +11 -0
- package/dist/typescript/module/features/exampleSolution/model/ExampleSolutionApi.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/model/ExampleSolutionCache.d.ts +12 -0
- package/dist/typescript/module/features/exampleSolution/model/ExampleSolutionCache.d.ts.map +1 -0
- package/dist/typescript/module/features/exampleSolution/types.d.ts +25 -0
- package/dist/typescript/module/features/exampleSolution/types.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/GifCelebrations.d.ts +10 -0
- package/dist/typescript/module/features/gifCelebrations/GifCelebrations.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/components/Backdrop.d.ts +10 -0
- package/dist/typescript/module/features/gifCelebrations/components/Backdrop.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/components/ContentContainer.d.ts +10 -0
- package/dist/typescript/module/features/gifCelebrations/components/ContentContainer.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/components/Gif.d.ts +10 -0
- package/dist/typescript/module/features/gifCelebrations/components/Gif.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/components/Progress.d.ts +10 -0
- package/dist/typescript/module/features/gifCelebrations/components/Progress.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/constants.d.ts +26 -0
- package/dist/typescript/module/features/gifCelebrations/constants.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/helpers.d.ts +29 -0
- package/dist/typescript/module/features/gifCelebrations/helpers.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/index.d.ts +3 -0
- package/dist/typescript/module/features/gifCelebrations/index.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/model/GifCelebrations.model.d.ts +25 -0
- package/dist/typescript/module/features/gifCelebrations/model/GifCelebrations.model.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/model/GifCelebrationsApi.d.ts +7 -0
- package/dist/typescript/module/features/gifCelebrations/model/GifCelebrationsApi.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/model/GifCelebrationsCache.d.ts +18 -0
- package/dist/typescript/module/features/gifCelebrations/model/GifCelebrationsCache.d.ts.map +1 -0
- package/dist/typescript/module/features/gifCelebrations/types/model.types.d.ts +45 -0
- package/dist/typescript/module/features/gifCelebrations/types/model.types.d.ts.map +1 -0
- package/dist/typescript/module/features/problemSelector/components/ProblemSelectorButton.d.ts.map +1 -1
- package/dist/typescript/module/features/problemSelector/constants.d.ts +2 -5
- package/dist/typescript/module/features/problemSelector/constants.d.ts.map +1 -1
- package/dist/typescript/module/index.d.ts +3 -0
- package/dist/typescript/module/index.d.ts.map +1 -1
- package/dist/typescript/module/lib/effector/ControlledSample.d.ts +17 -0
- package/dist/typescript/module/lib/effector/ControlledSample.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/lib/helpers/helpers.d.ts.map +1 -1
- package/dist/typescript/module/shared/icons/ExcitedLavaIcon.d.ts +4 -0
- package/dist/typescript/module/shared/icons/ExcitedLavaIcon.d.ts.map +1 -0
- package/dist/typescript/module/shared/icons/LavaIconInGlasses.d.ts +4 -0
- package/dist/typescript/module/shared/icons/LavaIconInGlasses.d.ts.map +1 -0
- package/dist/typescript/module/shared/icons/index.d.ts +19 -0
- package/dist/typescript/module/shared/icons/index.d.ts.map +1 -0
- package/dist/typescript/module/shared/translation/constants.d.ts +102 -0
- package/dist/typescript/module/shared/translation/constants.d.ts.map +1 -1
- package/dist/typescript/module/shared/translation/model.d.ts +24 -0
- package/dist/typescript/module/shared/translation/model.d.ts.map +1 -1
- package/dist/typescript/module/shared/translation/types.d.ts +3 -1
- package/dist/typescript/module/shared/translation/types.d.ts.map +1 -1
- package/dist/typescript/module/shared/translation/validation.types.d.ts +5 -1
- package/dist/typescript/module/shared/translation/validation.types.d.ts.map +1 -1
- package/dist/typescript/module/types/common.types.d.ts +5 -0
- package/dist/typescript/module/types/common.types.d.ts.map +1 -0
- package/package.json +11 -7
- package/src/features/chatbot/components/Alternatives/Alternatives.tsx +6 -0
- package/src/features/chatbot/components/Alternatives/HelpRequestOption.tsx +28 -29
- package/src/features/chatbot/components/ChatMessage/ChatMessage.tsx +6 -1
- package/src/features/chatbot/components/ChatMessage/MessageButtonsBlock.tsx +24 -4
- package/src/features/chatbot/components/ChatMessage/MessageContent.tsx +39 -6
- package/src/features/chatbot/components/ChatMessage/MessageLoader.tsx +11 -3
- package/src/features/chatbot/components/ChatMessage/MessageTextToSpeech.tsx +28 -7
- package/src/features/chatbot/components/ChatMessage/ReceivedMessage.tsx +25 -5
- package/src/features/chatbot/components/ChatMessage/SentMessage.tsx +24 -13
- package/src/features/chatbot/components/ChatMessages/ChatbotMessages.tsx +13 -3
- package/src/features/chatbot/components/Chatbot.tsx +6 -2
- package/src/features/chatbot/components/ThreeDotsLoader/ThreeDotsLoader.tsx +7 -10
- package/src/features/chatbot/constants.ts +37 -0
- package/src/features/chatbot/errorSpotting/ErrorSpottingModel.ts +11 -1
- package/src/features/chatbot/index.ts +1 -0
- package/src/features/chatbot/model/ChatBotModel.ts +66 -42
- package/src/features/chatbot/model/ChatBotThreadManager.ts +4 -10
- package/src/features/chatbot/model/ChatBoxTextManager.ts +14 -1
- package/src/features/chatbot/model/DefaultMessageCreator.ts +4 -2
- package/src/features/chatbot/model/constants.ts +0 -2
- package/src/features/chatbot/model/translation.ts +11 -1
- package/src/features/chatbot/types/model.types.ts +5 -2
- package/src/features/chatbot/types/style.types.ts +4 -0
- package/src/features/endOfAssignment/components/Modal/Modal.tsx +3 -0
- package/src/features/exampleSolution/ExampleSolutionModal.tsx +29 -0
- package/src/features/exampleSolution/assets/grid.png +0 -0
- package/src/features/exampleSolution/components/ExampleSolutionModalContent.tsx +78 -0
- package/src/features/exampleSolution/components/LavaIcon.tsx +33 -0
- package/src/features/exampleSolution/components/MessageBlock.tsx +67 -0
- package/src/features/exampleSolution/components/QuestionSection.tsx +56 -0
- package/src/features/exampleSolution/components/SolutionSection.tsx +69 -0
- package/src/features/exampleSolution/components/index.ts +0 -0
- package/src/features/exampleSolution/constants.ts +5 -0
- package/src/features/exampleSolution/hooks/useExampleSolution.ts +64 -0
- package/src/features/exampleSolution/index.ts +3 -0
- package/src/features/exampleSolution/model/ExampleSolution.model.ts +12 -0
- package/src/features/exampleSolution/model/ExampleSolutionApi.ts +23 -0
- package/src/features/exampleSolution/model/ExampleSolutionCache.ts +20 -0
- package/src/features/exampleSolution/types.ts +25 -0
- package/src/features/feedback/model/comments.ts +7 -7
- package/src/features/feedback/model/model.ts +6 -6
- package/src/features/gifCelebrations/GifCelebrations.tsx +75 -0
- package/src/features/gifCelebrations/assets/confetti.webp +0 -0
- package/src/features/gifCelebrations/assets/gifFallback.gif +0 -0
- package/src/features/gifCelebrations/components/Backdrop.tsx +41 -0
- package/src/features/gifCelebrations/components/ContentContainer.tsx +44 -0
- package/src/features/gifCelebrations/components/Gif.tsx +88 -0
- package/src/features/gifCelebrations/components/Progress.tsx +106 -0
- package/src/features/gifCelebrations/constants.ts +32 -0
- package/src/features/gifCelebrations/helpers.ts +144 -0
- package/src/features/gifCelebrations/index.ts +2 -0
- package/src/features/gifCelebrations/model/GifCelebrations.model.ts +167 -0
- package/src/features/gifCelebrations/model/GifCelebrationsApi.ts +26 -0
- package/src/features/gifCelebrations/model/GifCelebrationsCache.ts +41 -0
- package/src/features/gifCelebrations/types/model.types.ts +53 -0
- package/src/features/problemSelector/components/ProblemSelectorButton.tsx +17 -10
- package/src/features/problemSelector/constants.ts +3 -2
- package/src/index.ts +3 -0
- package/src/lib/effector/ControlledSample.ts +40 -0
- package/src/lib/effector/createControllerEffect.ts +41 -41
- package/src/lib/helpers/helpers.ts +1 -1
- package/src/react-app-env.d.ts +6 -0
- package/src/shared/icons/ExcitedLavaIcon.tsx +541 -0
- package/src/shared/icons/LavaIconInGlasses.tsx +489 -0
- package/src/shared/icons/index.ts +18 -0
- package/src/shared/translation/constants.ts +4 -0
- package/src/shared/translation/localization/ca.json +33 -0
- package/src/shared/translation/localization/en.json +13 -1
- package/src/shared/translation/localization/gb.json +13 -1
- package/src/shared/translation/localization/sct.json +33 -0
- package/src/shared/translation/localization/sw.json +13 -1
- package/src/shared/translation/types.ts +6 -0
- package/src/shared/translation/validation.types.ts +9 -1
- package/src/types/common.types.ts +4 -0
- package/dist/commonjs/shared/icons/LockIcon.js +0 -31
- package/dist/commonjs/shared/icons/LockIcon.js.map +0 -1
- package/dist/module/shared/icons/LockIcon.js +0 -23
- package/dist/module/shared/icons/LockIcon.js.map +0 -1
- package/dist/typescript/commonjs/shared/icons/LockIcon.d.ts +0 -4
- package/dist/typescript/commonjs/shared/icons/LockIcon.d.ts.map +0 -1
- package/dist/typescript/module/shared/icons/LockIcon.d.ts +0 -4
- package/dist/typescript/module/shared/icons/LockIcon.d.ts.map +0 -1
- package/src/shared/icons/LockIcon.tsx +0 -16
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { useEffect } from 'react';
|
|
4
|
+
import { Gif } from "./components/Gif.js";
|
|
5
|
+
import { Progress } from "./components/Progress.js";
|
|
6
|
+
import { ContentContainer } from "./components/ContentContainer.js";
|
|
7
|
+
import { Backdrop } from "./components/Backdrop.js";
|
|
8
|
+
import { Easing, runOnJS, useSharedValue, withSequence, withTiming } from 'react-native-reanimated';
|
|
9
|
+
import { useUnit } from 'effector-react';
|
|
10
|
+
import { ANIMATION_DURATION } from "./constants.js";
|
|
11
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
12
|
+
export const GifCelebrations = ({
|
|
13
|
+
model,
|
|
14
|
+
TextComponent
|
|
15
|
+
}) => {
|
|
16
|
+
const [problemsAmount, resolvedProblemsAmount, activeGif] = useUnit([model.$problemsAmount, model.$resolvedProblemsAmount, model.$activeGif]);
|
|
17
|
+
const completedPercent = resolvedProblemsAmount && problemsAmount && Math.round(resolvedProblemsAmount / problemsAmount * 100);
|
|
18
|
+
const progress = useSharedValue(0);
|
|
19
|
+
const stopAnimation = () => {
|
|
20
|
+
model.stop();
|
|
21
|
+
progress.value = 0;
|
|
22
|
+
};
|
|
23
|
+
const playAnimation = () => {
|
|
24
|
+
progress.value = withSequence(withTiming(1, {
|
|
25
|
+
duration: ANIMATION_DURATION,
|
|
26
|
+
easing: Easing.bezier(0.52, 0.16, 0.26, 0.77)
|
|
27
|
+
}), withTiming(2, {
|
|
28
|
+
duration: ANIMATION_DURATION,
|
|
29
|
+
easing: Easing.bezier(0.71, 0.09, 0.49, 0.89)
|
|
30
|
+
}, () => runOnJS(stopAnimation)()));
|
|
31
|
+
};
|
|
32
|
+
useEffect(() => {
|
|
33
|
+
if (activeGif) {
|
|
34
|
+
playAnimation();
|
|
35
|
+
}
|
|
36
|
+
}, [activeGif]);
|
|
37
|
+
if (!activeGif) {
|
|
38
|
+
return null;
|
|
39
|
+
}
|
|
40
|
+
return /*#__PURE__*/_jsx(Backdrop, {
|
|
41
|
+
progress: progress,
|
|
42
|
+
children: /*#__PURE__*/_jsxs(ContentContainer, {
|
|
43
|
+
progress: progress,
|
|
44
|
+
children: [/*#__PURE__*/_jsx(Gif, {
|
|
45
|
+
gifObject: activeGif,
|
|
46
|
+
getCachePathMethod: model.cache.getCachePathMethod,
|
|
47
|
+
TextComponent: TextComponent
|
|
48
|
+
}), /*#__PURE__*/_jsx(Progress, {
|
|
49
|
+
progress: progress,
|
|
50
|
+
completedPercent: completedPercent
|
|
51
|
+
})]
|
|
52
|
+
})
|
|
53
|
+
});
|
|
54
|
+
};
|
|
55
|
+
//# sourceMappingURL=GifCelebrations.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","useEffect","Gif","Progress","ContentContainer","Backdrop","Easing","runOnJS","useSharedValue","withSequence","withTiming","useUnit","ANIMATION_DURATION","jsx","_jsx","jsxs","_jsxs","GifCelebrations","model","TextComponent","problemsAmount","resolvedProblemsAmount","activeGif","$problemsAmount","$resolvedProblemsAmount","$activeGif","completedPercent","Math","round","progress","stopAnimation","stop","value","playAnimation","duration","easing","bezier","children","gifObject","getCachePathMethod","cache"],"sourceRoot":"../../../../src","sources":["features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,CAAC,CAAC,EACF1B,UAAU,CACR,CAAC,EACD;MACEwB,QAAQ,EAAEtB,kBAAkB;MAC5BuB,MAAM,EAAE7B,MAAM,CAAC8B,MAAM,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI;IAC9C,CAAC,EACD,MAAM7B,OAAO,CAACuB,aAAa,CAAC,CAAC,CAC/B,CACF,CAAC;EACH,CAAC;EAED7B,SAAS,CAAC,MAAM;IACd,IAAIqB,SAAS,EAAE;MACbW,aAAa,CAAC,CAAC;IACjB;EACF,CAAC,EAAE,CAACX,SAAS,CAAC,CAAC;EAEf,IAAI,CAACA,SAAS,EAAE;IACd,OAAO,IAAI;EACb;EAEA,oBACER,IAAA,CAACT,QAAQ;IAACwB,QAAQ,EAAEA,QAAS;IAAAQ,QAAA,eAC3BrB,KAAA,CAACZ,gBAAgB;MAACyB,QAAQ,EAAEA,QAAS;MAAAQ,QAAA,gBACnCvB,IAAA,CAACZ,GAAG;QACFoC,SAAS,EAAEhB,SAAU;QACrBiB,kBAAkB,EAAErB,KAAK,CAACsB,KAAK,CAACD,kBAAmB;QACnDpB,aAAa,EAAEA;MAAc,CAC9B,CAAC,eACFL,IAAA,CAACX,QAAQ;QAAC0B,QAAQ,EAAEA,QAAS;QAACH,gBAAgB,EAAEA;MAAiB,CAAE,CAAC;IAAA,CACpD;EAAC,CACX,CAAC;AAEf,CAAC","ignoreList":[]}
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { StyleSheet, useWindowDimensions } from 'react-native';
|
|
4
|
+
import React from 'react';
|
|
5
|
+
import Animated, { useAnimatedStyle, interpolateColor } from 'react-native-reanimated';
|
|
6
|
+
import { BACKDROP_COLOR } from "../constants.js";
|
|
7
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
8
|
+
export const Backdrop = ({
|
|
9
|
+
children,
|
|
10
|
+
progress
|
|
11
|
+
}) => {
|
|
12
|
+
const {
|
|
13
|
+
width,
|
|
14
|
+
height
|
|
15
|
+
} = useWindowDimensions();
|
|
16
|
+
const backdropAnimatedStyle = useAnimatedStyle(() => ({
|
|
17
|
+
backgroundColor: interpolateColor(progress.value, [0, 1, 2], [BACKDROP_COLOR.INITIAL, BACKDROP_COLOR.FINAL, BACKDROP_COLOR.INITIAL])
|
|
18
|
+
}), [progress]);
|
|
19
|
+
return /*#__PURE__*/_jsx(Animated.View, {
|
|
20
|
+
style: [styles.backdrop, {
|
|
21
|
+
width,
|
|
22
|
+
height
|
|
23
|
+
}, backdropAnimatedStyle],
|
|
24
|
+
children: children
|
|
25
|
+
});
|
|
26
|
+
};
|
|
27
|
+
const styles = StyleSheet.create({
|
|
28
|
+
backdrop: {
|
|
29
|
+
position: 'absolute',
|
|
30
|
+
zIndex: 10100,
|
|
31
|
+
justifyContent: 'center',
|
|
32
|
+
alignItems: 'center',
|
|
33
|
+
backgroundColor: 'rgba(51, 51, 51, 0.33);'
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
//# sourceMappingURL=Backdrop.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["StyleSheet","useWindowDimensions","React","Animated","useAnimatedStyle","interpolateColor","BACKDROP_COLOR","jsx","_jsx","Backdrop","children","progress","width","height","backdropAnimatedStyle","backgroundColor","value","INITIAL","FINAL","View","style","styles","backdrop","create","position","zIndex","justifyContent","alignItems"],"sourceRoot":"../../../../../src","sources":["features/gifCelebrations/components/Backdrop.tsx"],"mappings":";;AAAA,SAASA,UAAU,EAAEC,mBAAmB,QAAQ,cAAc;AAC9D,OAAOC,KAAK,MAAM,OAAO;AACzB,OAAOC,QAAQ,IAAIC,gBAAgB,EAAEC,gBAAgB,QAAqB,yBAAyB;AACnG,SAASC,cAAc,QAAQ,iBAAc;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAQ7C,OAAO,MAAMC,QAAQ,GAAGA,CAAC;EAAEC,QAAQ;EAAEC;AAAwB,CAAC,KAAK;EACjE,MAAM;IAAEC,KAAK;IAAEC;EAAO,CAAC,GAAGZ,mBAAmB,CAAC,CAAC;EAE/C,MAAMa,qBAAqB,GAAGV,gBAAgB,CAC5C,OAAO;IACLW,eAAe,EAAEV,gBAAgB,CAC/BM,QAAQ,CAACK,KAAK,EACd,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EACT,CAACV,cAAc,CAACW,OAAO,EAAEX,cAAc,CAACY,KAAK,EAAEZ,cAAc,CAACW,OAAO,CACvE;EACF,CAAC,CAAC,EACF,CAACN,QAAQ,CACX,CAAC;EAED,oBACEH,IAAA,CAACL,QAAQ,CAACgB,IAAI;IAACC,KAAK,EAAE,CAACC,MAAM,CAACC,QAAQ,EAAE;MAAEV,KAAK;MAAEC;IAAO,CAAC,EAAEC,qBAAqB,CAAE;IAAAJ,QAAA,EAC/EA;EAAQ,CACI,CAAC;AAEpB,CAAC;AAED,MAAMW,MAAM,GAAGrB,UAAU,CAACuB,MAAM,CAAC;EAC/BD,QAAQ,EAAE;IACRE,QAAQ,EAAE,UAAU;IACpBC,MAAM,EAAE,KAAK;IACbC,cAAc,EAAE,QAAQ;IACxBC,UAAU,EAAE,QAAQ;IACpBZ,eAAe,EAAE;EACnB;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { StyleSheet, useWindowDimensions } from 'react-native';
|
|
4
|
+
import React from 'react';
|
|
5
|
+
import { SPACING } from '@magmamath/react-native-ui';
|
|
6
|
+
import Animated, { useAnimatedStyle, interpolate } from 'react-native-reanimated';
|
|
7
|
+
import { CONTENT_CONTAINER } from "../constants.js";
|
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
9
|
+
export const ContentContainer = ({
|
|
10
|
+
children,
|
|
11
|
+
progress
|
|
12
|
+
}) => {
|
|
13
|
+
const {
|
|
14
|
+
width
|
|
15
|
+
} = useWindowDimensions();
|
|
16
|
+
const RIGHT_POSITION = width / 2 + CONTENT_CONTAINER.CONTAINER_WIDTH / 2 + CONTENT_CONTAINER.ROTATION_PADDING;
|
|
17
|
+
const LEFT_POSITION = -RIGHT_POSITION - CONTENT_CONTAINER.ROTATION_PADDING;
|
|
18
|
+
const animatedStyles = useAnimatedStyle(() => ({
|
|
19
|
+
transform: [{
|
|
20
|
+
translateX: interpolate(progress.value, [0, 1, 2], [LEFT_POSITION, 0, RIGHT_POSITION])
|
|
21
|
+
}, {
|
|
22
|
+
rotate: `${interpolate(progress.value, [0, 1, 2], [-CONTENT_CONTAINER.ANGLE, 0, CONTENT_CONTAINER.ANGLE])}deg`
|
|
23
|
+
}]
|
|
24
|
+
}), [progress, RIGHT_POSITION, LEFT_POSITION]);
|
|
25
|
+
return /*#__PURE__*/_jsx(Animated.View, {
|
|
26
|
+
style: [styles.container, animatedStyles],
|
|
27
|
+
children: children
|
|
28
|
+
});
|
|
29
|
+
};
|
|
30
|
+
const styles = StyleSheet.create({
|
|
31
|
+
container: {
|
|
32
|
+
width: CONTENT_CONTAINER.CONTAINER_WIDTH,
|
|
33
|
+
alignItems: 'center',
|
|
34
|
+
gap: SPACING[800],
|
|
35
|
+
position: 'absolute'
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
//# sourceMappingURL=ContentContainer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["StyleSheet","useWindowDimensions","React","SPACING","Animated","useAnimatedStyle","interpolate","CONTENT_CONTAINER","jsx","_jsx","ContentContainer","children","progress","width","RIGHT_POSITION","CONTAINER_WIDTH","ROTATION_PADDING","LEFT_POSITION","animatedStyles","transform","translateX","value","rotate","ANGLE","View","style","styles","container","create","alignItems","gap","position"],"sourceRoot":"../../../../../src","sources":["features/gifCelebrations/components/ContentContainer.tsx"],"mappings":";;AAAA,SAASA,UAAU,EAAEC,mBAAmB,QAAQ,cAAc;AAC9D,OAAOC,KAAK,MAAM,OA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AAC;EAC/BD,SAAS,EAAE;IACTd,KAAK,EAAEN,iBAAiB,CAACQ,eAAe;IACxCc,UAAU,EAAE,QAAQ;IACpBC,GAAG,EAAE3B,OAAO,CAAC,GAAG,CAAC;IACjB4B,QAAQ,EAAE;EACZ;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { StyleSheet, View, Image } from 'react-native';
|
|
4
|
+
import React, { useLayoutEffect, useState } from 'react';
|
|
5
|
+
import { BORDER_RADIUS, COLORS, IS_WEB, SPACING } from '@magmamath/react-native-ui';
|
|
6
|
+
import { MAX_GIF_SIZE, MIN_GIF_SIZE } from "../constants.js";
|
|
7
|
+
import { useText } from "../../../shared/translation/index.js";
|
|
8
|
+
import { constrainDimension, getGifLabel, getImagePath } from "../helpers.js";
|
|
9
|
+
import gifFallback from '../assets/gifFallback.gif';
|
|
10
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
11
|
+
export const Gif = ({
|
|
12
|
+
gifObject,
|
|
13
|
+
getCachePathMethod,
|
|
14
|
+
TextComponent
|
|
15
|
+
}) => {
|
|
16
|
+
const [size, setSize] = useState(null);
|
|
17
|
+
const [pathOrUri, setPathOrUri] = useState('');
|
|
18
|
+
const t = useText();
|
|
19
|
+
const gifGroupNumber = Number(gifObject.group.replace('group', ''));
|
|
20
|
+
const gifLabel = getGifLabel(gifGroupNumber);
|
|
21
|
+
useLayoutEffect(() => {
|
|
22
|
+
const loadImageSize = async () => {
|
|
23
|
+
let localPath;
|
|
24
|
+
try {
|
|
25
|
+
localPath = await getImagePath(gifObject.url, getCachePathMethod);
|
|
26
|
+
} catch (error) {
|
|
27
|
+
localPath = IS_WEB ? gifFallback : Image.resolveAssetSource(gifFallback).uri;
|
|
28
|
+
console.error('Error fetching image from cache:', error);
|
|
29
|
+
}
|
|
30
|
+
Image.getSize(localPath, (width, height) => {
|
|
31
|
+
setSize({
|
|
32
|
+
width: constrainDimension(width, MIN_GIF_SIZE, MAX_GIF_SIZE.WIDTH),
|
|
33
|
+
height: constrainDimension(height, MIN_GIF_SIZE, MAX_GIF_SIZE.HEIGHT)
|
|
34
|
+
});
|
|
35
|
+
setPathOrUri(localPath);
|
|
36
|
+
});
|
|
37
|
+
};
|
|
38
|
+
loadImageSize();
|
|
39
|
+
}, [gifObject.url]);
|
|
40
|
+
return /*#__PURE__*/_jsx(View, {
|
|
41
|
+
style: styles.backgroundContainer,
|
|
42
|
+
children: /*#__PURE__*/_jsxs(View, {
|
|
43
|
+
style: styles.container,
|
|
44
|
+
children: [size && pathOrUri && /*#__PURE__*/_jsx(Image, {
|
|
45
|
+
alt: "Funny celebration animated image",
|
|
46
|
+
source: {
|
|
47
|
+
uri: pathOrUri
|
|
48
|
+
},
|
|
49
|
+
width: size.width,
|
|
50
|
+
height: size.height,
|
|
51
|
+
style: [styles.image, {
|
|
52
|
+
width: size.width,
|
|
53
|
+
height: size.height
|
|
54
|
+
}] //this sizes duplication is needed for compatibility with web and rn
|
|
55
|
+
}), /*#__PURE__*/_jsx(View, {
|
|
56
|
+
style: styles.textContainer,
|
|
57
|
+
children: TextComponent(t(gifLabel))
|
|
58
|
+
})]
|
|
59
|
+
})
|
|
60
|
+
});
|
|
61
|
+
};
|
|
62
|
+
const styles = StyleSheet.create({
|
|
63
|
+
backgroundContainer: {
|
|
64
|
+
backgroundColor: 'rgba(255, 255, 255, 0.6)',
|
|
65
|
+
borderRadius: 23,
|
|
66
|
+
padding: SPACING[200]
|
|
67
|
+
},
|
|
68
|
+
container: {
|
|
69
|
+
padding: SPACING[1600],
|
|
70
|
+
borderRadius: BORDER_RADIUS[400],
|
|
71
|
+
backgroundColor: COLORS.NEUTRAL_1
|
|
72
|
+
},
|
|
73
|
+
image: {
|
|
74
|
+
borderRadius: BORDER_RADIUS[100]
|
|
75
|
+
},
|
|
76
|
+
textContainer: {
|
|
77
|
+
position: 'absolute',
|
|
78
|
+
bottom: 74,
|
|
79
|
+
alignSelf: 'center'
|
|
80
|
+
}
|
|
81
|
+
});
|
|
82
|
+
//# sourceMappingURL=Gif.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["StyleSheet","View","Image","React","useLayoutEffect","useState","BORDER_RADIUS","COLORS","IS_WEB","SPACING","MAX_GIF_SIZE","MIN_GIF_SIZE","useText","constrainDimension","getGifLabel","getImagePath","gifFallback","jsx","_jsx","jsxs","_jsxs","Gif","gifObject","getCachePathMethod","TextComponent","size","setSize","pathOrUri","setPathOrUri","t","gifGroupNumber","Number","group","replace","gifLabel","loadImageSize","localPath","url","error","resolveAssetSource","uri","console","getSize","width","height","WIDTH","HEIGHT","style","styles","backgroundContainer","children","container","alt","source","image","textContainer","create","backgroundColor","borderRadius","padding","NEUTRAL_1","position","bottom","alignSelf"],"sourceRoot":"../../../../../src","sources":["features/gifCelebrations/components/Gif.tsx"],"mappings":";;AAAA,SAASA,UAAU,EAAEC,IAAI,EAAEC,KAAK,QAAQ,cAAc;AACtD,OAAOC,KAAK,IAAIC,eAAe,EAAEC,QAAQ,QAAQ,OAAO;AACxD,SAASC,aAAa,EAAEC,MAAM,EAAEC,MAAM,EAAEC,OAAO,QAAQ,4BAA4B;AAEnF,SAASC,YAAY,EAAEC,YAAY,QAAQ,iBAAc;AACzD,SAASC,OAAO,QAAQ,sCAA6B;AACrD,SAASC,kBAAkB,EAAEC,WAAW,EAAEC,YAAY,QAAQ,eAAY;AAC1E,OAAOC,WAAW,MAAM,2BAA2B;AAAA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AASnD,OAAO,MAAMC,GAAG,GAAGA,CAAC;EAAEC,SAAS;EAAEC,kBAAkB;EAAEC;AAAwB,CAAC,KAAK;EACjF,MAAM,CAACC,IAAI,EAAEC,OAAO,CAAC,GAAGrB,QAAQ,CAAc,IAAI,CAAC;EACnD,MAAM,CAACsB,SAAS,EAAEC,YAAY,CAAC,GAA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AC3BzB,IAAI,IAAIE,SAAS,iBAChBT,IAAA,CAAChB,KAAK;QACJkD,GAAG,EAAC,kCAAkC;QACtCC,MAAM,EAAE;UACNb,GAAG,EAAEb;QACP,CAAE;QACFgB,KAAK,EAAElB,IAAI,CAACkB,KAAM;QAClBC,MAAM,EAAEnB,IAAI,CAACmB,MAAO;QACpBG,KAAK,EAAE,CAACC,MAAM,CAACM,KAAK,EAAE;UAAEX,KAAK,EAAElB,IAAI,CAACkB,KAAK;UAAEC,MAAM,EAAEnB,IAAI,CAACmB;QAAO,CAAC,CAAE,CAAC;MAAA,CACpE,CACF,eACD1B,IAAA,CAACjB,IAAI;QAAC8C,KAAK,EAAEC,MAAM,CAACO,aAAc;QAAAL,QAAA,EAAE1B,aAAa,CAACK,CAAC,CAACK,QAAQ,CAAC;MAAC,CAAO,CAAC;IAAA,CAClE;EAAC,CACH,CAAC;AAEX,CAAC;AAED,MAAMc,MAAM,GAAGhD,UAAU,CAACwD,MAAM,CAAC;EAC/BP,mBAAmB,EAAE;IACnBQ,eAAe,EAAE,0BAA0B;IAC3CC,YAAY,EAAE,EAAE;IAChBC,OAAO,EAAElD,OAAO,CAAC,GAAG;EACtB,CAAC;EACD0C,SAAS,EAAE;IACTQ,OAAO,EAAElD,OAAO,CAAC,IAAI,CAAC;IACtBiD,YAAY,EAAEpD,aAAa,CAAC,GAAG,CAAC;IAChCmD,eAAe,EAAElD,MAAM,CAACqD;EAC1B,CAAC;EACDN,KAAK,EAAE;IACLI,YAAY,EAAEpD,aAAa,CAAC,GAAG;EACjC,CAAC;EACDiD,aAAa,EAAE;IACbM,QAAQ,EAAE,UAAU;IACpBC,MAAM,EAAE,EAAE;IACVC,SAAS,EAAE;EACb;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { StyleSheet, View, Image } from 'react-native';
|
|
4
|
+
import React from 'react';
|
|
5
|
+
import { BORDER_RADIUS, COLORS, HeadingVariants, IS_WEB, SPACING, Typography } from '@magmamath/react-native-ui';
|
|
6
|
+
import Animated, { useAnimatedStyle, interpolate } from 'react-native-reanimated';
|
|
7
|
+
import confettiImage from '../assets/confetti.webp';
|
|
8
|
+
import { getProgressLineWidth } from "../helpers.js";
|
|
9
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
10
|
+
export const Progress = ({
|
|
11
|
+
progress,
|
|
12
|
+
completedPercent
|
|
13
|
+
}) => {
|
|
14
|
+
const progressLineWidth = getProgressLineWidth(completedPercent);
|
|
15
|
+
const animatedStyles = useAnimatedStyle(() => ({
|
|
16
|
+
width: `${interpolate(progress.value, [0, 1, 2], [0, progressLineWidth, progressLineWidth])}%`
|
|
17
|
+
}), [progress, progressLineWidth]);
|
|
18
|
+
return /*#__PURE__*/_jsx(View, {
|
|
19
|
+
style: styles.backgroundContainer,
|
|
20
|
+
children: /*#__PURE__*/_jsxs(View, {
|
|
21
|
+
style: styles.container,
|
|
22
|
+
children: [/*#__PURE__*/_jsx(View, {
|
|
23
|
+
style: styles.progressContainer,
|
|
24
|
+
children: /*#__PURE__*/_jsx(Animated.View, {
|
|
25
|
+
style: [styles.progress, animatedStyles],
|
|
26
|
+
children: /*#__PURE__*/_jsx(Typography, {
|
|
27
|
+
variant: HeadingVariants.H1,
|
|
28
|
+
style: styles.percent,
|
|
29
|
+
children: `${completedPercent}%`
|
|
30
|
+
})
|
|
31
|
+
})
|
|
32
|
+
}), /*#__PURE__*/_jsx(Image, {
|
|
33
|
+
source: IS_WEB ? {
|
|
34
|
+
uri: confettiImage
|
|
35
|
+
} : require('../assets/confetti.webp'),
|
|
36
|
+
style: styles.confetti
|
|
37
|
+
})]
|
|
38
|
+
})
|
|
39
|
+
});
|
|
40
|
+
};
|
|
41
|
+
const styles = StyleSheet.create({
|
|
42
|
+
backgroundContainer: {
|
|
43
|
+
backgroundColor: 'rgba(255, 255, 255, 0.6)',
|
|
44
|
+
borderRadius: 23,
|
|
45
|
+
padding: SPACING[200],
|
|
46
|
+
width: '100%'
|
|
47
|
+
},
|
|
48
|
+
container: {
|
|
49
|
+
width: '100%',
|
|
50
|
+
height: 116,
|
|
51
|
+
flexDirection: 'row',
|
|
52
|
+
alignItems: 'center',
|
|
53
|
+
borderRadius: BORDER_RADIUS[400],
|
|
54
|
+
backgroundColor: COLORS.NEUTRAL_1,
|
|
55
|
+
paddingLeft: SPACING[400],
|
|
56
|
+
paddingRight: SPACING[200],
|
|
57
|
+
gap: SPACING[100]
|
|
58
|
+
},
|
|
59
|
+
progressContainer: {
|
|
60
|
+
height: 50,
|
|
61
|
+
flexGrow: 1,
|
|
62
|
+
backgroundColor: COLORS.NEUTRAL_5,
|
|
63
|
+
borderRadius: 90,
|
|
64
|
+
overflow: 'hidden'
|
|
65
|
+
},
|
|
66
|
+
progress: {
|
|
67
|
+
position: 'absolute',
|
|
68
|
+
height: '100%',
|
|
69
|
+
backgroundColor: COLORS.PRIMARY_BLUE,
|
|
70
|
+
borderRadius: BORDER_RADIUS[200],
|
|
71
|
+
justifyContent: 'center',
|
|
72
|
+
alignItems: 'flex-end',
|
|
73
|
+
paddingRight: 10.6,
|
|
74
|
+
overflow: 'hidden'
|
|
75
|
+
},
|
|
76
|
+
confetti: {
|
|
77
|
+
width: 75,
|
|
78
|
+
height: 70,
|
|
79
|
+
marginHorizontal: SPACING[200]
|
|
80
|
+
},
|
|
81
|
+
percent: {
|
|
82
|
+
position: 'absolute',
|
|
83
|
+
paddingRight: 10,
|
|
84
|
+
color: COLORS.NEUTRAL_1,
|
|
85
|
+
fontWeight: '700'
|
|
86
|
+
}
|
|
87
|
+
});
|
|
88
|
+
//# sourceMappingURL=Progress.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["StyleSheet","View","Image","React","BORDER_RADIUS","COLORS","HeadingVariants","IS_WEB","SPACING","Typography","Animated","useAnimatedStyle","interpolate","confettiImage","getProgressLineWidth","jsx","_jsx","jsxs","_jsxs","Progress","progress","completedPercent","progressLineWidth","animatedStyles","width","value","style","styles","backgroundContainer","children","container","progressContainer","variant","H1","percent","source","uri","require","confetti","create","backgroundColor","borderRadius","padding","height","flexDirection","alignItems","NEUTRAL_1","paddingLeft","paddingRight","gap","flexGrow","NEUTRAL_5","overflow","position","PRIMARY_BLUE","justifyContent","marginHorizontal","color","fontWeight"],"sourceRoot":"../../../../../src","sources":["features/gifCelebrations/components/Progress.tsx"],"mappings":";;AAAA,SAASA,UAAU,EAAEC,IAAI,EAAEC,KAAK,QAAQ,cAAc;AACtD,OAAOC,KAAK,MAAM,OAAO;AACzB,SACEC,aAAa,EACbC,MAAM,EACNC,eAAe,EACfC,MAAM,EACNC,OAAO,EACPC,UAAU,QACL,4BAA4B;AACnC,OAAOC,QAAQ,IAAIC,gBAAgB,EAAeC,WAAW,QAAQ,yBAAyB;AAC9F,OAAOC,aAAa,MAAM,yBAAyB;AAEnD,SAASC,oBAAoB,QAAQ,eAAY;AAAA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAOjD,OAAO,MAAMC,QAAQ,GAAGA,CAAC;EAAEC,QAAQ;EAAEC;AAAgC,CAAC,KAAK;EACzE,MAAMC,iBAAiB,GAAGR,oBAAoB,CAACO,gBAAgB,CAAC;EAEhE,MAAME,cAAc,GAAGZ,gBAAgB,CACrC,OAAO;IACLa,KAAK,EAAE,GAAGZ,WAAW,CACnBQ,QAAQ,CAACK,KAAK,EACd,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EACT,CAAC,CAAC,EAAEH,iBAAiB,EAAEA,iBAAiB,CAC1C,CAAC;EACH,CAAC,CAAC,EACF,CAACF,QAAQ,EAAEE,iBAAiB,CAC9B,CAAC;EAED,oBACEN,IAAA,CAACf,IAAI;IAACyB,KAAK,EAAEC,MAAM,CAACC,mBAAoB;IAAAC,QAAA,eACtCX,KAAA,CAACjB,IAAI;MAACyB,KAAK,EAAEC,MAAM,CAACG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E,CAAC;IACXV,eAAe,EAAEnC,MAAM,CAAC8C,SAAS;IACjCV,YAAY,EAAE,EAAE;IAChBW,QAAQ,EAAE;EACZ,CAAC;EACDhC,QAAQ,EAAE;IACRiC,QAAQ,EAAE,UAAU;IACpBV,MAAM,EAAE,MAAM;IACdH,eAAe,EAAEnC,MAAM,CAACiD,YAAY;IACpCb,YAAY,EAAErC,aAAa,CAAC,GAAG,CAAC;IAChCmD,cAAc,EAAE,QAAQ;IACxBV,UAAU,EAAE,UAAU;IACtBG,YAAY,EAAE,IAAI;IAClBI,QAAQ,EAAE;EACZ,CAAC;EACDd,QAAQ,EAAE;IACRd,KAAK,EAAE,EAAE;IACTmB,MAAM,EAAE,EAAE;IACVa,gBAAgB,EAAEhD,OAAO,CAAC,GAAG;EAC/B,CAAC;EACD0B,OAAO,EAAE;IACPmB,QAAQ,EAAE,UAAU;IACpBL,YAAY,EAAE,EAAE;IAChBS,KAAK,EAAEpD,MAAM,CAACyC,SAAS;IACvBY,UAAU,EAAE;EACd;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
export const BACKDROP_COLOR = {
|
|
4
|
+
INITIAL: 'rgba(51, 51, 51, 0)',
|
|
5
|
+
FINAL: 'rgba(51, 51, 51, 0.66)'
|
|
6
|
+
};
|
|
7
|
+
export const CONTENT_CONTAINER = {
|
|
8
|
+
ANGLE: 5,
|
|
9
|
+
CONTAINER_WIDTH: 769,
|
|
10
|
+
ROTATION_PADDING: 44 // to be sure that the content is not cut off on the edges because of rotate transform
|
|
11
|
+
};
|
|
12
|
+
export const ANIMATION_DURATION = 1750;
|
|
13
|
+
export const MIN_PROBLEMS_TO_SHOW_GIF = 7;
|
|
14
|
+
export const MAX_GIF_SIZE = {
|
|
15
|
+
WIDTH: 480,
|
|
16
|
+
HEIGHT: 300
|
|
17
|
+
};
|
|
18
|
+
export const MIN_GIF_SIZE = 300;
|
|
19
|
+
export const GROUPS_PERCENTAGES = {
|
|
20
|
+
group1: [15, 20, 25, 30],
|
|
21
|
+
// Early celebrations
|
|
22
|
+
group2: [33, 40, 45, 50],
|
|
23
|
+
// Mid celebrations
|
|
24
|
+
group3: [60, 66, 75, 80] // Party
|
|
25
|
+
};
|
|
26
|
+
export const MIN_WIDTH_FOR_ONE_DIGIT = 12;
|
|
27
|
+
export const MIN_WIDTH_FOR_TWO_DIGITS = 15;
|
|
28
|
+
export const GET_GIFS_TIMEOUT = 5000;
|
|
29
|
+
export const GIFS_FETCHED_KEY = 'gifsFetchedTimestamp';
|
|
30
|
+
//# sourceMappingURL=constants.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["BACKDROP_COLOR","INITIAL","FINAL","CONTENT_CONTAINER","ANGLE","CONTAINER_WIDTH","ROTATION_PADDING","ANIMATION_DURATION","MIN_PROBLEMS_TO_SHOW_GIF","MAX_GIF_SIZE","WIDTH","HEIGHT","MIN_GIF_SIZE","GROUPS_PERCENTAGES","group1","group2","group3","MIN_WIDTH_FOR_ONE_DIGIT","MIN_WIDTH_FOR_TWO_DIGITS","GET_GIFS_TIMEOUT","GIFS_FETCHED_KEY"],"sourceRoot":"../../../../src","sources":["features/gifCelebrations/constants.ts"],"mappings":";;AAAA,OAAO,MAAMA,cAAc,GAAG;EAC5BC,OAAO,EAAE,qBAAqB;EAC9BC,KAAK,EAAE;AACT,CAAC;AAED,OAAO,MAAMC,iBAAiB,GAAG;EAC/BC,KAAK,EAAE,CAAC;EACRC,eAAe,EAAE,GAAG;EACpBC,gBAAgB,EAAE,EAAE,CAAE;AACxB,CAAC;AAED,OAAO,MAAMC,kBAAkB,GAAG,IAAI;AACtC,OAAO,MAAMC,wBAAwB,GAAG,CAAC;AAEzC,OAAO,MAAMC,YAAY,GAAG;EAC1BC,KAAK,EAAE,GAAG;EACVC,MAAM,EAAE;AACV,CAAC;AACD,OAAO,MAAMC,YAAY,GAAG,GAAG;AAE/B,OAAO,MAAMC,kBAAkB,GAAG;EAChCC,MAAM,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC;EAAE;EAC1BC,MAAM,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC;EAAE;EAC1BC,MAAM,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,CAAE;AAC5B,CAAC;AAED,OAAO,MAAMC,uBAAuB,GAAG,EAAE;AACzC,OAAO,MAAMC,wBAAwB,GAAG,EAAE;AAE1C,OAAO,MAAMC,gBAAgB,GAAG,IAAI;AAEpC,OAAO,MAAMC,gBAAgB,GAAG,sBAAsB","ignoreList":[]}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { MIN_WIDTH_FOR_ONE_DIGIT, MIN_WIDTH_FOR_TWO_DIGITS } from "./constants.js";
|
|
4
|
+
import { Image } from 'react-native';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Number of problems When we show gif
|
|
8
|
+
* <6 Never
|
|
9
|
+
* 7-12 50% completion
|
|
10
|
+
* 13-18 33%, 66% completion
|
|
11
|
+
* 19-24 25%, 50%, 75 completion
|
|
12
|
+
* 25-30 20%, 40%, 60%, 80% completion
|
|
13
|
+
* .>30 15%, 30%, 45%, 60%, 75% completion
|
|
14
|
+
*
|
|
15
|
+
* We are also going to have different buckets with different gifs. The logic is as follows:
|
|
16
|
+
* Group 1: 15%, 20%, 25%, 30% - Early celebrations
|
|
17
|
+
* Group 2: 33%, 40%, 45%, 50% - Mid celebrations
|
|
18
|
+
* Group 3: 60%, 66%, 75%, 80% - Party
|
|
19
|
+
* or
|
|
20
|
+
* Group 1: <=30% - Early celebrations
|
|
21
|
+
* Group 2: >30% <60% - Mid celebrations
|
|
22
|
+
* Group 3: >=60% - Party
|
|
23
|
+
*/
|
|
24
|
+
export const generateProblemsGifsTable = (problemsAmount, resolvedProblems, gifs) => {
|
|
25
|
+
const percentageMilestones = getPercentageMilestones(problemsAmount);
|
|
26
|
+
const result = {};
|
|
27
|
+
for (const percentage of percentageMilestones) {
|
|
28
|
+
const problemNumber = Math.ceil(problemsAmount * (percentage / 100));
|
|
29
|
+
if (problemNumber <= resolvedProblems) continue;
|
|
30
|
+
const groupKey = findGroupForPercentage(percentage);
|
|
31
|
+
const gifsInGroup = gifs[groupKey];
|
|
32
|
+
if (!gifsInGroup || gifsInGroup.length === 0) continue;
|
|
33
|
+
const unshownGif = gifsInGroup.find(gif => !gif.isShown);
|
|
34
|
+
const selectedGif = unshownGif || gifsInGroup[0];
|
|
35
|
+
if (selectedGif) {
|
|
36
|
+
result[problemNumber] = {
|
|
37
|
+
url: selectedGif.url,
|
|
38
|
+
group: groupKey
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
return result;
|
|
43
|
+
};
|
|
44
|
+
const getPercentageMilestones = problemsAmount => {
|
|
45
|
+
if (problemsAmount <= 12) return [50];
|
|
46
|
+
if (problemsAmount <= 18) return [33, 66];
|
|
47
|
+
if (problemsAmount <= 24) return [25, 50, 75];
|
|
48
|
+
if (problemsAmount <= 30) return [20, 40, 60, 80];
|
|
49
|
+
return [15, 30, 45, 60, 75];
|
|
50
|
+
};
|
|
51
|
+
export const generateGifsStructure = gifs => Object.fromEntries(Object.entries(gifs).map(([key, value]) => [key, value.map(url => ({
|
|
52
|
+
url,
|
|
53
|
+
isShown: false,
|
|
54
|
+
group: key
|
|
55
|
+
}))]));
|
|
56
|
+
export const getGifLabel = relatedGroup => {
|
|
57
|
+
if (relatedGroup === 2) {
|
|
58
|
+
return 'gifCelebrations.onTheWay';
|
|
59
|
+
}
|
|
60
|
+
if (relatedGroup === 3) {
|
|
61
|
+
return 'gifCelebrations.almostThere';
|
|
62
|
+
}
|
|
63
|
+
return 'gifCelebrations.greatStart';
|
|
64
|
+
};
|
|
65
|
+
export const getProgressLineWidth = completedPercent => {
|
|
66
|
+
if (completedPercent <= 9) {
|
|
67
|
+
return MIN_WIDTH_FOR_ONE_DIGIT;
|
|
68
|
+
}
|
|
69
|
+
if (completedPercent <= 15) {
|
|
70
|
+
return MIN_WIDTH_FOR_TWO_DIGITS;
|
|
71
|
+
}
|
|
72
|
+
return completedPercent;
|
|
73
|
+
};
|
|
74
|
+
export const findGroupForPercentage = percentage => {
|
|
75
|
+
if (percentage <= 30) {
|
|
76
|
+
return 'group1';
|
|
77
|
+
}
|
|
78
|
+
if (percentage < 60) {
|
|
79
|
+
return 'group2';
|
|
80
|
+
}
|
|
81
|
+
return 'group3';
|
|
82
|
+
};
|
|
83
|
+
export const getImagePath = async (url, cacheMethod) => {
|
|
84
|
+
if (cacheMethod) {
|
|
85
|
+
const path = await cacheMethod(url);
|
|
86
|
+
if (path) return path;
|
|
87
|
+
} else {
|
|
88
|
+
// @ts-ignore
|
|
89
|
+
const isImagesStored = await Image.queryCache([url]).then(images => !!images[url]);
|
|
90
|
+
if (isImagesStored) return url;
|
|
91
|
+
}
|
|
92
|
+
throw new Error('Image not found in cache');
|
|
93
|
+
};
|
|
94
|
+
export const constrainDimension = (value, min, max) => Math.max(min, Math.min(max, value));
|
|
95
|
+
export const shouldRefreshGifs = timestamp => {
|
|
96
|
+
if (!timestamp) return true;
|
|
97
|
+
const REFRESH_INTERVAL_HOURS = 24;
|
|
98
|
+
const lastFetchedDate = new Date(timestamp);
|
|
99
|
+
const currentDate = new Date();
|
|
100
|
+
const diffInHours = (currentDate.getTime() - lastFetchedDate.getTime()) / (1000 * 60 * 60);
|
|
101
|
+
return diffInHours > REFRESH_INTERVAL_HOURS;
|
|
102
|
+
};
|
|
103
|
+
//# sourceMappingURL=helpers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["MIN_WIDTH_FOR_ONE_DIGIT","MIN_WIDTH_FOR_TWO_DIGITS","Image","generateProblemsGifsTable","problemsAmount","resolvedProblems","gifs","percentageMilestones","getPercentageMilestones","result","percentage","problemNumber","Math","ceil","groupKey","findGroupForPercentage","gifsInGroup","length","unshownGif","find","gif","isShown","selectedGif","url","group","generateGifsStructure","Object","fromEntries","entries","map","key","value","getGifLabel","relatedGroup","getProgressLineWidth","completedPercent","getImagePath","cacheMethod","path","isImagesStored","queryCache","then","images","Error","constrainDimension","min","max","shouldRefreshGifs","timestamp","REFRESH_INTERVAL_HOURS","lastFetchedDate","Date","currentDate","diffInHours","getTime"],"sourceRoot":"../../../../src","sources":["features/gifCelebrations/helpers.ts"],"mappings":";;AASA,SAASA,uBAAuB,EAAEC,wBAAwB,QAAQ,gBAAa;AAC/E,SAASC,KAAK,QAAQ,cAAc;;AAEpC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,yBAAyB,GAAGA,CACvCC,cAAsB,EACtBC,gBAAwB,EACxBC,IAAmB,KACG;EACtB,MAAMC,oBAAoB,GAAGC,uBAAuB,CAACJ,cAAc,CAAC;EAEpE,MAAMK,MAAyB,GAAG,CAAC,CAAC;EAEpC,KAAK,MAAMC,UAAU,IAAIH,oBAAoB,EAAE;IAC7C,MAAMI,aAAa,GAAGC,IAAI,CAACC,IAAI,CAACT,cAAc,IAAIM,UAAU,GAAG,GAAG,CAAC,CAAC;IAEpE,IAAIC,aAAa,IAAIN,gBAAgB,EAAE;IAEvC,MAAMS,QAAQ,GAAGC,sBAAsB,CAACL,UAAU,CAAC;IACnD,MAAMM,WAAW,GAAGV,IAAI,CAACQ,QAAQ,CAAC;IAElC,IAAI,CAACE,WAAW,IAAIA,WAAW,CAACC,MAAM,KAAK,CAAC,EAAE;IAE9C,MAAMC,UAAU,GAAGF,WAAW,CAACG,IAAI,CAAEC,GAAG,IAAK,CAACA,GAAG,CAACC,OAAO,CAAC;IAE1D,MAAMC,WAAW,GAAGJ,UAAU,IAAIF,WAAW,CAAC,CAAC,CAAC;IAEhD,IAAIM,WA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ME,WAAW,GAAG,CAACD,WAAW,CAACE,OAAO,CAAC,CAAC,GAAGJ,eAAe,CAACI,OAAO,CAAC,CAAC,KAAK,IAAI,GAAG,EAAE,GAAG,EAAE,CAAC;EAE1F,OAAOD,WAAW,GAAGJ,sBAAsB;AAC7C,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["GifCelebrations","GifCelebrationsModel"],"sourceRoot":"../../../../src","sources":["features/gifCelebrations/index.ts"],"mappings":";;AAAA,SAASA,eAAe,QAAQ,sBAAmB;AACnD,SAASC,oBAAoB,QAAQ,kCAA+B","ignoreList":[]}
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { createEffect, createEvent, createStore, sample } from 'effector';
|
|
4
|
+
import { GifCelebrationsApi } from "./GifCelebrationsApi.js";
|
|
5
|
+
import { GifCelebrationsCache } from "./GifCelebrationsCache.js";
|
|
6
|
+
import { generateProblemsGifsTable, shouldRefreshGifs } from "../helpers.js";
|
|
7
|
+
import { MIN_PROBLEMS_TO_SHOW_GIF, GIFS_FETCHED_KEY } from "../constants.js";
|
|
8
|
+
export class GifCelebrationsModel {
|
|
9
|
+
play = createEvent();
|
|
10
|
+
stop = createEvent();
|
|
11
|
+
resetGifTriggerable = createEvent();
|
|
12
|
+
setGifTriggerable = createEvent();
|
|
13
|
+
$isGifTriggerable = createStore(false).reset(this.resetGifTriggerable).reset(this.stop).on(this.setGifTriggerable, (_, isGifCelebrationMayBeTriggered) => isGifCelebrationMayBeTriggered);
|
|
14
|
+
resetProblemsGifsTable = createEvent();
|
|
15
|
+
$problemsGifsTable = createStore(null).reset(this.resetProblemsGifsTable);
|
|
16
|
+
setActiveGif = createEvent();
|
|
17
|
+
$activeGif = createStore(null).reset(this.stop).reset(this.resetGifTriggerable).on(this.setActiveGif, (_, gif) => gif);
|
|
18
|
+
initialize = createEvent();
|
|
19
|
+
constructor({
|
|
20
|
+
api,
|
|
21
|
+
problemsAmount,
|
|
22
|
+
resolvedProblemsAmount,
|
|
23
|
+
customLocalStorage,
|
|
24
|
+
customGetCachePathMethod,
|
|
25
|
+
customPrefetchMethod
|
|
26
|
+
}) {
|
|
27
|
+
this.api = new GifCelebrationsApi(api);
|
|
28
|
+
this.cache = new GifCelebrationsCache({
|
|
29
|
+
customGetCachePathMethod,
|
|
30
|
+
customPrefetchMethod
|
|
31
|
+
});
|
|
32
|
+
this.$problemsAmount = problemsAmount;
|
|
33
|
+
this.$resolvedProblemsAmount = resolvedProblemsAmount;
|
|
34
|
+
this.localStorage = customLocalStorage || localStorage;
|
|
35
|
+
this.setupEventHandlers();
|
|
36
|
+
}
|
|
37
|
+
setupEventHandlers() {
|
|
38
|
+
sample({
|
|
39
|
+
clock: this.initialize,
|
|
40
|
+
source: this.cache.$gifs,
|
|
41
|
+
filter: gifs => {
|
|
42
|
+
if (!gifs) return true;
|
|
43
|
+
const gifsFetchedTimestamp = this.localStorage.getItem(GIFS_FETCHED_KEY);
|
|
44
|
+
return shouldRefreshGifs(gifsFetchedTimestamp);
|
|
45
|
+
},
|
|
46
|
+
target: this.api.getGifsFx
|
|
47
|
+
});
|
|
48
|
+
sample({
|
|
49
|
+
source: this.api.getGifsFx.doneData,
|
|
50
|
+
filter: response => response.ok,
|
|
51
|
+
fn: response => response.data,
|
|
52
|
+
target: this.cache.initialSet
|
|
53
|
+
});
|
|
54
|
+
sample({
|
|
55
|
+
source: this.api.getGifsFx.doneData,
|
|
56
|
+
filter: response => response.ok,
|
|
57
|
+
target: createEffect(() => {
|
|
58
|
+
this.localStorage.setItem(GIFS_FETCHED_KEY, new Date().toISOString());
|
|
59
|
+
})
|
|
60
|
+
});
|
|
61
|
+
sample({
|
|
62
|
+
clock: [this.initialize, this.api.getGifsFx.doneData],
|
|
63
|
+
source: {
|
|
64
|
+
gifs: this.cache.$gifs,
|
|
65
|
+
problemsAmount: this.$problemsAmount,
|
|
66
|
+
resolvedProblemsAmount: this.$resolvedProblemsAmount
|
|
67
|
+
},
|
|
68
|
+
filter: ({
|
|
69
|
+
gifs
|
|
70
|
+
}) => !!gifs,
|
|
71
|
+
fn: ({
|
|
72
|
+
problemsAmount,
|
|
73
|
+
resolvedProblemsAmount,
|
|
74
|
+
gifs
|
|
75
|
+
}) => {
|
|
76
|
+
if (!gifs || problemsAmount < MIN_PROBLEMS_TO_SHOW_GIF) return null;
|
|
77
|
+
return generateProblemsGifsTable(problemsAmount, resolvedProblemsAmount, gifs);
|
|
78
|
+
},
|
|
79
|
+
target: this.$problemsGifsTable
|
|
80
|
+
});
|
|
81
|
+
sample({
|
|
82
|
+
source: this.$problemsGifsTable,
|
|
83
|
+
filter: problemsGifsTable => !!problemsGifsTable,
|
|
84
|
+
fn: problemsGifsTable => {
|
|
85
|
+
if (!problemsGifsTable) return [];
|
|
86
|
+
return Object.values(problemsGifsTable).map(gif => gif.url);
|
|
87
|
+
},
|
|
88
|
+
target: this.cache.prefetchGifs
|
|
89
|
+
});
|
|
90
|
+
sample({
|
|
91
|
+
clock: this.play,
|
|
92
|
+
source: {
|
|
93
|
+
isGifCelebrationMayBeTriggered: this.$isGifTriggerable,
|
|
94
|
+
gifsGroups: this.cache.$gifs,
|
|
95
|
+
resolvedProblemsAmount: this.$resolvedProblemsAmount,
|
|
96
|
+
problemsGifsTable: this.$problemsGifsTable
|
|
97
|
+
},
|
|
98
|
+
filter: ({
|
|
99
|
+
isGifCelebrationMayBeTriggered,
|
|
100
|
+
gifsGroups,
|
|
101
|
+
problemsGifsTable
|
|
102
|
+
}) => !!(isGifCelebrationMayBeTriggered && gifsGroups && problemsGifsTable),
|
|
103
|
+
fn: sources => sources,
|
|
104
|
+
target: this.updateGifShownStatus
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
updateGifShownStatus = createEffect(({
|
|
108
|
+
gifsGroups,
|
|
109
|
+
resolvedProblemsAmount,
|
|
110
|
+
problemsGifsTable
|
|
111
|
+
}) => {
|
|
112
|
+
const gifToShow = problemsGifsTable[resolvedProblemsAmount];
|
|
113
|
+
const groupName = gifToShow.group;
|
|
114
|
+
const gifsInGroup = gifsGroups[groupName];
|
|
115
|
+
const selectedGifIndex = gifsInGroup?.findIndex(gif => gif.url === gifToShow.url);
|
|
116
|
+
if (!gifsInGroup || selectedGifIndex === -1) {
|
|
117
|
+
console.warn(`Gif with URL ${gifToShow.url} not found in group ${groupName}`);
|
|
118
|
+
return;
|
|
119
|
+
}
|
|
120
|
+
const updatedGifsInGroup = gifsInGroup.map((gif, index) => ({
|
|
121
|
+
...gif,
|
|
122
|
+
isShown: index === selectedGifIndex ? true : gif.isShown
|
|
123
|
+
}));
|
|
124
|
+
this.cache.set({
|
|
125
|
+
...gifsGroups,
|
|
126
|
+
[groupName]: updatedGifsInGroup
|
|
127
|
+
});
|
|
128
|
+
this.setActiveGif(gifToShow);
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
//# sourceMappingURL=GifCelebrations.model.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["createEffect","createEvent","createStore","sample","GifCelebrationsApi","GifCelebrationsCache","generateProblemsGifsTable","shouldRefreshGifs","MIN_PROBLEMS_TO_SHOW_GIF","GIFS_FETCHED_KEY","GifCelebrationsModel","play","stop","resetGifTriggerable","setGifTriggerable","$isGifTriggerable","reset","on","_","isGifCelebrationMayBeTriggered","resetProblemsGifsTable","$problemsGifsTable","setActiveGif","$activeGif","gif","initialize","constructor","api","problemsAmount","resolvedProblemsAmount","customLocalStorage","customGetCachePathMethod","customPrefetchMethod","cache","$problemsAmount","$resolvedProblemsAmount","localStorage","setupEventHandlers","clock","source","$gifs","filter","gifs","gifsFetchedTimestamp","getItem","target","getGifsFx","doneData","response","ok","fn","data","initialSet","setItem","Date","toISOString","problemsGifsTable","Object","values","map","url","prefetchGifs","gifsGroups","sources","updateGifShownStatus","gifToShow","groupName","group","gifsInGroup","selectedGifIndex","findIndex","console","warn","updatedGifsInGroup","index","isShown","set"],"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