@magmamath/students-features 0.9.106 → 0.9.107-rc.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (246) hide show
  1. package/dist/commonjs/features/voiceRecord/components/VoiceRecord.js +81 -0
  2. package/dist/commonjs/features/voiceRecord/components/VoiceRecord.js.map +1 -0
  3. package/dist/commonjs/features/voiceRecord/components/VoiceRecordButton.js +72 -0
  4. package/dist/commonjs/features/voiceRecord/components/VoiceRecordButton.js.map +1 -0
  5. package/dist/commonjs/features/voiceRecord/components/VoiceRecordDeleteButton.js +32 -0
  6. package/dist/commonjs/features/voiceRecord/components/VoiceRecordDeleteButton.js.map +1 -0
  7. package/dist/commonjs/features/voiceRecord/components/VoiceRecordDevider.js +27 -0
  8. package/dist/commonjs/features/voiceRecord/components/VoiceRecordDevider.js.map +1 -0
  9. package/dist/commonjs/features/voiceRecord/components/VoiceRecordTimer.js +49 -0
  10. package/dist/commonjs/features/voiceRecord/components/VoiceRecordTimer.js.map +1 -0
  11. package/dist/commonjs/features/voiceRecord/constants.js +18 -0
  12. package/dist/commonjs/features/voiceRecord/constants.js.map +1 -0
  13. package/dist/commonjs/features/voiceRecord/helpers.js +138 -0
  14. package/dist/commonjs/features/voiceRecord/helpers.js.map +1 -0
  15. package/dist/commonjs/features/voiceRecord/hooks/useVoiceRecorder.js +75 -0
  16. package/dist/commonjs/features/voiceRecord/hooks/useVoiceRecorder.js.map +1 -0
  17. package/dist/commonjs/features/voiceRecord/hooks/useVoiceRecorderAnimation.js +22 -0
  18. package/dist/commonjs/features/voiceRecord/hooks/useVoiceRecorderAnimation.js.map +1 -0
  19. package/dist/commonjs/features/voiceRecord/index.js +72 -0
  20. package/dist/commonjs/features/voiceRecord/index.js.map +1 -0
  21. package/dist/commonjs/features/voiceRecord/modal/VoiceRecordDeleteModal.js +93 -0
  22. package/dist/commonjs/features/voiceRecord/modal/VoiceRecordDeleteModal.js.map +1 -0
  23. package/dist/commonjs/features/voiceRecord/modal/VoiceRecordUndoModal.js +75 -0
  24. package/dist/commonjs/features/voiceRecord/modal/VoiceRecordUndoModal.js.map +1 -0
  25. package/dist/commonjs/features/voiceRecord/model/Recorder.model.js +37 -0
  26. package/dist/commonjs/features/voiceRecord/model/Recorder.model.js.map +1 -0
  27. package/dist/commonjs/features/voiceRecord/model/VoiceRecord.model.js +151 -0
  28. package/dist/commonjs/features/voiceRecord/model/VoiceRecord.model.js.map +1 -0
  29. package/dist/commonjs/features/voiceRecord/model/VoiceRecordApi.js +29 -0
  30. package/dist/commonjs/features/voiceRecord/model/VoiceRecordApi.js.map +1 -0
  31. package/dist/commonjs/features/voiceRecord/model/VoiceRecordCollection.js +30 -0
  32. package/dist/commonjs/features/voiceRecord/model/VoiceRecordCollection.js.map +1 -0
  33. package/dist/commonjs/features/voiceRecord/types.js +6 -0
  34. package/dist/commonjs/features/voiceRecord/types.js.map +1 -0
  35. package/dist/commonjs/index.js +12 -0
  36. package/dist/commonjs/index.js.map +1 -1
  37. package/dist/commonjs/shared/translation/localization/ca.json +13 -0
  38. package/dist/commonjs/shared/translation/localization/de.json +13 -0
  39. package/dist/commonjs/shared/translation/localization/en.json +13 -0
  40. package/dist/commonjs/shared/translation/localization/gb.json +13 -0
  41. package/dist/commonjs/shared/translation/localization/sct.json +13 -0
  42. package/dist/commonjs/shared/translation/localization/sw.json +13 -0
  43. package/dist/module/features/voiceRecord/components/VoiceRecord.js +73 -0
  44. package/dist/module/features/voiceRecord/components/VoiceRecord.js.map +1 -0
  45. package/dist/module/features/voiceRecord/components/VoiceRecordButton.js +66 -0
  46. package/dist/module/features/voiceRecord/components/VoiceRecordButton.js.map +1 -0
  47. package/dist/module/features/voiceRecord/components/VoiceRecordDeleteButton.js +26 -0
  48. package/dist/module/features/voiceRecord/components/VoiceRecordDeleteButton.js.map +1 -0
  49. package/dist/module/features/voiceRecord/components/VoiceRecordDevider.js +21 -0
  50. package/dist/module/features/voiceRecord/components/VoiceRecordDevider.js.map +1 -0
  51. package/dist/module/features/voiceRecord/components/VoiceRecordTimer.js +43 -0
  52. package/dist/module/features/voiceRecord/components/VoiceRecordTimer.js.map +1 -0
  53. package/dist/module/features/voiceRecord/constants.js +14 -0
  54. package/dist/module/features/voiceRecord/constants.js.map +1 -0
  55. package/dist/module/features/voiceRecord/helpers.js +127 -0
  56. package/dist/module/features/voiceRecord/helpers.js.map +1 -0
  57. package/dist/module/features/voiceRecord/hooks/useVoiceRecorder.js +70 -0
  58. package/dist/module/features/voiceRecord/hooks/useVoiceRecorder.js.map +1 -0
  59. package/dist/module/features/voiceRecord/hooks/useVoiceRecorderAnimation.js +17 -0
  60. package/dist/module/features/voiceRecord/hooks/useVoiceRecorderAnimation.js.map +1 -0
  61. package/dist/module/features/voiceRecord/index.js +9 -0
  62. package/dist/module/features/voiceRecord/index.js.map +1 -0
  63. package/dist/module/features/voiceRecord/modal/VoiceRecordDeleteModal.js +86 -0
  64. package/dist/module/features/voiceRecord/modal/VoiceRecordDeleteModal.js.map +1 -0
  65. package/dist/module/features/voiceRecord/modal/VoiceRecordUndoModal.js +69 -0
  66. package/dist/module/features/voiceRecord/modal/VoiceRecordUndoModal.js.map +1 -0
  67. package/dist/module/features/voiceRecord/model/Recorder.model.js +32 -0
  68. package/dist/module/features/voiceRecord/model/Recorder.model.js.map +1 -0
  69. package/dist/module/features/voiceRecord/model/VoiceRecord.model.js +146 -0
  70. package/dist/module/features/voiceRecord/model/VoiceRecord.model.js.map +1 -0
  71. package/dist/module/features/voiceRecord/model/VoiceRecordApi.js +24 -0
  72. package/dist/module/features/voiceRecord/model/VoiceRecordApi.js.map +1 -0
  73. package/dist/module/features/voiceRecord/model/VoiceRecordCollection.js +25 -0
  74. package/dist/module/features/voiceRecord/model/VoiceRecordCollection.js.map +1 -0
  75. package/dist/module/features/voiceRecord/types.js +4 -0
  76. package/dist/module/features/voiceRecord/types.js.map +1 -0
  77. package/dist/module/index.js +1 -0
  78. package/dist/module/index.js.map +1 -1
  79. package/dist/module/shared/translation/localization/ca.json +13 -0
  80. package/dist/module/shared/translation/localization/de.json +13 -0
  81. package/dist/module/shared/translation/localization/en.json +13 -0
  82. package/dist/module/shared/translation/localization/gb.json +13 -0
  83. package/dist/module/shared/translation/localization/sct.json +13 -0
  84. package/dist/module/shared/translation/localization/sw.json +13 -0
  85. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecord.d.ts +10 -0
  86. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecord.d.ts.map +1 -0
  87. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecordButton.d.ts +11 -0
  88. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecordButton.d.ts.map +1 -0
  89. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecordDeleteButton.d.ts +7 -0
  90. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecordDeleteButton.d.ts.map +1 -0
  91. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecordDevider.d.ts +3 -0
  92. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecordDevider.d.ts.map +1 -0
  93. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecordTimer.d.ts +11 -0
  94. package/dist/typescript/commonjs/features/voiceRecord/components/VoiceRecordTimer.d.ts.map +1 -0
  95. package/dist/typescript/commonjs/features/voiceRecord/constants.d.ts +11 -0
  96. package/dist/typescript/commonjs/features/voiceRecord/constants.d.ts.map +1 -0
  97. package/dist/typescript/commonjs/features/voiceRecord/helpers.d.ts +29 -0
  98. package/dist/typescript/commonjs/features/voiceRecord/helpers.d.ts.map +1 -0
  99. package/dist/typescript/commonjs/features/voiceRecord/hooks/useVoiceRecorder.d.ts +5 -0
  100. package/dist/typescript/commonjs/features/voiceRecord/hooks/useVoiceRecorder.d.ts.map +1 -0
  101. package/dist/typescript/commonjs/features/voiceRecord/hooks/useVoiceRecorderAnimation.d.ts +6 -0
  102. package/dist/typescript/commonjs/features/voiceRecord/hooks/useVoiceRecorderAnimation.d.ts.map +1 -0
  103. package/dist/typescript/commonjs/features/voiceRecord/index.d.ts +7 -0
  104. package/dist/typescript/commonjs/features/voiceRecord/index.d.ts.map +1 -0
  105. package/dist/typescript/commonjs/features/voiceRecord/modal/VoiceRecordDeleteModal.d.ts +13 -0
  106. package/dist/typescript/commonjs/features/voiceRecord/modal/VoiceRecordDeleteModal.d.ts.map +1 -0
  107. package/dist/typescript/commonjs/features/voiceRecord/modal/VoiceRecordUndoModal.d.ts +13 -0
  108. package/dist/typescript/commonjs/features/voiceRecord/modal/VoiceRecordUndoModal.d.ts.map +1 -0
  109. package/dist/typescript/commonjs/features/voiceRecord/model/Recorder.model.d.ts +15 -0
  110. package/dist/typescript/commonjs/features/voiceRecord/model/Recorder.model.d.ts.map +1 -0
  111. package/dist/typescript/commonjs/features/voiceRecord/model/VoiceRecord.model.d.ts +39 -0
  112. package/dist/typescript/commonjs/features/voiceRecord/model/VoiceRecord.model.d.ts.map +1 -0
  113. package/dist/typescript/commonjs/features/voiceRecord/model/VoiceRecordApi.d.ts +5 -0
  114. package/dist/typescript/commonjs/features/voiceRecord/model/VoiceRecordApi.d.ts.map +1 -0
  115. package/dist/typescript/commonjs/features/voiceRecord/model/VoiceRecordCollection.d.ts +10 -0
  116. package/dist/typescript/commonjs/features/voiceRecord/model/VoiceRecordCollection.d.ts.map +1 -0
  117. package/dist/typescript/commonjs/features/voiceRecord/types.d.ts +43 -0
  118. package/dist/typescript/commonjs/features/voiceRecord/types.d.ts.map +1 -0
  119. package/dist/typescript/commonjs/index.d.ts +1 -0
  120. package/dist/typescript/commonjs/index.d.ts.map +1 -1
  121. package/dist/typescript/commonjs/shared/translation/constants.d.ts +78 -0
  122. package/dist/typescript/commonjs/shared/translation/constants.d.ts.map +1 -1
  123. package/dist/typescript/commonjs/shared/translation/model.d.ts +26 -0
  124. package/dist/typescript/commonjs/shared/translation/model.d.ts.map +1 -1
  125. package/dist/typescript/commonjs/types/common.types.d.ts +3 -0
  126. package/dist/typescript/commonjs/types/common.types.d.ts.map +1 -1
  127. package/dist/typescript/module/features/voiceRecord/components/VoiceRecord.d.ts +10 -0
  128. package/dist/typescript/module/features/voiceRecord/components/VoiceRecord.d.ts.map +1 -0
  129. package/dist/typescript/module/features/voiceRecord/components/VoiceRecordButton.d.ts +11 -0
  130. package/dist/typescript/module/features/voiceRecord/components/VoiceRecordButton.d.ts.map +1 -0
  131. package/dist/typescript/module/features/voiceRecord/components/VoiceRecordDeleteButton.d.ts +7 -0
  132. package/dist/typescript/module/features/voiceRecord/components/VoiceRecordDeleteButton.d.ts.map +1 -0
  133. package/dist/typescript/module/features/voiceRecord/components/VoiceRecordDevider.d.ts +3 -0
  134. package/dist/typescript/module/features/voiceRecord/components/VoiceRecordDevider.d.ts.map +1 -0
  135. package/dist/typescript/module/features/voiceRecord/components/VoiceRecordTimer.d.ts +11 -0
  136. package/dist/typescript/module/features/voiceRecord/components/VoiceRecordTimer.d.ts.map +1 -0
  137. package/dist/typescript/module/features/voiceRecord/constants.d.ts +11 -0
  138. package/dist/typescript/module/features/voiceRecord/constants.d.ts.map +1 -0
  139. package/dist/typescript/module/features/voiceRecord/helpers.d.ts +29 -0
  140. package/dist/typescript/module/features/voiceRecord/helpers.d.ts.map +1 -0
  141. package/dist/typescript/module/features/voiceRecord/hooks/useVoiceRecorder.d.ts +5 -0
  142. package/dist/typescript/module/features/voiceRecord/hooks/useVoiceRecorder.d.ts.map +1 -0
  143. package/dist/typescript/module/features/voiceRecord/hooks/useVoiceRecorderAnimation.d.ts +6 -0
  144. package/dist/typescript/module/features/voiceRecord/hooks/useVoiceRecorderAnimation.d.ts.map +1 -0
  145. package/dist/typescript/module/features/voiceRecord/index.d.ts +7 -0
  146. package/dist/typescript/module/features/voiceRecord/index.d.ts.map +1 -0
  147. package/dist/typescript/module/features/voiceRecord/modal/VoiceRecordDeleteModal.d.ts +13 -0
  148. package/dist/typescript/module/features/voiceRecord/modal/VoiceRecordDeleteModal.d.ts.map +1 -0
  149. package/dist/typescript/module/features/voiceRecord/modal/VoiceRecordUndoModal.d.ts +13 -0
  150. package/dist/typescript/module/features/voiceRecord/modal/VoiceRecordUndoModal.d.ts.map +1 -0
  151. package/dist/typescript/module/features/voiceRecord/model/Recorder.model.d.ts +15 -0
  152. package/dist/typescript/module/features/voiceRecord/model/Recorder.model.d.ts.map +1 -0
  153. package/dist/typescript/module/features/voiceRecord/model/VoiceRecord.model.d.ts +39 -0
  154. package/dist/typescript/module/features/voiceRecord/model/VoiceRecord.model.d.ts.map +1 -0
  155. package/dist/typescript/module/features/voiceRecord/model/VoiceRecordApi.d.ts +5 -0
  156. package/dist/typescript/module/features/voiceRecord/model/VoiceRecordApi.d.ts.map +1 -0
  157. package/dist/typescript/module/features/voiceRecord/model/VoiceRecordCollection.d.ts +10 -0
  158. package/dist/typescript/module/features/voiceRecord/model/VoiceRecordCollection.d.ts.map +1 -0
  159. package/dist/typescript/module/features/voiceRecord/types.d.ts +43 -0
  160. package/dist/typescript/module/features/voiceRecord/types.d.ts.map +1 -0
  161. package/dist/typescript/module/index.d.ts +1 -0
  162. package/dist/typescript/module/index.d.ts.map +1 -1
  163. package/dist/typescript/module/shared/translation/constants.d.ts +78 -0
  164. package/dist/typescript/module/shared/translation/constants.d.ts.map +1 -1
  165. package/dist/typescript/module/shared/translation/model.d.ts +26 -0
  166. package/dist/typescript/module/shared/translation/model.d.ts.map +1 -1
  167. package/dist/typescript/module/types/common.types.d.ts +3 -0
  168. package/dist/typescript/module/types/common.types.d.ts.map +1 -1
  169. package/package.json +9 -3
  170. package/src/features/voiceRecord/components/VoiceRecord.tsx +73 -0
  171. package/src/features/voiceRecord/components/VoiceRecordButton.tsx +86 -0
  172. package/src/features/voiceRecord/components/VoiceRecordDeleteButton.tsx +24 -0
  173. package/src/features/voiceRecord/components/VoiceRecordDevider.tsx +17 -0
  174. package/src/features/voiceRecord/components/VoiceRecordTimer.tsx +53 -0
  175. package/src/features/voiceRecord/constants.ts +10 -0
  176. package/src/features/voiceRecord/helpers.ts +167 -0
  177. package/src/features/voiceRecord/hooks/useVoiceRecorder.ts +85 -0
  178. package/src/features/voiceRecord/hooks/useVoiceRecorderAnimation.ts +19 -0
  179. package/src/features/voiceRecord/index.ts +6 -0
  180. package/src/features/voiceRecord/modal/VoiceRecordDeleteModal.tsx +106 -0
  181. package/src/features/voiceRecord/modal/VoiceRecordUndoModal.tsx +82 -0
  182. package/src/features/voiceRecord/model/Recorder.model.ts +40 -0
  183. package/src/features/voiceRecord/model/VoiceRecord.model.ts +178 -0
  184. package/src/features/voiceRecord/model/VoiceRecordApi.ts +25 -0
  185. package/src/features/voiceRecord/model/VoiceRecordCollection.ts +26 -0
  186. package/src/features/voiceRecord/types.ts +49 -0
  187. package/src/index.ts +1 -0
  188. package/src/shared/translation/localization/ca.json +13 -0
  189. package/src/shared/translation/localization/de.json +13 -0
  190. package/src/shared/translation/localization/en.json +13 -0
  191. package/src/shared/translation/localization/gb.json +13 -0
  192. package/src/shared/translation/localization/sct.json +13 -0
  193. package/src/shared/translation/localization/sw.json +13 -0
  194. package/src/types/common.types.ts +1 -0
  195. package/.editorconfig +0 -15
  196. package/.eslintignore +0 -2
  197. package/.eslintrc +0 -22
  198. package/.gitattributes +0 -3
  199. package/.github/actions/setup/action.yml +0 -37
  200. package/.github/workflows/ci.yml +0 -73
  201. package/.gitignore +0 -84
  202. package/.idea/.gitignore +0 -8
  203. package/.idea/codeStyles/Project.xml +0 -62
  204. package/.idea/codeStyles/codeStyleConfig.xml +0 -5
  205. package/.idea/copilot.data.migration.agent.xml +0 -6
  206. package/.idea/copilot.data.migration.ask.xml +0 -6
  207. package/.idea/copilot.data.migration.ask2agent.xml +0 -6
  208. package/.idea/copilot.data.migration.edit.xml +0 -6
  209. package/.idea/inspectionProfiles/Project_Default.xml +0 -8
  210. package/.idea/jsLinters/eslint.xml +0 -6
  211. package/.idea/modules.xml +0 -8
  212. package/.idea/prettier.xml +0 -7
  213. package/.idea/shelf/Uncommitted_changes_before_Checkout_at_30_12_2025,_11_06_[Changes]/shelved.patch +0 -18
  214. package/.idea/shelf/Uncommitted_changes_before_Checkout_at_30_12_2025,_11_07_[Changes]/shelved.patch +0 -18
  215. package/.idea/shelf/Uncommitted_changes_before_Checkout_at_30_12_2025__11_06__Changes_.xml +0 -4
  216. package/.idea/shelf/Uncommitted_changes_before_Checkout_at_30_12_2025__11_07__Changes_.xml +0 -4
  217. package/.idea/students-features.iml +0 -12
  218. package/.idea/vcs.xml +0 -6
  219. package/.idea/workspace.xml +0 -646
  220. package/.nvmrc +0 -1
  221. package/.prettierrc +0 -11
  222. package/.release-it.json +0 -17
  223. package/.watchmanconfig +0 -1
  224. package/.yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs +0 -541
  225. package/.yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs +0 -28
  226. package/.yarn/releases/yarn-3.6.1.cjs +0 -874
  227. package/babel.config.js +0 -5
  228. package/bob.config.js +0 -25
  229. package/example/.expo/README.md +0 -8
  230. package/example/.expo/devices.json +0 -3
  231. package/example/.expo/web/cache/production/images/favicon/favicon-24272cdaeff82cc5facdaccd982a6f05b60c4504704bbf94c19a6388659880bb-contain-transparent/favicon-48.png +0 -0
  232. package/example/app.json +0 -30
  233. package/example/assets/adaptive-icon.png +0 -0
  234. package/example/assets/favicon.png +0 -0
  235. package/example/assets/icon.png +0 -0
  236. package/example/assets/splash-icon.png +0 -0
  237. package/example/babel.config.js +0 -28
  238. package/example/index.js +0 -8
  239. package/example/metro.config.js +0 -18
  240. package/example/package.json +0 -25
  241. package/example/src/App.tsx +0 -8
  242. package/example/tsconfig.json +0 -6
  243. package/example/yarn.lock +0 -6552
  244. package/tsconfig.build.json +0 -4
  245. package/tsconfig.json +0 -34
  246. package/yarn.lock +0 -8623
@@ -0,0 +1,11 @@
1
+ export declare const VOICE_RECORDER_CONTAINER_SIZES: {
2
+ COLLAPSED: number;
3
+ EXPANDED: number;
4
+ };
5
+ export declare const VOICE_RECORDER_MAX_DURATION_MS = 300000;
6
+ export declare enum VoiceRecorderState {
7
+ IDLE = 0,
8
+ RECORDING = 1,
9
+ PAUSED = 2
10
+ }
11
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/features/voiceRecord/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,8BAA8B;;;CAG1C,CAAA;AACD,eAAO,MAAM,8BAA8B,SAAS,CAAA;AACpD,oBAAY,kBAAkB;IAC5B,IAAI,IAAA;IACJ,SAAS,IAAA;IACT,MAAM,IAAA;CACP"}
@@ -0,0 +1,29 @@
1
+ import { AudioPlayer, AudioRecorder } from 'expo-audio';
2
+ import { AudioApi } from './types';
3
+ export declare const formatDuration: (ms: number) => string;
4
+ export declare const ensureRecordingPermissions: () => Promise<boolean>;
5
+ export declare const getAvailableInputs: (recorder: AudioRecorder) => Promise<MediaDeviceInfo[] | import("expo-audio").RecordingInput[]>;
6
+ export declare const addAudioInputsListenerWeb: (callback: (devices: MediaDeviceInfo[]) => void) => () => void;
7
+ /**
8
+ *
9
+ * @param fileUri
10
+ * @param externalPlayer - is optional expo-audio player, but should be provided
11
+ * because creating player is resource consuming operation
12
+ */
13
+ export declare const getAudioDurationMs: (fileUri: string, externalPlayer?: AudioPlayer) => Promise<number | undefined>;
14
+ type GenerateAudioFormDataParams = {
15
+ audioFileUri: string;
16
+ durationMs?: number;
17
+ fileName?: string;
18
+ };
19
+ export declare const generateAudioFormData: ({ audioFileUri, durationMs, fileName, }: GenerateAudioFormDataParams) => Promise<FormData>;
20
+ export declare const uploadAudioFileRequestGenerator: (audioFileFormData: FormData, api: AudioApi) => {
21
+ uploadAudio: () => Promise<{
22
+ id: string;
23
+ fileName: string;
24
+ fileType: string;
25
+ }>;
26
+ controller: AbortController;
27
+ };
28
+ export {};
29
+ //# sourceMappingURL=helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../src/features/voiceRecord/helpers.ts"],"names":[],"mappings":"AACA,OAAO,EACL,WAAW,EACX,aAAa,EAId,MAAM,YAAY,CAAA;AACnB,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAA;AAElC,eAAO,MAAM,cAAc,OAAQ,MAAM,KAAG,MAK3C,CAAA;AAED,eAAO,MAAM,0BAA0B,wBAStC,CAAA;AASD,eAAO,MAAM,kBAAkB,aAAoB,aAAa,uEAQ/D,CAAA;AAED,eAAO,MAAM,yBAAyB,aAAc,CAAC,OAAO,EAAE,eAAe,EAAE,KAAK,IAAI,eAiBvF,CAAA;AACD;;;;;GAKG;AACH,eAAO,MAAM,kBAAkB,YACpB,MAAM,mBACE,WAAW,KAC3B,OAAO,CAAC,MAAM,GAAG,SAAS,CAkC5B,CAAA;AAED,KAAK,2BAA2B,GAAG;IACjC,YAAY,EAAE,MAAM,CAAA;IACpB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,CAAA;AAED,eAAO,MAAM,qBAAqB,4CAI/B,2BAA2B,KAAG,OAAO,CAAC,QAAQ,CA8BhD,CAAA;AAED,eAAO,MAAM,+BAA+B,sBAAuB,QAAQ,OAAO,QAAQ;;;;;;;CAgBzF,CAAA"}
@@ -0,0 +1,5 @@
1
+ import { VoiceRecordModel } from '../model/VoiceRecord.model';
2
+ export declare const useVoiceRecorder: (model: VoiceRecordModel) => {
3
+ recorderState: import("expo-audio").RecorderState;
4
+ };
5
+ //# sourceMappingURL=useVoiceRecorder.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useVoiceRecorder.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/hooks/useVoiceRecorder.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAA;AAM7D,eAAO,MAAM,gBAAgB,UAAW,gBAAgB;;CAuEvD,CAAA"}
@@ -0,0 +1,6 @@
1
+ export declare const useVoiceRecorderAnimation: (isExpanded: boolean) => {
2
+ containerAnimatedStyle: {
3
+ height: number;
4
+ };
5
+ };
6
+ //# sourceMappingURL=useVoiceRecorderAnimation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useVoiceRecorderAnimation.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/hooks/useVoiceRecorderAnimation.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,yBAAyB,eAAgB,OAAO;;;;CAe5D,CAAA"}
@@ -0,0 +1,7 @@
1
+ export * from './components/VoiceRecord';
2
+ export * from './model/VoiceRecord.model';
3
+ export * from './modal/VoiceRecordDeleteModal';
4
+ export * from './modal/VoiceRecordUndoModal';
5
+ export * from './constants';
6
+ export * from './types';
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/features/voiceRecord/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAA;AACxC,cAAc,2BAA2B,CAAA;AACzC,cAAc,gCAAgC,CAAA;AAC9C,cAAc,8BAA8B,CAAA;AAC5C,cAAc,aAAa,CAAA;AAC3B,cAAc,SAAS,CAAA"}
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ import { VoiceRecordModel } from '../model/VoiceRecord.model';
3
+ type VoiceRecordDeleteModalComponentProps = {
4
+ modal: {
5
+ closeModal: () => void;
6
+ params: {
7
+ model: VoiceRecordModel;
8
+ };
9
+ };
10
+ };
11
+ export declare const VoiceRecordDeleteModal: ({ modal: { closeModal, params }, }: VoiceRecordDeleteModalComponentProps) => React.JSX.Element;
12
+ export {};
13
+ //# sourceMappingURL=VoiceRecordDeleteModal.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecordDeleteModal.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/modal/VoiceRecordDeleteModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoB,MAAM,OAAO,CAAA;AAWxC,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAA;AAI7D,KAAK,oCAAoC,GAAG;IAC1C,KAAK,EAAE;QACL,UAAU,EAAE,MAAM,IAAI,CAAA;QACtB,MAAM,EAAE;YACN,KAAK,EAAE,gBAAgB,CAAA;SACxB,CAAA;KACF,CAAA;CACF,CAAA;AA2BD,eAAO,MAAM,sBAAsB,uCAEhC,oCAAoC,sBA0CtC,CAAA"}
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ import { VoiceRecordModel } from '../model/VoiceRecord.model';
3
+ type VoiceRecordUndoModalProps = {
4
+ modal: {
5
+ closeModal: () => void;
6
+ params: {
7
+ model: VoiceRecordModel;
8
+ };
9
+ };
10
+ };
11
+ export declare const VoiceRecordUndoModal: ({ modal: { closeModal, params }, }: VoiceRecordUndoModalProps) => React.JSX.Element;
12
+ export {};
13
+ //# sourceMappingURL=VoiceRecordUndoModal.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecordUndoModal.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/modal/VoiceRecordUndoModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAWzB,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAA;AAE7D,KAAK,yBAAyB,GAAG;IAC/B,KAAK,EAAE;QACL,UAAU,EAAE,MAAM,IAAI,CAAA;QACtB,MAAM,EAAE;YACN,KAAK,EAAE,gBAAgB,CAAA;SACxB,CAAA;KACF,CAAA;CACF,CAAA;AA2BD,eAAO,MAAM,oBAAoB,uCAE9B,yBAAyB,sBAoB3B,CAAA"}
@@ -0,0 +1,15 @@
1
+ import { AudioRecorder } from 'expo-audio';
2
+ import { VoiceRecorderState } from '../constants';
3
+ export declare class RecorderModel {
4
+ recorder: AudioRecorder;
5
+ readonly reset: import("effector").EventCallable<void>;
6
+ readonly setAudioFileDurationMs: import("effector").EventCallable<number>;
7
+ readonly setVoiceRecordState: import("effector").EventCallable<VoiceRecorderState>;
8
+ readonly setAvailableInputs: import("effector").EventCallable<MediaDeviceInfo[] | import("expo-audio").RecordingInput[]>;
9
+ readonly $audioFileDurationMs: import("effector").StoreWritable<number>;
10
+ readonly $voiceRecordState: import("effector").StoreWritable<VoiceRecorderState>;
11
+ readonly $availableInputs: import("effector").StoreWritable<MediaDeviceInfo[] | import("expo-audio").RecordingInput[]>;
12
+ readonly start: import("effector").Effect<void, void, Error>;
13
+ readonly stop: import("effector").Effect<void, void, Error>;
14
+ }
15
+ //# sourceMappingURL=Recorder.model.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Recorder.model.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/model/Recorder.model.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAqB,MAAM,YAAY,CAAA;AAC7D,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAA;AAQjD,qBAAa,aAAa;IACjB,QAAQ,EAAG,aAAa,CAAA;IAE/B,SAAgB,KAAK,yCAAgB;IACrC,SAAgB,sBAAsB,2CAAwB;IAC9D,SAAgB,mBAAmB,uDAAoC;IACvE,SAAgB,kBAAkB,8FAAsC;IAExE,SAAgB,oBAAoB,2CAA4D;IAChG,SAAgB,iBAAiB,uDAGd;IACnB,SAAgB,gBAAgB,8FAAuC;IAEvE,SAAgB,KAAK,+CASnB;IAEF,SAAgB,IAAI,+CAElB;CACH"}
@@ -0,0 +1,39 @@
1
+ import { AudioApi, VoiceRecordNotificationTypes, VoiceRecordStackItem } from '../types';
2
+ import { RecorderModel } from './Recorder.model';
3
+ import { VoiceRecordsCollection } from './VoiceRecordCollection';
4
+ type VoiceRecordModelParams = {
5
+ api: AudioApi;
6
+ notification: VoiceRecordNotificationTypes;
7
+ events: VoiceRecordEvents;
8
+ };
9
+ type VoiceRecordEvents = {
10
+ deleteRecord: () => void;
11
+ undoRecord: () => void;
12
+ };
13
+ type DeleteCurrentRecordingProps = {
14
+ notification?: boolean;
15
+ };
16
+ export declare class VoiceRecordModel {
17
+ readonly recorderModel: RecorderModel;
18
+ readonly collection: VoiceRecordsCollection;
19
+ readonly api: AudioApi;
20
+ readonly notification: VoiceRecordNotificationTypes;
21
+ readonly events: VoiceRecordEvents;
22
+ readonly setCurrentKey: import("effector").EventCallable<string>;
23
+ readonly setUri: import("effector").EventCallable<string>;
24
+ readonly setCurrentRecord: import("effector").EventCallable<any>;
25
+ readonly reset: import("effector").EventCallable<void>;
26
+ readonly $currentKey: import("effector").StoreWritable<string>;
27
+ readonly $currentRecord: import("effector").StoreWritable<VoiceRecordStackItem | null>;
28
+ readonly $uri: import("effector").StoreWritable<string>;
29
+ readonly deleteCurrentRecording: import("effector").Effect<void | DeleteCurrentRecordingProps, void, Error>;
30
+ readonly initializeRecording: import("effector").Effect<void, void, Error>;
31
+ constructor({ api, notification, events }: VoiceRecordModelParams);
32
+ private abortUploadIfInProgress;
33
+ private resetRecordingState;
34
+ private handleAudioUpload;
35
+ private setupUploadHandler;
36
+ private setupCurrentRecordSync;
37
+ }
38
+ export {};
39
+ //# sourceMappingURL=VoiceRecord.model.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecord.model.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/model/VoiceRecord.model.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,QAAQ,EAAE,4BAA4B,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA;AAEvF,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAA;AAChD,OAAO,EAAE,sBAAsB,EAAE,MAAM,yBAAyB,CAAA;AAEhE,KAAK,sBAAsB,GAAG;IAC5B,GAAG,EAAE,QAAQ,CAAA;IACb,YAAY,EAAE,4BAA4B,CAAA;IAC1C,MAAM,EAAE,iBAAiB,CAAA;CAC1B,CAAA;AAOD,KAAK,iBAAiB,GAAG;IACvB,YAAY,EAAE,MAAM,IAAI,CAAA;IACxB,UAAU,EAAE,MAAM,IAAI,CAAA;CACvB,CAAA;AAED,KAAK,2BAA2B,GAAG;IACjC,YAAY,CAAC,EAAE,OAAO,CAAA;CACvB,CAAA;AAMD,qBAAa,gBAAgB;IAC3B,SAAgB,aAAa,EAAE,aAAa,CAAA;IAC5C,SAAgB,UAAU,EAAE,sBAAsB,CAAA;IAClD,SAAgB,GAAG,EAAE,QAAQ,CAAA;IAC7B,SAAgB,YAAY,EAAE,4BAA4B,CAAA;IAC1D,SAAgB,MAAM,EAAE,iBAAiB,CAAA;IAEzC,SAAgB,aAAa,2CAAwB;IACrD,SAAgB,MAAM,2CAAwB;IAC9C,SAAgB,gBAAgB,wCAAqB;IACrD,SAAgB,KAAK,yCAAgB;IAErC,SAAgB,WAAW,2CAAkC;IAC7D,SAAgB,cAAc,gEAAmE;IACjG,SAAgB,IAAI,2CAA6C;IAEjE,SAAgB,sBAAsB,6EAiBpC;IAEF,SAAgB,mBAAmB,+CAkBjC;gBAEU,EAAE,GAAG,EAAE,YAAY,EAAE,MAAM,EAAE,EAAE,sBAAsB;IAWjE,OAAO,CAAC,uBAAuB;IAM/B,OAAO,CAAC,mBAAmB;YAMb,iBAAiB;IA4B/B,OAAO,CAAC,kBAAkB;IAY1B,OAAO,CAAC,sBAAsB;CAsB/B"}
@@ -0,0 +1,5 @@
1
+ import { AudioApi } from '../types';
2
+ export declare class VoiceRecordApi {
3
+ constructor(api: AudioApi);
4
+ }
5
+ //# sourceMappingURL=VoiceRecordApi.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecordApi.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/model/VoiceRecordApi.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAA;AAGnC,qBAAa,cAAc;gBASb,GAAG,EAAE,QAAQ;CAW1B"}
@@ -0,0 +1,10 @@
1
+ import { VoiceRecordStackItem } from '../types';
2
+ export declare class VoiceRecordsCollection {
3
+ readonly collection: Map<string, VoiceRecordStackItem>;
4
+ add(key: string, item: VoiceRecordStackItem): void;
5
+ update(key: string, item: Partial<VoiceRecordStackItem>): void;
6
+ delete(key: string): void;
7
+ get(key: string): VoiceRecordStackItem | undefined;
8
+ clear(): void;
9
+ }
10
+ //# sourceMappingURL=VoiceRecordCollection.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecordCollection.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/model/VoiceRecordCollection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA;AAE/C,qBAAa,sBAAsB;IACjC,SAAgB,UAAU,EAAE,GAAG,CAAC,MAAM,EAAE,oBAAoB,CAAC,CAAY;IAElE,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,oBAAoB;IAI3C,MAAM,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,CAAC,oBAAoB,CAAC;IAKvD,MAAM,CAAC,GAAG,EAAE,MAAM;IAIlB,GAAG,CAAC,GAAG,EAAE,MAAM;IAIf,KAAK;CAGb"}
@@ -0,0 +1,43 @@
1
+ import { WithAbortSignal } from 'src/types/common.types';
2
+ import { getAvailableInputs } from './helpers';
3
+ import { VoiceRecordModel } from './model/VoiceRecord.model';
4
+ export type VoiceRecordNotificationTypes = {
5
+ info: (message: string) => void;
6
+ error: (message: string) => void;
7
+ warning: (message: string) => void;
8
+ };
9
+ export type UploadAudioPayload = WithAbortSignal<{
10
+ audioFileFormData: FormData;
11
+ }>;
12
+ type AudioTranscriptResponse = {
13
+ text: string;
14
+ };
15
+ type UploadAudioResponse = {
16
+ id: string;
17
+ fileName: string;
18
+ fileType: string;
19
+ };
20
+ export type AudioApi = {
21
+ uploadAudioFile: (data: UploadAudioPayload) => Promise<UploadAudioResponse>;
22
+ getAudioFileTranscript: (audioFileId: string) => Promise<AudioTranscriptResponse>;
23
+ };
24
+ export type VoiceRecordStackItem = {
25
+ solutionId?: string;
26
+ id?: string;
27
+ durationMs?: number;
28
+ uri?: string;
29
+ audioUploadPromise?: Promise<void | UploadAudioResponse>;
30
+ controller?: AbortController;
31
+ };
32
+ export type VoiceRecordStack = {
33
+ [problemId: string]: VoiceRecordStackItem;
34
+ };
35
+ export type AvailableAudioInputs = Awaited<ReturnType<typeof getAvailableInputs>>;
36
+ export type VoiceRecordDeleteModalParams = {
37
+ model: VoiceRecordModel;
38
+ };
39
+ export type VoiceRecordUndoModalParams = {
40
+ model: VoiceRecordModel;
41
+ };
42
+ export {};
43
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/features/voiceRecord/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAA;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAA;AAC9C,OAAO,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAA;AAE5D,MAAM,MAAM,4BAA4B,GAAG;IACzC,IAAI,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAA;IAC/B,KAAK,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAA;IAChC,OAAO,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAA;CACnC,CAAA;AAED,MAAM,MAAM,kBAAkB,GAAG,eAAe,CAAC;IAC/C,iBAAiB,EAAE,QAAQ,CAAA;CAC5B,CAAC,CAAA;AAEF,KAAK,uBAAuB,GAAG;IAC7B,IAAI,EAAE,MAAM,CAAA;CACb,CAAA;AACD,KAAK,mBAAmB,GAAG;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,QAAQ,EAAE,MAAM,CAAA;IAChB,QAAQ,EAAE,MAAM,CAAA;CACjB,CAAA;AAED,MAAM,MAAM,QAAQ,GAAG;IACrB,eAAe,EAAE,CAAC,IAAI,EAAE,kBAAkB,KAAK,OAAO,CAAC,mBAAmB,CAAC,CAAA;IAC3E,sBAAsB,EAAE,CAAC,WAAW,EAAE,MAAM,KAAK,OAAO,CAAC,uBAAuB,CAAC,CAAA;CAClF,CAAA;AAED,MAAM,MAAM,oBAAoB,GAAG;IACjC,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,kBAAkB,CAAC,EAAE,OAAO,CAAC,IAAI,GAAG,mBAAmB,CAAC,CAAA;IACxD,UAAU,CAAC,EAAE,eAAe,CAAA;CAC7B,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG;IAC7B,CAAC,SAAS,EAAE,MAAM,GAAG,oBAAoB,CAAA;CAC1C,CAAA;AAED,MAAM,MAAM,oBAAoB,GAAG,OAAO,CAAC,UAAU,CAAC,OAAO,kBAAkB,CAAC,CAAC,CAAA;AAEjF,MAAM,MAAM,4BAA4B,GAAG;IACzC,KAAK,EAAE,gBAAgB,CAAA;CACxB,CAAA;AACD,MAAM,MAAM,0BAA0B,GAAG;IACvC,KAAK,EAAE,gBAAgB,CAAA;CACxB,CAAA"}
@@ -10,4 +10,5 @@ export * from './features/gifCelebrations';
10
10
  export * from './features/exampleSolution';
11
11
  export * from './features/keyboard';
12
12
  export * from './shared/icons';
13
+ export * from './features/voiceRecord';
13
14
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,uBAAuB,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAA;AAC/F,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAA;AACxD,cAAc,oBAAoB,CAAA;AAClC,cAAc,qBAAqB,CAAA;AACnC,cAAc,yBAAyB,CAAA;AACvC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,yBAAyB,CAAA;AACvC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,4BAA4B,CAAA;AAC1C,cAAc,4BAA4B,CAAA;AAC1C,cAAc,qBAAqB,CAAA;AACnC,cAAc,gBAAgB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,uBAAuB,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAA;AAC/F,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAA;AACxD,cAAc,oBAAoB,CAAA;AAClC,cAAc,qBAAqB,CAAA;AACnC,cAAc,yBAAyB,CAAA;AACvC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,yBAAyB,CAAA;AACvC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,4BAA4B,CAAA;AAC1C,cAAc,4BAA4B,CAAA;AAC1C,cAAc,qBAAqB,CAAA;AACnC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,wBAAwB,CAAA"}
@@ -41,6 +41,19 @@ export declare const LOCALIZATION_CONFIGS: {
41
41
  weight: string;
42
42
  time: string;
43
43
  };
44
+ voiceRecorder: {
45
+ deleteRecording: string;
46
+ youWontBeAbleToRecover: string;
47
+ recordingDeleted: string;
48
+ delete: string;
49
+ cancel: string;
50
+ noMicrophoneAccess: string;
51
+ noMicrophoneFound: string;
52
+ uploadFailed: string;
53
+ redoRecording: string;
54
+ redo: string;
55
+ thisWillRemoveRecording: string;
56
+ };
44
57
  };
45
58
  "en-GB": {
46
59
  locale: string;
@@ -84,6 +97,19 @@ export declare const LOCALIZATION_CONFIGS: {
84
97
  weight: string;
85
98
  time: string;
86
99
  };
100
+ voiceRecorder: {
101
+ deleteRecording: string;
102
+ youWontBeAbleToRecover: string;
103
+ recordingDeleted: string;
104
+ delete: string;
105
+ cancel: string;
106
+ noMicrophoneAccess: string;
107
+ noMicrophoneFound: string;
108
+ uploadFailed: string;
109
+ redoRecording: string;
110
+ redo: string;
111
+ thisWillRemoveRecording: string;
112
+ };
87
113
  };
88
114
  "sv-SE": {
89
115
  locale: string;
@@ -127,6 +153,19 @@ export declare const LOCALIZATION_CONFIGS: {
127
153
  weight: string;
128
154
  time: string;
129
155
  };
156
+ voiceRecorder: {
157
+ deleteRecording: string;
158
+ youWontBeAbleToRecover: string;
159
+ recordingDeleted: string;
160
+ delete: string;
161
+ cancel: string;
162
+ noMicrophoneAccess: string;
163
+ noMicrophoneFound: string;
164
+ uploadFailed: string;
165
+ redoRecording: string;
166
+ redo: string;
167
+ thisWillRemoveRecording: string;
168
+ };
130
169
  };
131
170
  "en-CA": {
132
171
  locale: string;
@@ -170,6 +209,19 @@ export declare const LOCALIZATION_CONFIGS: {
170
209
  weight: string;
171
210
  time: string;
172
211
  };
212
+ voiceRecorder: {
213
+ deleteRecording: string;
214
+ youWontBeAbleToRecover: string;
215
+ recordingDeleted: string;
216
+ delete: string;
217
+ cancel: string;
218
+ noMicrophoneAccess: string;
219
+ noMicrophoneFound: string;
220
+ uploadFailed: string;
221
+ redoRecording: string;
222
+ redo: string;
223
+ thisWillRemoveRecording: string;
224
+ };
173
225
  };
174
226
  "en-SCT": {
175
227
  locale: string;
@@ -213,6 +265,19 @@ export declare const LOCALIZATION_CONFIGS: {
213
265
  weight: string;
214
266
  time: string;
215
267
  };
268
+ voiceRecorder: {
269
+ deleteRecording: string;
270
+ youWontBeAbleToRecover: string;
271
+ recordingDeleted: string;
272
+ delete: string;
273
+ cancel: string;
274
+ noMicrophoneAccess: string;
275
+ noMicrophoneFound: string;
276
+ uploadFailed: string;
277
+ redoRecording: string;
278
+ redo: string;
279
+ thisWillRemoveRecording: string;
280
+ };
216
281
  };
217
282
  "de-DE": {
218
283
  locale: string;
@@ -256,6 +321,19 @@ export declare const LOCALIZATION_CONFIGS: {
256
321
  weight: string;
257
322
  time: string;
258
323
  };
324
+ voiceRecorder: {
325
+ deleteRecording: string;
326
+ youWontBeAbleToRecover: string;
327
+ recordingDeleted: string;
328
+ delete: string;
329
+ cancel: string;
330
+ noMicrophoneAccess: string;
331
+ noMicrophoneFound: string;
332
+ uploadFailed: string;
333
+ redoRecording: string;
334
+ redo: string;
335
+ thisWillRemoveRecording: string;
336
+ };
259
337
  };
260
338
  };
261
339
  //# sourceMappingURL=constants.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/constants.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAOhC,CAAA"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/constants.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAOhC,CAAA"}
@@ -42,6 +42,19 @@ export declare const setLocalization: import("effector").EventCallable<{
42
42
  weight: string;
43
43
  time: string;
44
44
  };
45
+ voiceRecorder: {
46
+ deleteRecording: string;
47
+ youWontBeAbleToRecover: string;
48
+ recordingDeleted: string;
49
+ delete: string;
50
+ cancel: string;
51
+ noMicrophoneAccess: string;
52
+ noMicrophoneFound: string;
53
+ uploadFailed: string;
54
+ redoRecording: string;
55
+ redo: string;
56
+ thisWillRemoveRecording: string;
57
+ };
45
58
  } | ((config: typeof LOCALIZATION_CONFIGS) => Translations)>;
46
59
  export declare const $localization: import("effector").StoreWritable<{
47
60
  locale: string;
@@ -85,5 +98,18 @@ export declare const $localization: import("effector").StoreWritable<{
85
98
  weight: string;
86
99
  time: string;
87
100
  };
101
+ voiceRecorder: {
102
+ deleteRecording: string;
103
+ youWontBeAbleToRecover: string;
104
+ recordingDeleted: string;
105
+ delete: string;
106
+ cancel: string;
107
+ noMicrophoneAccess: string;
108
+ noMicrophoneFound: string;
109
+ uploadFailed: string;
110
+ redoRecording: string;
111
+ redo: string;
112
+ thisWillRemoveRecording: string;
113
+ };
88
114
  }>;
89
115
  //# sourceMappingURL=model.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/model.ts"],"names":[],"mappings":"AACA,OAAO,EAAU,YAAY,EAAE,MAAM,SAAS,CAAA;AAC9C,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAElD,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cACD,OAAO,oBAAoB,KAAK,YAAY,EACpE,CAAA;AAEH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAMzB,CAAA"}
1
+ {"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../../../../src/shared/translation/model.ts"],"names":[],"mappings":"AACA,OAAO,EAAU,YAAY,EAAE,MAAM,SAAS,CAAA;AAC9C,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAElD,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cACD,OAAO,oBAAoB,KAAK,YAAY,EACpE,CAAA;AAEH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAMzB,CAAA"}
@@ -2,4 +2,7 @@ export type Size = {
2
2
  width: number;
3
3
  height: number;
4
4
  };
5
+ export type WithAbortSignal<T> = T & {
6
+ signal?: AbortSignal;
7
+ };
5
8
  //# sourceMappingURL=common.types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"common.types.d.ts","sourceRoot":"","sources":["../../../../src/types/common.types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,IAAI,GAAG;IACjB,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,EAAE,MAAM,CAAA;CACf,CAAA"}
1
+ {"version":3,"file":"common.types.d.ts","sourceRoot":"","sources":["../../../../src/types/common.types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,IAAI,GAAG;IACjB,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,EAAE,MAAM,CAAA;CACf,CAAA;AACD,MAAM,MAAM,eAAe,CAAC,CAAC,IAAI,CAAC,GAAG;IAAE,MAAM,CAAC,EAAE,WAAW,CAAA;CAAE,CAAA"}
@@ -0,0 +1,10 @@
1
+ import { StyleProp, ViewStyle } from 'react-native';
2
+ import React from 'react';
3
+ import { VoiceRecordModel } from '../model/VoiceRecord.model';
4
+ type VoiceRecordProps = {
5
+ style?: StyleProp<ViewStyle>;
6
+ model: VoiceRecordModel;
7
+ };
8
+ export declare const VoiceRecord: ({ style, model }: VoiceRecordProps) => React.JSX.Element;
9
+ export {};
10
+ //# sourceMappingURL=VoiceRecord.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecord.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/components/VoiceRecord.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,SAAS,EAAc,MAAM,cAAc,CAAA;AAE/D,OAAO,KAAoB,MAAM,OAAO,CAAA;AAMxC,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAA;AAK7D,KAAK,gBAAgB,GAAG;IACtB,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAA;IAC5B,KAAK,EAAE,gBAAgB,CAAA;CACxB,CAAA;AAED,eAAO,MAAM,WAAW,qBAAsB,gBAAgB,sBAoC7D,CAAA"}
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import { ButtonStyle } from '@magmamath/react-native-ui';
3
+ import { VoiceRecordModel } from '../model/VoiceRecord.model';
4
+ type VoiceRecordButtonProps = {
5
+ style?: ButtonStyle;
6
+ disabled?: boolean;
7
+ model: VoiceRecordModel;
8
+ };
9
+ export declare const VoiceRecordButton: ({ style, disabled, model }: VoiceRecordButtonProps) => React.JSX.Element;
10
+ export {};
11
+ //# sourceMappingURL=VoiceRecordButton.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecordButton.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/components/VoiceRecordButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAA;AACtC,OAAO,EAIL,WAAW,EAEZ,MAAM,4BAA4B,CAAA;AAGnC,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAA;AAK7D,KAAK,sBAAsB,GAAG;IAC5B,KAAK,CAAC,EAAE,WAAW,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,KAAK,EAAE,gBAAgB,CAAA;CACxB,CAAA;AAED,eAAO,MAAM,iBAAiB,+BAAgC,sBAAsB,sBAgEnF,CAAA"}
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ type VoiceRecordDeleteProps = {
3
+ onPress?: () => void;
4
+ };
5
+ export declare const VoiceRecordDeleteButton: ({ onPress }: VoiceRecordDeleteProps) => React.JSX.Element;
6
+ export {};
7
+ //# sourceMappingURL=VoiceRecordDeleteButton.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecordDeleteButton.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/components/VoiceRecordDeleteButton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,KAAK,sBAAsB,GAAG;IAC5B,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACrB,CAAA;AAED,eAAO,MAAM,uBAAuB,gBAAiB,sBAAsB,sBAM1E,CAAA"}
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ export declare const VoiceRecordDevider: () => React.JSX.Element;
3
+ //# sourceMappingURL=VoiceRecordDevider.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecordDevider.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/components/VoiceRecordDevider.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,eAAO,MAAM,kBAAkB,yBAE9B,CAAA"}
@@ -0,0 +1,11 @@
1
+ import { StyleProp, ViewStyle } from 'react-native';
2
+ import React from 'react';
3
+ import { VoiceRecordModel } from '../model/VoiceRecord.model';
4
+ type VoiceRecordTimerProps = {
5
+ style?: StyleProp<ViewStyle>;
6
+ model: VoiceRecordModel;
7
+ recordingFileDurationMs?: number;
8
+ };
9
+ export declare const VoiceRecordTimer: ({ style, model, recordingFileDurationMs, }: VoiceRecordTimerProps) => React.JSX.Element;
10
+ export default VoiceRecordTimer;
11
+ //# sourceMappingURL=VoiceRecordTimer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VoiceRecordTimer.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/components/VoiceRecordTimer.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAoB,SAAS,EAAE,MAAM,cAAc,CAAA;AAErE,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAA;AAI7D,KAAK,qBAAqB,GAAG;IAC3B,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAA;IAC5B,KAAK,EAAE,gBAAgB,CAAA;IACvB,uBAAuB,CAAC,EAAE,MAAM,CAAA;CACjC,CAAA;AAED,eAAO,MAAM,gBAAgB,+CAI1B,qBAAqB,sBAcvB,CAAA;AAED,eAAe,gBAAgB,CAAA"}
@@ -0,0 +1,11 @@
1
+ export declare const VOICE_RECORDER_CONTAINER_SIZES: {
2
+ COLLAPSED: number;
3
+ EXPANDED: number;
4
+ };
5
+ export declare const VOICE_RECORDER_MAX_DURATION_MS = 300000;
6
+ export declare enum VoiceRecorderState {
7
+ IDLE = 0,
8
+ RECORDING = 1,
9
+ PAUSED = 2
10
+ }
11
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/features/voiceRecord/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,8BAA8B;;;CAG1C,CAAA;AACD,eAAO,MAAM,8BAA8B,SAAS,CAAA;AACpD,oBAAY,kBAAkB;IAC5B,IAAI,IAAA;IACJ,SAAS,IAAA;IACT,MAAM,IAAA;CACP"}
@@ -0,0 +1,29 @@
1
+ import { AudioPlayer, AudioRecorder } from 'expo-audio';
2
+ import { AudioApi } from './types';
3
+ export declare const formatDuration: (ms: number) => string;
4
+ export declare const ensureRecordingPermissions: () => Promise<boolean>;
5
+ export declare const getAvailableInputs: (recorder: AudioRecorder) => Promise<MediaDeviceInfo[] | import("expo-audio").RecordingInput[]>;
6
+ export declare const addAudioInputsListenerWeb: (callback: (devices: MediaDeviceInfo[]) => void) => () => void;
7
+ /**
8
+ *
9
+ * @param fileUri
10
+ * @param externalPlayer - is optional expo-audio player, but should be provided
11
+ * because creating player is resource consuming operation
12
+ */
13
+ export declare const getAudioDurationMs: (fileUri: string, externalPlayer?: AudioPlayer) => Promise<number | undefined>;
14
+ type GenerateAudioFormDataParams = {
15
+ audioFileUri: string;
16
+ durationMs?: number;
17
+ fileName?: string;
18
+ };
19
+ export declare const generateAudioFormData: ({ audioFileUri, durationMs, fileName, }: GenerateAudioFormDataParams) => Promise<FormData>;
20
+ export declare const uploadAudioFileRequestGenerator: (audioFileFormData: FormData, api: AudioApi) => {
21
+ uploadAudio: () => Promise<{
22
+ id: string;
23
+ fileName: string;
24
+ fileType: string;
25
+ }>;
26
+ controller: AbortController;
27
+ };
28
+ export {};
29
+ //# sourceMappingURL=helpers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../src/features/voiceRecord/helpers.ts"],"names":[],"mappings":"AACA,OAAO,EACL,WAAW,EACX,aAAa,EAId,MAAM,YAAY,CAAA;AACnB,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAA;AAElC,eAAO,MAAM,cAAc,OAAQ,MAAM,KAAG,MAK3C,CAAA;AAED,eAAO,MAAM,0BAA0B,wBAStC,CAAA;AASD,eAAO,MAAM,kBAAkB,aAAoB,aAAa,uEAQ/D,CAAA;AAED,eAAO,MAAM,yBAAyB,aAAc,CAAC,OAAO,EAAE,eAAe,EAAE,KAAK,IAAI,eAiBvF,CAAA;AACD;;;;;GAKG;AACH,eAAO,MAAM,kBAAkB,YACpB,MAAM,mBACE,WAAW,KAC3B,OAAO,CAAC,MAAM,GAAG,SAAS,CAkC5B,CAAA;AAED,KAAK,2BAA2B,GAAG;IACjC,YAAY,EAAE,MAAM,CAAA;IACpB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,CAAA;AAED,eAAO,MAAM,qBAAqB,4CAI/B,2BAA2B,KAAG,OAAO,CAAC,QAAQ,CA8BhD,CAAA;AAED,eAAO,MAAM,+BAA+B,sBAAuB,QAAQ,OAAO,QAAQ;;;;;;;CAgBzF,CAAA"}
@@ -0,0 +1,5 @@
1
+ import { VoiceRecordModel } from '../model/VoiceRecord.model';
2
+ export declare const useVoiceRecorder: (model: VoiceRecordModel) => {
3
+ recorderState: import("expo-audio").RecorderState;
4
+ };
5
+ //# sourceMappingURL=useVoiceRecorder.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useVoiceRecorder.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/hooks/useVoiceRecorder.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAA;AAM7D,eAAO,MAAM,gBAAgB,UAAW,gBAAgB;;CAuEvD,CAAA"}
@@ -0,0 +1,6 @@
1
+ export declare const useVoiceRecorderAnimation: (isExpanded: boolean) => {
2
+ containerAnimatedStyle: {
3
+ height: number;
4
+ };
5
+ };
6
+ //# sourceMappingURL=useVoiceRecorderAnimation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useVoiceRecorderAnimation.d.ts","sourceRoot":"","sources":["../../../../../../src/features/voiceRecord/hooks/useVoiceRecorderAnimation.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,yBAAyB,eAAgB,OAAO;;;;CAe5D,CAAA"}
@@ -0,0 +1,7 @@
1
+ export * from './components/VoiceRecord';
2
+ export * from './model/VoiceRecord.model';
3
+ export * from './modal/VoiceRecordDeleteModal';
4
+ export * from './modal/VoiceRecordUndoModal';
5
+ export * from './constants';
6
+ export * from './types';
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/features/voiceRecord/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAA;AACxC,cAAc,2BAA2B,CAAA;AACzC,cAAc,gCAAgC,CAAA;AAC9C,cAAc,8BAA8B,CAAA;AAC5C,cAAc,aAAa,CAAA;AAC3B,cAAc,SAAS,CAAA"}