@magmamath/students-features 1.3.23-rc.19 → 1.3.23-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.
Files changed (306) hide show
  1. package/dist/commonjs/features/voice/index.js +4 -4
  2. package/dist/commonjs/features/voice/index.js.map +1 -1
  3. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptionsDropdown.js +251 -0
  4. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptionsDropdown.js.map +1 -0
  5. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptionsDropdownItem.js +109 -0
  6. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptionsDropdownItem.js.map +1 -0
  7. package/dist/commonjs/features/voice/playing/hooks/{useDropdownAnimation.js → useVoiceTranscriptionsDropdown.js} +7 -8
  8. package/dist/commonjs/features/voice/playing/hooks/useVoiceTranscriptionsDropdown.js.map +1 -0
  9. package/dist/commonjs/features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.js +34 -0
  10. package/dist/commonjs/features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.js.map +1 -0
  11. package/dist/commonjs/features/voice/playing/model/Player.model.js +1 -24
  12. package/dist/commonjs/features/voice/playing/model/Player.model.js.map +1 -1
  13. package/dist/commonjs/features/voice/playing/model/TranscriptionsDownloaderModel.js +66 -0
  14. package/dist/commonjs/features/voice/playing/model/TranscriptionsDownloaderModel.js.map +1 -0
  15. package/dist/commonjs/features/voice/playing/model/VoiceFileDownloader.model.js +2 -2
  16. package/dist/commonjs/features/voice/playing/model/VoiceFileDownloader.model.js.map +1 -1
  17. package/dist/commonjs/features/voice/playing/model/VoicePlayer.model.js +172 -46
  18. package/dist/commonjs/features/voice/playing/model/VoicePlayer.model.js.map +1 -1
  19. package/dist/commonjs/features/voice/playing/model/{TranscriptionsCollection.js → VoiceTranscriptionsCollection.js} +4 -4
  20. package/dist/commonjs/features/voice/playing/model/VoiceTranscriptionsCollection.js.map +1 -0
  21. package/dist/commonjs/features/voice/playing/model/{Dropdown.model.js → VoiceTranscriptionsDropdown.model.js} +4 -4
  22. package/dist/commonjs/features/voice/playing/model/VoiceTranscriptionsDropdown.model.js.map +1 -0
  23. package/dist/commonjs/features/voice/types.js.map +1 -1
  24. package/dist/commonjs/index.js +0 -12
  25. package/dist/commonjs/index.js.map +1 -1
  26. package/dist/module/features/voice/index.js +1 -1
  27. package/dist/module/features/voice/index.js.map +1 -1
  28. package/dist/module/features/voice/playing/components/VoiceTranscriptionsDropdown.js +244 -0
  29. package/dist/module/features/voice/playing/components/VoiceTranscriptionsDropdown.js.map +1 -0
  30. package/dist/module/features/voice/playing/components/VoiceTranscriptionsDropdownItem.js +103 -0
  31. package/dist/module/features/voice/playing/components/VoiceTranscriptionsDropdownItem.js.map +1 -0
  32. package/dist/module/features/voice/playing/hooks/{useDropdownAnimation.js → useVoiceTranscriptionsDropdown.js} +5 -6
  33. package/dist/module/features/voice/playing/hooks/useVoiceTranscriptionsDropdown.js.map +1 -0
  34. package/dist/module/features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.js +29 -0
  35. package/dist/module/features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.js.map +1 -0
  36. package/dist/module/features/voice/playing/model/Player.model.js +1 -24
  37. package/dist/module/features/voice/playing/model/Player.model.js.map +1 -1
  38. package/dist/module/features/voice/playing/model/TranscriptionsDownloaderModel.js +61 -0
  39. package/dist/module/features/voice/playing/model/TranscriptionsDownloaderModel.js.map +1 -0
  40. package/dist/module/features/voice/playing/model/VoiceFileDownloader.model.js +2 -2
  41. package/dist/module/features/voice/playing/model/VoiceFileDownloader.model.js.map +1 -1
  42. package/dist/module/features/voice/playing/model/VoicePlayer.model.js +174 -48
  43. package/dist/module/features/voice/playing/model/VoicePlayer.model.js.map +1 -1
  44. package/dist/module/features/voice/playing/model/{TranscriptionsCollection.js → VoiceTranscriptionsCollection.js} +2 -2
  45. package/dist/module/features/voice/playing/model/VoiceTranscriptionsCollection.js.map +1 -0
  46. package/dist/module/features/voice/playing/model/{Dropdown.model.js → VoiceTranscriptionsDropdown.model.js} +2 -2
  47. package/dist/module/features/voice/playing/model/VoiceTranscriptionsDropdown.model.js.map +1 -0
  48. package/dist/module/features/voice/types.js.map +1 -1
  49. package/dist/module/index.js +0 -1
  50. package/dist/module/index.js.map +1 -1
  51. package/dist/typescript/commonjs/features/voice/index.d.ts +1 -1
  52. package/dist/typescript/commonjs/features/voice/index.d.ts.map +1 -1
  53. package/dist/typescript/{module/features/voice/playing/components/VoiceTranscription.d.ts → commonjs/features/voice/playing/components/VoiceTranscriptionsDropdown.d.ts} +4 -3
  54. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscriptionsDropdown.d.ts.map +1 -0
  55. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscriptionsDropdownItem.d.ts +12 -0
  56. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscriptionsDropdownItem.d.ts.map +1 -0
  57. package/dist/typescript/{module/features/voice/playing/hooks/useDropdownAnimation.d.ts → commonjs/features/voice/playing/hooks/useVoiceTranscriptionsDropdown.d.ts} +3 -3
  58. package/dist/typescript/commonjs/features/voice/playing/hooks/useVoiceTranscriptionsDropdown.d.ts.map +1 -0
  59. package/dist/typescript/commonjs/features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.d.ts +11 -0
  60. package/dist/typescript/commonjs/features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.d.ts.map +1 -0
  61. package/dist/typescript/commonjs/features/voice/playing/model/Player.model.d.ts +0 -3
  62. package/dist/typescript/commonjs/features/voice/playing/model/Player.model.d.ts.map +1 -1
  63. package/dist/typescript/commonjs/features/voice/playing/model/TranscriptionsDownloaderModel.d.ts +15 -0
  64. package/dist/typescript/commonjs/features/voice/playing/model/TranscriptionsDownloaderModel.d.ts.map +1 -0
  65. package/dist/typescript/commonjs/features/voice/playing/model/VoiceFileDownloader.model.d.ts +2 -2
  66. package/dist/typescript/commonjs/features/voice/playing/model/VoiceFileDownloader.model.d.ts.map +1 -1
  67. package/dist/typescript/commonjs/features/voice/playing/model/VoicePlayer.model.d.ts +18 -18
  68. package/dist/typescript/commonjs/features/voice/playing/model/VoicePlayer.model.d.ts.map +1 -1
  69. package/dist/typescript/{module/features/voice/playing/model/TranscriptionsCollection.d.ts → commonjs/features/voice/playing/model/VoiceTranscriptionsCollection.d.ts} +2 -2
  70. package/dist/typescript/commonjs/features/voice/playing/model/VoiceTranscriptionsCollection.d.ts.map +1 -0
  71. package/dist/typescript/commonjs/features/voice/playing/model/{Dropdown.model.d.ts → VoiceTranscriptionsDropdown.model.d.ts} +2 -2
  72. package/dist/typescript/commonjs/features/voice/playing/model/VoiceTranscriptionsDropdown.model.d.ts.map +1 -0
  73. package/dist/typescript/commonjs/features/voice/types.d.ts +1 -5
  74. package/dist/typescript/commonjs/features/voice/types.d.ts.map +1 -1
  75. package/dist/typescript/commonjs/index.d.ts +0 -1
  76. package/dist/typescript/commonjs/index.d.ts.map +1 -1
  77. package/dist/typescript/module/features/voice/index.d.ts +1 -1
  78. package/dist/typescript/module/features/voice/index.d.ts.map +1 -1
  79. package/dist/typescript/{commonjs/features/voice/playing/components/VoiceTranscription.d.ts → module/features/voice/playing/components/VoiceTranscriptionsDropdown.d.ts} +4 -3
  80. package/dist/typescript/module/features/voice/playing/components/VoiceTranscriptionsDropdown.d.ts.map +1 -0
  81. package/dist/typescript/module/features/voice/playing/components/VoiceTranscriptionsDropdownItem.d.ts +12 -0
  82. package/dist/typescript/module/features/voice/playing/components/VoiceTranscriptionsDropdownItem.d.ts.map +1 -0
  83. package/dist/typescript/{commonjs/features/voice/playing/hooks/useDropdownAnimation.d.ts → module/features/voice/playing/hooks/useVoiceTranscriptionsDropdown.d.ts} +3 -3
  84. package/dist/typescript/module/features/voice/playing/hooks/useVoiceTranscriptionsDropdown.d.ts.map +1 -0
  85. package/dist/typescript/module/features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.d.ts +11 -0
  86. package/dist/typescript/module/features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.d.ts.map +1 -0
  87. package/dist/typescript/module/features/voice/playing/model/Player.model.d.ts +0 -3
  88. package/dist/typescript/module/features/voice/playing/model/Player.model.d.ts.map +1 -1
  89. package/dist/typescript/module/features/voice/playing/model/TranscriptionsDownloaderModel.d.ts +15 -0
  90. package/dist/typescript/module/features/voice/playing/model/TranscriptionsDownloaderModel.d.ts.map +1 -0
  91. package/dist/typescript/module/features/voice/playing/model/VoiceFileDownloader.model.d.ts +2 -2
  92. package/dist/typescript/module/features/voice/playing/model/VoiceFileDownloader.model.d.ts.map +1 -1
  93. package/dist/typescript/module/features/voice/playing/model/VoicePlayer.model.d.ts +18 -18
  94. package/dist/typescript/module/features/voice/playing/model/VoicePlayer.model.d.ts.map +1 -1
  95. package/dist/typescript/{commonjs/features/voice/playing/model/TranscriptionsCollection.d.ts → module/features/voice/playing/model/VoiceTranscriptionsCollection.d.ts} +2 -2
  96. package/dist/typescript/module/features/voice/playing/model/VoiceTranscriptionsCollection.d.ts.map +1 -0
  97. package/dist/typescript/module/features/voice/playing/model/{Dropdown.model.d.ts → VoiceTranscriptionsDropdown.model.d.ts} +2 -2
  98. package/dist/typescript/module/features/voice/playing/model/VoiceTranscriptionsDropdown.model.d.ts.map +1 -0
  99. package/dist/typescript/module/features/voice/types.d.ts +1 -5
  100. package/dist/typescript/module/features/voice/types.d.ts.map +1 -1
  101. package/dist/typescript/module/index.d.ts +0 -1
  102. package/dist/typescript/module/index.d.ts.map +1 -1
  103. package/package.json +1 -1
  104. package/src/features/voice/index.ts +1 -1
  105. package/src/features/voice/playing/components/VoiceTranscriptionsDropdown.tsx +302 -0
  106. package/src/features/voice/playing/components/VoiceTranscriptionsDropdownItem.tsx +128 -0
  107. package/src/features/voice/playing/hooks/{useDropdownAnimation.ts → useVoiceTranscriptionsDropdown.ts} +5 -5
  108. package/src/features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.ts +40 -0
  109. package/src/features/voice/playing/model/Player.model.ts +1 -26
  110. package/src/features/voice/playing/model/TranscriptionsDownloaderModel.ts +80 -0
  111. package/src/features/voice/playing/model/VoiceFileDownloader.model.ts +2 -2
  112. package/src/features/voice/playing/model/VoicePlayer.model.ts +194 -57
  113. package/src/features/voice/playing/model/{TranscriptionsCollection.ts → VoiceTranscriptionsCollection.ts} +1 -1
  114. package/src/features/voice/playing/model/{Dropdown.model.ts → VoiceTranscriptionsDropdown.model.ts} +2 -2
  115. package/src/features/voice/types.ts +0 -10
  116. package/src/index.ts +0 -1
  117. package/dist/commonjs/features/translation/constants.js +0 -11
  118. package/dist/commonjs/features/translation/constants.js.map +0 -1
  119. package/dist/commonjs/features/translation/helpers.js +0 -60
  120. package/dist/commonjs/features/translation/helpers.js.map +0 -1
  121. package/dist/commonjs/features/translation/index.js +0 -105
  122. package/dist/commonjs/features/translation/index.js.map +0 -1
  123. package/dist/commonjs/features/translation/model/TranslationModel.js +0 -122
  124. package/dist/commonjs/features/translation/model/TranslationModel.js.map +0 -1
  125. package/dist/commonjs/features/translation/model/TranslationPreprocessor.js +0 -142
  126. package/dist/commonjs/features/translation/model/TranslationPreprocessor.js.map +0 -1
  127. package/dist/commonjs/features/translation/model/TranslationService.js +0 -112
  128. package/dist/commonjs/features/translation/model/TranslationService.js.map +0 -1
  129. package/dist/commonjs/features/translation/preserve/wordsToPreserve.js +0 -314
  130. package/dist/commonjs/features/translation/preserve/wordsToPreserve.js.map +0 -1
  131. package/dist/commonjs/features/translation/providers/google/GoogleTranslationProvider.js +0 -50
  132. package/dist/commonjs/features/translation/providers/google/GoogleTranslationProvider.js.map +0 -1
  133. package/dist/commonjs/features/translation/providers/google/supportedLanguages.js +0 -230
  134. package/dist/commonjs/features/translation/providers/google/supportedLanguages.js.map +0 -1
  135. package/dist/commonjs/features/translation/providers/google.types.js +0 -2
  136. package/dist/commonjs/features/translation/providers/google.types.js.map +0 -1
  137. package/dist/commonjs/features/translation/providers/translation.interface.js +0 -49
  138. package/dist/commonjs/features/translation/providers/translation.interface.js.map +0 -1
  139. package/dist/commonjs/features/translation/types.js +0 -2
  140. package/dist/commonjs/features/translation/types.js.map +0 -1
  141. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptContent.js +0 -44
  142. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptContent.js.map +0 -1
  143. package/dist/commonjs/features/voice/playing/components/VoiceTranscription.js +0 -100
  144. package/dist/commonjs/features/voice/playing/components/VoiceTranscription.js.map +0 -1
  145. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptionCollapsible.js +0 -66
  146. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptionCollapsible.js.map +0 -1
  147. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptionHeaderActions.js +0 -58
  148. package/dist/commonjs/features/voice/playing/components/VoiceTranscriptionHeaderActions.js.map +0 -1
  149. package/dist/commonjs/features/voice/playing/hooks/useDropdownAnimation.js.map +0 -1
  150. package/dist/commonjs/features/voice/playing/hooks/useVoiceTranscriptionController.js +0 -128
  151. package/dist/commonjs/features/voice/playing/hooks/useVoiceTranscriptionController.js.map +0 -1
  152. package/dist/commonjs/features/voice/playing/model/Dropdown.model.js.map +0 -1
  153. package/dist/commonjs/features/voice/playing/model/PlaybackController.js +0 -183
  154. package/dist/commonjs/features/voice/playing/model/PlaybackController.js.map +0 -1
  155. package/dist/commonjs/features/voice/playing/model/TranscriptionsCollection.js.map +0 -1
  156. package/dist/commonjs/features/voice/playing/model/TranscriptionsDownloader.model.js +0 -82
  157. package/dist/commonjs/features/voice/playing/model/TranscriptionsDownloader.model.js.map +0 -1
  158. package/dist/commonjs/features/voice/playing/model/Translation.model.js +0 -62
  159. package/dist/commonjs/features/voice/playing/model/Translation.model.js.map +0 -1
  160. package/dist/module/features/translation/constants.js +0 -7
  161. package/dist/module/features/translation/constants.js.map +0 -1
  162. package/dist/module/features/translation/helpers.js +0 -53
  163. package/dist/module/features/translation/helpers.js.map +0 -1
  164. package/dist/module/features/translation/index.js +0 -12
  165. package/dist/module/features/translation/index.js.map +0 -1
  166. package/dist/module/features/translation/model/TranslationModel.js +0 -117
  167. package/dist/module/features/translation/model/TranslationModel.js.map +0 -1
  168. package/dist/module/features/translation/model/TranslationPreprocessor.js +0 -137
  169. package/dist/module/features/translation/model/TranslationPreprocessor.js.map +0 -1
  170. package/dist/module/features/translation/model/TranslationService.js +0 -107
  171. package/dist/module/features/translation/model/TranslationService.js.map +0 -1
  172. package/dist/module/features/translation/preserve/wordsToPreserve.js +0 -310
  173. package/dist/module/features/translation/preserve/wordsToPreserve.js.map +0 -1
  174. package/dist/module/features/translation/providers/google/GoogleTranslationProvider.js +0 -45
  175. package/dist/module/features/translation/providers/google/GoogleTranslationProvider.js.map +0 -1
  176. package/dist/module/features/translation/providers/google/supportedLanguages.js +0 -225
  177. package/dist/module/features/translation/providers/google/supportedLanguages.js.map +0 -1
  178. package/dist/module/features/translation/providers/google.types.js +0 -2
  179. package/dist/module/features/translation/providers/google.types.js.map +0 -1
  180. package/dist/module/features/translation/providers/translation.interface.js +0 -44
  181. package/dist/module/features/translation/providers/translation.interface.js.map +0 -1
  182. package/dist/module/features/translation/types.js +0 -2
  183. package/dist/module/features/translation/types.js.map +0 -1
  184. package/dist/module/features/voice/playing/components/VoiceTranscriptContent.js +0 -38
  185. package/dist/module/features/voice/playing/components/VoiceTranscriptContent.js.map +0 -1
  186. package/dist/module/features/voice/playing/components/VoiceTranscription.js +0 -94
  187. package/dist/module/features/voice/playing/components/VoiceTranscription.js.map +0 -1
  188. package/dist/module/features/voice/playing/components/VoiceTranscriptionCollapsible.js +0 -58
  189. package/dist/module/features/voice/playing/components/VoiceTranscriptionCollapsible.js.map +0 -1
  190. package/dist/module/features/voice/playing/components/VoiceTranscriptionHeaderActions.js +0 -52
  191. package/dist/module/features/voice/playing/components/VoiceTranscriptionHeaderActions.js.map +0 -1
  192. package/dist/module/features/voice/playing/hooks/useDropdownAnimation.js.map +0 -1
  193. package/dist/module/features/voice/playing/hooks/useVoiceTranscriptionController.js +0 -123
  194. package/dist/module/features/voice/playing/hooks/useVoiceTranscriptionController.js.map +0 -1
  195. package/dist/module/features/voice/playing/model/Dropdown.model.js.map +0 -1
  196. package/dist/module/features/voice/playing/model/PlaybackController.js +0 -178
  197. package/dist/module/features/voice/playing/model/PlaybackController.js.map +0 -1
  198. package/dist/module/features/voice/playing/model/TranscriptionsCollection.js.map +0 -1
  199. package/dist/module/features/voice/playing/model/TranscriptionsDownloader.model.js +0 -77
  200. package/dist/module/features/voice/playing/model/TranscriptionsDownloader.model.js.map +0 -1
  201. package/dist/module/features/voice/playing/model/Translation.model.js +0 -57
  202. package/dist/module/features/voice/playing/model/Translation.model.js.map +0 -1
  203. package/dist/typescript/commonjs/features/translation/constants.d.ts +0 -5
  204. package/dist/typescript/commonjs/features/translation/constants.d.ts.map +0 -1
  205. package/dist/typescript/commonjs/features/translation/helpers.d.ts +0 -9
  206. package/dist/typescript/commonjs/features/translation/helpers.d.ts.map +0 -1
  207. package/dist/typescript/commonjs/features/translation/index.d.ts +0 -12
  208. package/dist/typescript/commonjs/features/translation/index.d.ts.map +0 -1
  209. package/dist/typescript/commonjs/features/translation/model/TranslationModel.d.ts +0 -33
  210. package/dist/typescript/commonjs/features/translation/model/TranslationModel.d.ts.map +0 -1
  211. package/dist/typescript/commonjs/features/translation/model/TranslationPreprocessor.d.ts +0 -34
  212. package/dist/typescript/commonjs/features/translation/model/TranslationPreprocessor.d.ts.map +0 -1
  213. package/dist/typescript/commonjs/features/translation/model/TranslationService.d.ts +0 -40
  214. package/dist/typescript/commonjs/features/translation/model/TranslationService.d.ts.map +0 -1
  215. package/dist/typescript/commonjs/features/translation/preserve/wordsToPreserve.d.ts +0 -3
  216. package/dist/typescript/commonjs/features/translation/preserve/wordsToPreserve.d.ts.map +0 -1
  217. package/dist/typescript/commonjs/features/translation/providers/google/GoogleTranslationProvider.d.ts +0 -17
  218. package/dist/typescript/commonjs/features/translation/providers/google/GoogleTranslationProvider.d.ts.map +0 -1
  219. package/dist/typescript/commonjs/features/translation/providers/google/supportedLanguages.d.ts +0 -209
  220. package/dist/typescript/commonjs/features/translation/providers/google/supportedLanguages.d.ts.map +0 -1
  221. package/dist/typescript/commonjs/features/translation/providers/google.types.d.ts +0 -15
  222. package/dist/typescript/commonjs/features/translation/providers/google.types.d.ts.map +0 -1
  223. package/dist/typescript/commonjs/features/translation/providers/translation.interface.d.ts +0 -30
  224. package/dist/typescript/commonjs/features/translation/providers/translation.interface.d.ts.map +0 -1
  225. package/dist/typescript/commonjs/features/translation/types.d.ts +0 -27
  226. package/dist/typescript/commonjs/features/translation/types.d.ts.map +0 -1
  227. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscriptContent.d.ts +0 -8
  228. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscriptContent.d.ts.map +0 -1
  229. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscription.d.ts.map +0 -1
  230. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscriptionCollapsible.d.ts +0 -10
  231. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscriptionCollapsible.d.ts.map +0 -1
  232. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscriptionHeaderActions.d.ts +0 -12
  233. package/dist/typescript/commonjs/features/voice/playing/components/VoiceTranscriptionHeaderActions.d.ts.map +0 -1
  234. package/dist/typescript/commonjs/features/voice/playing/hooks/useDropdownAnimation.d.ts.map +0 -1
  235. package/dist/typescript/commonjs/features/voice/playing/hooks/useVoiceTranscriptionController.d.ts +0 -30
  236. package/dist/typescript/commonjs/features/voice/playing/hooks/useVoiceTranscriptionController.d.ts.map +0 -1
  237. package/dist/typescript/commonjs/features/voice/playing/model/Dropdown.model.d.ts.map +0 -1
  238. package/dist/typescript/commonjs/features/voice/playing/model/PlaybackController.d.ts +0 -28
  239. package/dist/typescript/commonjs/features/voice/playing/model/PlaybackController.d.ts.map +0 -1
  240. package/dist/typescript/commonjs/features/voice/playing/model/TranscriptionsCollection.d.ts.map +0 -1
  241. package/dist/typescript/commonjs/features/voice/playing/model/TranscriptionsDownloader.model.d.ts +0 -19
  242. package/dist/typescript/commonjs/features/voice/playing/model/TranscriptionsDownloader.model.d.ts.map +0 -1
  243. package/dist/typescript/commonjs/features/voice/playing/model/Translation.model.d.ts +0 -25
  244. package/dist/typescript/commonjs/features/voice/playing/model/Translation.model.d.ts.map +0 -1
  245. package/dist/typescript/module/features/translation/constants.d.ts +0 -5
  246. package/dist/typescript/module/features/translation/constants.d.ts.map +0 -1
  247. package/dist/typescript/module/features/translation/helpers.d.ts +0 -9
  248. package/dist/typescript/module/features/translation/helpers.d.ts.map +0 -1
  249. package/dist/typescript/module/features/translation/index.d.ts +0 -12
  250. package/dist/typescript/module/features/translation/index.d.ts.map +0 -1
  251. package/dist/typescript/module/features/translation/model/TranslationModel.d.ts +0 -33
  252. package/dist/typescript/module/features/translation/model/TranslationModel.d.ts.map +0 -1
  253. package/dist/typescript/module/features/translation/model/TranslationPreprocessor.d.ts +0 -34
  254. package/dist/typescript/module/features/translation/model/TranslationPreprocessor.d.ts.map +0 -1
  255. package/dist/typescript/module/features/translation/model/TranslationService.d.ts +0 -40
  256. package/dist/typescript/module/features/translation/model/TranslationService.d.ts.map +0 -1
  257. package/dist/typescript/module/features/translation/preserve/wordsToPreserve.d.ts +0 -3
  258. package/dist/typescript/module/features/translation/preserve/wordsToPreserve.d.ts.map +0 -1
  259. package/dist/typescript/module/features/translation/providers/google/GoogleTranslationProvider.d.ts +0 -17
  260. package/dist/typescript/module/features/translation/providers/google/GoogleTranslationProvider.d.ts.map +0 -1
  261. package/dist/typescript/module/features/translation/providers/google/supportedLanguages.d.ts +0 -209
  262. package/dist/typescript/module/features/translation/providers/google/supportedLanguages.d.ts.map +0 -1
  263. package/dist/typescript/module/features/translation/providers/google.types.d.ts +0 -15
  264. package/dist/typescript/module/features/translation/providers/google.types.d.ts.map +0 -1
  265. package/dist/typescript/module/features/translation/providers/translation.interface.d.ts +0 -30
  266. package/dist/typescript/module/features/translation/providers/translation.interface.d.ts.map +0 -1
  267. package/dist/typescript/module/features/translation/types.d.ts +0 -27
  268. package/dist/typescript/module/features/translation/types.d.ts.map +0 -1
  269. package/dist/typescript/module/features/voice/playing/components/VoiceTranscriptContent.d.ts +0 -8
  270. package/dist/typescript/module/features/voice/playing/components/VoiceTranscriptContent.d.ts.map +0 -1
  271. package/dist/typescript/module/features/voice/playing/components/VoiceTranscription.d.ts.map +0 -1
  272. package/dist/typescript/module/features/voice/playing/components/VoiceTranscriptionCollapsible.d.ts +0 -10
  273. package/dist/typescript/module/features/voice/playing/components/VoiceTranscriptionCollapsible.d.ts.map +0 -1
  274. package/dist/typescript/module/features/voice/playing/components/VoiceTranscriptionHeaderActions.d.ts +0 -12
  275. package/dist/typescript/module/features/voice/playing/components/VoiceTranscriptionHeaderActions.d.ts.map +0 -1
  276. package/dist/typescript/module/features/voice/playing/hooks/useDropdownAnimation.d.ts.map +0 -1
  277. package/dist/typescript/module/features/voice/playing/hooks/useVoiceTranscriptionController.d.ts +0 -30
  278. package/dist/typescript/module/features/voice/playing/hooks/useVoiceTranscriptionController.d.ts.map +0 -1
  279. package/dist/typescript/module/features/voice/playing/model/Dropdown.model.d.ts.map +0 -1
  280. package/dist/typescript/module/features/voice/playing/model/PlaybackController.d.ts +0 -28
  281. package/dist/typescript/module/features/voice/playing/model/PlaybackController.d.ts.map +0 -1
  282. package/dist/typescript/module/features/voice/playing/model/TranscriptionsCollection.d.ts.map +0 -1
  283. package/dist/typescript/module/features/voice/playing/model/TranscriptionsDownloader.model.d.ts +0 -19
  284. package/dist/typescript/module/features/voice/playing/model/TranscriptionsDownloader.model.d.ts.map +0 -1
  285. package/dist/typescript/module/features/voice/playing/model/Translation.model.d.ts +0 -25
  286. package/dist/typescript/module/features/voice/playing/model/Translation.model.d.ts.map +0 -1
  287. package/src/features/translation/constants.ts +0 -4
  288. package/src/features/translation/helpers.ts +0 -63
  289. package/src/features/translation/index.ts +0 -30
  290. package/src/features/translation/model/TranslationModel.ts +0 -174
  291. package/src/features/translation/model/TranslationPreprocessor.ts +0 -171
  292. package/src/features/translation/model/TranslationService.ts +0 -148
  293. package/src/features/translation/preserve/wordsToPreserve.ts +0 -87
  294. package/src/features/translation/providers/google/GoogleTranslationProvider.ts +0 -50
  295. package/src/features/translation/providers/google/supportedLanguages.ts +0 -229
  296. package/src/features/translation/providers/google.types.ts +0 -16
  297. package/src/features/translation/providers/translation.interface.ts +0 -63
  298. package/src/features/translation/types.ts +0 -30
  299. package/src/features/voice/playing/components/VoiceTranscriptContent.tsx +0 -37
  300. package/src/features/voice/playing/components/VoiceTranscription.tsx +0 -104
  301. package/src/features/voice/playing/components/VoiceTranscriptionCollapsible.tsx +0 -59
  302. package/src/features/voice/playing/components/VoiceTranscriptionHeaderActions.tsx +0 -61
  303. package/src/features/voice/playing/hooks/useVoiceTranscriptionController.ts +0 -171
  304. package/src/features/voice/playing/model/PlaybackController.ts +0 -213
  305. package/src/features/voice/playing/model/TranscriptionsDownloader.model.ts +0 -88
  306. package/src/features/voice/playing/model/Translation.model.ts +0 -75
@@ -58,14 +58,14 @@ Object.keys(_VoicePlayerModel).forEach(function (key) {
58
58
  }
59
59
  });
60
60
  });
61
- var _VoiceTranscription = require("./playing/components/VoiceTranscription.js");
62
- Object.keys(_VoiceTranscription).forEach(function (key) {
61
+ var _VoiceTranscriptionsDropdown = require("./playing/components/VoiceTranscriptionsDropdown.js");
62
+ Object.keys(_VoiceTranscriptionsDropdown).forEach(function (key) {
63
63
  if (key === "default" || key === "__esModule") return;
64
- if (key in exports && exports[key] === _VoiceTranscription[key]) return;
64
+ if (key in exports && exports[key] === _VoiceTranscriptionsDropdown[key]) return;
65
65
  Object.defineProperty(exports, key, {
66
66
  enumerable: true,
67
67
  get: function () {
68
- return _VoiceTranscription[key];
68
+ return _VoiceTranscriptionsDropdown[key];
69
69
  }
70
70
  });
71
71
  });
@@ -1 +1 @@
1
- {"version":3,"names":["_VoiceRecord","require","Object","keys","forEach","key","exports","defineProperty","enumerable","get","_VoiceRecordModel","_VoiceRecordDeleteModal","_VoiceRecordUndoModal","_VoicePlayerModel","_VoiceTranscription","_VoiceIcon","_constants","_types"],"sourceRoot":"../../../../src","sources":["features/voice/index.ts"],"mappings":";;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,YAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAL,YAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAT,YAAA,CAAAK,GAAA;IAAA;EAAA;AAAA;AACA,IAAAK,iBAAA,GAAAT,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAO,iBAAA,EAAAN,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAK,iBAAA,CAAAL,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAC,iBAAA,CAAAL,GAAA;IAAA;EAAA;AAAA;AACA,IAAAM,uBAAA,GAAAV,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAQ,uBAAA,EAAAP,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAM,uBAAA,CAAAN,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC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AAY,UAAA,EAAAX,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAU,UAAA,CAAAV,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAM,UAAA,CAAAV,GAAA;IAAA;EAAA;AAAA;AACA,IAAAW,UAAA,GAAAf,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAa,UAAA,EAAAZ,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAW,UAAA,CAAAX,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAO,UAAA,CAAAX,GAAA;IAAA;EAAA;AAAA;AACA,IAAAY,MAAA,GAAAhB,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAc,MAAA,EAAAb,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAY,MAAA,CAAAZ,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAQ,MAAA,CAAAZ,GAAA;IAAA;EAAA;AAAA","ignoreList":[]}
1
+ {"version":3,"names":["_VoiceRecord","require","Object","keys","forEach","key","exports","defineProperty","enumerable","get","_VoiceRecordModel","_VoiceRecordDeleteModal","_VoiceRecordUndoModal","_VoicePlayerModel","_VoiceTranscriptionsDropdown","_VoiceIcon","_constants","_types"],"sourceRoot":"../../../../src","sources":["features/voice/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A,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAM,UAAA,CAAAV,GAAA;IAAA;EAAA;AAAA;AACA,IAAAW,UAAA,GAAAf,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAa,UAAA,EAAAZ,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAW,UAAA,CAAAX,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAO,UAAA,CAAAX,GAAA;IAAA;EAAA;AAAA;AACA,IAAAY,MAAA,GAAAhB,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAc,MAAA,EAAAb,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAA,GAAA,IAAAC,OAAA,IAAAA,OAAA,CAAAD,GAAA,MAAAY,MAAA,CAAAZ,GAAA;EAAAH,MAAA,CAAAK,cAAA,CAAAD,OAAA,EAAAD,GAAA;IAAAG,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAQ,MAAA,CAAAZ,GAAA;IAAA;EAAA;AAAA","ignoreList":[]}
@@ -0,0 +1,251 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.VoiceTranscriptionsDropdown = void 0;
7
+ var _reactNativeUi = require("@magmamath/react-native-ui");
8
+ var _effectorReact = require("effector-react");
9
+ var _react = _interopRequireWildcard(require("react"));
10
+ var _reactNative = require("react-native");
11
+ var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
12
+ var _types = require("../../types.js");
13
+ var _useVoiceTranscriptionsDropdown = require("../hooks/useVoiceTranscriptionsDropdown.js");
14
+ var _index = require("../model/index.js");
15
+ var _VoiceTranscriptionsDropdownItem = require("./VoiceTranscriptionsDropdownItem.js");
16
+ var _constants = require("../../constants.js");
17
+ var _i18n = require("../../../../i18n/i18n.js");
18
+ var _PlayButton = require("../../../../shared/components/PlayButton.js");
19
+ var _helpers = require("../../helpers.js");
20
+ var _jsxRuntime = require("react/jsx-runtime");
21
+ 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); }
22
+ 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; }
23
+ const AnimatedTouchableOpacity = _reactNativeReanimated.default.createAnimatedComponent(_reactNative.TouchableOpacity);
24
+ const VoiceTranscriptionsDropdown = ({
25
+ style,
26
+ model,
27
+ answers,
28
+ attemptOffset,
29
+ onAttemptOffsetChange,
30
+ attemptsCount,
31
+ problemId,
32
+ variant = _types.VoiceTranscriptionVariant.SMALL
33
+ }) => {
34
+ const [attempts, setAttempts] = (0, _react.useState)([]);
35
+ const scrollRef = (0, _react.useRef)(null);
36
+ const scrollViewRef = (0, _react.useRef)(null);
37
+ const itemLayoutsRef = (0, _react.useRef)(new Map());
38
+ const answersRef = (0, _react.useRef)(answers);
39
+ answersRef.current = answers;
40
+ const t = (0, _i18n.useText)();
41
+ const [currentAttempt, transcriptsLoaded, playerState, isDropdownExpanded] = (0, _effectorReact.useUnit)([model.$currentAttempt, model.loader.$transcriptsLoaded, model.$playerState, model.dropdown.$isExpanded]);
42
+ const activeAttempt = (0, _helpers.getActiveAttempt)(attemptOffset, attemptsCount);
43
+ const answersKey = (0, _react.useMemo)(() => answers.map(a => `${a._id}:${a.audioFileId ?? ''}`).join(','), [answers]);
44
+ const hasActiveTranscript = activeAttempt !== null && answers?.[activeAttempt - 1]?.audioFileId !== undefined;
45
+ const playButtonState = {
46
+ isActive: playerState !== _index.PlayerState.IDLE,
47
+ isLoading: playerState === _index.PlayerState.LOADING,
48
+ status: (0, _helpers.getAudioStatus)(playerState)
49
+ };
50
+ const {
51
+ listAnimatedStyle,
52
+ iconAnimatedStyle,
53
+ onListLayout
54
+ } = (0, _useVoiceTranscriptionsDropdown.useVoiceTranscriptionsDropdown)(model.dropdown);
55
+ const handleItemLayout = (0, _react.useCallback)((id, event) => {
56
+ itemLayoutsRef.current.set(id, event.nativeEvent.layout.y);
57
+ }, []);
58
+ const scrollToAttempt = (0, _react.useCallback)(attemptNumber => {
59
+ if (_reactNativeUi.IS_WEB) {
60
+ const item = attempts.find(item => item.attemptNumber === attemptNumber);
61
+ if (item) {
62
+ const y = itemLayoutsRef.current.get(item._id);
63
+ if (y !== undefined) {
64
+ scrollViewRef.current?.scrollTo({
65
+ y,
66
+ animated: true
67
+ });
68
+ }
69
+ }
70
+ return;
71
+ }
72
+ const index = attempts.findIndex(item => item.attemptNumber === attemptNumber);
73
+ if (index !== -1) {
74
+ scrollRef.current?.scrollToIndex({
75
+ index,
76
+ animated: true,
77
+ viewPosition: 0
78
+ });
79
+ }
80
+ }, [attempts]);
81
+ const handleItemToggle = (0, _react.useCallback)(attempt => {
82
+ if (onAttemptOffsetChange && attemptsCount !== undefined) {
83
+ onAttemptOffsetChange(attemptsCount - attempt);
84
+ }
85
+ }, [onAttemptOffsetChange, attemptsCount]);
86
+ const handlePlayPress = (0, _react.useCallback)(() => {
87
+ if (activeAttempt) {
88
+ model.togglePlayPause(activeAttempt);
89
+ }
90
+ }, [model, activeAttempt]);
91
+ const handleScrollToIndexFailed = (0, _react.useCallback)(info => {
92
+ setTimeout(() => {
93
+ scrollRef.current?.scrollToIndex({
94
+ index: info.index,
95
+ animated: true,
96
+ viewPosition: 0
97
+ });
98
+ }, 100);
99
+ }, []);
100
+ (0, _react.useEffect)(() => {
101
+ model.reinitializePlayer();
102
+ return () => model.cleanup();
103
+ }, [model]);
104
+ (0, _react.useEffect)(() => {
105
+ const isLastAttemptsWithoutDrowing = !answers[answers.length - 1].drawing;
106
+ if (answers.length > 0 && isLastAttemptsWithoutDrowing) {
107
+ model.dropdown.setExpanded(true);
108
+ } else {
109
+ model.dropdown.setExpanded(false);
110
+ }
111
+ model.resetPlayer();
112
+ }, [problemId]);
113
+ (0, _react.useEffect)(() => {
114
+ if (answersRef.current.some(answer => answer.audioFileId)) {
115
+ model.initializeWithAudios(answersRef.current);
116
+ model.loader.loadAllTranscripts();
117
+ }
118
+ }, [model, answersKey]);
119
+ (0, _react.useEffect)(() => {
120
+ model.stopAudio();
121
+ }, [activeAttempt]);
122
+ (0, _react.useEffect)(() => {
123
+ const allAttempts = model.getAllAttempts();
124
+ setAttempts(allAttempts);
125
+ }, [answersKey, transcriptsLoaded, currentAttempt, model]);
126
+ (0, _react.useEffect)(() => {
127
+ if (isDropdownExpanded && activeAttempt !== null) {
128
+ setTimeout(() => {
129
+ scrollToAttempt(activeAttempt);
130
+ }, 500);
131
+ }
132
+ }, [isDropdownExpanded, answersKey]);
133
+ const renderItem = (0, _react.useCallback)(({
134
+ item
135
+ }) => {
136
+ const isLoading = model.loader.isTranscriptLoading(item.attemptNumber);
137
+ const transcript = model.loader.getTranscript(item.attemptNumber);
138
+ const isActive = activeAttempt === item.attemptNumber;
139
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_VoiceTranscriptionsDropdownItem.VoiceTranscriptionsDropdownItem, {
140
+ isLoading: isActive && isLoading,
141
+ attempt: item.attemptNumber,
142
+ content: transcript && transcript !== _constants.NO_AUDIO_BE_MESSAGE ? transcript : t('voice.transcriptNotAvailable'),
143
+ isActive: isActive,
144
+ onToggle: handleItemToggle,
145
+ scrollToAttempt: scrollToAttempt
146
+ });
147
+ }, [model, activeAttempt, t, handleItemToggle, scrollToAttempt]);
148
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNativeReanimated.default.View, {
149
+ style: [styles.container, style],
150
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
151
+ style: styles.header,
152
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeUi.Typography, {
153
+ style: styles.title,
154
+ variant: "h7",
155
+ children: t('voice.transcriptions')
156
+ }), hasActiveTranscript && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
157
+ entering: _reactNativeReanimated.FadeIn.duration(120),
158
+ exiting: _reactNativeReanimated.FadeOut.duration(120),
159
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_PlayButton.PlayButton, {
160
+ state: playButtonState,
161
+ onPress: handlePlayPress,
162
+ activityIndicatorColor: _reactNativeUi.COLORS.NEUTRAL_1
163
+ })
164
+ })]
165
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
166
+ style: [listAnimatedStyle, {
167
+ overflow: 'hidden'
168
+ }],
169
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
170
+ onLayout: onListLayout,
171
+ style: styles.listContainer,
172
+ children: _reactNativeUi.IS_WEB ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeUi.ScrollableListScrollView, {
173
+ bounces: false,
174
+ ref: scrollViewRef,
175
+ hideShadow: true,
176
+ style: styles.list,
177
+ contentContainerStyle: styles.listContent,
178
+ children: attempts.map(item => /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
179
+ onLayout: e => handleItemLayout(item._id, e),
180
+ children: renderItem({
181
+ item
182
+ })
183
+ }, item._id))
184
+ }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeUi.ScrollableList, {
185
+ bounces: false,
186
+ ref: scrollRef,
187
+ hideShadow: true,
188
+ data: attempts,
189
+ keyExtractor: item => item._id,
190
+ onScrollToIndexFailed: handleScrollToIndexFailed,
191
+ renderItem: renderItem,
192
+ contentContainerStyle: styles.listContent
193
+ })
194
+ })
195
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedTouchableOpacity, {
196
+ style: [styles.expandButton, iconAnimatedStyle],
197
+ onPress: () => model.dropdown.toggleExpand(),
198
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeUi.CaretDownIcon, {
199
+ size: 22
200
+ })
201
+ })]
202
+ });
203
+ };
204
+ exports.VoiceTranscriptionsDropdown = VoiceTranscriptionsDropdown;
205
+ const styles = _reactNative.StyleSheet.create({
206
+ container: {
207
+ position: 'absolute',
208
+ top: 56,
209
+ left: 8,
210
+ width: 222,
211
+ maxHeight: 405,
212
+ minHeight: 51,
213
+ padding: 4,
214
+ boxShadow: '0px 1px 3px 0px rgba(51, 51, 51, 0.25)',
215
+ borderRadius: 12,
216
+ backgroundColor: _reactNativeUi.COLORS.NEUTRAL_1,
217
+ overflow: 'hidden'
218
+ },
219
+ // hugeContainer: {
220
+ // width: '98%',
221
+ // height: '100%',
222
+ // },
223
+ header: {
224
+ flexDirection: 'row',
225
+ justifyContent: 'space-between',
226
+ alignItems: 'center',
227
+ padding: 4,
228
+ marginBottom: 4,
229
+ height: 32
230
+ },
231
+ title: {
232
+ color: _reactNativeUi.COLORS.NEUTRAL_9,
233
+ marginLeft: 4
234
+ },
235
+ list: {
236
+ flex: 1
237
+ },
238
+ expandButton: {
239
+ justifyContent: 'center',
240
+ alignItems: 'center'
241
+ },
242
+ listContainer: {
243
+ position: 'absolute',
244
+ maxHeight: _constants.DROPDOWN_MAX_CONTENT_HEIGHT,
245
+ width: '100%'
246
+ },
247
+ listContent: {
248
+ paddingHorizontal: 4
249
+ }
250
+ });
251
+ //# sourceMappingURL=VoiceTranscriptionsDropdown.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_reactNativeUi","require","_effectorReact","_react","_interopRequireWildcard","_reactNative","_reactNativeReanimated","_types","_useVoiceTranscriptionsDropdown","_index","_VoiceTranscriptionsDropdownItem","_constants","_i18n","_PlayButton","_helpers","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","AnimatedTouchableOpacity","Animated","createAnimatedComponent","TouchableOpacity","VoiceTranscriptionsDropdown","style","model","answers","attemptOffset","onAttemptOffsetChange","attemptsCount","problemId","variant","VoiceTranscriptionVariant","SMALL","attempts","setAttempts","useState","scrollRef","useRef","scrollViewRef","itemLayoutsRef","Map","answersRef","current","useText","currentAttempt","transcriptsLoaded","playerState","isDropdownExpanded","useUnit","$currentAttempt","loader","$transcriptsLoaded","$playerState","dropdown","$isExpanded","activeAttempt","getActiveAttempt","answersKey","useMemo","map","_id","audioFileId","join","hasActiveTranscript","undefined","playButtonState","isActive","PlayerState","IDLE","isLoading","LOADING","status","getAudioStatus","listAnimatedStyle","iconAnimatedStyle","onListLayout","useVoiceTranscriptionsDropdown","handleItemLayout","useCallback","id","event","nativeEvent","layout","y","scrollToAttempt","attemptNumber","IS_WEB","item","find","scrollTo","animated","index","findIndex","scrollToIndex","viewPosition","handleItemToggle","attempt","handlePlayPress","togglePlayPause","handleScrollToIndexFailed","info","setTimeout","useEffect","reinitializePlayer","cleanup","isLastAttemptsWithoutDrowing","length","drawing","setExpanded","resetPlayer","some","answer","initializeWithAudios","loadAllTranscripts","stopAudio","allAttempts","getAllAttempts","renderItem","isTranscriptLoading","transcript","getTranscript","jsx","VoiceTranscriptionsDropdownItem","content","NO_AUDIO_BE_MESSAGE","onToggle","jsxs","View","styles","container","children","header","Typography","title","entering","FadeIn","duration","exiting","FadeOut","PlayButton","state","onPress","activityIndicatorColor","COLORS","NEUTRAL_1","overflow","onLayout","listContainer","ScrollableListScrollView","bounces","ref","hideShadow","list","contentContainerStyle","listContent","ScrollableList","data","keyExtractor","onScrollToIndexFailed","expandButton","toggleExpand","CaretDownIcon","size","exports","StyleSheet","create","position","top","left","width","maxHeight","minHeight","padding","boxShadow","borderRadius","backgroundColor","flexDirection","justifyContent","alignItems","marginBottom","height","color","NEUTRAL_9","marginLeft","flex","DROPDOWN_MAX_CONTENT_HEIGHT","paddingHorizontal"],"sourceRoot":"../../../../../../src","sources":["features/voice/playing/components/VoiceTranscriptionsDropdown.tsx"],"mappings":";;;;;;AAAA,IAAAA,cAAA,GAAAC,OAAA;AAQA,IAAAC,cAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAC,uBAAA,CAAAH,OAAA;AACA,IAAAI,YAAA,GAAAJ,OAAA;AAUA,IAAAK,sBAAA,GAAAF,uBAAA,CAAAH,OAAA;AACA,IAAAM,MAAA,GAAAN,OAAA;AACA,IAAAO,+BAAA,GAAAP,OAAA;AACA,IAAAQ,MAAA,GAAAR,OAAA;AACA,IAAAS,gCAAA,GAAAT,OAAA;AACA,IAAAU,UAAA,GAAAV,OAAA;AACA,IAAAW,KAAA,GAAAX,OAAA;AACA,IAAAY,WAAA,GAAAZ,OAAA;AACA,IAAAa,QAAA,GAAAb,OAAA;AAAgE,IAAAc,WAAA,GAAAd,OAAA;AAAA,SAAAe,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,SAAAb,wBAAAa,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,UA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109 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.VoiceTranscriptionsDropdownItem = void 0;
7
+ var _reactNative = require("react-native");
8
+ var _react = _interopRequireWildcard(require("react"));
9
+ var _reactNativeUi = require("@magmamath/react-native-ui");
10
+ var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
11
+ var _useVoiceTranscriptionsDropdownItemAnimation = require("../hooks/useVoiceTranscriptionsDropdownItemAnimation.js");
12
+ var _i18n = require("../../../../i18n/i18n.js");
13
+ var _jsxRuntime = require("react/jsx-runtime");
14
+ 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); }
15
+ 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; }
16
+ const VoiceTranscriptionsDropdownItem = exports.VoiceTranscriptionsDropdownItem = /*#__PURE__*/(0, _react.memo)(({
17
+ attempt,
18
+ content,
19
+ isActive,
20
+ isLoading,
21
+ onToggle,
22
+ scrollToAttempt
23
+ }) => {
24
+ const t = (0, _i18n.useText)();
25
+ const isActiveRef = (0, _react.useRef)(isActive);
26
+ isActiveRef.current = isActive;
27
+ const {
28
+ contentAnimatedStyle,
29
+ onLayout,
30
+ progress
31
+ } = (0, _useVoiceTranscriptionsDropdownItemAnimation.useVoiceTranscriptionsDropdownItemAnimation)(isActive);
32
+ const handleScrollToAttempt = (0, _react.useCallback)(attemptNumber => {
33
+ if (!isActiveRef.current) return;
34
+ scrollToAttempt(attemptNumber);
35
+ }, [scrollToAttempt]);
36
+ (0, _reactNativeReanimated.useAnimatedReaction)(() => progress.value, progress => {
37
+ if (progress === 1 && isActive) {
38
+ (0, _reactNativeReanimated.runOnJS)(handleScrollToAttempt)(attempt);
39
+ }
40
+ }, [progress, attempt, isActive]);
41
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
42
+ style: styles.container,
43
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Pressable, {
44
+ disabled: isActive,
45
+ style: styles.itemHeader,
46
+ onPress: () => onToggle(attempt),
47
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeUi.Button, {
48
+ onPress: () => !isActive && onToggle(attempt),
49
+ size: _reactNativeUi.ButtonSize.SMALL,
50
+ variant: _reactNativeUi.ButtonVariant.TERTIARY,
51
+ style: {
52
+ text: {
53
+ textTransform: 'uppercase',
54
+ color: isActive ? _reactNativeUi.COLORS.NEUTRAL_9 : _reactNativeUi.COLORS.NEUTRAL_7
55
+ }
56
+ },
57
+ children: t('voice.attempt', {
58
+ number: String(attempt)
59
+ })
60
+ })
61
+ }), isLoading ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
62
+ style: styles.loaderContainer,
63
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeUi.Loader, {
64
+ size: _reactNativeUi.LoaderSize.SMALL,
65
+ color: _reactNativeUi.LoaderColor.BLUE
66
+ })
67
+ }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
68
+ style: contentAnimatedStyle,
69
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
70
+ onLayout: onLayout,
71
+ style: styles.contentWrapper,
72
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeUi.Typography, {
73
+ variant: "h8",
74
+ style: [styles.itemContent, {
75
+ color: isActive ? _reactNativeUi.COLORS.NEUTRAL_9 : _reactNativeUi.COLORS.NEUTRAL_7
76
+ }],
77
+ children: content
78
+ })
79
+ })
80
+ })]
81
+ });
82
+ });
83
+ const styles = _reactNative.StyleSheet.create({
84
+ container: {
85
+ borderTopWidth: 1,
86
+ borderColor: _reactNativeUi.COLORS.NEUTRAL_3
87
+ },
88
+ itemHeader: {
89
+ flexDirection: 'row',
90
+ justifyContent: 'space-between',
91
+ alignItems: 'center',
92
+ width: '100%',
93
+ paddingVertical: 8
94
+ },
95
+ itemContent: {
96
+ paddingHorizontal: 8
97
+ },
98
+ contentWrapper: {
99
+ width: '100%',
100
+ position: 'absolute'
101
+ },
102
+ loaderContainer: {
103
+ justifyContent: 'center',
104
+ alignItems: 'center',
105
+ paddingTop: 4,
106
+ paddingBottom: 8
107
+ }
108
+ });
109
+ //# sourceMappingURL=VoiceTranscriptionsDropdownItem.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_reactNative","require","_react","_interopRequireWildcard","_reactNativeUi","_reactNativeReanimated","_useVoiceTranscriptionsDropdownItemAnimation","_i18n","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","VoiceTranscriptionsDropdownItem","exports","memo","attempt","content","isActive","isLoading","onToggle","scrollToAttempt","useText","isActiveRef","useRef","current","contentAnimatedStyle","onLayout","progress","useVoiceTranscriptionsDropdownItemAnimation","handleScrollToAttempt","useCallback","attemptNumber","useAnimatedReaction","value","runOnJS","jsxs","View","style","styles","container","children","jsx","Pressable","disabled","itemHeader","onPress","Button","size","ButtonSize","SMALL","variant","ButtonVariant","TERTIARY","text","textTransform","color","COLORS","NEUTRAL_9","NEUTRAL_7","number","String","loaderContainer","Loader","LoaderSize","LoaderColor","BLUE","contentWrapper","Typography","itemContent","StyleSheet","create","borderTopWidth","borderColor","NEUTRAL_3","flexDirection","justifyContent","alignItems","width","paddingVertical","paddingHoriz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,eACrD,IAAAjD,WAAA,CAAAkD,GAAA,EAACtD,cAAA,CAAAgF,UAAU;UACTjB,OAAO,EAAC,IAAI;UACZb,KAAK,EAAE,CACLC,MAAM,CAAC8B,WAAW,EAClB;YACEb,KAAK,EAAEtC,QAAQ,GAAGuC,qBAAM,CAACC,SAAS,GAAGD,qBAAM,CAACE;UAC9C,CAAC,CACD;UAAAlB,QAAA,EAEDxB;QAAO,CACE;MAAC,CACT;IAAC,CACM,CAChB;EAAA,CACG,CAAC;AAEX,CACF,CAAC;AAED,MAAMsB,MAAM,GAAG+B,uBAAU,CAACC,MAAM,CAAC;EAC/B/B,SAAS,EAAE;IACTgC,cAAc,EAAE,CAAC;IACjBC,WAAW,EAAEhB,qBAAM,CAACiB;EACtB,CAAC;EACD7B,UAAU,EAAE;IACV8B,aAAa,EAAE,KAAK;IACpBC,cAAc,EAAE,eAAe;IAC/BC,UAAU,EAAE,QAAQ;IACpBC,KAAK,EAAE,MAAM;IACbC,eAAe,EAAE;EACnB,CAAC;EACDV,WAAW,EAAE;IACXW,iBAAiB,EAAE;EACrB,CAAC;EACDb,cAAc,EAAE;IACdW,KAAK,EAAE,MAAM;IACbG,QAAQ,EAAE;EACZ,CAAC;EACDnB,eAAe,EAAE;IACfc,cAAc,EAAE,QAAQ;IACxBC,UAAU,EAAE,QAAQ;IACpBK,UAAU,EAAE,CAAC;IACbC,aAAa,EAAE;EACjB;AACF,CAAC,CAAC","ignoreList":[]}
@@ -3,21 +3,20 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.useDropdownAnimation = void 0;
6
+ exports.useVoiceTranscriptionsDropdown = void 0;
7
7
  var _react = require("react");
8
8
  var _effectorReact = require("effector-react");
9
9
  var _reactNativeReanimated = require("react-native-reanimated");
10
10
  var _constants = require("../../constants.js");
11
- const useDropdownAnimation = model => {
11
+ const useVoiceTranscriptionsDropdown = model => {
12
12
  const isExpanded = (0, _effectorReact.useUnit)(model.$isExpanded);
13
13
  const contentHeight = (0, _reactNativeReanimated.useSharedValue)(0);
14
14
  const animationProgress = (0, _reactNativeReanimated.useSharedValue)(isExpanded ? 1 : 0);
15
15
  const onListLayout = event => {
16
16
  const measuredHeight = event.nativeEvent.layout.height;
17
- if (measuredHeight <= 0) return;
18
- contentHeight.value = contentHeight.value === 0 ? measuredHeight : (0, _reactNativeReanimated.withTiming)(measuredHeight, {
19
- duration: 180
20
- });
17
+ if (measuredHeight > 0) {
18
+ contentHeight.value = measuredHeight;
19
+ }
21
20
  };
22
21
  const listAnimatedStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => {
23
22
  const height = (0, _reactNativeReanimated.interpolate)(animationProgress.value, [0, 1], [0, contentHeight.value || _constants.DROPDOWN_MAX_CONTENT_HEIGHT]);
@@ -47,5 +46,5 @@ const useDropdownAnimation = model => {
47
46
  onListLayout
48
47
  };
49
48
  };
50
- exports.useDropdownAnimation = useDropdownAnimation;
51
- //# sourceMappingURL=useDropdownAnimation.js.map
49
+ exports.useVoiceTranscriptionsDropdown = useVoiceTranscriptionsDropdown;
50
+ //# sourceMappingURL=useVoiceTranscriptionsDropdown.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","require","_effectorReact","_reactNativeReanimated","_constants","useVoiceTranscriptionsDropdown","model","isExpanded","useUnit","$isExpanded","contentHeight","useSharedValue","animationProgress","onListLayout","event","measuredHeight","nativeEvent","layout","height","value","listAnimatedStyle","useAnimatedStyle","interpolate","DROPDOWN_MAX_CONTENT_HEIGHT","opacity","iconAnimatedStyle","rotation","transform","rotate","useEffect","withTiming","duration","exports"],"sourceRoot":"../../../../../../src","sources":["features/voice/playing/hooks/useVoiceTranscriptionsDropdown.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,cAAA,GAAAD,OAAA;AACA,IAAAE,sBAAA,GAAAF,OAAA;AAEA,IAAAG,UAAA,GAAAH,OAAA;AAGO,MAAMI,8BAA8B,GAAIC,KAAu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,EAAE,CAACd,iBAAiB,CAAC,CAAC;EAEvB,IAAAiB,gBAAS,EAAC,MAAM;IACdjB,iBAAiB,CAACO,KAAK,GAAG,IAAAW,iCAAU,EAACvB,UAAU,GAAG,CAAC,GAAG,CAAC,EAAE;MAAEwB,QAAQ,EAAE;IAAI,CAAC,CAAC;EAC7E,CAAC,EAAE,CAACxB,UAAU,EAAEK,iBAAiB,CAAC,CAAC;EAEnC,OAAO;IACLL,UAAU;IACVa,iBAAiB;IACjBK,iBAAiB;IACjBZ;EACF,CAAC;AACH,CAAC;AAAAmB,OAAA,CAAA3B,8BAAA,GAAAA,8BAAA","ignoreList":[]}
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.useVoiceTranscriptionsDropdownItemAnimation = void 0;
7
+ var _react = require("react");
8
+ var _reactNativeReanimated = require("react-native-reanimated");
9
+ const useVoiceTranscriptionsDropdownItemAnimation = isExpanded => {
10
+ const height = (0, _reactNativeReanimated.useSharedValue)(0);
11
+ const progress = (0, _reactNativeReanimated.useSharedValue)(isExpanded ? 1 : 0);
12
+ (0, _react.useEffect)(() => {
13
+ progress.value = (0, _reactNativeReanimated.withTiming)(isExpanded ? 1 : 0);
14
+ }, [isExpanded, progress]);
15
+ const derivedHeight = (0, _reactNativeReanimated.useDerivedValue)(() => height.value * progress.value, [height, progress]);
16
+ const contentAnimatedStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => {
17
+ const opacity = (0, _reactNativeReanimated.interpolate)(progress.value, [0, 0.3, 1], [0, 0, 1]);
18
+ return {
19
+ height: derivedHeight.value,
20
+ opacity,
21
+ overflow: 'hidden'
22
+ };
23
+ }, [progress, derivedHeight]);
24
+ const onLayout = event => {
25
+ height.value = event.nativeEvent.layout.height;
26
+ };
27
+ return {
28
+ contentAnimatedStyle,
29
+ onLayout,
30
+ progress
31
+ };
32
+ };
33
+ exports.useVoiceTranscriptionsDropdownItemAnimation = useVoiceTranscriptionsDropdownItemAnimation;
34
+ //# sourceMappingURL=useVoiceTranscriptionsDropdownItemAnimation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","require","_reactNativeReanimated","useVoiceTranscriptionsDropdownItemAnimation","isExpanded","height","useSharedValue","progress","useEffect","value","withTiming","derivedHeight","useDerivedValue","contentAnimatedStyle","useAnimatedStyle","opacity","interpolate","overflow","onLayout","event","nativeEvent","layout","exports"],"sourceRoot":"../../../../../../src","sources":["features/voice/playing/hooks/useVoiceTranscriptionsDropdownItemAnimation.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAEA,IAAAC,sBAAA,GAAAD,OAAA;AAQO,MAAME,2CAA2C,GAAIC,UAAmB,IAAK;EAClF,MAAMC,MAAM,GAAG,IAAAC,qCAAc,EAAC,CAAC,CAAC;EAChC,MAAMC,QAAQ,GAAG,IAAAD,qCAAc,EAACF,UAAU,GAAG,CAAC,GAAG,CAAC,CAAC;EAEnD,IAAAI,gBAAS,EAAC,MAAM;IACdD,QAAQ,CAACE,KAAK,GAAG,IAAAC,iCAAU,EAACN,UAAU,GAAG,CAAC,GAAG,CAAC,CAAC;EACjD,CAAC,EAAE,CAACA,UAAU,EAAEG,QAAQ,CAAC,CAAC;EAE1B,MAAMI,aAAa,GAAG,IAAAC,sCAAe,EAAC,MAAMP,MAAM,CAACI,KAAK,GAAGF,QAAQ,CAACE,KAAK,EAAE,CAACJ,MAAM,EAAEE,QAAQ,CAAC,CAAC;EAE9F,MAAMM,oBAAoB,GAAG,IAAAC,uCAAgB,EAAC,MAAM;IAClD,MAAMC,OAAO,GAAG,IAAAC,kCAAW,EAACT,QAAQ,CAACE,KAAK,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;IAEnE,OAAO;MACLJ,MAAM,EAAEM,aAAa,CAACF,KAAK;MAC3BM,OAAO;MACPE,QAAQ,EAAE;IACZ,CAAC;EACH,CAAC,EAAE,CAACV,QAAQ,EAAEI,aAAa,CAAC,CAAC;EAE7B,MAAMO,QAAQ,GAAIC,KAAwB,IAAK;IAC7Cd,MAAM,CAACI,KAAK,GAAGU,KAAK,CAACC,WAAW,CAACC,MAAM,CAAChB,MAAM;EAChD,CAAC;EAED,OAAO;IACLQ,oBAAoB;IACpBK,QAAQ;IACRX;EACF,CAAC;AACH,CAAC;AAAAe,OAAA,CAAAnB,2CAAA,GAAAA,2CAAA","ignoreList":[]}
@@ -16,7 +16,6 @@ let PlayerState = exports.PlayerState = /*#__PURE__*/function (PlayerState) {
16
16
  class PlayerModel {
17
17
  player = (0, _expoAudio.createAudioPlayer)();
18
18
  stopped = false;
19
- primedUri = null;
20
19
  reset = (0, _effector.createEvent)();
21
20
  setPlayerState = (0, _effector.createEvent)();
22
21
  playbackFinished = (0, _effector.createEvent)();
@@ -40,29 +39,11 @@ class PlayerModel {
40
39
  this.stopped = true;
41
40
  if (this.player) {
42
41
  this.player.replace('');
43
- this.primedUri = null;
44
42
  this.setPlayerState(PlayerState.IDLE);
45
43
  } else {
46
44
  console.warn('Cannot stop: audio player not initialized');
47
45
  }
48
46
  });
49
- prime = (0, _effector.createEffect)(uri => {
50
- if (!this.player) return;
51
- if (this.primedUri === uri) return;
52
- this.primedUri = uri;
53
- this.player.replace(uri);
54
- });
55
- seek = (0, _effector.createEffect)(async seconds => {
56
- if (!this.player) {
57
- console.warn('Cannot seek: audio player not initialized');
58
- return;
59
- }
60
- if (!this.player.isLoaded) {
61
- console.warn('Cannot seek: audio player not loaded');
62
- return;
63
- }
64
- await this.player.seekTo(seconds);
65
- });
66
47
  resume = (0, _effector.createEffect)(() => {
67
48
  if (this.player) {
68
49
  this.player.play();
@@ -77,10 +58,7 @@ class PlayerModel {
77
58
  return;
78
59
  }
79
60
  this.stopped = false;
80
- if (this.primedUri !== uri) {
81
- this.player.replace(uri);
82
- this.primedUri = uri;
83
- }
61
+ this.player.replace(uri);
84
62
  const waitForLoad = () => {
85
63
  if (this.stopped) return;
86
64
  if (this.player && this.player.isLoaded) {
@@ -113,7 +91,6 @@ class PlayerModel {
113
91
  this.player.release();
114
92
  this.player = null;
115
93
  }
116
- this.primedUri = null;
117
94
  this.reset();
118
95
  }
119
96
  }
@@ -1 +1 @@
1
- {"version":3,"names":["_effector","require","_expoAudio","PlayerState","exports","PlayerModel","player","createAudioPlayer","stopped","primedUri","reset","createEvent","setPlayerState","playbackFinished","$playerState","restore","IDLE","setupAudioMode","createEffect","setAudioModeAsync","playsInSilentMode","shouldPlayInBackground","interruptionMode","pause","PAUSED","console","warn","stop","replace","prime","uri","seek","seconds","isLoaded","seekTo","resume","play","PLAYING","waitForLoad","unsubscribe","addListener","status","didJustFinish","remove","setTimeout","reinitialize","release","error"],"sourceRoot":"../../../../../../src","sources":["features/voice/playing/model/Player.model.ts"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AACA,IAAAC,UAAA,GAAAD,OAAA;AAA8E,IAE5DE,WAAW,GAAAC,OAAA,CAAAD,WAAA,0BAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAA,OAAXA,WAAW;AAAA;AAOtB,MAAME,WAAW,CAAC;EAChBC,MAAM,GAAuB,IAAAC,4BAAiB,EAAC,CAAC;EAC/CC,OAAO,GAAG,KAAK;EACfC,SAAS,GAAkB,IAAI;EAEvBC,KAAK,GAAG,IAAAC,qBAAW,EAAC,CAAC;EACrBC,cAAc,GAAG,IAAAD,qBAAW,EAAc,CAAC;EAC3CE,gBAAgB,GAAG,IAAAF,qBAAW,EAAC,CAAC;EAEhCG,YAAY,GAAG,IAAAC,iBAAO,EAAC,IAAI,CAACH,cAAc,EAAET,WAAW,CAACa,IAAI,CAAC,CAACN,KAAK,CAAC,IAAI,CAACA,KAAK,CAAC;EAE/EO,cAAc,GAAG,IAAAC,sBAAY,EAAC,YAAY;IACxD,MAAM,IAA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I,CAACV,MAAM,CAAC8B,IAAI,CAAC,CAAC;QAClB,IAAI,CAACxB,cAAc,CAACT,WAAW,CAACkC,OAAO,CAAC;MAC1C,CAAC,MAAM;QACLO,UAAU,CAACN,WAAW,EAAE,EAAE,CAAC;MAC7B;IACF,CAAC;IAEDA,WAAW,CAAC,CAAC;EACf,CAAC,CAAC;EAEKO,YAAYA,CAAA,EAAG;IACpB,IAAI,CAAC,IAAI,CAACvC,MAAM,EAAE;MAChB,IAAI,CAACA,MAAM,GAAG,IAAAC,4BAAiB,EAAC,CAAC;IACnC;EACF;EAEOuC,OAAOA,CAAA,EAAG;IACf,IAAI,IAAI,CAACxC,MAAM,EAAE;MACf,IAAI;QACF,IAAI,CAACqB,IAAI,CAAC,CAAC;QACX,IAAI,CAACrB,MAAM,CAACqC,MAAM,CAAC,CAAC;MACtB,CAAC,CAAC,OAAOI,KAAK,EAAE,CAAC;MACjB,IAAI,CAACzC,MAAM,CAACwC,OAAO,CAAC,CAAC;MACrB,IAAI,CAACxC,MAAM,GAAG,IAAI;IACpB;IACA,IAAI,CAACG,SAAS,GAAG,IAAI;IACrB,IAAI,CAACC,KAAK,CAAC,CAAC;EACd;AACF;AAACN,OAAA,CAAAC,WAAA,GAAAA,WAAA","ignoreList":[]}
1
+ {"version":3,"names":["_effector","require","_expoAudio","PlayerState","exports","PlayerModel","player","createAudioPlayer","stopped","reset","createEvent","setPlayerState","playbackFinished","$playerState","restore","IDLE","setupAudioMode","createEffect","setAudioModeAsync","playsInSilentMode","shouldPlayInBackground","interruptionMode","pause","PAUSED","console","warn","stop","replace","resume","play","PLAYING","uri","waitForLoad","isLoaded","unsubscribe","addListener","status","didJustFinish","remove","setTimeout","reinitialize","release","error"],"sourceRoot":"../../../../../../src","sources":["features/voice/playing/model/Player.model.ts"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AACA,IAAAC,UAAA,GAAAD,OAAA;AAA8E,IAE5DE,WAAW,GAAAC,OAAA,CAAAD,WA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