@coorpacademy/components 10.24.5 → 10.25.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (817) hide show
  1. package/es/atom/choice/test/fixtures.native.d.ts +2 -0
  2. package/es/atom/choice/test/fixtures.native.d.ts.map +1 -0
  3. package/es/atom/gradient/test/fixtures.native.d.ts +2 -0
  4. package/es/atom/gradient/test/fixtures.native.d.ts.map +1 -0
  5. package/es/atom/header-back-button/test/fixtures.native.d.ts +2 -0
  6. package/es/atom/header-back-button/test/fixtures.native.d.ts.map +1 -0
  7. package/es/atom/header-back-icon/test/fixtures.native.d.ts +2 -0
  8. package/es/atom/header-back-icon/test/fixtures.native.d.ts.map +1 -0
  9. package/es/atom/html/test/fixtures.native.d.ts +2 -0
  10. package/es/atom/html/test/fixtures.native.d.ts.map +1 -0
  11. package/es/atom/image-background/test/fixtures.native.d.ts +2 -0
  12. package/es/atom/image-background/test/fixtures.native.d.ts.map +1 -0
  13. package/es/atom/loader/index.d.ts +13 -0
  14. package/es/atom/loader/index.d.ts.map +1 -0
  15. package/es/atom/lottie-wrapper/index.d.ts +8 -0
  16. package/es/atom/lottie-wrapper/index.d.ts.map +1 -0
  17. package/es/atom/lottie-wrapper/prop-types.d.ts +26 -9
  18. package/es/atom/lottie-wrapper/prop-types.d.ts.map +1 -1
  19. package/es/atom/lottie-wrapper/prop-types.js +2 -1
  20. package/es/atom/lottie-wrapper/prop-types.js.map +1 -1
  21. package/es/atom/lottie-wrapper/test/fixtures/confetti.d.ts +20 -0
  22. package/es/atom/lottie-wrapper/test/fixtures/confetti.d.ts.map +1 -0
  23. package/es/atom/lottie-wrapper/test/fixtures/default.d.ts +20 -0
  24. package/es/atom/lottie-wrapper/test/fixtures/default.d.ts.map +1 -0
  25. package/es/atom/lottie-wrapper/test/fixtures/rank.d.ts +16 -0
  26. package/es/atom/lottie-wrapper/test/fixtures/rank.d.ts.map +1 -0
  27. package/es/atom/provider/index.d.ts +1 -1
  28. package/es/atom/provider/web-context.js +1 -1
  29. package/es/atom/provider/web-context.js.map +1 -1
  30. package/es/atom/range/handle.d.ts +34 -0
  31. package/es/atom/range/handle.d.ts.map +1 -0
  32. package/es/atom/range/index.d.ts +32 -0
  33. package/es/atom/range/index.d.ts.map +1 -0
  34. package/es/atom/review-background/index.d.ts +7 -0
  35. package/es/atom/review-background/index.d.ts.map +1 -0
  36. package/es/atom/review-header-step-item/index.d.ts +2 -2
  37. package/es/atom/review-header-step-item/index.d.ts.map +1 -1
  38. package/es/atom/review-header-step-item/index.js.map +1 -1
  39. package/es/atom/review-header-step-item/index.native.d.ts +2 -2
  40. package/es/atom/review-header-step-item/index.native.d.ts.map +1 -1
  41. package/es/atom/review-header-step-item/index.native.js.map +1 -1
  42. package/es/atom/review-header-step-item/test/fixtures.native.d.ts +2 -0
  43. package/es/atom/review-header-step-item/test/fixtures.native.d.ts.map +1 -0
  44. package/es/atom/review-header-step-item/types.d.ts +2 -2
  45. package/es/atom/review-header-step-item/types.d.ts.map +1 -1
  46. package/es/atom/review-header-step-item/types.js.map +1 -1
  47. package/es/atom/review-presentation/index.d.ts +7 -0
  48. package/es/atom/review-presentation/index.d.ts.map +1 -0
  49. package/es/atom/review-presentation/prop-types.d.ts +26 -0
  50. package/es/atom/review-presentation/prop-types.d.ts.map +1 -0
  51. package/es/atom/review-presentation/test/fixtures/default.d.ts +28 -0
  52. package/es/atom/review-presentation/test/fixtures/default.d.ts.map +1 -0
  53. package/es/atom/select/index.d.ts +56 -0
  54. package/es/atom/select/index.d.ts.map +1 -0
  55. package/es/atom/select-modal/test/fixtures.native.d.ts +2 -0
  56. package/es/atom/select-modal/test/fixtures.native.d.ts.map +1 -0
  57. package/es/atom/space/test/fixtures.native.d.ts +2 -0
  58. package/es/atom/space/test/fixtures.native.d.ts.map +1 -0
  59. package/es/atom/text/test/fixtures.native.d.ts +2 -0
  60. package/es/atom/text/test/fixtures.native.d.ts.map +1 -0
  61. package/es/hoc/animation/index.d.ts +54 -0
  62. package/es/hoc/animation/index.d.ts.map +1 -0
  63. package/es/hoc/animation-scheduler/index.d.ts +38 -0
  64. package/es/hoc/animation-scheduler/index.d.ts.map +1 -0
  65. package/es/hoc/animation-scheduler/index.js +3 -3
  66. package/es/hoc/animation-scheduler/index.js.map +1 -1
  67. package/es/hoc/modal/select/test/fixtures.native.d.ts +2 -0
  68. package/es/hoc/modal/select/test/fixtures.native.d.ts.map +1 -0
  69. package/es/hoc/modal/select-item/test/fixtures.native.d.ts +2 -0
  70. package/es/hoc/modal/select-item/test/fixtures.native.d.ts.map +1 -0
  71. package/es/hoc/modal/test/fixtures.native.d.ts +2 -0
  72. package/es/hoc/modal/test/fixtures.native.d.ts.map +1 -0
  73. package/es/hoc/swapper/index.js +1 -1
  74. package/es/hoc/swapper/index.js.map +1 -1
  75. package/es/hoc/touchable/test/fixtures.native.d.ts +2 -0
  76. package/es/hoc/touchable/test/fixtures.native.d.ts.map +1 -0
  77. package/es/hoc/transition/index.d.ts +11 -0
  78. package/es/hoc/transition/index.d.ts.map +1 -0
  79. package/es/hoc/transition/index.js +1 -1
  80. package/es/hoc/transition/index.js.map +1 -1
  81. package/es/molecule/add-to-my-list/index.js +1 -1
  82. package/es/molecule/add-to-my-list/index.js.map +1 -1
  83. package/es/molecule/answer/index.d.ts +7 -0
  84. package/es/molecule/answer/index.d.ts.map +1 -0
  85. package/es/molecule/answer/index.native.d.ts +2 -2
  86. package/es/molecule/answer/index.native.d.ts.map +1 -1
  87. package/es/molecule/answer/index.native.js.map +1 -1
  88. package/es/molecule/answer/prop-types.d.ts +27 -10
  89. package/es/molecule/answer/prop-types.d.ts.map +1 -1
  90. package/es/molecule/answer/prop-types.js.map +1 -1
  91. package/es/molecule/answer/test/fixtures/audio.d.ts +7 -0
  92. package/es/molecule/answer/test/fixtures/audio.d.ts.map +1 -0
  93. package/es/molecule/answer/test/fixtures/default.d.ts +7 -0
  94. package/es/molecule/answer/test/fixtures/default.d.ts.map +1 -0
  95. package/es/molecule/answer/test/fixtures/drop-down.d.ts +2 -2
  96. package/es/molecule/answer/test/fixtures/drop-down.d.ts.map +1 -1
  97. package/es/molecule/answer/test/fixtures/qcm-arabic.d.ts +7 -0
  98. package/es/molecule/answer/test/fixtures/qcm-arabic.d.ts.map +1 -0
  99. package/es/molecule/answer/test/fixtures/qcm-drag.d.ts +7 -0
  100. package/es/molecule/answer/test/fixtures/qcm-drag.d.ts.map +1 -0
  101. package/es/molecule/answer/test/fixtures/qcm-graphic.d.ts +7 -0
  102. package/es/molecule/answer/test/fixtures/qcm-graphic.d.ts.map +1 -0
  103. package/es/molecule/answer/test/fixtures/qcm-short-audio.d.ts +7 -0
  104. package/es/molecule/answer/test/fixtures/qcm-short-audio.d.ts.map +1 -0
  105. package/es/molecule/answer/test/fixtures/qcm-short-video.d.ts +7 -0
  106. package/es/molecule/answer/test/fixtures/qcm-short-video.d.ts.map +1 -0
  107. package/es/molecule/answer/test/fixtures/qcm-short.d.ts +7 -0
  108. package/es/molecule/answer/test/fixtures/qcm-short.d.ts.map +1 -0
  109. package/es/molecule/answer/test/fixtures/qcm.d.ts +7 -0
  110. package/es/molecule/answer/test/fixtures/qcm.d.ts.map +1 -0
  111. package/es/molecule/answer/test/fixtures/range.d.ts +7 -0
  112. package/es/molecule/answer/test/fixtures/range.d.ts.map +1 -0
  113. package/es/molecule/answer/test/fixtures/template.d.ts +2 -2
  114. package/es/molecule/answer/test/fixtures/template.d.ts.map +1 -1
  115. package/es/molecule/answer/test/fixtures.native.d.ts +2 -0
  116. package/es/molecule/answer/test/fixtures.native.d.ts.map +1 -0
  117. package/es/molecule/audio/index.d.ts +42 -0
  118. package/es/molecule/audio/index.d.ts.map +1 -0
  119. package/es/molecule/brand-logo/test/fixtures.native.d.ts +2 -0
  120. package/es/molecule/brand-logo/test/fixtures.native.d.ts.map +1 -0
  121. package/es/molecule/card/index.js +1 -1
  122. package/es/molecule/card/index.js.map +1 -1
  123. package/es/molecule/cm-popin/index.d.ts +2 -51
  124. package/es/molecule/cm-popin/index.js +2 -37
  125. package/es/molecule/cm-popin/index.js.map +1 -1
  126. package/es/molecule/cm-popin/test/fixtures/on-review-quit.d.ts +7 -0
  127. package/es/molecule/cm-popin/test/fixtures/on-review-quit.d.ts.map +1 -0
  128. package/es/molecule/cm-popin/types.d.ts +70 -0
  129. package/es/molecule/cm-popin/types.d.ts.map +1 -0
  130. package/es/molecule/cm-popin/types.js +41 -0
  131. package/es/molecule/cm-popin/types.js.map +1 -0
  132. package/es/molecule/dashboard/battle-request-list/index.js +1 -1
  133. package/es/molecule/dashboard/battle-request-list/index.js.map +1 -1
  134. package/es/molecule/dashboard/news-list/index.js +1 -1
  135. package/es/molecule/dashboard/news-list/index.js.map +1 -1
  136. package/es/molecule/dashboard/review-banner/index.js +1 -1
  137. package/es/molecule/dashboard/review-banner/index.js.map +1 -1
  138. package/es/molecule/dashboard/start-battle/index.js +1 -1
  139. package/es/molecule/dashboard/start-battle/index.js.map +1 -1
  140. package/es/molecule/questions/drop-down/index.d.ts +16 -0
  141. package/es/molecule/questions/drop-down/index.d.ts.map +1 -0
  142. package/es/molecule/questions/free-text/index.d.ts +35 -0
  143. package/es/molecule/questions/free-text/index.d.ts.map +1 -0
  144. package/es/molecule/questions/free-text/test/fixtures/default.d.ts +7 -0
  145. package/es/molecule/questions/free-text/test/fixtures/default.d.ts.map +1 -0
  146. package/es/molecule/questions/free-text/test/fixtures/with-value-on-change.d.ts +10 -0
  147. package/es/molecule/questions/free-text/test/fixtures/with-value-on-change.d.ts.map +1 -0
  148. package/es/molecule/questions/free-text/test/fixtures/with-value.d.ts +8 -0
  149. package/es/molecule/questions/free-text/test/fixtures/with-value.d.ts.map +1 -0
  150. package/es/molecule/questions/free-text/test/fixtures.native.d.ts +2 -0
  151. package/es/molecule/questions/free-text/test/fixtures.native.d.ts.map +1 -0
  152. package/es/molecule/questions/mobile/draggable/test/fixtures.native.d.ts +2 -0
  153. package/es/molecule/questions/mobile/draggable/test/fixtures.native.d.ts.map +1 -0
  154. package/es/molecule/questions/mobile/slider/test/fixtures.native.d.ts +2 -0
  155. package/es/molecule/questions/mobile/slider/test/fixtures.native.d.ts.map +1 -0
  156. package/es/molecule/questions/mobile/switch/test/fixtures.native.d.ts +2 -0
  157. package/es/molecule/questions/mobile/switch/test/fixtures.native.d.ts.map +1 -0
  158. package/es/molecule/questions/mobile/template/test/fixtures.native.d.ts +2 -0
  159. package/es/molecule/questions/mobile/template/test/fixtures.native.d.ts.map +1 -0
  160. package/es/molecule/questions/qcm/index.d.ts +37 -0
  161. package/es/molecule/questions/qcm/index.d.ts.map +1 -0
  162. package/es/molecule/questions/qcm/test/fixtures/arabic.d.ts +11 -0
  163. package/es/molecule/questions/qcm/test/fixtures/arabic.d.ts.map +1 -0
  164. package/es/molecule/questions/qcm/test/fixtures/default.d.ts +12 -0
  165. package/es/molecule/questions/qcm/test/fixtures/default.d.ts.map +1 -0
  166. package/es/molecule/questions/qcm/test/fixtures/short-answers.d.ts +11 -0
  167. package/es/molecule/questions/qcm/test/fixtures/short-answers.d.ts.map +1 -0
  168. package/es/molecule/questions/qcm-drag/index.d.ts +68 -0
  169. package/es/molecule/questions/qcm-drag/index.d.ts.map +1 -0
  170. package/es/molecule/questions/qcm-drag/test/fixtures/default.d.ts +17 -0
  171. package/es/molecule/questions/qcm-drag/test/fixtures/default.d.ts.map +1 -0
  172. package/es/molecule/questions/qcm-graphic/index.d.ts +38 -0
  173. package/es/molecule/questions/qcm-graphic/index.d.ts.map +1 -0
  174. package/es/molecule/questions/qcm-graphic/test/fixtures/default.d.ts +12 -0
  175. package/es/molecule/questions/qcm-graphic/test/fixtures/default.d.ts.map +1 -0
  176. package/es/molecule/questions/question-range/index.d.ts +38 -0
  177. package/es/molecule/questions/question-range/index.d.ts.map +1 -0
  178. package/es/molecule/questions/question-range/test/fixtures/default.d.ts +11 -0
  179. package/es/molecule/questions/question-range/test/fixtures/default.d.ts.map +1 -0
  180. package/es/molecule/questions/template/index.d.ts +31 -0
  181. package/es/molecule/questions/template/index.d.ts.map +1 -0
  182. package/es/molecule/review-card-congrats/index.d.ts +8 -0
  183. package/es/molecule/review-card-congrats/index.d.ts.map +1 -0
  184. package/es/molecule/review-card-congrats/prop-types.d.ts +14 -1
  185. package/es/molecule/review-card-congrats/prop-types.d.ts.map +1 -1
  186. package/es/molecule/review-card-congrats/prop-types.js.map +1 -1
  187. package/es/molecule/review-card-congrats/test/fixtures/rank.d.ts +28 -0
  188. package/es/molecule/review-card-congrats/test/fixtures/rank.d.ts.map +1 -0
  189. package/es/molecule/review-card-congrats/test/fixtures/star.d.ts +31 -0
  190. package/es/molecule/review-card-congrats/test/fixtures/star.d.ts.map +1 -0
  191. package/es/molecule/review-correction-popin/index.d.ts +7 -0
  192. package/es/molecule/review-correction-popin/index.d.ts.map +1 -0
  193. package/es/molecule/review-correction-popin/prop-types.d.ts +26 -9
  194. package/es/molecule/review-correction-popin/prop-types.d.ts.map +1 -1
  195. package/es/molecule/review-correction-popin/prop-types.js +2 -1
  196. package/es/molecule/review-correction-popin/prop-types.js.map +1 -1
  197. package/es/molecule/review-correction-popin/test/fixtures/right.d.ts +18 -0
  198. package/es/molecule/review-correction-popin/test/fixtures/right.d.ts.map +1 -0
  199. package/es/molecule/review-correction-popin/test/fixtures/wrong.d.ts +22 -0
  200. package/es/molecule/review-correction-popin/test/fixtures/wrong.d.ts.map +1 -0
  201. package/es/molecule/review-header-steps/index.d.ts +7 -0
  202. package/es/molecule/review-header-steps/index.d.ts.map +1 -0
  203. package/es/molecule/review-header-steps/prop-types.d.ts +9 -5
  204. package/es/molecule/review-header-steps/prop-types.d.ts.map +1 -1
  205. package/es/molecule/review-header-steps/prop-types.js +2 -1
  206. package/es/molecule/review-header-steps/prop-types.js.map +1 -1
  207. package/es/molecule/review-header-steps/test/fixtures/all-questions-ok.d.ts +7 -0
  208. package/es/molecule/review-header-steps/test/fixtures/all-questions-ok.d.ts.map +1 -0
  209. package/es/molecule/review-header-steps/test/fixtures/current-question-no-aswered.d.ts +7 -0
  210. package/es/molecule/review-header-steps/test/fixtures/current-question-no-aswered.d.ts.map +1 -0
  211. package/es/molecule/review-header-steps/test/fixtures/current-question-wrong.d.ts +7 -0
  212. package/es/molecule/review-header-steps/test/fixtures/current-question-wrong.d.ts.map +1 -0
  213. package/es/molecule/review-header-steps/test/fixtures/first-question-current-right.d.ts +7 -0
  214. package/es/molecule/review-header-steps/test/fixtures/first-question-current-right.d.ts.map +1 -0
  215. package/es/molecule/review-header-steps/test/fixtures/no-answered-question.d.ts +7 -0
  216. package/es/molecule/review-header-steps/test/fixtures/no-answered-question.d.ts.map +1 -0
  217. package/es/molecule/review-header-steps/test/fixtures/question-to-repeat.d.ts +7 -0
  218. package/es/molecule/review-header-steps/test/fixtures/question-to-repeat.d.ts.map +1 -0
  219. package/es/molecule/share/index.js +1 -1
  220. package/es/molecule/share/index.js.map +1 -1
  221. package/es/molecule/skill-card/index.d.ts +7 -0
  222. package/es/molecule/skill-card/index.d.ts.map +1 -0
  223. package/es/molecule/skill-card/test/fixtures/default.d.ts +16 -0
  224. package/es/molecule/skill-card/test/fixtures/default.d.ts.map +1 -0
  225. package/es/molecule/video-iframe/index.d.ts +22 -0
  226. package/es/molecule/video-iframe/index.d.ts.map +1 -0
  227. package/es/molecule/video-player/index.d.ts +51 -0
  228. package/es/molecule/video-player/index.d.ts.map +1 -0
  229. package/es/molecule/video-player/jwplayer.d.ts +58 -0
  230. package/es/molecule/video-player/jwplayer.d.ts.map +1 -0
  231. package/es/molecule/video-player/vimeo.d.ts +154 -0
  232. package/es/molecule/video-player/vimeo.d.ts.map +1 -0
  233. package/es/organism/header-v2/test/fixtures.native.d.ts +2 -0
  234. package/es/organism/header-v2/test/fixtures.native.d.ts.map +1 -0
  235. package/es/organism/mobile-navigation/test/fixtures.native.d.ts +2 -0
  236. package/es/organism/mobile-navigation/test/fixtures.native.d.ts.map +1 -0
  237. package/es/organism/review-congrats/index.d.ts +8 -0
  238. package/es/organism/review-congrats/index.d.ts.map +1 -0
  239. package/es/organism/review-congrats/prop-types.d.ts +25 -3
  240. package/es/organism/review-congrats/prop-types.d.ts.map +1 -1
  241. package/es/organism/review-congrats/prop-types.js +2 -1
  242. package/es/organism/review-congrats/prop-types.js.map +1 -1
  243. package/es/organism/review-congrats/test/fixtures/default.d.ts +7 -0
  244. package/es/organism/review-congrats/test/fixtures/default.d.ts.map +1 -0
  245. package/es/organism/review-header/index.d.ts +7 -0
  246. package/es/organism/review-header/index.d.ts.map +1 -0
  247. package/es/organism/review-header/index.native.d.ts +2 -2
  248. package/es/organism/review-header/index.native.d.ts.map +1 -1
  249. package/es/organism/review-header/index.native.js.map +1 -1
  250. package/es/organism/review-header/test/fixtures/all-questions-ok.d.ts +15 -0
  251. package/es/organism/review-header/test/fixtures/all-questions-ok.d.ts.map +1 -0
  252. package/es/organism/review-header/test/fixtures/current-question-no-answered.d.ts +7 -0
  253. package/es/organism/review-header/test/fixtures/current-question-no-answered.d.ts.map +1 -0
  254. package/es/organism/review-header/test/fixtures/current-question-wrong.d.ts +7 -0
  255. package/es/organism/review-header/test/fixtures/current-question-wrong.d.ts.map +1 -0
  256. package/es/organism/review-header/test/fixtures/first-question-current-right.d.ts +7 -0
  257. package/es/organism/review-header/test/fixtures/first-question-current-right.d.ts.map +1 -0
  258. package/es/organism/review-header/test/fixtures/no-answered-question.d.ts +7 -0
  259. package/es/organism/review-header/test/fixtures/no-answered-question.d.ts.map +1 -0
  260. package/es/organism/review-header/test/fixtures/question-to-repeat.d.ts +7 -0
  261. package/es/organism/review-header/test/fixtures/question-to-repeat.d.ts.map +1 -0
  262. package/es/organism/review-header/test/fixtures/steps-animation.d.ts +7 -0
  263. package/es/organism/review-header/test/fixtures/steps-animation.d.ts.map +1 -0
  264. package/es/organism/review-header/test/fixtures.native.d.ts +2 -0
  265. package/es/organism/review-header/test/fixtures.native.d.ts.map +1 -0
  266. package/es/organism/review-header/types.d.ts +4 -4
  267. package/es/organism/review-header/types.d.ts.map +1 -1
  268. package/es/organism/review-header/types.js.map +1 -1
  269. package/es/organism/review-skills/index.d.ts +7 -0
  270. package/es/organism/review-skills/index.d.ts.map +1 -0
  271. package/es/organism/review-skills/test/fixtures/many-skills.d.ts +22 -0
  272. package/es/organism/review-skills/test/fixtures/many-skills.d.ts.map +1 -0
  273. package/es/organism/review-skills/test/fixtures/no-skills.d.ts +12 -0
  274. package/es/organism/review-skills/test/fixtures/no-skills.d.ts.map +1 -0
  275. package/es/organism/review-slide/index.d.ts +7 -0
  276. package/es/organism/review-slide/index.d.ts.map +1 -0
  277. package/es/organism/review-slide/index.native.d.ts +2 -2
  278. package/es/organism/review-slide/index.native.d.ts.map +1 -1
  279. package/es/organism/review-slide/index.native.js +3 -3
  280. package/es/organism/review-slide/index.native.js.map +1 -1
  281. package/es/organism/review-slide/prop-types.d.ts +21 -36
  282. package/es/organism/review-slide/prop-types.d.ts.map +1 -1
  283. package/es/organism/review-slide/prop-types.js.map +1 -1
  284. package/es/organism/review-slide/test/fixtures/choices-selected.d.ts +22 -0
  285. package/es/organism/review-slide/test/fixtures/choices-selected.d.ts.map +1 -0
  286. package/es/organism/review-slide/test/fixtures/correction-ok-animated.d.ts +36 -0
  287. package/es/organism/review-slide/test/fixtures/correction-ok-animated.d.ts.map +1 -0
  288. package/es/organism/review-slide/test/fixtures/correction-ok.d.ts +36 -0
  289. package/es/organism/review-slide/test/fixtures/correction-ok.d.ts.map +1 -0
  290. package/es/organism/review-slide/test/fixtures/correction-wrong-animated.d.ts +38 -0
  291. package/es/organism/review-slide/test/fixtures/correction-wrong-animated.d.ts.map +1 -0
  292. package/es/organism/review-slide/test/fixtures/correction-wrong.d.ts +38 -0
  293. package/es/organism/review-slide/test/fixtures/correction-wrong.d.ts.map +1 -0
  294. package/es/organism/review-slide/test/fixtures/initial-state.d.ts +22 -0
  295. package/es/organism/review-slide/test/fixtures/initial-state.d.ts.map +1 -0
  296. package/es/organism/review-slide/test/fixtures/loading.d.ts +12 -0
  297. package/es/organism/review-slide/test/fixtures/loading.d.ts.map +1 -0
  298. package/es/organism/review-slide/test/fixtures.native.d.ts +2 -0
  299. package/es/organism/review-slide/test/fixtures.native.d.ts.map +1 -0
  300. package/es/organism/review-stacked-slides/index.d.ts +13 -0
  301. package/es/organism/review-stacked-slides/index.d.ts.map +1 -0
  302. package/es/organism/review-stacked-slides/index.js +3 -6
  303. package/es/organism/review-stacked-slides/index.js.map +1 -1
  304. package/es/organism/review-stacked-slides/index.native.d.ts +2 -2
  305. package/es/organism/review-stacked-slides/index.native.d.ts.map +1 -1
  306. package/es/organism/review-stacked-slides/index.native.js +3 -6
  307. package/es/organism/review-stacked-slides/index.native.js.map +1 -1
  308. package/es/organism/review-stacked-slides/prop-types.d.ts +26 -25
  309. package/es/organism/review-stacked-slides/prop-types.d.ts.map +1 -1
  310. package/es/organism/review-stacked-slides/prop-types.js.map +1 -1
  311. package/es/organism/review-stacked-slides/test/fixtures/all-ok.d.ts +9 -0
  312. package/es/organism/review-stacked-slides/test/fixtures/all-ok.d.ts.map +1 -0
  313. package/es/organism/review-stacked-slides/test/fixtures/end-review.d.ts +7 -0
  314. package/es/organism/review-stacked-slides/test/fixtures/end-review.d.ts.map +1 -0
  315. package/es/organism/review-stacked-slides/test/fixtures/first-correct.d.ts +9 -0
  316. package/es/organism/review-stacked-slides/test/fixtures/first-correct.d.ts.map +1 -0
  317. package/es/organism/review-stacked-slides/test/fixtures/initial-state.d.ts +7 -0
  318. package/es/organism/review-stacked-slides/test/fixtures/initial-state.d.ts.map +1 -0
  319. package/es/organism/review-stacked-slides/test/fixtures/loading.d.ts +7 -0
  320. package/es/organism/review-stacked-slides/test/fixtures/loading.d.ts.map +1 -0
  321. package/es/organism/review-stacked-slides/test/fixtures/restack.d.ts +9 -0
  322. package/es/organism/review-stacked-slides/test/fixtures/restack.d.ts.map +1 -0
  323. package/es/organism/review-stacked-slides/test/fixtures/second-wrong.d.ts +9 -0
  324. package/es/organism/review-stacked-slides/test/fixtures/second-wrong.d.ts.map +1 -0
  325. package/es/organism/review-stacked-slides/test/fixtures/unstack.d.ts +9 -0
  326. package/es/organism/review-stacked-slides/test/fixtures/unstack.d.ts.map +1 -0
  327. package/es/organism/review-stacked-slides/test/fixtures/wrong.d.ts +9 -0
  328. package/es/organism/review-stacked-slides/test/fixtures/wrong.d.ts.map +1 -0
  329. package/es/organism/review-stacked-slides/test/fixtures.native.d.ts +2 -0
  330. package/es/organism/review-stacked-slides/test/fixtures.native.d.ts.map +1 -0
  331. package/es/template/app-player/popin-end/summary.js +3 -4
  332. package/es/template/app-player/popin-end/summary.js.map +1 -1
  333. package/es/template/app-review/demo-ts/test/fixtures.native.d.ts +2 -0
  334. package/es/template/app-review/demo-ts/test/fixtures.native.d.ts.map +1 -0
  335. package/es/template/app-review/index.d.ts +603 -0
  336. package/es/template/app-review/index.d.ts.map +1 -0
  337. package/es/template/app-review/index.js +16 -21
  338. package/es/template/app-review/index.js.map +1 -1
  339. package/es/template/app-review/index.native.d.ts +5 -0
  340. package/es/template/app-review/index.native.d.ts.map +1 -0
  341. package/es/template/app-review/index.native.js +20 -25
  342. package/es/template/app-review/index.native.js.map +1 -1
  343. package/es/template/app-review/onboarding/index.d.ts +3 -0
  344. package/es/template/app-review/onboarding/index.d.ts.map +1 -0
  345. package/es/template/app-review/onboarding/index.native.d.ts +9 -0
  346. package/es/template/app-review/onboarding/index.native.d.ts.map +1 -0
  347. package/es/template/app-review/onboarding/test/fixtures/default.d.ts +3 -0
  348. package/es/template/app-review/onboarding/test/fixtures/default.d.ts.map +1 -0
  349. package/es/template/app-review/onboarding/test/fixtures.native.d.ts +2 -0
  350. package/es/template/app-review/onboarding/test/fixtures.native.d.ts.map +1 -0
  351. package/es/template/app-review/player/index.d.ts +13 -0
  352. package/es/template/app-review/player/index.d.ts.map +1 -0
  353. package/es/template/app-review/player/index.native.d.ts +2 -2
  354. package/es/template/app-review/player/index.native.d.ts.map +1 -1
  355. package/es/template/app-review/player/index.native.js.map +1 -1
  356. package/es/template/app-review/player/prop-types.d.ts +31 -31
  357. package/es/template/app-review/player/prop-types.d.ts.map +1 -1
  358. package/es/template/app-review/player/prop-types.js.map +1 -1
  359. package/es/template/app-review/player/test/fixtures/all-ok.d.ts +7 -0
  360. package/es/template/app-review/player/test/fixtures/all-ok.d.ts.map +1 -0
  361. package/es/template/app-review/player/test/fixtures/end-review.d.ts +7 -0
  362. package/es/template/app-review/player/test/fixtures/end-review.d.ts.map +1 -0
  363. package/es/template/app-review/player/test/fixtures/first-right.d.ts +7 -0
  364. package/es/template/app-review/player/test/fixtures/first-right.d.ts.map +1 -0
  365. package/es/template/app-review/player/test/fixtures/initial-state.d.ts +7 -0
  366. package/es/template/app-review/player/test/fixtures/initial-state.d.ts.map +1 -0
  367. package/es/template/app-review/player/test/fixtures/loading.d.ts +7 -0
  368. package/es/template/app-review/player/test/fixtures/loading.d.ts.map +1 -0
  369. package/es/template/app-review/player/test/fixtures/on-quit.d.ts +7 -0
  370. package/es/template/app-review/player/test/fixtures/on-quit.d.ts.map +1 -0
  371. package/es/template/app-review/player/test/fixtures/one-fail.d.ts +7 -0
  372. package/es/template/app-review/player/test/fixtures/one-fail.d.ts.map +1 -0
  373. package/es/template/app-review/player/test/fixtures/restack.d.ts +7 -0
  374. package/es/template/app-review/player/test/fixtures/restack.d.ts.map +1 -0
  375. package/es/template/app-review/player/test/fixtures/second-failed-question.d.ts +7 -0
  376. package/es/template/app-review/player/test/fixtures/second-failed-question.d.ts.map +1 -0
  377. package/es/template/app-review/player/test/fixtures/unstack.d.ts +7 -0
  378. package/es/template/app-review/player/test/fixtures/unstack.d.ts.map +1 -0
  379. package/es/template/app-review/player/test/fixtures.native.d.ts +2 -0
  380. package/es/template/app-review/player/test/fixtures.native.d.ts.map +1 -0
  381. package/es/template/app-review/prop-types.d.ts +610 -0
  382. package/es/template/app-review/prop-types.d.ts.map +1 -0
  383. package/es/template/app-review/prop-types.js +3 -9
  384. package/es/template/app-review/prop-types.js.map +1 -1
  385. package/es/template/app-review/skills/index.d.ts +3 -0
  386. package/es/template/app-review/skills/index.d.ts.map +1 -0
  387. package/es/template/app-review/skills/test/fixtures/many-skills.d.ts +3 -0
  388. package/es/template/app-review/skills/test/fixtures/many-skills.d.ts.map +1 -0
  389. package/es/template/app-review/skills/test/fixtures/no-skills.d.ts +3 -0
  390. package/es/template/app-review/skills/test/fixtures/no-skills.d.ts.map +1 -0
  391. package/es/template/app-review/skills/test/fixtures.native.d.ts +2 -0
  392. package/es/template/app-review/skills/test/fixtures.native.d.ts.map +1 -0
  393. package/es/template/app-review/template-context.js +1 -1
  394. package/es/template/app-review/template-context.js.map +1 -1
  395. package/es/template/app-review/test/fixtures/onboarding.d.ts +7 -0
  396. package/es/template/app-review/test/fixtures/onboarding.d.ts.map +1 -0
  397. package/es/template/app-review/test/fixtures/player.d.ts +7 -0
  398. package/es/template/app-review/test/fixtures/player.d.ts.map +1 -0
  399. package/es/template/app-review/test/fixtures/skills.d.ts +7 -0
  400. package/es/template/app-review/test/fixtures/skills.d.ts.map +1 -0
  401. package/es/template/app-review/test/fixtures.native.d.ts +2 -0
  402. package/es/template/app-review/test/fixtures.native.d.ts.map +1 -0
  403. package/es/template/common/dashboard/index.js +1 -1
  404. package/es/template/common/dashboard/index.js.map +1 -1
  405. package/es/test/helpers/render-component.d.ts +20 -0
  406. package/es/test/helpers/render-component.d.ts.map +1 -0
  407. package/es/util/get-shadow-box-color-from-primary.d.ts +2 -0
  408. package/es/util/get-shadow-box-color-from-primary.d.ts.map +1 -0
  409. package/lib/atom/choice/test/fixtures.native.d.ts +2 -0
  410. package/lib/atom/choice/test/fixtures.native.d.ts.map +1 -0
  411. package/lib/atom/gradient/test/fixtures.native.d.ts +2 -0
  412. package/lib/atom/gradient/test/fixtures.native.d.ts.map +1 -0
  413. package/lib/atom/header-back-button/test/fixtures.native.d.ts +2 -0
  414. package/lib/atom/header-back-button/test/fixtures.native.d.ts.map +1 -0
  415. package/lib/atom/header-back-icon/test/fixtures.native.d.ts +2 -0
  416. package/lib/atom/header-back-icon/test/fixtures.native.d.ts.map +1 -0
  417. package/lib/atom/html/test/fixtures.native.d.ts +2 -0
  418. package/lib/atom/html/test/fixtures.native.d.ts.map +1 -0
  419. package/lib/atom/image-background/test/fixtures.native.d.ts +2 -0
  420. package/lib/atom/image-background/test/fixtures.native.d.ts.map +1 -0
  421. package/lib/atom/loader/index.d.ts +13 -0
  422. package/lib/atom/loader/index.d.ts.map +1 -0
  423. package/lib/atom/lottie-wrapper/index.d.ts +8 -0
  424. package/lib/atom/lottie-wrapper/index.d.ts.map +1 -0
  425. package/lib/atom/lottie-wrapper/prop-types.d.ts +26 -9
  426. package/lib/atom/lottie-wrapper/prop-types.d.ts.map +1 -1
  427. package/lib/atom/lottie-wrapper/prop-types.js +2 -1
  428. package/lib/atom/lottie-wrapper/prop-types.js.map +1 -1
  429. package/lib/atom/lottie-wrapper/test/fixtures/confetti.d.ts +20 -0
  430. package/lib/atom/lottie-wrapper/test/fixtures/confetti.d.ts.map +1 -0
  431. package/lib/atom/lottie-wrapper/test/fixtures/default.d.ts +20 -0
  432. package/lib/atom/lottie-wrapper/test/fixtures/default.d.ts.map +1 -0
  433. package/lib/atom/lottie-wrapper/test/fixtures/rank.d.ts +16 -0
  434. package/lib/atom/lottie-wrapper/test/fixtures/rank.d.ts.map +1 -0
  435. package/lib/atom/provider/index.d.ts +1 -1
  436. package/lib/atom/provider/web-context.js +1 -1
  437. package/lib/atom/provider/web-context.js.map +1 -1
  438. package/lib/atom/range/handle.d.ts +34 -0
  439. package/lib/atom/range/handle.d.ts.map +1 -0
  440. package/lib/atom/range/index.d.ts +32 -0
  441. package/lib/atom/range/index.d.ts.map +1 -0
  442. package/lib/atom/review-background/index.d.ts +7 -0
  443. package/lib/atom/review-background/index.d.ts.map +1 -0
  444. package/lib/atom/review-header-step-item/index.d.ts +2 -2
  445. package/lib/atom/review-header-step-item/index.d.ts.map +1 -1
  446. package/lib/atom/review-header-step-item/index.js.map +1 -1
  447. package/lib/atom/review-header-step-item/index.native.d.ts +2 -2
  448. package/lib/atom/review-header-step-item/index.native.d.ts.map +1 -1
  449. package/lib/atom/review-header-step-item/index.native.js.map +1 -1
  450. package/lib/atom/review-header-step-item/test/fixtures.native.d.ts +2 -0
  451. package/lib/atom/review-header-step-item/test/fixtures.native.d.ts.map +1 -0
  452. package/lib/atom/review-header-step-item/types.d.ts +2 -2
  453. package/lib/atom/review-header-step-item/types.d.ts.map +1 -1
  454. package/lib/atom/review-header-step-item/types.js.map +1 -1
  455. package/lib/atom/review-presentation/index.d.ts +7 -0
  456. package/lib/atom/review-presentation/index.d.ts.map +1 -0
  457. package/lib/atom/review-presentation/prop-types.d.ts +26 -0
  458. package/lib/atom/review-presentation/prop-types.d.ts.map +1 -0
  459. package/lib/atom/review-presentation/test/fixtures/default.d.ts +28 -0
  460. package/lib/atom/review-presentation/test/fixtures/default.d.ts.map +1 -0
  461. package/lib/atom/select/index.d.ts +56 -0
  462. package/lib/atom/select/index.d.ts.map +1 -0
  463. package/lib/atom/select-modal/test/fixtures.native.d.ts +2 -0
  464. package/lib/atom/select-modal/test/fixtures.native.d.ts.map +1 -0
  465. package/lib/atom/space/test/fixtures.native.d.ts +2 -0
  466. package/lib/atom/space/test/fixtures.native.d.ts.map +1 -0
  467. package/lib/atom/text/test/fixtures.native.d.ts +2 -0
  468. package/lib/atom/text/test/fixtures.native.d.ts.map +1 -0
  469. package/lib/hoc/animation/index.d.ts +54 -0
  470. package/lib/hoc/animation/index.d.ts.map +1 -0
  471. package/lib/hoc/animation-scheduler/index.d.ts +38 -0
  472. package/lib/hoc/animation-scheduler/index.d.ts.map +1 -0
  473. package/lib/hoc/animation-scheduler/index.js +3 -3
  474. package/lib/hoc/animation-scheduler/index.js.map +1 -1
  475. package/lib/hoc/modal/select/test/fixtures.native.d.ts +2 -0
  476. package/lib/hoc/modal/select/test/fixtures.native.d.ts.map +1 -0
  477. package/lib/hoc/modal/select-item/test/fixtures.native.d.ts +2 -0
  478. package/lib/hoc/modal/select-item/test/fixtures.native.d.ts.map +1 -0
  479. package/lib/hoc/modal/test/fixtures.native.d.ts +2 -0
  480. package/lib/hoc/modal/test/fixtures.native.d.ts.map +1 -0
  481. package/lib/hoc/swapper/index.js +1 -1
  482. package/lib/hoc/swapper/index.js.map +1 -1
  483. package/lib/hoc/touchable/test/fixtures.native.d.ts +2 -0
  484. package/lib/hoc/touchable/test/fixtures.native.d.ts.map +1 -0
  485. package/lib/hoc/transition/index.d.ts +11 -0
  486. package/lib/hoc/transition/index.d.ts.map +1 -0
  487. package/lib/hoc/transition/index.js +1 -1
  488. package/lib/hoc/transition/index.js.map +1 -1
  489. package/lib/molecule/add-to-my-list/index.js +1 -1
  490. package/lib/molecule/add-to-my-list/index.js.map +1 -1
  491. package/lib/molecule/answer/index.d.ts +7 -0
  492. package/lib/molecule/answer/index.d.ts.map +1 -0
  493. package/lib/molecule/answer/index.native.d.ts +2 -2
  494. package/lib/molecule/answer/index.native.d.ts.map +1 -1
  495. package/lib/molecule/answer/index.native.js.map +1 -1
  496. package/lib/molecule/answer/prop-types.d.ts +27 -10
  497. package/lib/molecule/answer/prop-types.d.ts.map +1 -1
  498. package/lib/molecule/answer/prop-types.js.map +1 -1
  499. package/lib/molecule/answer/test/fixtures/audio.d.ts +7 -0
  500. package/lib/molecule/answer/test/fixtures/audio.d.ts.map +1 -0
  501. package/lib/molecule/answer/test/fixtures/default.d.ts +7 -0
  502. package/lib/molecule/answer/test/fixtures/default.d.ts.map +1 -0
  503. package/lib/molecule/answer/test/fixtures/drop-down.d.ts +2 -2
  504. package/lib/molecule/answer/test/fixtures/drop-down.d.ts.map +1 -1
  505. package/lib/molecule/answer/test/fixtures/qcm-arabic.d.ts +7 -0
  506. package/lib/molecule/answer/test/fixtures/qcm-arabic.d.ts.map +1 -0
  507. package/lib/molecule/answer/test/fixtures/qcm-drag.d.ts +7 -0
  508. package/lib/molecule/answer/test/fixtures/qcm-drag.d.ts.map +1 -0
  509. package/lib/molecule/answer/test/fixtures/qcm-graphic.d.ts +7 -0
  510. package/lib/molecule/answer/test/fixtures/qcm-graphic.d.ts.map +1 -0
  511. package/lib/molecule/answer/test/fixtures/qcm-short-audio.d.ts +7 -0
  512. package/lib/molecule/answer/test/fixtures/qcm-short-audio.d.ts.map +1 -0
  513. package/lib/molecule/answer/test/fixtures/qcm-short-video.d.ts +7 -0
  514. package/lib/molecule/answer/test/fixtures/qcm-short-video.d.ts.map +1 -0
  515. package/lib/molecule/answer/test/fixtures/qcm-short.d.ts +7 -0
  516. package/lib/molecule/answer/test/fixtures/qcm-short.d.ts.map +1 -0
  517. package/lib/molecule/answer/test/fixtures/qcm.d.ts +7 -0
  518. package/lib/molecule/answer/test/fixtures/qcm.d.ts.map +1 -0
  519. package/lib/molecule/answer/test/fixtures/range.d.ts +7 -0
  520. package/lib/molecule/answer/test/fixtures/range.d.ts.map +1 -0
  521. package/lib/molecule/answer/test/fixtures/template.d.ts +2 -2
  522. package/lib/molecule/answer/test/fixtures/template.d.ts.map +1 -1
  523. package/lib/molecule/answer/test/fixtures.native.d.ts +2 -0
  524. package/lib/molecule/answer/test/fixtures.native.d.ts.map +1 -0
  525. package/lib/molecule/audio/index.d.ts +42 -0
  526. package/lib/molecule/audio/index.d.ts.map +1 -0
  527. package/lib/molecule/brand-logo/test/fixtures.native.d.ts +2 -0
  528. package/lib/molecule/brand-logo/test/fixtures.native.d.ts.map +1 -0
  529. package/lib/molecule/card/index.js +1 -1
  530. package/lib/molecule/card/index.js.map +1 -1
  531. package/lib/molecule/cm-popin/index.d.ts +2 -51
  532. package/lib/molecule/cm-popin/index.js +3 -38
  533. package/lib/molecule/cm-popin/index.js.map +1 -1
  534. package/lib/molecule/cm-popin/test/fixtures/on-review-quit.d.ts +7 -0
  535. package/lib/molecule/cm-popin/test/fixtures/on-review-quit.d.ts.map +1 -0
  536. package/lib/molecule/cm-popin/types.d.ts +70 -0
  537. package/lib/molecule/cm-popin/types.d.ts.map +1 -0
  538. package/lib/molecule/cm-popin/types.js +52 -0
  539. package/lib/molecule/cm-popin/types.js.map +1 -0
  540. package/lib/molecule/dashboard/battle-request-list/index.js +1 -1
  541. package/lib/molecule/dashboard/battle-request-list/index.js.map +1 -1
  542. package/lib/molecule/dashboard/news-list/index.js +1 -1
  543. package/lib/molecule/dashboard/news-list/index.js.map +1 -1
  544. package/lib/molecule/dashboard/review-banner/index.js +1 -1
  545. package/lib/molecule/dashboard/review-banner/index.js.map +1 -1
  546. package/lib/molecule/dashboard/start-battle/index.js +1 -1
  547. package/lib/molecule/dashboard/start-battle/index.js.map +1 -1
  548. package/lib/molecule/questions/drop-down/index.d.ts +16 -0
  549. package/lib/molecule/questions/drop-down/index.d.ts.map +1 -0
  550. package/lib/molecule/questions/free-text/index.d.ts +35 -0
  551. package/lib/molecule/questions/free-text/index.d.ts.map +1 -0
  552. package/lib/molecule/questions/free-text/test/fixtures/default.d.ts +7 -0
  553. package/lib/molecule/questions/free-text/test/fixtures/default.d.ts.map +1 -0
  554. package/lib/molecule/questions/free-text/test/fixtures/with-value-on-change.d.ts +10 -0
  555. package/lib/molecule/questions/free-text/test/fixtures/with-value-on-change.d.ts.map +1 -0
  556. package/lib/molecule/questions/free-text/test/fixtures/with-value.d.ts +8 -0
  557. package/lib/molecule/questions/free-text/test/fixtures/with-value.d.ts.map +1 -0
  558. package/lib/molecule/questions/free-text/test/fixtures.native.d.ts +2 -0
  559. package/lib/molecule/questions/free-text/test/fixtures.native.d.ts.map +1 -0
  560. package/lib/molecule/questions/mobile/draggable/test/fixtures.native.d.ts +2 -0
  561. package/lib/molecule/questions/mobile/draggable/test/fixtures.native.d.ts.map +1 -0
  562. package/lib/molecule/questions/mobile/slider/test/fixtures.native.d.ts +2 -0
  563. package/lib/molecule/questions/mobile/slider/test/fixtures.native.d.ts.map +1 -0
  564. package/lib/molecule/questions/mobile/switch/test/fixtures.native.d.ts +2 -0
  565. package/lib/molecule/questions/mobile/switch/test/fixtures.native.d.ts.map +1 -0
  566. package/lib/molecule/questions/mobile/template/test/fixtures.native.d.ts +2 -0
  567. package/lib/molecule/questions/mobile/template/test/fixtures.native.d.ts.map +1 -0
  568. package/lib/molecule/questions/qcm/index.d.ts +37 -0
  569. package/lib/molecule/questions/qcm/index.d.ts.map +1 -0
  570. package/lib/molecule/questions/qcm/test/fixtures/arabic.d.ts +11 -0
  571. package/lib/molecule/questions/qcm/test/fixtures/arabic.d.ts.map +1 -0
  572. package/lib/molecule/questions/qcm/test/fixtures/default.d.ts +12 -0
  573. package/lib/molecule/questions/qcm/test/fixtures/default.d.ts.map +1 -0
  574. package/lib/molecule/questions/qcm/test/fixtures/short-answers.d.ts +11 -0
  575. package/lib/molecule/questions/qcm/test/fixtures/short-answers.d.ts.map +1 -0
  576. package/lib/molecule/questions/qcm-drag/index.d.ts +68 -0
  577. package/lib/molecule/questions/qcm-drag/index.d.ts.map +1 -0
  578. package/lib/molecule/questions/qcm-drag/test/fixtures/default.d.ts +17 -0
  579. package/lib/molecule/questions/qcm-drag/test/fixtures/default.d.ts.map +1 -0
  580. package/lib/molecule/questions/qcm-graphic/index.d.ts +38 -0
  581. package/lib/molecule/questions/qcm-graphic/index.d.ts.map +1 -0
  582. package/lib/molecule/questions/qcm-graphic/test/fixtures/default.d.ts +12 -0
  583. package/lib/molecule/questions/qcm-graphic/test/fixtures/default.d.ts.map +1 -0
  584. package/lib/molecule/questions/question-range/index.d.ts +38 -0
  585. package/lib/molecule/questions/question-range/index.d.ts.map +1 -0
  586. package/lib/molecule/questions/question-range/test/fixtures/default.d.ts +11 -0
  587. package/lib/molecule/questions/question-range/test/fixtures/default.d.ts.map +1 -0
  588. package/lib/molecule/questions/template/index.d.ts +31 -0
  589. package/lib/molecule/questions/template/index.d.ts.map +1 -0
  590. package/lib/molecule/review-card-congrats/index.d.ts +8 -0
  591. package/lib/molecule/review-card-congrats/index.d.ts.map +1 -0
  592. package/lib/molecule/review-card-congrats/prop-types.d.ts +14 -1
  593. package/lib/molecule/review-card-congrats/prop-types.d.ts.map +1 -1
  594. package/lib/molecule/review-card-congrats/prop-types.js.map +1 -1
  595. package/lib/molecule/review-card-congrats/test/fixtures/rank.d.ts +28 -0
  596. package/lib/molecule/review-card-congrats/test/fixtures/rank.d.ts.map +1 -0
  597. package/lib/molecule/review-card-congrats/test/fixtures/star.d.ts +31 -0
  598. package/lib/molecule/review-card-congrats/test/fixtures/star.d.ts.map +1 -0
  599. package/lib/molecule/review-correction-popin/index.d.ts +7 -0
  600. package/lib/molecule/review-correction-popin/index.d.ts.map +1 -0
  601. package/lib/molecule/review-correction-popin/prop-types.d.ts +26 -9
  602. package/lib/molecule/review-correction-popin/prop-types.d.ts.map +1 -1
  603. package/lib/molecule/review-correction-popin/prop-types.js +2 -1
  604. package/lib/molecule/review-correction-popin/prop-types.js.map +1 -1
  605. package/lib/molecule/review-correction-popin/test/fixtures/right.d.ts +18 -0
  606. package/lib/molecule/review-correction-popin/test/fixtures/right.d.ts.map +1 -0
  607. package/lib/molecule/review-correction-popin/test/fixtures/wrong.d.ts +22 -0
  608. package/lib/molecule/review-correction-popin/test/fixtures/wrong.d.ts.map +1 -0
  609. package/lib/molecule/review-header-steps/index.d.ts +7 -0
  610. package/lib/molecule/review-header-steps/index.d.ts.map +1 -0
  611. package/lib/molecule/review-header-steps/prop-types.d.ts +9 -5
  612. package/lib/molecule/review-header-steps/prop-types.d.ts.map +1 -1
  613. package/lib/molecule/review-header-steps/prop-types.js +2 -1
  614. package/lib/molecule/review-header-steps/prop-types.js.map +1 -1
  615. package/lib/molecule/review-header-steps/test/fixtures/all-questions-ok.d.ts +7 -0
  616. package/lib/molecule/review-header-steps/test/fixtures/all-questions-ok.d.ts.map +1 -0
  617. package/lib/molecule/review-header-steps/test/fixtures/current-question-no-aswered.d.ts +7 -0
  618. package/lib/molecule/review-header-steps/test/fixtures/current-question-no-aswered.d.ts.map +1 -0
  619. package/lib/molecule/review-header-steps/test/fixtures/current-question-wrong.d.ts +7 -0
  620. package/lib/molecule/review-header-steps/test/fixtures/current-question-wrong.d.ts.map +1 -0
  621. package/lib/molecule/review-header-steps/test/fixtures/first-question-current-right.d.ts +7 -0
  622. package/lib/molecule/review-header-steps/test/fixtures/first-question-current-right.d.ts.map +1 -0
  623. package/lib/molecule/review-header-steps/test/fixtures/no-answered-question.d.ts +7 -0
  624. package/lib/molecule/review-header-steps/test/fixtures/no-answered-question.d.ts.map +1 -0
  625. package/lib/molecule/review-header-steps/test/fixtures/question-to-repeat.d.ts +7 -0
  626. package/lib/molecule/review-header-steps/test/fixtures/question-to-repeat.d.ts.map +1 -0
  627. package/lib/molecule/share/index.js +1 -1
  628. package/lib/molecule/share/index.js.map +1 -1
  629. package/lib/molecule/skill-card/index.d.ts +7 -0
  630. package/lib/molecule/skill-card/index.d.ts.map +1 -0
  631. package/lib/molecule/skill-card/test/fixtures/default.d.ts +16 -0
  632. package/lib/molecule/skill-card/test/fixtures/default.d.ts.map +1 -0
  633. package/lib/molecule/video-iframe/index.d.ts +22 -0
  634. package/lib/molecule/video-iframe/index.d.ts.map +1 -0
  635. package/lib/molecule/video-player/index.d.ts +51 -0
  636. package/lib/molecule/video-player/index.d.ts.map +1 -0
  637. package/lib/molecule/video-player/jwplayer.d.ts +58 -0
  638. package/lib/molecule/video-player/jwplayer.d.ts.map +1 -0
  639. package/lib/molecule/video-player/vimeo.d.ts +154 -0
  640. package/lib/molecule/video-player/vimeo.d.ts.map +1 -0
  641. package/lib/organism/header-v2/test/fixtures.native.d.ts +2 -0
  642. package/lib/organism/header-v2/test/fixtures.native.d.ts.map +1 -0
  643. package/lib/organism/mobile-navigation/test/fixtures.native.d.ts +2 -0
  644. package/lib/organism/mobile-navigation/test/fixtures.native.d.ts.map +1 -0
  645. package/lib/organism/review-congrats/index.d.ts +8 -0
  646. package/lib/organism/review-congrats/index.d.ts.map +1 -0
  647. package/lib/organism/review-congrats/prop-types.d.ts +25 -3
  648. package/lib/organism/review-congrats/prop-types.d.ts.map +1 -1
  649. package/lib/organism/review-congrats/prop-types.js +2 -1
  650. package/lib/organism/review-congrats/prop-types.js.map +1 -1
  651. package/lib/organism/review-congrats/test/fixtures/default.d.ts +7 -0
  652. package/lib/organism/review-congrats/test/fixtures/default.d.ts.map +1 -0
  653. package/lib/organism/review-header/index.d.ts +7 -0
  654. package/lib/organism/review-header/index.d.ts.map +1 -0
  655. package/lib/organism/review-header/index.native.d.ts +2 -2
  656. package/lib/organism/review-header/index.native.d.ts.map +1 -1
  657. package/lib/organism/review-header/index.native.js.map +1 -1
  658. package/lib/organism/review-header/test/fixtures/all-questions-ok.d.ts +15 -0
  659. package/lib/organism/review-header/test/fixtures/all-questions-ok.d.ts.map +1 -0
  660. package/lib/organism/review-header/test/fixtures/current-question-no-answered.d.ts +7 -0
  661. package/lib/organism/review-header/test/fixtures/current-question-no-answered.d.ts.map +1 -0
  662. package/lib/organism/review-header/test/fixtures/current-question-wrong.d.ts +7 -0
  663. package/lib/organism/review-header/test/fixtures/current-question-wrong.d.ts.map +1 -0
  664. package/lib/organism/review-header/test/fixtures/first-question-current-right.d.ts +7 -0
  665. package/lib/organism/review-header/test/fixtures/first-question-current-right.d.ts.map +1 -0
  666. package/lib/organism/review-header/test/fixtures/no-answered-question.d.ts +7 -0
  667. package/lib/organism/review-header/test/fixtures/no-answered-question.d.ts.map +1 -0
  668. package/lib/organism/review-header/test/fixtures/question-to-repeat.d.ts +7 -0
  669. package/lib/organism/review-header/test/fixtures/question-to-repeat.d.ts.map +1 -0
  670. package/lib/organism/review-header/test/fixtures/steps-animation.d.ts +7 -0
  671. package/lib/organism/review-header/test/fixtures/steps-animation.d.ts.map +1 -0
  672. package/lib/organism/review-header/test/fixtures.native.d.ts +2 -0
  673. package/lib/organism/review-header/test/fixtures.native.d.ts.map +1 -0
  674. package/lib/organism/review-header/types.d.ts +4 -4
  675. package/lib/organism/review-header/types.d.ts.map +1 -1
  676. package/lib/organism/review-header/types.js.map +1 -1
  677. package/lib/organism/review-skills/index.d.ts +7 -0
  678. package/lib/organism/review-skills/index.d.ts.map +1 -0
  679. package/lib/organism/review-skills/test/fixtures/many-skills.d.ts +22 -0
  680. package/lib/organism/review-skills/test/fixtures/many-skills.d.ts.map +1 -0
  681. package/lib/organism/review-skills/test/fixtures/no-skills.d.ts +12 -0
  682. package/lib/organism/review-skills/test/fixtures/no-skills.d.ts.map +1 -0
  683. package/lib/organism/review-slide/index.d.ts +7 -0
  684. package/lib/organism/review-slide/index.d.ts.map +1 -0
  685. package/lib/organism/review-slide/index.native.d.ts +2 -2
  686. package/lib/organism/review-slide/index.native.d.ts.map +1 -1
  687. package/lib/organism/review-slide/index.native.js +3 -3
  688. package/lib/organism/review-slide/index.native.js.map +1 -1
  689. package/lib/organism/review-slide/prop-types.d.ts +21 -36
  690. package/lib/organism/review-slide/prop-types.d.ts.map +1 -1
  691. package/lib/organism/review-slide/prop-types.js.map +1 -1
  692. package/lib/organism/review-slide/test/fixtures/choices-selected.d.ts +22 -0
  693. package/lib/organism/review-slide/test/fixtures/choices-selected.d.ts.map +1 -0
  694. package/lib/organism/review-slide/test/fixtures/correction-ok-animated.d.ts +36 -0
  695. package/lib/organism/review-slide/test/fixtures/correction-ok-animated.d.ts.map +1 -0
  696. package/lib/organism/review-slide/test/fixtures/correction-ok.d.ts +36 -0
  697. package/lib/organism/review-slide/test/fixtures/correction-ok.d.ts.map +1 -0
  698. package/lib/organism/review-slide/test/fixtures/correction-wrong-animated.d.ts +38 -0
  699. package/lib/organism/review-slide/test/fixtures/correction-wrong-animated.d.ts.map +1 -0
  700. package/lib/organism/review-slide/test/fixtures/correction-wrong.d.ts +38 -0
  701. package/lib/organism/review-slide/test/fixtures/correction-wrong.d.ts.map +1 -0
  702. package/lib/organism/review-slide/test/fixtures/initial-state.d.ts +22 -0
  703. package/lib/organism/review-slide/test/fixtures/initial-state.d.ts.map +1 -0
  704. package/lib/organism/review-slide/test/fixtures/loading.d.ts +12 -0
  705. package/lib/organism/review-slide/test/fixtures/loading.d.ts.map +1 -0
  706. package/lib/organism/review-slide/test/fixtures.native.d.ts +2 -0
  707. package/lib/organism/review-slide/test/fixtures.native.d.ts.map +1 -0
  708. package/lib/organism/review-stacked-slides/index.d.ts +13 -0
  709. package/lib/organism/review-stacked-slides/index.d.ts.map +1 -0
  710. package/lib/organism/review-stacked-slides/index.js +3 -6
  711. package/lib/organism/review-stacked-slides/index.js.map +1 -1
  712. package/lib/organism/review-stacked-slides/index.native.d.ts +2 -2
  713. package/lib/organism/review-stacked-slides/index.native.d.ts.map +1 -1
  714. package/lib/organism/review-stacked-slides/index.native.js +3 -6
  715. package/lib/organism/review-stacked-slides/index.native.js.map +1 -1
  716. package/lib/organism/review-stacked-slides/prop-types.d.ts +26 -25
  717. package/lib/organism/review-stacked-slides/prop-types.d.ts.map +1 -1
  718. package/lib/organism/review-stacked-slides/prop-types.js.map +1 -1
  719. package/lib/organism/review-stacked-slides/test/fixtures/all-ok.d.ts +9 -0
  720. package/lib/organism/review-stacked-slides/test/fixtures/all-ok.d.ts.map +1 -0
  721. package/lib/organism/review-stacked-slides/test/fixtures/end-review.d.ts +7 -0
  722. package/lib/organism/review-stacked-slides/test/fixtures/end-review.d.ts.map +1 -0
  723. package/lib/organism/review-stacked-slides/test/fixtures/first-correct.d.ts +9 -0
  724. package/lib/organism/review-stacked-slides/test/fixtures/first-correct.d.ts.map +1 -0
  725. package/lib/organism/review-stacked-slides/test/fixtures/initial-state.d.ts +7 -0
  726. package/lib/organism/review-stacked-slides/test/fixtures/initial-state.d.ts.map +1 -0
  727. package/lib/organism/review-stacked-slides/test/fixtures/loading.d.ts +7 -0
  728. package/lib/organism/review-stacked-slides/test/fixtures/loading.d.ts.map +1 -0
  729. package/lib/organism/review-stacked-slides/test/fixtures/restack.d.ts +9 -0
  730. package/lib/organism/review-stacked-slides/test/fixtures/restack.d.ts.map +1 -0
  731. package/lib/organism/review-stacked-slides/test/fixtures/second-wrong.d.ts +9 -0
  732. package/lib/organism/review-stacked-slides/test/fixtures/second-wrong.d.ts.map +1 -0
  733. package/lib/organism/review-stacked-slides/test/fixtures/unstack.d.ts +9 -0
  734. package/lib/organism/review-stacked-slides/test/fixtures/unstack.d.ts.map +1 -0
  735. package/lib/organism/review-stacked-slides/test/fixtures/wrong.d.ts +9 -0
  736. package/lib/organism/review-stacked-slides/test/fixtures/wrong.d.ts.map +1 -0
  737. package/lib/organism/review-stacked-slides/test/fixtures.native.d.ts +2 -0
  738. package/lib/organism/review-stacked-slides/test/fixtures.native.d.ts.map +1 -0
  739. package/lib/template/app-player/popin-end/summary.js +3 -4
  740. package/lib/template/app-player/popin-end/summary.js.map +1 -1
  741. package/lib/template/app-review/demo-ts/test/fixtures.native.d.ts +2 -0
  742. package/lib/template/app-review/demo-ts/test/fixtures.native.d.ts.map +1 -0
  743. package/lib/template/app-review/index.d.ts +603 -0
  744. package/lib/template/app-review/index.d.ts.map +1 -0
  745. package/lib/template/app-review/index.js +15 -24
  746. package/lib/template/app-review/index.js.map +1 -1
  747. package/lib/template/app-review/index.native.d.ts +5 -0
  748. package/lib/template/app-review/index.native.d.ts.map +1 -0
  749. package/lib/template/app-review/index.native.js +20 -26
  750. package/lib/template/app-review/index.native.js.map +1 -1
  751. package/lib/template/app-review/onboarding/index.d.ts +3 -0
  752. package/lib/template/app-review/onboarding/index.d.ts.map +1 -0
  753. package/lib/template/app-review/onboarding/index.native.d.ts +9 -0
  754. package/lib/template/app-review/onboarding/index.native.d.ts.map +1 -0
  755. package/lib/template/app-review/onboarding/test/fixtures/default.d.ts +3 -0
  756. package/lib/template/app-review/onboarding/test/fixtures/default.d.ts.map +1 -0
  757. package/lib/template/app-review/onboarding/test/fixtures.native.d.ts +2 -0
  758. package/lib/template/app-review/onboarding/test/fixtures.native.d.ts.map +1 -0
  759. package/lib/template/app-review/player/index.d.ts +13 -0
  760. package/lib/template/app-review/player/index.d.ts.map +1 -0
  761. package/lib/template/app-review/player/index.native.d.ts +2 -2
  762. package/lib/template/app-review/player/index.native.d.ts.map +1 -1
  763. package/lib/template/app-review/player/index.native.js.map +1 -1
  764. package/lib/template/app-review/player/prop-types.d.ts +31 -31
  765. package/lib/template/app-review/player/prop-types.d.ts.map +1 -1
  766. package/lib/template/app-review/player/prop-types.js.map +1 -1
  767. package/lib/template/app-review/player/test/fixtures/all-ok.d.ts +7 -0
  768. package/lib/template/app-review/player/test/fixtures/all-ok.d.ts.map +1 -0
  769. package/lib/template/app-review/player/test/fixtures/end-review.d.ts +7 -0
  770. package/lib/template/app-review/player/test/fixtures/end-review.d.ts.map +1 -0
  771. package/lib/template/app-review/player/test/fixtures/first-right.d.ts +7 -0
  772. package/lib/template/app-review/player/test/fixtures/first-right.d.ts.map +1 -0
  773. package/lib/template/app-review/player/test/fixtures/initial-state.d.ts +7 -0
  774. package/lib/template/app-review/player/test/fixtures/initial-state.d.ts.map +1 -0
  775. package/lib/template/app-review/player/test/fixtures/loading.d.ts +7 -0
  776. package/lib/template/app-review/player/test/fixtures/loading.d.ts.map +1 -0
  777. package/lib/template/app-review/player/test/fixtures/on-quit.d.ts +7 -0
  778. package/lib/template/app-review/player/test/fixtures/on-quit.d.ts.map +1 -0
  779. package/lib/template/app-review/player/test/fixtures/one-fail.d.ts +7 -0
  780. package/lib/template/app-review/player/test/fixtures/one-fail.d.ts.map +1 -0
  781. package/lib/template/app-review/player/test/fixtures/restack.d.ts +7 -0
  782. package/lib/template/app-review/player/test/fixtures/restack.d.ts.map +1 -0
  783. package/lib/template/app-review/player/test/fixtures/second-failed-question.d.ts +7 -0
  784. package/lib/template/app-review/player/test/fixtures/second-failed-question.d.ts.map +1 -0
  785. package/lib/template/app-review/player/test/fixtures/unstack.d.ts +7 -0
  786. package/lib/template/app-review/player/test/fixtures/unstack.d.ts.map +1 -0
  787. package/lib/template/app-review/player/test/fixtures.native.d.ts +2 -0
  788. package/lib/template/app-review/player/test/fixtures.native.d.ts.map +1 -0
  789. package/lib/template/app-review/prop-types.d.ts +610 -0
  790. package/lib/template/app-review/prop-types.d.ts.map +1 -0
  791. package/lib/template/app-review/prop-types.js +4 -12
  792. package/lib/template/app-review/prop-types.js.map +1 -1
  793. package/lib/template/app-review/skills/index.d.ts +3 -0
  794. package/lib/template/app-review/skills/index.d.ts.map +1 -0
  795. package/lib/template/app-review/skills/test/fixtures/many-skills.d.ts +3 -0
  796. package/lib/template/app-review/skills/test/fixtures/many-skills.d.ts.map +1 -0
  797. package/lib/template/app-review/skills/test/fixtures/no-skills.d.ts +3 -0
  798. package/lib/template/app-review/skills/test/fixtures/no-skills.d.ts.map +1 -0
  799. package/lib/template/app-review/skills/test/fixtures.native.d.ts +2 -0
  800. package/lib/template/app-review/skills/test/fixtures.native.d.ts.map +1 -0
  801. package/lib/template/app-review/template-context.js +1 -1
  802. package/lib/template/app-review/template-context.js.map +1 -1
  803. package/lib/template/app-review/test/fixtures/onboarding.d.ts +7 -0
  804. package/lib/template/app-review/test/fixtures/onboarding.d.ts.map +1 -0
  805. package/lib/template/app-review/test/fixtures/player.d.ts +7 -0
  806. package/lib/template/app-review/test/fixtures/player.d.ts.map +1 -0
  807. package/lib/template/app-review/test/fixtures/skills.d.ts +7 -0
  808. package/lib/template/app-review/test/fixtures/skills.d.ts.map +1 -0
  809. package/lib/template/app-review/test/fixtures.native.d.ts +2 -0
  810. package/lib/template/app-review/test/fixtures.native.d.ts.map +1 -0
  811. package/lib/template/common/dashboard/index.js +1 -1
  812. package/lib/template/common/dashboard/index.js.map +1 -1
  813. package/lib/test/helpers/render-component.d.ts +20 -0
  814. package/lib/test/helpers/render-component.d.ts.map +1 -0
  815. package/lib/util/get-shadow-box-color-from-primary.d.ts +2 -0
  816. package/lib/util/get-shadow-box-color-from-primary.d.ts.map +1 -0
  817. package/package.json +2 -2
@@ -1 +1 @@
1
- {"version":3,"file":"index.native.js","names":["createStyle","current","icon","backgroundColor","COLORS","positive","negative","gray","StyleSheet","create","step","width","height","opacity","marginHorizontal","alignItems","justifyContent","borderRadius","stepText","fontWeight","fontSize","Step","value","style","setStyle","useState","useEffect","_style","child"],"sources":["../../../src/atom/review-header-step-item/index.native.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react';\nimport {StyleSheet, Text, View} from 'react-native';\nimport {\n NovaCompositionCoorpacademyCheck as RightIcon,\n NovaSolidStatusClose as WrongIcon\n} from '@coorpacademy/nova-icons';\nimport {COLORS} from '../../variables/colors';\nimport {Props} from './types';\n\nconst createStyle = (current: boolean, icon: Props['icon']) => {\n let backgroundColor;\n\n switch (icon) {\n case 'right':\n backgroundColor = COLORS.positive;\n break;\n case 'wrong':\n backgroundColor = COLORS.negative;\n break;\n case 'no-answer':\n default:\n backgroundColor = COLORS.gray;\n }\n\n return StyleSheet.create({\n step: {\n width: current ? 40 : 32,\n height: current ? 40 : 32,\n opacity: current ? 1 : 0.5,\n marginHorizontal: 8,\n backgroundColor,\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: 50\n },\n stepText: {\n fontWeight: '600',\n fontSize: current ? 16 : 12\n },\n icon: {\n width: current ? 14 : 12,\n height: current ? 14 : 12\n }\n });\n};\n\nconst Step = ({value, icon, current}: Props) => {\n const [style, setStyle] = useState<any | null>(null);\n\n useEffect(() => {\n const _style = createStyle(current, icon);\n setStyle(_style);\n }, [current, icon]);\n\n if (!style) {\n return null;\n }\n\n let child;\n\n switch (icon) {\n case 'right':\n child = <RightIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'wrong':\n child = <WrongIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'no-answer':\n default:\n child = <Text style={style.stepText}>{value}</Text>;\n }\n\n return <View style={style.step}>{child}</View>;\n};\n\nexport default Step;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AAIA;;;;;;AAGA,MAAMA,WAAW,GAAG,CAACC,OAAD,EAAmBC,IAAnB,KAA2C;EAC7D,IAAIC,eAAJ;;EAEA,QAAQD,IAAR;IACE,KAAK,OAAL;MACEC,eAAe,GAAGC,cAAA,CAAOC,QAAzB;MACA;;IACF,KAAK,OAAL;MACEF,eAAe,GAAGC,cAAA,CAAOE,QAAzB;MACA;;IACF,KAAK,WAAL;IACA;MACEH,eA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MACE0B,KAAK,gBAAG,6BAAC,+BAAD;QAAW,KAAK,EAAEL,KAAK,CAACrB,IAAxB;QAA8B,KAAK,EAAC;MAApC,EAAR;MACA;;IACF,KAAK,WAAL;IACA;MACE0B,KAAK,gBAAG,6BAAC,iBAAD;QAAM,KAAK,EAAEL,KAAK,CAACL;MAAnB,GAA8BI,KAA9B,CAAR;EATJ;;EAYA,oBAAO,6BAAC,iBAAD;IAAM,KAAK,EAAEC,KAAK,CAACb;EAAnB,GAA0BkB,KAA1B,CAAP;AACD,CA3BD;;eA6BeP,I"}
1
+ {"version":3,"file":"index.native.js","names":["createStyle","current","icon","backgroundColor","COLORS","positive","negative","gray","StyleSheet","create","step","width","height","opacity","marginHorizontal","alignItems","justifyContent","borderRadius","stepText","fontWeight","fontSize","Step","value","style","setStyle","useState","useEffect","_style","child"],"sources":["../../../src/atom/review-header-step-item/index.native.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react';\nimport {StyleSheet, Text, View} from 'react-native';\nimport {\n NovaCompositionCoorpacademyCheck as RightIcon,\n NovaSolidStatusClose as WrongIcon\n} from '@coorpacademy/nova-icons';\nimport {COLORS} from '../../variables/colors';\nimport {HeaderStepItemProps} from './types';\n\nconst createStyle = (current: boolean, icon: HeaderStepItemProps['icon']) => {\n let backgroundColor;\n\n switch (icon) {\n case 'right':\n backgroundColor = COLORS.positive;\n break;\n case 'wrong':\n backgroundColor = COLORS.negative;\n break;\n case 'no-answer':\n default:\n backgroundColor = COLORS.gray;\n }\n\n return StyleSheet.create({\n step: {\n width: current ? 40 : 32,\n height: current ? 40 : 32,\n opacity: current ? 1 : 0.5,\n marginHorizontal: 8,\n backgroundColor,\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: 50\n },\n stepText: {\n fontWeight: '600',\n fontSize: current ? 16 : 12\n },\n icon: {\n width: current ? 14 : 12,\n height: current ? 14 : 12\n }\n });\n};\n\nconst Step = ({value, icon, current}: HeaderStepItemProps) => {\n const [style, setStyle] = useState<any | null>(null);\n\n useEffect(() => {\n const _style = createStyle(current, icon);\n setStyle(_style);\n }, [current, icon]);\n\n if (!style) {\n return null;\n }\n\n let child;\n\n switch (icon) {\n case 'right':\n child = <RightIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'wrong':\n child = <WrongIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'no-answer':\n default:\n child = <Text style={style.stepText}>{value}</Text>;\n }\n\n return <View style={style.step}>{child}</View>;\n};\n\nexport default Step;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AAIA;;;;;;AAGA,MAAMA,WAAW,GAAG,CAACC,OAAD,EAAmBC,IAAnB,KAAyD;EAC3E,IAAIC,eAAJ;;EAEA,QAAQD,IAAR;IACE,KAAK,OAAL;MACEC,eAAe,GAAGC,cAAA,CAAOC,QAAzB;MACA;;IACF,KAAK,OAAL;MACEF,eAAe,GAAGC,cAAA,CAAOE,QAAzB;MACA;;IACF,KAAK,WAAL;IACA;MACEH,eAAe,GAAGC,cAAA,CAAOG,IAAzB;EATJ;;EAYA,OAAOC,uBAAA,CAAWC,MAAX,CAAkB;IACvBC,IAAI,EAAE;MACJC,KAAK,EAAEV,OAAO,GAAG,EAAH,GAAQ,EADlB;MAEJW,MAAM,EAAEX,OAAO,GAAG,EAAH,GAAQ,EAFnB;MAGJY,OAAO,EAAEZ,OAAO,GAAG,CAAH,GAAO,GAHnB;MAIJa,gBAAgB,EAAE,CAJd;MAKJX,eALI;MAMJY,UAAU,EAAE,QANR;MAOJC,cAAc,EAAE,QAPZ;MAQJC,YAAY,EAAE;IARV,CADiB;IAWvBC,QAAQ,EAAE;MACRC,UAAU,EAAE,KADJ;MAERC,QAAQ,EAAEnB,OAAO,GAAG,EAAH,GAAQ;IAFjB,CAXa;IAevBC,IAAI,EAAE;MACJS,KAAK,EAAEV,OAAO,GAAG,EAAH,GAAQ,EADlB;MAEJW,MAAM,EAAEX,OAAO,GAAG,EAAH,GAAQ;IAFnB;EAfiB,CAAlB,CAAP;AAoBD,CAnCD;;AAqCA,MAAMoB,IAAI,GAAG,CAAC;EAACC,KAAD;EAAQpB,IAAR;EAAcD;AAAd,CAAD,KAAiD;EAC5D,MAAM,CAACsB,KAAD,EAAQC,QAAR,IAAoB,IAAAC,eAAA,EAAqB,IAArB,CAA1B;EAEA,IAAAC,gBAAA,EAAU,MAAM;IACd,MAAMC,MAAM,GAAG3B,WAAW,CAACC,OAAD,EAAUC,IAAV,CAA1B;;IACAsB,QAAQ,CAACG,MAAD,CAAR;EACD,CAHD,EAGG,CAAC1B,OAAD,EAAUC,IAAV,CAHH;;EAKA,IAAI,CAACqB,KAAL,EAAY;IACV,OAAO,IAAP;EACD;;EAED,IAAIK,KAAJ;;EAEA,QAAQ1B,IAAR;IACE,KAAK,OAAL;MACE0B,KAAK,gBAAG,6BAAC,2CAAD;QAAW,KAAK,EAAEL,KAAK,CAACrB,IAAxB;QAA8B,KAAK,EAAC;MAApC,EAAR;MACA;;IACF,KAAK,OAAL;MACE0B,KAAK,gBAAG,6BAAC,+BAAD;QAAW,KAAK,EAAEL,KAAK,CAACrB,IAAxB;QAA8B,KAAK,EAAC;MAApC,EAAR;MACA;;IACF,KAAK,WAAL;IACA;MACE0B,KAAK,gBAAG,6BAAC,iBAAD;QAAM,KAAK,EAAEL,KAAK,CAACL;MAAnB,GAA8BI,KAA9B,CAAR;EATJ;;EAYA,oBAAO,6BAAC,iBAAD;IAAM,KAAK,EAAEC,KAAK,CAACb;EAAnB,GAA0BkB,KAA1B,CAAP;AACD,CA3BD;;eA6BeP,I"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=fixtures.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/atom/review-header-step-item/test/fixtures.native.ts"],"names":[],"mappings":""}
@@ -5,12 +5,12 @@ declare const propTypes: {
5
5
  value: PropTypes.Requireable<string>;
6
6
  };
7
7
  export default propTypes;
8
- export declare type Props = {
8
+ export declare type HeaderStepItemProps = {
9
9
  current: boolean;
10
10
  icon: 'no-answer' | 'right' | 'wrong';
11
11
  value: string;
12
12
  };
13
13
  export declare type Fixture = {
14
- props: Props;
14
+ props: HeaderStepItemProps;
15
15
  };
16
16
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/atom/review-header-step-item/types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAEnC,QAAA,MAAM,SAAS;;;;CAId,CAAC;AAEF,eAAe,SAAS,CAAC;AAEzB,oBAAY,KAAK,GAAG;IAClB,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,EAAE,WAAW,GAAG,OAAO,GAAG,OAAO,CAAC;IACtC,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,oBAAY,OAAO,GAAG;IACpB,KAAK,EAAE,KAAK,CAAC;CACd,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/atom/review-header-step-item/types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAEnC,QAAA,MAAM,SAAS;;;;CAId,CAAC;AAEF,eAAe,SAAS,CAAC;AAEzB,oBAAY,mBAAmB,GAAG;IAChC,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,EAAE,WAAW,GAAG,OAAO,GAAG,OAAO,CAAC;IACtC,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,oBAAY,OAAO,GAAG;IACpB,KAAK,EAAE,mBAAmB,CAAC;CAC5B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","names":["propTypes","current","PropTypes","bool","icon","oneOf","value","string"],"sources":["../../../src/atom/review-header-step-item/types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\n\nconst propTypes = {\n current: PropTypes.bool,\n icon: PropTypes.oneOf(['no-answer', 'right', 'wrong']),\n value: PropTypes.string\n};\n\nexport default propTypes;\n\nexport type Props = {\n current: boolean;\n icon: 'no-answer' | 'right' | 'wrong';\n value: string;\n};\n\nexport type Fixture = {\n props: Props;\n};\n"],"mappings":";;;;;AAAA;;;;AAEA,MAAMA,SAAS,GAAG;EAChBC,OAAO,EAAEC,kBAAA,CAAUC,IADH;EAEhBC,IAAI,EAAEF,kBAAA,CAAUG,KAAV,CAAgB,CAAC,WAAD,EAAc,OAAd,EAAuB,OAAvB,CAAhB,CAFU;EAGhBC,KAAK,EAAEJ,kBAAA,CAAUK;AAHD,CAAlB;eAMeP,S"}
1
+ {"version":3,"file":"types.js","names":["propTypes","current","PropTypes","bool","icon","oneOf","value","string"],"sources":["../../../src/atom/review-header-step-item/types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\n\nconst propTypes = {\n current: PropTypes.bool,\n icon: PropTypes.oneOf(['no-answer', 'right', 'wrong']),\n value: PropTypes.string\n};\n\nexport default propTypes;\n\nexport type HeaderStepItemProps = {\n current: boolean;\n icon: 'no-answer' | 'right' | 'wrong';\n value: string;\n};\n\nexport type Fixture = {\n props: HeaderStepItemProps;\n};\n"],"mappings":";;;;;AAAA;;;;AAEA,MAAMA,SAAS,GAAG;EAChBC,OAAO,EAAEC,kBAAA,CAAUC,IADH;EAEhBC,IAAI,EAAEF,kBAAA,CAAUG,KAAV,CAAgB,CAAC,WAAD,EAAc,OAAd,EAAuB,OAAvB,CAAhB,CAFU;EAGhBC,KAAK,EAAEJ,kBAAA,CAAUK;AAHD,CAAlB;eAMeP,S"}
@@ -0,0 +1,7 @@
1
+ export default ReviewPresentation;
2
+ declare function ReviewPresentation(props: any): JSX.Element;
3
+ declare namespace ReviewPresentation {
4
+ export { propTypes };
5
+ }
6
+ import propTypes from "./prop-types";
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/review-presentation/index.js"],"names":[],"mappings":";AA4CA,6DA+BC"}
@@ -0,0 +1,26 @@
1
+ export default propTypes;
2
+ declare const propTypes: {
3
+ 'aria-label': PropTypes.Requireable<string>;
4
+ reviewTitle: PropTypes.Requireable<string>;
5
+ reviewText: PropTypes.Requireable<string>;
6
+ labelsList: PropTypes.Requireable<PropTypes.InferProps<{
7
+ skills: PropTypes.Requireable<PropTypes.InferProps<{
8
+ text: PropTypes.Requireable<string>;
9
+ tooltipText: PropTypes.Requireable<string>;
10
+ }>>;
11
+ questions: PropTypes.Requireable<PropTypes.InferProps<{
12
+ text: PropTypes.Requireable<string>;
13
+ tooltipText: PropTypes.Requireable<string>;
14
+ }>>;
15
+ lifes: PropTypes.Requireable<PropTypes.InferProps<{
16
+ text: PropTypes.Requireable<string>;
17
+ tooltipText: PropTypes.Requireable<string>;
18
+ }>>;
19
+ allright: PropTypes.Requireable<PropTypes.InferProps<{
20
+ text: PropTypes.Requireable<string>;
21
+ tooltipText: PropTypes.Requireable<string>;
22
+ }>>;
23
+ }>>;
24
+ };
25
+ import PropTypes from "prop-types";
26
+ //# sourceMappingURL=prop-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"prop-types.d.ts","sourceRoot":"","sources":["../../../src/atom/review-presentation/prop-types.js"],"names":[],"mappings":";AAOA;;;;;;;;;;;;;;;;;;;;;;EAUE"}
@@ -0,0 +1,28 @@
1
+ export const defaultProps: {
2
+ 'aria-label': string;
3
+ reviewTitle: string;
4
+ reviewText: string;
5
+ labelsList: {
6
+ skills: {
7
+ text: string;
8
+ tooltipText: string;
9
+ };
10
+ questions: {
11
+ text: string;
12
+ tooltipText: string;
13
+ };
14
+ lifes: {
15
+ text: string;
16
+ tooltipText: string;
17
+ };
18
+ allright: {
19
+ text: string;
20
+ tooltipText: string;
21
+ };
22
+ };
23
+ };
24
+ declare namespace _default {
25
+ export { defaultProps as props };
26
+ }
27
+ export default _default;
28
+ //# sourceMappingURL=default.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"default.d.ts","sourceRoot":"","sources":["../../../../../src/atom/review-presentation/test/fixtures/default.js"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;EAcE"}
@@ -0,0 +1,56 @@
1
+ export namespace SelectOptionPropTypes {
2
+ const name: PropTypes.Validator<string>;
3
+ const value: PropTypes.Requireable<NonNullable<string | number | null | undefined>>;
4
+ const selected: PropTypes.Requireable<boolean>;
5
+ const validOption: PropTypes.Requireable<boolean>;
6
+ }
7
+ export default Select;
8
+ import PropTypes from "prop-types";
9
+ declare function Select(props: any, legacyContext: any): JSX.Element;
10
+ declare namespace Select {
11
+ namespace contextTypes {
12
+ const skin: PropTypes.Requireable<PropTypes.InferProps<{
13
+ common: PropTypes.Requireable<{
14
+ [x: string]: any;
15
+ }>;
16
+ images: PropTypes.Requireable<PropTypes.InferProps<{
17
+ 'logo-mobile': PropTypes.Requireable<any>;
18
+ logo: PropTypes.Requireable<any>;
19
+ 'logo-email': PropTypes.Requireable<any>;
20
+ login: PropTypes.Requireable<any>;
21
+ }>>;
22
+ icons: PropTypes.Requireable<{
23
+ [x: string]: any;
24
+ }>;
25
+ mod: PropTypes.Requireable<{
26
+ [x: string]: any;
27
+ }>;
28
+ courses: PropTypes.Requireable<any[]>;
29
+ texts: PropTypes.Requireable<{
30
+ [x: string]: any;
31
+ }>;
32
+ }>>;
33
+ }
34
+ namespace propTypes {
35
+ export const title: PropTypes.Requireable<string>;
36
+ const name_1: PropTypes.Requireable<string>;
37
+ export { name_1 as name };
38
+ export const className: PropTypes.Requireable<string>;
39
+ export const borderClassName: PropTypes.Requireable<string>;
40
+ export const disabled: PropTypes.Requireable<boolean>;
41
+ export const multiple: PropTypes.Requireable<boolean>;
42
+ export const description: PropTypes.Requireable<string>;
43
+ export const required: PropTypes.Requireable<boolean>;
44
+ export const onChange: PropTypes.Requireable<(...args: any[]) => any>;
45
+ export const theme: PropTypes.Requireable<string>;
46
+ export const options: PropTypes.Requireable<(PropTypes.InferProps<{
47
+ name: PropTypes.Validator<string>;
48
+ value: PropTypes.Requireable<NonNullable<string | number | null | undefined>>;
49
+ selected: PropTypes.Requireable<boolean>;
50
+ validOption: PropTypes.Requireable<boolean>;
51
+ }> | null | undefined)[]>;
52
+ export const modified: PropTypes.Requireable<boolean>;
53
+ export const error: PropTypes.Requireable<boolean>;
54
+ }
55
+ }
56
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/select/index.js"],"names":[],"mappings":";;;;;;;;AA6BA,qEA0JC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=fixtures.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/atom/select-modal/test/fixtures.native.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=fixtures.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/atom/space/test/fixtures.native.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=fixtures.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/atom/text/test/fixtures.native.ts"],"names":[],"mappings":""}
@@ -0,0 +1,54 @@
1
+ export const LINEAR: any;
2
+ export const EASE_IN_QUAD: any;
3
+ export const EASE_IN_CUBIC: any;
4
+ export const EASE_IN_QUART: any;
5
+ export const EASE_IN_QUINT: any;
6
+ export const EASE_IN_SINE: any;
7
+ export const EASE_IN_EXPO: any;
8
+ export const EASE_IN_CIRC: any;
9
+ export const EASE_IN_BACK: any;
10
+ export const EASE_OUT_QUAD: any;
11
+ export const EASE_OUT_CUBIC: any;
12
+ export const EASE_OUT_QUART: any;
13
+ export const EASE_OUT_QUINT: any;
14
+ export const EASE_OUT_SINE: any;
15
+ export const EASE_OUT_EXPO: any;
16
+ export const EASE_OUT_CIRC: any;
17
+ export const EASE_OUT_BACK: any;
18
+ export const EASE_IN_OUT_QUAD: any;
19
+ export const EASE_IN_OUT_CUBIC: any;
20
+ export const EASE_IN_OUT_QUART: any;
21
+ export const EASE_IN_OUT_QUINT: any;
22
+ export const EASE_IN_OUT_SINE: any;
23
+ export const EASE_IN_OUT_EXPO: any;
24
+ export const EASE_IN_OUT_CIRC: any;
25
+ export const EASE_IN_OUT_BACK: any;
26
+ export const SWIFT_OUT: any;
27
+ export const BOUNCE: any;
28
+ export default Animation;
29
+ declare class Animation extends React.Component<any, any, any> {
30
+ static propTypes: {
31
+ name: PropTypes.Validator<string>;
32
+ bezier: PropTypes.Validator<(...args: any[]) => any>;
33
+ duration: PropTypes.Validator<number>;
34
+ onAnimationEnd: PropTypes.Requireable<(...args: any[]) => any>;
35
+ animated: PropTypes.Requireable<boolean>;
36
+ children: PropTypes.Requireable<(...args: any[]) => any>;
37
+ };
38
+ constructor(props: any);
39
+ state: {
40
+ progress: number;
41
+ requestID: null;
42
+ };
43
+ componentDidMount(): void;
44
+ componentDidUpdate(prevProps: any): void;
45
+ componentWillUnmount(): void;
46
+ startAnimation(): void;
47
+ stopAnimation(): void;
48
+ tick(timestamp: any): void;
49
+ getProgress(deltaDuration: any): number;
50
+ render(): any;
51
+ }
52
+ import React from "react";
53
+ import PropTypes from "prop-types";
54
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/hoc/animation/index.js"],"names":[],"mappings":"AAMA,yBAAkD;AAClD,+BAAoE;AACpE,gCAAqE;AACrE,gCAAqE;AACrE,gCAAqE;AACrE,+BAAiE;AACjE,+BAAoE;AACpE,+BAAmE;AACnE,+BAAoE;AACpE,gCAAqE;AACrE,iCAAmE;AACnE,iCAAmE;AACnE,iCAAgE;AAChE,gCAAkE;AAClE,gCAA+D;AAC/D,gCAAkE;AAClE,gCAAqE;AACrE,mCAAwE;AACxE,oCAAsE;AACtE,oCAAmE;AACnE,oCAAmE;AACnE,mCAAwE;AACxE,mCAA4D;AAC5D,mCAAwE;AACxE,mCAAyE;AACzE,4BAA0D;AAC1D,yBAA6D;;AAE7D;IACE;;;;;;;MAOE;IAEF,wBAOC;IAJC;;;MAGC;IAGH,0BAGC;IAED,yCAQC;IAED,6BAEC;IAED,uBAUC;IAED,sBAWC;IAED,2BAuBC;IAED,wCAGC;IAED,cAMC;CACF"}
@@ -0,0 +1,38 @@
1
+ export default AnimationScheduler;
2
+ declare class AnimationScheduler extends React.Component<any, any, any> {
3
+ static propTypes: {
4
+ onAnimationEnd: PropTypes.Requireable<(...args: any[]) => any>;
5
+ animated: PropTypes.Requireable<boolean>;
6
+ children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
7
+ };
8
+ static getDerivedStateFromProps(props: any, state: any): {
9
+ animations: any;
10
+ };
11
+ constructor(props: any);
12
+ state: {
13
+ animations: any;
14
+ };
15
+ isAnimated(after: any): boolean;
16
+ handlerAnimationEnd(name: any): void;
17
+ processAnimation(child: any): React.DetailedReactHTMLElement<{
18
+ animated: any;
19
+ onAnimationEnd: (name: React.AnimationEvent<HTMLElement>) => any;
20
+ }, HTMLElement>;
21
+ render(): any;
22
+ }
23
+ export function AnimationAdapter({ animated, onAnimationEnd, name, children }: {
24
+ animated: any;
25
+ onAnimationEnd?: import("lodash/fp").LodashNoop | undefined;
26
+ name: any;
27
+ children: any;
28
+ }): any;
29
+ export namespace AnimationAdapter {
30
+ namespace propTypes {
31
+ const name: PropTypes.Validator<string>;
32
+ const onAnimationEnd: PropTypes.Requireable<(...args: any[]) => any>;
33
+ const animated: PropTypes.Requireable<boolean>;
34
+ }
35
+ }
36
+ import React from "react";
37
+ import PropTypes from "prop-types";
38
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/hoc/animation-scheduler/index.js"],"names":[],"mappings":";AAoFA;IACE;;;;MAIE;IAEF;;MAMC;IAED,wBAOC;IAHC;;MAEC;IAGH,gCAWC;IAED,qCAUC;IAED;;;oBAWC;IAED,cAOC;CACF;AAlID;;;;;QAOC"}
@@ -53,7 +53,7 @@ const AnimationAdapter = ({
53
53
  name,
54
54
  children
55
55
  }) => {
56
- return _react.default.Children.map(children, child => _react.default.cloneElement(child, {
56
+ return _react.default.Children.map(children, child => /*#__PURE__*/_react.default.cloneElement(child, {
57
57
  animated,
58
58
  onAnimationEnd: () => onAnimationEnd(name)
59
59
  }));
@@ -75,7 +75,7 @@ const walker = (type, handler) => children => {
75
75
  if ((0, _isNil2.default)(child) || (0, _isString2.default)(child)) return child;
76
76
  const newChild = child.type === type ? handler(child) : child;
77
77
  if (_react.default.Children.count(newChild.props.children) === 0) return newChild;
78
- return _react.default.cloneElement(newChild, {}, walker(type, handler)(newChild.props.children));
78
+ return /*#__PURE__*/_react.default.cloneElement(newChild, {}, walker(type, handler)(newChild.props.children));
79
79
  });
80
80
  };
81
81
 
@@ -163,7 +163,7 @@ class AnimationScheduler extends _react.default.Component {
163
163
  onAnimationEnd = _noop2.default,
164
164
  after
165
165
  } = child.props;
166
- return _react.default.cloneElement(child, {
166
+ return /*#__PURE__*/_react.default.cloneElement(child, {
167
167
  animated: parentAnimated ? this.isAnimated(after) || animated : animated,
168
168
  onAnimationEnd: name => {
169
169
  this.handlerAnimationEnd(name);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["AnimationAdapter","animated","onAnimationEnd","name","children","React","Children","map","child","cloneElement","propTypes","PropTypes","string","isRequired","func","bool","pickByWithKey","convert","cap","walker","type","handler","index","newChild","count","props","reduceChildren","fun","acc","newAcc","getAnimationNames","Animation","Transition","mergeAnimationStates","animations","names","value","key","AnimationScheduler","Component","getDerivedStateFromProps","state","constructor","isAnimated","after","handlerAnimationEnd","setState","hasPendingAnimation","processAnimation","parentAnimated","render","bind","node"],"sources":["../../../src/hoc/animation-scheduler/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {\n assign,\n every,\n getOr,\n get,\n includes,\n isArray,\n isNil,\n isString,\n noop,\n pickBy,\n some,\n negate,\n identity,\n values,\n pipe,\n reduce,\n set\n} from 'lodash/fp';\nimport Animation from '../animation';\nimport Transition from '../transition';\n\nconst AnimationAdapter = ({animated, onAnimationEnd = noop, name, children}) => {\n return React.Children.map(children, child =>\n React.cloneElement(child, {\n animated,\n onAnimationEnd: () => onAnimationEnd(name)\n })\n );\n};\n\nAnimationAdapter.propTypes = {\n name: PropTypes.string.isRequired,\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool\n};\n\nconst pickByWithKey = pickBy.convert({cap: true});\n\nconst walker = (type, handler) => children => {\n return React.Children.map(children, (child, index) => {\n if (isNil(child) || isString(child)) return child;\n const newChild = child.type === type ? handler(child) : child;\n if (React.Children.count(newChild.props.children) === 0) return newChild;\n return React.cloneElement(newChild, {}, walker(type, handler)(newChild.props.children));\n });\n};\n\nconst reduceChildren = fun => acc => children => {\n let newAcc = acc;\n React.Children.map(children, child => {\n newAcc = fun(newAcc, child);\n return child;\n });\n return newAcc;\n};\n\nconst getAnimationNames = reduceChildren((acc, child) => {\n if (isString(child)) return acc;\n\n const {\n type,\n props: {children}\n } = child;\n if (Animation !== type && Transition !== type && AnimationAdapter !== type)\n return [...acc, ...getAnimationNames(children)];\n\n const {\n props: {name}\n } = child;\n return [name, ...acc, ...getAnimationNames(children)];\n})([]);\n\nconst mergeAnimationStates = (animations, children) => {\n const names = getAnimationNames(children);\n\n return pipe(\n pickByWithKey((value, key) => includes(key, names)),\n assign(reduce((acc, name) => set(name, false, acc), {}, names))\n )(animations);\n};\n\nclass AnimationScheduler extends React.Component {\n static propTypes = {\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool,\n children: PropTypes.node\n };\n\n static getDerivedStateFromProps(props, state) {\n const {children} = props;\n const {animations} = state;\n return {\n animations: mergeAnimationStates(animations, children)\n };\n }\n\n constructor(props) {\n super(props);\n\n const {children} = props;\n this.state = {\n animations: mergeAnimationStates({}, children)\n };\n }\n\n isAnimated(after) {\n if (isNil(after)) return true;\n\n const {animations} = this.state;\n\n const isAnimated = every(\n name => getOr(false, name, animations),\n isArray(after) ? after : [after]\n );\n\n return isAnimated;\n }\n\n handlerAnimationEnd(name) {\n this.setState(set(['animations', name], true), () => {\n const hasPendingAnimation = pipe(\n get('state.animations'),\n values,\n some(negate(identity))\n )(this);\n const {onAnimationEnd = noop} = this.props;\n if (!hasPendingAnimation) return onAnimationEnd();\n });\n }\n\n processAnimation(child) {\n const {animated: parentAnimated} = this.props;\n const {animated, onAnimationEnd = noop, after} = child.props;\n\n return React.cloneElement(child, {\n animated: parentAnimated ? this.isAnimated(after) || animated : animated,\n onAnimationEnd: name => {\n this.handlerAnimationEnd(name);\n return onAnimationEnd(name);\n }\n });\n }\n\n render() {\n const {children} = this.props;\n return pipe(\n walker(Animation, this.processAnimation.bind(this)),\n walker(Transition, this.processAnimation.bind(this)),\n walker(AnimationAdapter, this.processAnimation.bind(this))\n )(children);\n }\n}\n\nexport default AnimationScheduler;\n\nexport {AnimationAdapter};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AAoBA;;AACA;;;;AAEA,MAAMA,gBAAgB,GAAG,CAAC;EAACC,QAAD;EAAWC,cAAc,iBAAzB;EAAkCC,IAAlC;EAAwCC;AAAxC,CAAD,KAAuD;EAC9E,OAAOC,cAAA,CAAMC,QAAN,CAAeC,GAAf,CAAmBH,QAAnB,EAA6BI,KAAK,IACvCH,cAAA,CAAMI,YAAN,CAAmBD,KAAnB,EAA0B;IACxBP,QADwB;IAExBC,cAAc,EAAE,MAAMA,cAAc,CAACC,IAAD;EAFZ,CAA1B,CADK,CAAP;AAMD,CAPD;;;AASAH,gBAAgB,CAACU,SAAjB,2CAA6B;EAC3BP,IAAI,EAAEQ,kBAAA,CAAUC,MAAV,CAAiBC,UADI;EAE3B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AyB1C,IAAzB;QACA,OAAOD,cAAc,CAACC,IAAD,CAArB;MACD;IAL8B,CAA1B,CAAP;EAOD;;EAED+C,MAAM,GAAG;IACP,MAAM;MAAC9C;IAAD,IAAa,KAAKqB,KAAxB;IACA,OAAO,oBACLN,MAAM,CAACY,kBAAD,EAAY,KAAKiB,gBAAL,CAAsBG,IAAtB,CAA2B,IAA3B,CAAZ,CADD,EAELhC,MAAM,CAACa,mBAAD,EAAa,KAAKgB,gBAAL,CAAsBG,IAAtB,CAA2B,IAA3B,CAAb,CAFD,EAGLhC,MAAM,CAACnB,gBAAD,EAAmB,KAAKgD,gBAAL,CAAsBG,IAAtB,CAA2B,IAA3B,CAAnB,CAHD,EAIL/C,QAJK,CAAP;EAKD;;AArE8C;;AAA3CkC,kB,CACG5B,S,2CAAY;EACjBR,cAAc,EAAES,kBAAA,CAAUG,IADT;EAEjBb,QAAQ,EAAEU,kBAAA,CAAUI,IAFH;EAGjBX,QAAQ,EAAEO,kBAAA,CAAUyC;AAHH,C;eAuENd,kB"}
1
+ {"version":3,"file":"index.js","names":["AnimationAdapter","animated","onAnimationEnd","name","children","React","Children","map","child","cloneElement","propTypes","PropTypes","string","isRequired","func","bool","pickByWithKey","convert","cap","walker","type","handler","index","newChild","count","props","reduceChildren","fun","acc","newAcc","getAnimationNames","Animation","Transition","mergeAnimationStates","animations","names","value","key","AnimationScheduler","Component","getDerivedStateFromProps","state","constructor","isAnimated","after","handlerAnimationEnd","setState","hasPendingAnimation","processAnimation","parentAnimated","render","bind","node"],"sources":["../../../src/hoc/animation-scheduler/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {\n assign,\n every,\n getOr,\n get,\n includes,\n isArray,\n isNil,\n isString,\n noop,\n pickBy,\n some,\n negate,\n identity,\n values,\n pipe,\n reduce,\n set\n} from 'lodash/fp';\nimport Animation from '../animation';\nimport Transition from '../transition';\n\nconst AnimationAdapter = ({animated, onAnimationEnd = noop, name, children}) => {\n return React.Children.map(children, child =>\n React.cloneElement(child, {\n animated,\n onAnimationEnd: () => onAnimationEnd(name)\n })\n );\n};\n\nAnimationAdapter.propTypes = {\n name: PropTypes.string.isRequired,\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool\n};\n\nconst pickByWithKey = pickBy.convert({cap: true});\n\nconst walker = (type, handler) => children => {\n return React.Children.map(children, (child, index) => {\n if (isNil(child) || isString(child)) return child;\n const newChild = child.type === type ? handler(child) : child;\n if (React.Children.count(newChild.props.children) === 0) return newChild;\n return React.cloneElement(newChild, {}, walker(type, handler)(newChild.props.children));\n });\n};\n\nconst reduceChildren = fun => acc => children => {\n let newAcc = acc;\n React.Children.map(children, child => {\n newAcc = fun(newAcc, child);\n return child;\n });\n return newAcc;\n};\n\nconst getAnimationNames = reduceChildren((acc, child) => {\n if (isString(child)) return acc;\n\n const {\n type,\n props: {children}\n } = child;\n if (Animation !== type && Transition !== type && AnimationAdapter !== type)\n return [...acc, ...getAnimationNames(children)];\n\n const {\n props: {name}\n } = child;\n return [name, ...acc, ...getAnimationNames(children)];\n})([]);\n\nconst mergeAnimationStates = (animations, children) => {\n const names = getAnimationNames(children);\n\n return pipe(\n pickByWithKey((value, key) => includes(key, names)),\n assign(reduce((acc, name) => set(name, false, acc), {}, names))\n )(animations);\n};\n\nclass AnimationScheduler extends React.Component {\n static propTypes = {\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool,\n children: PropTypes.node\n };\n\n static getDerivedStateFromProps(props, state) {\n const {children} = props;\n const {animations} = state;\n return {\n animations: mergeAnimationStates(animations, children)\n };\n }\n\n constructor(props) {\n super(props);\n\n const {children} = props;\n this.state = {\n animations: mergeAnimationStates({}, children)\n };\n }\n\n isAnimated(after) {\n if (isNil(after)) return true;\n\n const {animations} = this.state;\n\n const isAnimated = every(\n name => getOr(false, name, animations),\n isArray(after) ? after : [after]\n );\n\n return isAnimated;\n }\n\n handlerAnimationEnd(name) {\n this.setState(set(['animations', name], true), () => {\n const hasPendingAnimation = pipe(\n get('state.animations'),\n values,\n some(negate(identity))\n )(this);\n const {onAnimationEnd = noop} = this.props;\n if (!hasPendingAnimation) return onAnimationEnd();\n });\n }\n\n processAnimation(child) {\n const {animated: parentAnimated} = this.props;\n const {animated, onAnimationEnd = noop, after} = child.props;\n\n return React.cloneElement(child, {\n animated: parentAnimated ? this.isAnimated(after) || animated : animated,\n onAnimationEnd: name => {\n this.handlerAnimationEnd(name);\n return onAnimationEnd(name);\n }\n });\n }\n\n render() {\n const {children} = this.props;\n return pipe(\n walker(Animation, this.processAnimation.bind(this)),\n walker(Transition, this.processAnimation.bind(this)),\n walker(AnimationAdapter, this.processAnimation.bind(this))\n )(children);\n }\n}\n\nexport default AnimationScheduler;\n\nexport {AnimationAdapter};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AAoBA;;AACA;;;;AAEA,MAAMA,gBAAgB,GAAG,CAAC;EAACC,QAAD;EAAWC,cAAc,iBAAzB;EAAkCC,IAAlC;EAAwCC;AAAxC,CAAD,KAAuD;EAC9E,OAAOC,cAAA,CAAMC,QAAN,CAAeC,GAAf,CAAmBH,QAAnB,EAA6BI,KAAK,iBACvCH,cAAA,CAAMI,YAAN,CAAmBD,KAAnB,EAA0B;IACxBP,QADwB;IAExBC,cAAc,EAAE,MAAMA,cAAc,CAACC,IAAD;EAFZ,CAA1B,CADK,CAAP;AAMD,CAPD;;;AASAH,gBAAgB,CAACU,SAAjB,2CAA6B;EAC3BP,IAAI,EAAEQ,kBAAA,CAAUC,MAAV,CAAiBC,UADI;EAE3BX,cAAc,EAAES,kBAAA,CAAUG,IAFC;EAG3Bb,QAAQ,EAAEU,kBAAA,CAAUI;AAHO,CAA7B;;AAMA,MAAMC,aAAa,GAAG,iBAAOC,OAAP,CAAe;EAACC,GAAG,EAAE;AAAN,CAAf,CAAtB;;AAEA,MAAMC,MAAM,GAAG,CAACC,IAAD,EAAOC,OAAP,KAAmBjB,QAAQ,IAAI;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,CADD,EAELhC,MAAM,CAACa,mBAAD,EAAa,KAAKgB,gBAAL,CAAsBG,IAAtB,CAA2B,IAA3B,CAAb,CAFD,EAGLhC,MAAM,CAACnB,gBAAD,EAAmB,KAAKgD,gBAAL,CAAsBG,IAAtB,CAA2B,IAA3B,CAAnB,CAHD,EAIL/C,QAJK,CAAP;EAKD;;AArE8C;;AAA3CkC,kB,CACG5B,S,2CAAY;EACjBR,cAAc,EAAES,kBAAA,CAAUG,IADT;EAEjBb,QAAQ,EAAEU,kBAAA,CAAUI,IAFH;EAGjBX,QAAQ,EAAEO,kBAAA,CAAUyC;AAHH,C;eAuENd,kB"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=fixtures.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../../src/hoc/modal/select/test/fixtures.native.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=fixtures.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../../src/hoc/modal/select-item/test/fixtures.native.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=fixtures.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/hoc/modal/test/fixtures.native.ts"],"names":[],"mappings":""}
@@ -52,7 +52,7 @@ class Swapper extends _react.default.Component {
52
52
 
53
53
  const child = _react.default.Children.only(children);
54
54
 
55
- return init ? _react.default.cloneElement(child, props) : child;
55
+ return init ? /*#__PURE__*/_react.default.cloneElement(child, props) : child;
56
56
  }
57
57
 
58
58
  }
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["safeCancelAnimationFrame","requestId","cancelAnimationFrame","Swapper","React","Component","constructor","props","state","init","componentDidMount","requestAnimationFrame","requestID","setState","componentWillUnmount","undefined","render","children","child","Children","only","cloneElement","propTypes","PropTypes","node"],"sources":["../../../src/hoc/swapper/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\n\nexport const safeCancelAnimationFrame = requestId => requestId && cancelAnimationFrame(requestId);\n\nclass Swapper extends React.Component {\n static propTypes = {\n children: PropTypes.node\n };\n\n constructor(props) {\n super(props);\n\n this.state = {\n init: true\n };\n }\n\n componentDidMount() {\n if (typeof requestAnimationFrame !== 'undefined') {\n this.requestID = requestAnimationFrame(() => this.setState({init: false}));\n }\n }\n\n componentWillUnmount() {\n if (this.requestID !== undefined) {\n safeCancelAnimationFrame(this.requestID);\n }\n }\n\n render() {\n const {init} = this.state;\n const {children, ...props} = this.props;\n const child = React.Children.only(children);\n\n return init ? React.cloneElement(child, props) : child;\n }\n}\n\nexport default Swapper;\n"],"mappings":";;;;;AAAA;;AACA;;;;;;;;AAEO,MAAMA,wBAAwB,GAAGC,SAAS,IAAIA,SAAS,IAAIC,oBAAoB,CAACD,SAAD,CAA/E;;;;AAEP,MAAME,OAAN,SAAsBC,cAAA,CAAMC,SAA5B,CAAsC;EAKpCC,WAAW,CAACC,KAAD,EAAQ;IACjB,MAAMA,KAAN;IAEA,KAAKC,KAAL,GAAa;MACXC,IAAI,EAAE;IADK,CAAb;EAGD;;EAEDC,iBAAiB,GAAG;IAClB,IAAI,OAAOC,qBAAP,KAAiC,WAArC,EAAkD;MAChD,KAAKC,SAAL,GAAiBD,qBAAqB,CAAC,MAAM,KAAKE,QAAL,CAAc;QAACJ,IAAI,EAAE;MAAP,CAAd,CAAP,CAAtC;IACD;EACF;;EAEDK,oBAAoB,GAAG;IACrB,IAAI,KAAKF,SAAL,KAAmBG,SAAvB,EAAkC;MAChCf,wBAAwB,CAAC,KAAKY,SAAN,CAAxB;IACD;EACF;;EAEDI,MAAM,GAAG;IACP,MAAM;MAACP;IAAD,IAAS,KAAKD,KAApB;;IACA,oBAA6B,KAAKD,KAAlC;IAAA,MAAM;MAACU;IAAD,CAAN;IAAA,MAAoBV,KAApB;;IACA,MAAMW,KAAK,GAAGd,cAAA,CAAMe,QAAN,CAAeC,IAAf,CAAoBH,QAApB,CAAd;;IAEA,OAAOR,IAAI,GAAGL,cAAA,CAAMiB,YAAN,CAAmBH,KAAnB,EAA0BX,KAA1B,CAAH,GAAsCW,KAAjD;EACD;;AA/BmC;;AAAhCf,O,CACGmB,S,2CAAY;EACjBL,QAAQ,EAAEM,kBAAA,CAAUC;AADH,C;eAiCNrB,O"}
1
+ {"version":3,"file":"index.js","names":["safeCancelAnimationFrame","requestId","cancelAnimationFrame","Swapper","React","Component","constructor","props","state","init","componentDidMount","requestAnimationFrame","requestID","setState","componentWillUnmount","undefined","render","children","child","Children","only","cloneElement","propTypes","PropTypes","node"],"sources":["../../../src/hoc/swapper/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\n\nexport const safeCancelAnimationFrame = requestId => requestId && cancelAnimationFrame(requestId);\n\nclass Swapper extends React.Component {\n static propTypes = {\n children: PropTypes.node\n };\n\n constructor(props) {\n super(props);\n\n this.state = {\n init: true\n };\n }\n\n componentDidMount() {\n if (typeof requestAnimationFrame !== 'undefined') {\n this.requestID = requestAnimationFrame(() => this.setState({init: false}));\n }\n }\n\n componentWillUnmount() {\n if (this.requestID !== undefined) {\n safeCancelAnimationFrame(this.requestID);\n }\n }\n\n render() {\n const {init} = this.state;\n const {children, ...props} = this.props;\n const child = React.Children.only(children);\n\n return init ? React.cloneElement(child, props) : child;\n }\n}\n\nexport default Swapper;\n"],"mappings":";;;;;AAAA;;AACA;;;;;;;;AAEO,MAAMA,wBAAwB,GAAGC,SAAS,IAAIA,SAAS,IAAIC,oBAAoB,CAACD,SAAD,CAA/E;;;;AAEP,MAAME,OAAN,SAAsBC,cAAA,CAAMC,SAA5B,CAAsC;EAKpCC,WAAW,CAACC,KAAD,EAAQ;IACjB,MAAMA,KAAN;IAEA,KAAKC,KAAL,GAAa;MACXC,IAAI,EAAE;IADK,CAAb;EAGD;;EAEDC,iBAAiB,GAAG;IAClB,IAAI,OAAOC,qBAAP,KAAiC,WAArC,EAAkD;MAChD,KAAKC,SAAL,GAAiBD,qBAAqB,CAAC,MAAM,KAAKE,QAAL,CAAc;QAACJ,IAAI,EAAE;MAAP,CAAd,CAAP,CAAtC;IACD;EACF;;EAEDK,oBAAoB,GAAG;IACrB,IAAI,KAAKF,SAAL,KAAmBG,SAAvB,EAAkC;MAChCf,wBAAwB,CAAC,KAAKY,SAAN,CAAxB;IACD;EACF;;EAEDI,MAAM,GAAG;IACP,MAAM;MAACP;IAAD,IAAS,KAAKD,KAApB;;IACA,oBAA6B,KAAKD,KAAlC;IAAA,MAAM;MAACU;IAAD,CAAN;IAAA,MAAoBV,KAApB;;IACA,MAAMW,KAAK,GAAGd,cAAA,CAAMe,QAAN,CAAeC,IAAf,CAAoBH,QAApB,CAAd;;IAEA,OAAOR,IAAI,gBAAGL,cAAA,CAAMiB,YAAN,CAAmBH,KAAnB,EAA0BX,KAA1B,CAAH,GAAsCW,KAAjD;EACD;;AA/BmC;;AAAhCf,O,CACGmB,S,2CAAY;EACjBL,QAAQ,EAAEM,kBAAA,CAAUC;AADH,C;eAiCNrB,O"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=fixtures.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/hoc/touchable/test/fixtures.native.ts"],"names":[],"mappings":""}
@@ -0,0 +1,11 @@
1
+ export default Transition;
2
+ declare function Transition(props: any): any;
3
+ declare namespace Transition {
4
+ namespace propTypes {
5
+ const name: PropTypes.Validator<string>;
6
+ const onAnimationEnd: PropTypes.Requireable<(...args: any[]) => any>;
7
+ const animated: PropTypes.Requireable<boolean>;
8
+ }
9
+ }
10
+ import PropTypes from "prop-types";
11
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/hoc/transition/index.js"],"names":[],"mappings":";AAKA,6CAyBC"}
@@ -38,7 +38,7 @@ const Transition = props => {
38
38
  const handlerAnimationEnd = (0, _react.useMemo)(() => () => {
39
39
  return onAnimationEnd(name);
40
40
  }, []);
41
- return _react.default.cloneElement(child, {
41
+ return /*#__PURE__*/_react.default.cloneElement(child, {
42
42
  className: (0, _classnames.default)(propClassName, className),
43
43
  onTransitionEnd: handlerAnimationEnd,
44
44
  onAnimationEnd: handlerAnimationEnd
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["Transition","props","name","children","className","animated","onAnimationEnd","Child","child","propClassName","handlerAnimationEnd","useMemo","React","cloneElement","classnames","onTransitionEnd","Children","map","propTypes","PropTypes","string","isRequired","func","bool"],"sources":["../../../src/hoc/transition/index.js"],"sourcesContent":["import React, {useMemo} from 'react';\nimport {noop} from 'lodash/fp';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\n\nconst Transition = props => {\n const {name, children, className, animated, onAnimationEnd = noop} = props;\n\n if (!animated) return children;\n\n const Child = ({child}) => {\n const {\n props: {className: propClassName}\n } = child;\n\n const handlerAnimationEnd = useMemo(\n () => () => {\n return onAnimationEnd(name);\n },\n []\n );\n\n return React.cloneElement(child, {\n className: classnames(propClassName, className),\n onTransitionEnd: handlerAnimationEnd,\n onAnimationEnd: handlerAnimationEnd\n });\n };\n\n return React.Children.map(children, child => <Child child={child} />);\n};\n\nTransition.propTypes = {\n name: PropTypes.string.isRequired,\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool\n};\n\nexport default Transition;\n"],"mappings":";;;;;;;AAAA;;AAEA;;AACA;;;;;;;;AAEA,MAAMA,UAAU,GAAGC,KAAK,IAAI;EAC1B,MAAM;IAACC,IAAD;IAAOC,QAAP;IAAiBC,SAAjB;IAA4BC,QAA5B;IAAsCC,cAAc;EAApD,IAA+DL,KAArE;EAEA,IAAI,CAACI,QAAL,EAAe,OAAOF,QAAP;;EAEf,MAAMI,KAAK,GAAG,CAAC;IAACC;EAAD,CAAD,KAAa;IACzB,MAAM;MACJP,KAAK,EAAE;QAACG,SAAS,EAAEK;MAAZ;IADH,IAEFD,KAFJ;IAIA,MAAME,mBAAmB,GAAG,IAAAC,cAAA,EAC1B,MAAM,MAAM;MACV,OAAOL,cAAc,CAACJ,IAAD,CAArB;IACD,CAHyB,EAI1B,EAJ0B,CAA5B;IAOA,OAAOU,cAAA,CAAMC,YAAN,CAAmBL,KAAnB,EAA0B;MAC/BJ,SAAS,EAAE,IAAAU,mBAAA,EAAWL,aAAX,EAA0BL,SAA1B,CADoB;MAE/BW,eAAe,EAAEL,mBAFc;MAG/BJ,cAAc,EAAEI;IAHe,CAA1B,CAAP;EAKD,CAjBD;;EAmBA,OAAOE,cAAA,CAAMI,QAAN,CAAeC,GAAf,CAAmBd,QAAnB,EAA6BK,KAAK,iBAAI,6BAAC,KAAD;IAAO,KAAK,EAAEA;EAAd,EAAtC,CAAP;AACD,CAzBD;;AA2BAR,UAAU,CAACkB,SAAX,2CAAuB;EACrBhB,IAAI,EAAEiB,kBAAA,CAAUC,MAAV,CAAiBC,UADF;EAErBf,cAAc,EAAEa,kBAAA,CAAUG,IAFL;EAGrBjB,QAAQ,EAAEc,kBAAA,CAAUI;AAHC,CAAvB;eAMevB,U"}
1
+ {"version":3,"file":"index.js","names":["Transition","props","name","children","className","animated","onAnimationEnd","Child","child","propClassName","handlerAnimationEnd","useMemo","React","cloneElement","classnames","onTransitionEnd","Children","map","propTypes","PropTypes","string","isRequired","func","bool"],"sources":["../../../src/hoc/transition/index.js"],"sourcesContent":["import React, {useMemo} from 'react';\nimport {noop} from 'lodash/fp';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\n\nconst Transition = props => {\n const {name, children, className, animated, onAnimationEnd = noop} = props;\n\n if (!animated) return children;\n\n const Child = ({child}) => {\n const {\n props: {className: propClassName}\n } = child;\n\n const handlerAnimationEnd = useMemo(\n () => () => {\n return onAnimationEnd(name);\n },\n []\n );\n\n return React.cloneElement(child, {\n className: classnames(propClassName, className),\n onTransitionEnd: handlerAnimationEnd,\n onAnimationEnd: handlerAnimationEnd\n });\n };\n\n return React.Children.map(children, child => <Child child={child} />);\n};\n\nTransition.propTypes = {\n name: PropTypes.string.isRequired,\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool\n};\n\nexport default Transition;\n"],"mappings":";;;;;;;AAAA;;AAEA;;AACA;;;;;;;;AAEA,MAAMA,UAAU,GAAGC,KAAK,IAAI;EAC1B,MAAM;IAACC,IAAD;IAAOC,QAAP;IAAiBC,SAAjB;IAA4BC,QAA5B;IAAsCC,cAAc;EAApD,IAA+DL,KAArE;EAEA,IAAI,CAACI,QAAL,EAAe,OAAOF,QAAP;;EAEf,MAAMI,KAAK,GAAG,CAAC;IAACC;EAAD,CAAD,KAAa;IACzB,MAAM;MACJP,KAAK,EAAE;QAACG,SAAS,EAAEK;MAAZ;IADH,IAEFD,KAFJ;IAIA,MAAME,mBAAmB,GAAG,IAAAC,cAAA,EAC1B,MAAM,MAAM;MACV,OAAOL,cAAc,CAACJ,IAAD,CAArB;IACD,CAHyB,EAI1B,EAJ0B,CAA5B;IAOA,oBAAOU,cAAA,CAAMC,YAAN,CAAmBL,KAAnB,EAA0B;MAC/BJ,SAAS,EAAE,IAAAU,mBAAA,EAAWL,aAAX,EAA0BL,SAA1B,CADoB;MAE/BW,eAAe,EAAEL,mBAFc;MAG/BJ,cAAc,EAAEI;IAHe,CAA1B,CAAP;EAKD,CAjBD;;EAmBA,OAAOE,cAAA,CAAMI,QAAN,CAAeC,GAAf,CAAmBd,QAAnB,EAA6BK,KAAK,iBAAI,6BAAC,KAAD;IAAO,KAAK,EAAEA;EAAd,EAAtC,CAAP;AACD,CAzBD;;AA2BAR,UAAU,CAACkB,SAAX,2CAAuB;EACrBhB,IAAI,EAAEiB,kBAAA,CAAUC,MAAV,CAAiBC,UADF;EAErBf,cAAc,EAAEa,kBAAA,CAAUG,IAFL;EAGrBjB,QAAQ,EAAEc,kBAAA,CAAUI;AAHC,CAAvB;eAMevB,U"}
@@ -26,7 +26,7 @@ const ADD_TO_MY_LIST_STATUS = {
26
26
  SUCCESS: 'SUCCESS'
27
27
  };
28
28
 
29
- const StatusContext = _react.default.createContext(ADD_TO_MY_LIST_STATUS.IDLE);
29
+ const StatusContext = /*#__PURE__*/_react.default.createContext(ADD_TO_MY_LIST_STATUS.IDLE);
30
30
 
31
31
  const AddToMyListStatusProvider = ({
32
32
  children
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["ADD_TO_MY_LIST_STATUS","IDLE","SUCCESS","StatusContext","React","createContext","AddToMyListStatusProvider","children","status","setStatus","useState","useEffect","timeoutId","DURATION","setTimeout","clearTimeout","statusValue","useMemo","AddToMyListFeedback","addToMyListText","removeFromMyListText","favorite","useContext","classnames","styles","feedback","checkIcon","AddToMyList","style","addToMyListButton","onFavoriteClick","cb","onClick","container","cta","wrapper","shareIcon","propTypes","PropTypes","node","string","bool","func"],"sources":["../../../src/molecule/add-to-my-list/index.js"],"sourcesContent":["import React, {useState, useContext, useEffect, useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n NovaCompositionCoorpacademyCheck as CheckIcon,\n NovaCompositionNavigationMore as MoreIcon\n} from '@coorpacademy/nova-icons';\nimport Link from '../../atom/link';\nimport styles from './style.css';\n\nconst ADD_TO_MY_LIST_STATUS = {\n IDLE: 'IDLE',\n SUCCESS: 'SUCCESS'\n};\n\nconst StatusContext = React.createContext(ADD_TO_MY_LIST_STATUS.IDLE);\n\nexport const AddToMyListStatusProvider = ({children}) => {\n const [status, setStatus] = useState(ADD_TO_MY_LIST_STATUS.IDLE);\n useEffect(() => {\n let timeoutId;\n const DURATION = 3000;\n if (status !== ADD_TO_MY_LIST_STATUS.IDLE) {\n timeoutId = setTimeout(() => setStatus(ADD_TO_MY_LIST_STATUS.IDLE), DURATION);\n }\n return () => clearTimeout(timeoutId);\n }, [status]);\n const statusValue = useMemo(() => [status, setStatus], [status, setStatus]);\n return <StatusContext.Provider value={statusValue}>{children}</StatusContext.Provider>;\n};\n\nexport const AddToMyListFeedback = ({addToMyListText, removeFromMyListText, favorite}) => {\n const [status] = useContext(StatusContext);\n if (status === ADD_TO_MY_LIST_STATUS.IDLE) return null;\n\n return (\n <div className={classnames(styles.feedback)} data-name={'add-to-my-list-feedback'}>\n <CheckIcon className={styles.checkIcon} width={13} height={13} />\n <p>{favorite ? addToMyListText : removeFromMyListText}</p>\n </div>\n );\n};\n\nconst AddToMyList = ({style, addToMyListButton, favorite, onFavoriteClick}) => {\n const [, setStatus] = useContext(StatusContext);\n const cb = () => setStatus(ADD_TO_MY_LIST_STATUS.SUCCESS);\n\n function onClick() {\n onFavoriteClick(cb);\n }\n\n return (\n <div className={(styles.container, style)}>\n <Link data-name={'add-to-my-list-button'} onClick={onClick} className={styles.cta}>\n <div className={styles.wrapper}>\n {favorite ? (\n <CheckIcon className={styles.shareIcon} width={15} height={15} />\n ) : (\n <MoreIcon className={styles.shareIcon} width={12} height={12} />\n )}\n <p>{addToMyListButton}</p>\n </div>\n </Link>\n </div>\n );\n};\n\nAddToMyListStatusProvider.propTypes = {\n children: PropTypes.node\n};\n\nAddToMyListFeedback.propTypes = {\n addToMyListText: PropTypes.string,\n removeFromMyListText: PropTypes.string,\n favorite: PropTypes.bool\n};\n\nAddToMyList.propTypes = {\n style: PropTypes.string,\n addToMyListButton: PropTypes.string,\n favorite: PropTypes.bool,\n onFavoriteClick: PropTypes.func\n};\n\nexport default AddToMyList;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AAIA;;AACA;;;;;;;;AAEA,MAAMA,qBAAqB,GAAG;EAC5BC,IAAI,EAAE,MADsB;EAE5BC,OAAO,EAAE;AAFmB,CAA9B;;AAKA,MAAMC,aAAa,GAAGC,cAAA,CAAMC,aAAN,CAAoBL,qBAAqB,CAACC,IAA1C,CAAtB;;AAEO,MAAMK,yBAAyB,GAAG,CA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AAUG,IAHE;EAItBX,eAAe,EAAEQ,kBAAA,CAAUI;AAJL,CAAxB;eAOef,W"}
1
+ {"version":3,"file":"index.js","names":["ADD_TO_MY_LIST_STATUS","IDLE","SUCCESS","StatusContext","React","createContext","AddToMyListStatusProvider","children","status","setStatus","useState","useEffect","timeoutId","DURATION","setTimeout","clearTimeout","statusValue","useMemo","AddToMyListFeedback","addToMyListText","removeFromMyListText","favorite","useContext","classnames","styles","feedback","checkIcon","AddToMyList","style","addToMyListButton","onFavoriteClick","cb","onClick","container","cta","wrapper","shareIcon","propTypes","PropTypes","node","string","bool","func"],"sources":["../../../src/molecule/add-to-my-list/index.js"],"sourcesContent":["import React, {useState, useContext, useEffect, useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n NovaCompositionCoorpacademyCheck as CheckIcon,\n NovaCompositionNavigationMore as MoreIcon\n} from '@coorpacademy/nova-icons';\nimport Link from '../../atom/link';\nimport styles from './style.css';\n\nconst ADD_TO_MY_LIST_STATUS = {\n IDLE: 'IDLE',\n SUCCESS: 'SUCCESS'\n};\n\nconst StatusContext = React.createContext(ADD_TO_MY_LIST_STATUS.IDLE);\n\nexport const AddToMyListStatusProvider = ({children}) => {\n const [status, setStatus] = useState(ADD_TO_MY_LIST_STATUS.IDLE);\n useEffect(() => {\n let timeoutId;\n const DURATION = 3000;\n if (status !== ADD_TO_MY_LIST_STATUS.IDLE) {\n timeoutId = setTimeout(() => setStatus(ADD_TO_MY_LIST_STATUS.IDLE), DURATION);\n }\n return () => clearTimeout(timeoutId);\n }, [status]);\n const statusValue = useMemo(() => [status, setStatus], [status, setStatus]);\n return <StatusContext.Provider value={statusValue}>{children}</StatusContext.Provider>;\n};\n\nexport const AddToMyListFeedback = ({addToMyListText, removeFromMyListText, favorite}) => {\n const [status] = useContext(StatusContext);\n if (status === ADD_TO_MY_LIST_STATUS.IDLE) return null;\n\n return (\n <div className={classnames(styles.feedback)} data-name={'add-to-my-list-feedback'}>\n <CheckIcon className={styles.checkIcon} width={13} height={13} />\n <p>{favorite ? addToMyListText : removeFromMyListText}</p>\n </div>\n );\n};\n\nconst AddToMyList = ({style, addToMyListButton, favorite, onFavoriteClick}) => {\n const [, setStatus] = useContext(StatusContext);\n const cb = () => setStatus(ADD_TO_MY_LIST_STATUS.SUCCESS);\n\n function onClick() {\n onFavoriteClick(cb);\n }\n\n return (\n <div className={(styles.container, style)}>\n <Link data-name={'add-to-my-list-button'} onClick={onClick} className={styles.cta}>\n <div className={styles.wrapper}>\n {favorite ? (\n <CheckIcon className={styles.shareIcon} width={15} height={15} />\n ) : (\n <MoreIcon className={styles.shareIcon} width={12} height={12} />\n )}\n <p>{addToMyListButton}</p>\n </div>\n </Link>\n </div>\n );\n};\n\nAddToMyListStatusProvider.propTypes = {\n children: PropTypes.node\n};\n\nAddToMyListFeedback.propTypes = {\n addToMyListText: PropTypes.string,\n removeFromMyListText: PropTypes.string,\n favorite: PropTypes.bool\n};\n\nAddToMyList.propTypes = {\n style: PropTypes.string,\n addToMyListButton: PropTypes.string,\n favorite: PropTypes.bool,\n onFavoriteClick: PropTypes.func\n};\n\nexport default AddToMyList;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AAIA;;AACA;;;;;;;;AAEA,MAAMA,qBAAqB,GAAG;EAC5BC,IAAI,EAAE,MADsB;EAE5BC,OAAO,EAAE;AAFmB,CAA9B;;AAKA,MAAMC,aAAa,gBAAGC,cAAA,CAAMC,aAAN,CAAoBL,qBAAqB,CAACC,IAA1C,CAAtB;;AAEO,MAAMK,yBAAyB,GAAG,CAAC;EAACC;AAAD,CAAD,KAAgB;EACvD,MAAM,CAACC,MAAD,EAASC,SAAT,IAAsB,IAAAC,eAAA,EAASV,qBAAqB,CAACC,IAA/B,CAA5B;EACA,IAAAU,gBAAA,EAAU,MAAM;IACd,IAAIC,SAAJ;IACA,MAAMC,QAAQ,GAAG,IAAjB;;IACA,IAAIL,MAAM,KAAKR,qBAAqB,CAACC,IAArC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,CAACC,EAAD,CAAf;EACD;;EAED,oBACE;IAAK,SAAS,GAAGP,cAAA,CAAOS,SAAP,EAAkBL,KAArB;EAAd,gBACE,6BAAC,aAAD;IAAM,aAAW,uBAAjB;IAA0C,OAAO,EAAEI,OAAnD;IAA4D,SAAS,EAAER,cAAA,CAAOU;EAA9E,gBACE;IAAK,SAAS,EAAEV,cAAA,CAAOW;EAAvB,GACGd,QAAQ,gBACP,6BAAC,2CAAD;IAAW,SAAS,EAAEG,cAAA,CAAOY,SAA7B;IAAwC,KAAK,EAAE,EAA/C;IAAmD,MAAM,EAAE;EAA3D,EADO,gBAGP,6BAAC,wCAAD;IAAU,SAAS,EAAEZ,cAAA,CAAOY,SAA5B;IAAuC,KAAK,EAAE,EAA9C;IAAkD,MAAM,EAAE;EAA1D,EAJJ,eAME,wCAAIP,iBAAJ,CANF,CADF,CADF,CADF;AAcD,CAtBD;;AAwBAvB,yBAAyB,CAAC+B,SAA1B,2CAAsC;EACpC9B,QAAQ,EAAE+B,kBAAA,CAAUC;AADgB,CAAtC;AAIArB,mBAAmB,CAACmB,SAApB,2CAAgC;EAC9BlB,eAAe,EAAEmB,kBAAA,CAAUE,MADG;EAE9BpB,oBAAoB,EAAEkB,kBAAA,CAAUE,MAFF;EAG9BnB,QAAQ,EAAEiB,kBAAA,CAAUG;AAHU,CAAhC;AAMAd,WAAW,CAACU,SAAZ,2CAAwB;EACtBT,KAAK,EAAEU,kBAAA,CAAUE,MADK;EAEtBX,iBAAiB,EAAES,kBAAA,CAAUE,MAFP;EAGtBnB,QAAQ,EAAEiB,kBAAA,CAAUG,IAHE;EAItBX,eAAe,EAAEQ,kBAAA,CAAUI;AAJL,CAAxB;eAOef,W"}
@@ -0,0 +1,7 @@
1
+ export default Answer;
2
+ declare function Answer(props: any): JSX.Element;
3
+ declare namespace Answer {
4
+ export { propTypes };
5
+ }
6
+ import propTypes from "./prop-types";
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/molecule/answer/index.js"],"names":[],"mappings":";AAuEA,iDASC"}
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- import { Props } from './prop-types';
3
- declare const Answer: (props: Props) => JSX.Element;
2
+ import { AnswerProps } from './prop-types';
3
+ declare const Answer: (props: AnswerProps) => JSX.Element;
4
4
  export default Answer;
5
5
  //# sourceMappingURL=index.native.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/molecule/answer/index.native.tsx"],"names":[],"mappings":";AAGA,OAAO,EAAC,KAAK,EAAC,MAAM,cAAc,CAAC;AAuCnC,QAAA,MAAM,MAAM,UAAW,KAAK,gBA8B3B,CAAC;AAEF,eAAe,MAAM,CAAC"}
1
+ {"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/molecule/answer/index.native.tsx"],"names":[],"mappings":";AAGA,OAAO,EAAC,WAAW,EAAC,MAAM,cAAc,CAAC;AAuCzC,QAAA,MAAM,MAAM,UAAW,WAAW,gBA8BjC,CAAC;AAEF,eAAe,MAAM,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.native.js","names":["convertType","modelType","convertToChoices","answers","map","answer","index","_id","label","title","value","onPress","onClick","onChange","selected","media","image","type","src","url","undefined","name","items","options","text","Answer","props","model","template","onSliderChange","minLabel","maxLabel","switchProps","onInputValueChange","choices","min","Number","parseInt","split","max","unit"],"sources":["../../../src/molecule/answer/index.native.tsx"],"sourcesContent":["import React from 'react';\nimport {Choice, QuestionType} from '../questions/types';\nimport Switch, {Props as SwitchProps} from '../questions/mobile/switch/index.native';\nimport {Props} from './prop-types';\n\nconst convertType = (modelType: Props['model']['type']): QuestionType => {\n switch (modelType) {\n case 'freeText':\n return 'basic';\n case 'dropDown':\n return 'template';\n default:\n return modelType;\n }\n};\n\nconst convertToChoices = (answers: Props['model']['answers'] = []): Choice[] =>\n answers.map((answer, index) => ({\n _id: `${index}`,\n label: answer.title,\n value: answer.title,\n onPress: answer.onClick || answer.onChange,\n selected: answer.selected,\n media: answer.image\n ? {\n type: 'img',\n src: [{url: answer.image}]\n }\n : undefined,\n // ---- custom properties for template choice\n type: answer.type,\n name: answer.name,\n items:\n answer.options &&\n answer.options.map(({name, selected, value}) => ({\n text: name,\n selected,\n value,\n _id: name\n }))\n }));\n\nconst Answer = (props: Props) => {\n const {\n model: {answers, onChange, template, type, onSliderChange, minLabel, maxLabel, title}\n } = props;\n\n const switchProps: SwitchProps = {\n type: convertType(type)\n };\n\n if (type === 'freeText') {\n switchProps.onInputValueChange = onChange;\n }\n\n if (type === 'qcm' || type === 'qcmDrag' || type === 'qcmGraphic' || type === 'template') {\n switchProps.choices = convertToChoices(answers);\n }\n\n if (type === 'template') {\n switchProps.template = template;\n }\n\n if (type === 'slider') {\n switchProps.onSliderChange = onSliderChange;\n switchProps.min = minLabel ? Number.parseInt(minLabel.split(' ')[0]) : 0;\n switchProps.max = maxLabel ? Number.parseInt(maxLabel.split(' ')[0]) : 1;\n switchProps.value = title ? Number.parseInt(title.split(' ')[0]) : 0;\n switchProps.unit = minLabel ? minLabel.split(' ')[1] : '';\n }\n\n return <Switch {...switchProps} />;\n};\n\nexport default Answer;\n"],"mappings":";;;;;AAAA;;AAEA;;;;AAGA,MAAMA,WAAW,GAAIC,SAAD,IAAqD;EACvE,QAAQA,SAAR;IACE,KAAK,UAAL;MACE,OAAO,OAAP;;IACF,KAAK,UAAL;MACE,OAAO,UAAP;;IACF;MACE,OAAOA,SAAP;EANJ;AAQD,CATD;;AAWA,MAAMC,gBAAgB,GAAG,CAACC,OAAkC,GAAG,EAAtC,KACvBA,OAAO,CAACC,GAAR,CAAY,CAACC,MAAD,EAASC,KAAT,MAAoB;EAC9BC,GAAG,EAAG,GAAED,KAAM,EADgB;EAE9BE,KAAK,EAAEH,MAAM,CAACI,KAFgB;EAG9BC,KAAK,EAAEL,MAAM,CAACI,KAHgB;EAI9BE,OAAO,EAAE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IACvBe,WAAW,CAACJ,QAAZ,GAAuBA,QAAvB;EACD;;EAED,IAAIX,IAAI,KAAK,QAAb,EAAuB;IACrBe,WAAW,CAACH,cAAZ,GAA6BA,cAA7B;IACAG,WAAW,CAACG,GAAZ,GAAkBL,QAAQ,GAAGM,MAAM,CAACC,QAAP,CAAgBP,QAAQ,CAACQ,KAAT,CAAe,GAAf,EAAoB,CAApB,CAAhB,CAAH,GAA6C,CAAvE;IACAN,WAAW,CAACO,GAAZ,GAAkBR,QAAQ,GAAGK,MAAM,CAACC,QAAP,CAAgBN,QAAQ,CAACO,KAAT,CAAe,GAAf,EAAoB,CAApB,CAAhB,CAAH,GAA6C,CAAvE;IACAN,WAAW,CAACtB,KAAZ,GAAoBD,KAAK,GAAG2B,MAAM,CAACC,QAAP,CAAgB5B,KAAK,CAAC6B,KAAN,CAAY,GAAZ,EAAiB,CAAjB,CAAhB,CAAH,GAA0C,CAAnE;IACAN,WAAW,CAACQ,IAAZ,GAAmBV,QAAQ,GAAGA,QAAQ,CAACQ,KAAT,CAAe,GAAf,EAAoB,CAApB,CAAH,GAA4B,EAAvD;EACD;;EAED,oBAAO,6BAAC,cAAD,EAAYN,WAAZ,CAAP;AACD,CA9BD;;eAgCeP,M"}
1
+ {"version":3,"file":"index.native.js","names":["convertType","modelType","convertToChoices","answers","map","answer","index","_id","label","title","value","onPress","onClick","onChange","selected","media","image","type","src","url","undefined","name","items","options","text","Answer","props","model","template","onSliderChange","minLabel","maxLabel","switchProps","onInputValueChange","choices","min","Number","parseInt","split","max","unit"],"sources":["../../../src/molecule/answer/index.native.tsx"],"sourcesContent":["import React from 'react';\nimport {Choice, QuestionType} from '../questions/types';\nimport Switch, {Props as SwitchProps} from '../questions/mobile/switch/index.native';\nimport {AnswerProps} from './prop-types';\n\nconst convertType = (modelType: AnswerProps['model']['type']): QuestionType => {\n switch (modelType) {\n case 'freeText':\n return 'basic';\n case 'dropDown':\n return 'template';\n default:\n return modelType;\n }\n};\n\nconst convertToChoices = (answers: AnswerProps['model']['answers'] = []): Choice[] =>\n answers.map((answer, index) => ({\n _id: `${index}`,\n label: answer.title,\n value: answer.title,\n onPress: answer.onClick || answer.onChange,\n selected: answer.selected,\n media: answer.image\n ? {\n type: 'img',\n src: [{url: answer.image}]\n }\n : undefined,\n // ---- custom properties for template choice\n type: answer.type,\n name: answer.name,\n items:\n answer.options &&\n answer.options.map(({name, selected, value}) => ({\n text: name,\n selected,\n value,\n _id: name\n }))\n }));\n\nconst Answer = (props: AnswerProps) => {\n const {\n model: {answers, onChange, template, type, onSliderChange, minLabel, maxLabel, title}\n } = props;\n\n const switchProps: SwitchProps = {\n type: convertType(type)\n };\n\n if (type === 'freeText') {\n switchProps.onInputValueChange = onChange;\n }\n\n if (type === 'qcm' || type === 'qcmDrag' || type === 'qcmGraphic' || type === 'template') {\n switchProps.choices = convertToChoices(answers);\n }\n\n if (type === 'template') {\n switchProps.template = template;\n }\n\n if (type === 'slider') {\n switchProps.onSliderChange = onSliderChange;\n switchProps.min = minLabel ? Number.parseInt(minLabel.split(' ')[0]) : 0;\n switchProps.max = maxLabel ? Number.parseInt(maxLabel.split(' ')[0]) : 1;\n switchProps.value = title ? Number.parseInt(title.split(' ')[0]) : 0;\n switchProps.unit = minLabel ? minLabel.split(' ')[1] : '';\n }\n\n return <Switch {...switchProps} />;\n};\n\nexport default Answer;\n"],"mappings":";;;;;AAAA;;AAEA;;;;AAGA,MAAMA,WAAW,GAAIC,SAAD,IAA2D;EAC7E,QAAQA,SAAR;IACE,KAAK,UAAL;MACE,OAAO,OAAP;;IACF,KAAK,UAAL;MACE,OAAO,UAAP;;IACF;MACE,OAAOA,SAAP;EANJ;AAQD,CATD;;AAWA,MAAMC,gBAAgB,GAAG,CAACC,OAAwC,GAAG,EAA5C,KACvBA,OAAO,CAACC,GAAR,CAAY,CAACC,MAAD,EAASC,KAAT,MAAoB;EAC9BC,GAAG,EAAG,GAAED,KAAM,EADgB;EAE9BE,KAAK,EAAEH,MAAM,CAACI,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