@coorpacademy/components 10.4.3 → 10.4.4

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 (1022) hide show
  1. package/es/atom/autocomplete/test/fixtures/error.js +1 -1
  2. package/es/atom/autocomplete/test/fixtures/error.js.map +1 -1
  3. package/es/atom/autocomplete/test/fixtures/filled.js +1 -1
  4. package/es/atom/autocomplete/test/fixtures/filled.js.map +1 -1
  5. package/es/atom/autocomplete/test/fixtures/modified.js +1 -1
  6. package/es/atom/autocomplete/test/fixtures/modified.js.map +1 -1
  7. package/es/atom/card-image-preview/index.js +35 -0
  8. package/es/atom/card-image-preview/index.js.map +1 -0
  9. package/es/atom/card-image-preview/style.css +34 -0
  10. package/es/atom/card-image-preview/test/fixtures/default.js +6 -0
  11. package/es/atom/card-image-preview/test/fixtures/default.js.map +1 -0
  12. package/es/atom/card-image-preview/test/fixtures/empty.js +4 -0
  13. package/es/atom/card-image-preview/test/fixtures/empty.js.map +1 -0
  14. package/es/atom/clue/index.js.map +1 -1
  15. package/es/atom/cta/test/fixtures/certification.js +1 -1
  16. package/es/atom/cta/test/fixtures/certification.js.map +1 -1
  17. package/es/atom/cta/test/fixtures/disabled.js +1 -1
  18. package/es/atom/cta/test/fixtures/disabled.js.map +1 -1
  19. package/es/atom/cta/test/fixtures/light-small.js +1 -1
  20. package/es/atom/cta/test/fixtures/light-small.js.map +1 -1
  21. package/es/atom/cta/test/fixtures/light.js +1 -1
  22. package/es/atom/cta/test/fixtures/light.js.map +1 -1
  23. package/es/atom/cta/test/fixtures/logout.js +1 -1
  24. package/es/atom/cta/test/fixtures/logout.js.map +1 -1
  25. package/es/atom/cta/test/fixtures/primary-small.js +1 -1
  26. package/es/atom/cta/test/fixtures/primary-small.js.map +1 -1
  27. package/es/atom/cta/test/fixtures/rectangular-secondary-fullwidth.js +1 -1
  28. package/es/atom/cta/test/fixtures/rectangular-secondary-fullwidth.js.map +1 -1
  29. package/es/atom/cta/test/fixtures/rectangular-secondary.js +1 -1
  30. package/es/atom/cta/test/fixtures/rectangular-secondary.js.map +1 -1
  31. package/es/atom/cta/test/fixtures/rectangular.js +1 -1
  32. package/es/atom/cta/test/fixtures/rectangular.js.map +1 -1
  33. package/es/atom/cta/test/fixtures/secondary-small.js +1 -1
  34. package/es/atom/cta/test/fixtures/secondary-small.js.map +1 -1
  35. package/es/atom/cta/test/fixtures/secondary.js +1 -1
  36. package/es/atom/cta/test/fixtures/secondary.js.map +1 -1
  37. package/es/atom/drag-and-drop/index.js +1 -1
  38. package/es/atom/drag-and-drop/index.js.map +1 -1
  39. package/es/atom/drag-and-drop/test/fixtures/loading.js +1 -1
  40. package/es/atom/drag-and-drop/test/fixtures/loading.js.map +1 -1
  41. package/es/atom/drag-and-drop/test/fixtures/with-image-reset.js +1 -1
  42. package/es/atom/drag-and-drop/test/fixtures/with-image-reset.js.map +1 -1
  43. package/es/atom/image-upload/index.js +1 -1
  44. package/es/atom/image-upload/index.js.map +1 -1
  45. package/es/atom/image-upload/test/fixtures/desktop-reset-description-multiple.js +1 -1
  46. package/es/atom/image-upload/test/fixtures/desktop-reset-description-multiple.js.map +1 -1
  47. package/es/atom/image-upload/test/fixtures/desktop-reset-description-only-png.js +1 -1
  48. package/es/atom/image-upload/test/fixtures/desktop-reset-description-only-png.js.map +1 -1
  49. package/es/atom/image-upload/test/fixtures/desktop-reset-description.js +1 -1
  50. package/es/atom/image-upload/test/fixtures/desktop-reset-description.js.map +1 -1
  51. package/es/atom/image-upload/test/fixtures/desktop-reset-no-description.js +1 -1
  52. package/es/atom/image-upload/test/fixtures/desktop-reset-no-description.js.map +1 -1
  53. package/es/atom/image-upload/test/fixtures/email.js +1 -1
  54. package/es/atom/image-upload/test/fixtures/email.js.map +1 -1
  55. package/es/atom/image-upload/test/fixtures/mobile.js +1 -1
  56. package/es/atom/image-upload/test/fixtures/mobile.js.map +1 -1
  57. package/es/atom/image-upload/test/fixtures/modified.js +1 -1
  58. package/es/atom/image-upload/test/fixtures/modified.js.map +1 -1
  59. package/es/atom/input-html/index.js.map +1 -1
  60. package/es/atom/input-switch/test/fixtures/disabled.js +1 -1
  61. package/es/atom/input-switch/test/fixtures/disabled.js.map +1 -1
  62. package/es/atom/link/index.js +2 -3
  63. package/es/atom/link/index.js.map +1 -1
  64. package/es/atom/loader/test/fixtures.js +2 -0
  65. package/es/atom/loader/test/fixtures.js.map +1 -1
  66. package/es/atom/promo-code/index.js.map +1 -1
  67. package/es/atom/provider/index.js.map +1 -1
  68. package/es/atom/provider/test/index.js +1 -1
  69. package/es/atom/provider/test/index.js.map +1 -1
  70. package/es/atom/range/index.js +1 -1
  71. package/es/atom/range/index.js.map +1 -1
  72. package/es/atom/range/test/fixtures/multi.js +1 -1
  73. package/es/atom/range/test/fixtures/multi.js.map +1 -1
  74. package/es/atom/range/test/index.js +9 -9
  75. package/es/atom/range/test/index.js.map +1 -1
  76. package/es/atom/video-upload/index.js +1 -1
  77. package/es/atom/video-upload/index.js.map +1 -1
  78. package/es/atom/video-upload/test/fixtures/loading.js +1 -1
  79. package/es/atom/video-upload/test/fixtures/loading.js.map +1 -1
  80. package/es/atom/video-upload/test/fixtures/modified.js +1 -1
  81. package/es/atom/video-upload/test/fixtures/modified.js.map +1 -1
  82. package/es/hoc/animation-scheduler/index.js +3 -3
  83. package/es/hoc/animation-scheduler/index.js.map +1 -1
  84. package/es/hoc/swapper/index.js +2 -4
  85. package/es/hoc/swapper/index.js.map +1 -1
  86. package/es/hoc/transition/index.js +1 -1
  87. package/es/hoc/transition/index.js.map +1 -1
  88. package/es/molecule/add-to-my-list/index.js +1 -1
  89. package/es/molecule/add-to-my-list/index.js.map +1 -1
  90. package/es/molecule/answer/index.js +2 -3
  91. package/es/molecule/answer/index.js.map +1 -1
  92. package/es/molecule/answer/test/fixtures/audio.js +1 -1
  93. package/es/molecule/answer/test/fixtures/audio.js.map +1 -1
  94. package/es/molecule/answer/test/fixtures/default.js +1 -1
  95. package/es/molecule/answer/test/fixtures/default.js.map +1 -1
  96. package/es/molecule/answer/test/fixtures/drop-down.js +1 -1
  97. package/es/molecule/answer/test/fixtures/drop-down.js.map +1 -1
  98. package/es/molecule/answer/test/fixtures/qcm-arabic.js +1 -1
  99. package/es/molecule/answer/test/fixtures/qcm-arabic.js.map +1 -1
  100. package/es/molecule/answer/test/fixtures/qcm-drag.js +1 -1
  101. package/es/molecule/answer/test/fixtures/qcm-drag.js.map +1 -1
  102. package/es/molecule/answer/test/fixtures/qcm-graphic.js +1 -1
  103. package/es/molecule/answer/test/fixtures/qcm-graphic.js.map +1 -1
  104. package/es/molecule/answer/test/fixtures/qcm-short-audio.js +1 -1
  105. package/es/molecule/answer/test/fixtures/qcm-short-audio.js.map +1 -1
  106. package/es/molecule/answer/test/fixtures/qcm-short-video.js +1 -1
  107. package/es/molecule/answer/test/fixtures/qcm-short-video.js.map +1 -1
  108. package/es/molecule/answer/test/fixtures/qcm-short.js +1 -1
  109. package/es/molecule/answer/test/fixtures/qcm-short.js.map +1 -1
  110. package/es/molecule/answer/test/fixtures/qcm.js +1 -1
  111. package/es/molecule/answer/test/fixtures/qcm.js.map +1 -1
  112. package/es/molecule/answer/test/fixtures/range.js +1 -1
  113. package/es/molecule/answer/test/fixtures/range.js.map +1 -1
  114. package/es/molecule/answer/test/fixtures/template.js +1 -1
  115. package/es/molecule/answer/test/fixtures/template.js.map +1 -1
  116. package/es/molecule/brand-form-group/index.js +18 -18
  117. package/es/molecule/brand-form-group/index.js.map +1 -1
  118. package/es/molecule/brand-form-group/test/fixtures/analytics.js +1 -1
  119. package/es/molecule/brand-form-group/test/fixtures/analytics.js.map +1 -1
  120. package/es/molecule/brand-form-group/test/fixtures/animations.js +2 -2
  121. package/es/molecule/brand-form-group/test/fixtures/animations.js.map +1 -1
  122. package/es/molecule/brand-form-group/test/fixtures/cohort.js +1 -1
  123. package/es/molecule/brand-form-group/test/fixtures/cohort.js.map +1 -1
  124. package/es/molecule/brand-form-group/test/fixtures/dashboard.js +1 -1
  125. package/es/molecule/brand-form-group/test/fixtures/dashboard.js.map +1 -1
  126. package/es/molecule/brand-form-group/test/fixtures/images.js +3 -3
  127. package/es/molecule/brand-form-group/test/fixtures/images.js.map +1 -1
  128. package/es/molecule/brand-form-group/test/fixtures/slider.js +1 -1
  129. package/es/molecule/brand-form-group/test/fixtures/slider.js.map +1 -1
  130. package/es/molecule/card/index.js +1 -1
  131. package/es/molecule/card/index.js.map +1 -1
  132. package/es/molecule/card/test/fixtures/adaptiv-and-disabled.js +1 -1
  133. package/es/molecule/card/test/fixtures/adaptiv-and-disabled.js.map +1 -1
  134. package/es/molecule/card/test/fixtures/adaptiv.js +1 -1
  135. package/es/molecule/card/test/fixtures/adaptiv.js.map +1 -1
  136. package/es/molecule/card/test/fixtures/disabled.js +1 -1
  137. package/es/molecule/card/test/fixtures/disabled.js.map +1 -1
  138. package/es/molecule/card/test/fixtures.js +2 -0
  139. package/es/molecule/card/test/fixtures.js.map +1 -1
  140. package/es/molecule/card-content/test/fixtures/adaptiv-and-disabled.js +1 -1
  141. package/es/molecule/card-content/test/fixtures/adaptiv-and-disabled.js.map +1 -1
  142. package/es/molecule/card-content/test/fixtures/adaptiv.js +1 -1
  143. package/es/molecule/card-content/test/fixtures/adaptiv.js.map +1 -1
  144. package/es/molecule/card-content/test/fixtures/disabled.js +1 -1
  145. package/es/molecule/card-content/test/fixtures/disabled.js.map +1 -1
  146. package/es/molecule/card-with-button/index.js.map +1 -1
  147. package/es/molecule/cockpit-popin/test/fixtures.js +17 -0
  148. package/es/molecule/cockpit-popin/test/fixtures.js.map +1 -0
  149. package/es/molecule/coorp-manager-roles/index.js +1 -1
  150. package/es/molecule/coorp-manager-roles/index.js.map +1 -1
  151. package/es/molecule/dashboard/battle-request-list/index.js +1 -1
  152. package/es/molecule/dashboard/battle-request-list/index.js.map +1 -1
  153. package/es/molecule/dashboard/cards-list/test/fixtures/microlearning.js +1 -1
  154. package/es/molecule/dashboard/cards-list/test/fixtures/microlearning.js.map +1 -1
  155. package/es/molecule/dashboard/cards-list/test/fixtures/performance.js +1 -1
  156. package/es/molecule/dashboard/cards-list/test/fixtures/performance.js.map +1 -1
  157. package/es/molecule/dashboard/cards-list/test/index.js +1 -1
  158. package/es/molecule/dashboard/cards-list/test/index.js.map +1 -1
  159. package/es/molecule/dashboard/news-list/index.js +1 -1
  160. package/es/molecule/dashboard/news-list/index.js.map +1 -1
  161. package/es/molecule/dashboard/start-battle/index.js +1 -1
  162. package/es/molecule/dashboard/start-battle/index.js.map +1 -1
  163. package/es/molecule/discipline-header/test/fixtures/long-description.js.map +1 -1
  164. package/es/molecule/drag-and-drop/index.js +1 -1
  165. package/es/molecule/drag-and-drop/index.js.map +1 -1
  166. package/es/molecule/drag-and-drop/test/fixtures/error.js +1 -1
  167. package/es/molecule/drag-and-drop/test/fixtures/error.js.map +1 -1
  168. package/es/molecule/drag-and-drop/test/fixtures/loading.js +1 -1
  169. package/es/molecule/drag-and-drop/test/fixtures/loading.js.map +1 -1
  170. package/es/molecule/drag-and-drop/test/fixtures/ready-invalid.js +1 -1
  171. package/es/molecule/drag-and-drop/test/fixtures/ready-invalid.js.map +1 -1
  172. package/es/molecule/drag-and-drop/test/fixtures/ready.js +1 -1
  173. package/es/molecule/drag-and-drop/test/fixtures/ready.js.map +1 -1
  174. package/es/molecule/drag-and-drop/test/fixtures/success-video.js +1 -1
  175. package/es/molecule/drag-and-drop/test/fixtures/success-video.js.map +1 -1
  176. package/es/molecule/drag-and-drop/test/fixtures/success.js +1 -1
  177. package/es/molecule/drag-and-drop/test/fixtures/success.js.map +1 -1
  178. package/es/molecule/drag-and-drop/test/on-click.js +2 -2
  179. package/es/molecule/drag-and-drop/test/on-click.js.map +1 -1
  180. package/es/molecule/drag-and-drop/upload-report.js +1 -1
  181. package/es/molecule/drag-and-drop/upload-report.js.map +1 -1
  182. package/es/molecule/feedback/index.js +1 -1
  183. package/es/molecule/feedback/index.js.map +1 -1
  184. package/es/molecule/filters/test/fixtures/default.js +4 -4
  185. package/es/molecule/filters/test/fixtures/default.js.map +1 -1
  186. package/es/molecule/filters/test/fixtures/filters-list.js +6 -6
  187. package/es/molecule/filters/test/fixtures/filters-list.js.map +1 -1
  188. package/es/molecule/filters/test/fixtures/one.js +2 -2
  189. package/es/molecule/filters/test/fixtures/one.js.map +1 -1
  190. package/es/molecule/filters/test/fixtures/only-radio-group.js +1 -1
  191. package/es/molecule/filters/test/fixtures/only-radio-group.js.map +1 -1
  192. package/es/molecule/filters/test/fixtures/only-timer.js +1 -1
  193. package/es/molecule/filters/test/fixtures/only-timer.js.map +1 -1
  194. package/es/molecule/filters/test/fixtures/three.js +3 -3
  195. package/es/molecule/filters/test/fixtures/three.js.map +1 -1
  196. package/es/molecule/filters/test/fixtures/two.js +3 -3
  197. package/es/molecule/filters/test/fixtures/two.js.map +1 -1
  198. package/es/molecule/filters/test/fixtures/zero.js +1 -1
  199. package/es/molecule/filters/test/fixtures/zero.js.map +1 -1
  200. package/es/molecule/forum/forum-thread/test/fixtures/deep-answers.js +4 -4
  201. package/es/molecule/forum/forum-thread/test/fixtures/deep-answers.js.map +1 -1
  202. package/es/molecule/forum/forum-thread/test/fixtures/with-answers.js +1 -1
  203. package/es/molecule/forum/forum-thread/test/fixtures/with-answers.js.map +1 -1
  204. package/es/molecule/hero/test/fixtures/arabic.js +1 -1
  205. package/es/molecule/hero/test/fixtures/arabic.js.map +1 -1
  206. package/es/molecule/hero/test/fixtures/hero.js +1 -1
  207. package/es/molecule/hero/test/fixtures/hero.js.map +1 -1
  208. package/es/molecule/news/test/fixtures/long-description.js +1 -1
  209. package/es/molecule/news/test/fixtures/long-description.js.map +1 -1
  210. package/es/molecule/news/test/fixtures/long-title.js +1 -1
  211. package/es/molecule/news/test/fixtures/long-title.js.map +1 -1
  212. package/es/molecule/news/test/fixtures/small-desciption.js +1 -1
  213. package/es/molecule/news/test/fixtures/small-desciption.js.map +1 -1
  214. package/es/molecule/news/test/fixtures/small-title.js +1 -1
  215. package/es/molecule/news/test/fixtures/small-title.js.map +1 -1
  216. package/es/molecule/popin/index.js +1 -1
  217. package/es/molecule/popin/index.js.map +1 -1
  218. package/es/molecule/progress-bar/index.js +1 -1
  219. package/es/molecule/progress-bar/index.js.map +1 -1
  220. package/es/molecule/questions/drop-down/index.js +1 -1
  221. package/es/molecule/questions/drop-down/index.js.map +1 -1
  222. package/es/molecule/questions/question-range/index.js +2 -3
  223. package/es/molecule/questions/question-range/index.js.map +1 -1
  224. package/es/molecule/questions/template/index.js +2 -2
  225. package/es/molecule/questions/template/index.js.map +1 -1
  226. package/es/molecule/questions/template/test/index.js +1 -1
  227. package/es/molecule/questions/template/test/index.js.map +1 -1
  228. package/es/molecule/quick-access-card/index.js.map +1 -1
  229. package/es/molecule/resource-player/index.js +1 -2
  230. package/es/molecule/resource-player/index.js.map +1 -1
  231. package/es/molecule/select-multiple/index.js +3 -3
  232. package/es/molecule/select-multiple/index.js.map +1 -1
  233. package/es/molecule/select-multiple/test/index.js +2 -2
  234. package/es/molecule/select-multiple/test/index.js.map +1 -1
  235. package/es/molecule/setup-section/index.js +1 -1
  236. package/es/molecule/setup-section/index.js.map +1 -1
  237. package/es/molecule/setup-section/test/fixtures/first.js +1 -1
  238. package/es/molecule/setup-section/test/fixtures/first.js.map +1 -1
  239. package/es/molecule/setup-slide/index.js +8 -8
  240. package/es/molecule/setup-slide/index.js.map +1 -1
  241. package/es/molecule/share/index.js +1 -1
  242. package/es/molecule/share/index.js.map +1 -1
  243. package/es/molecule/vertical-tabs/test/fixtures.js +2 -0
  244. package/es/molecule/vertical-tabs/test/fixtures.js.map +1 -1
  245. package/es/molecule/video-iframe/index.js +1 -1
  246. package/es/molecule/video-iframe/index.js.map +1 -1
  247. package/es/molecule/video-player/index.js +1 -3
  248. package/es/molecule/video-player/index.js.map +1 -1
  249. package/es/molecule/video-player/jwplayer.js +2 -2
  250. package/es/molecule/video-player/jwplayer.js.map +1 -1
  251. package/es/molecule/video-player/test/fixtures/youtube.js +1 -1
  252. package/es/molecule/video-player/test/fixtures/youtube.js.map +1 -1
  253. package/es/molecule/video-player/vimeo.js +1 -1
  254. package/es/molecule/video-player/vimeo.js.map +1 -1
  255. package/es/organism/accordion/coorp-manager/index.js +1 -1
  256. package/es/organism/accordion/coorp-manager/index.js.map +1 -1
  257. package/es/organism/accordion/toggler/index.js +1 -1
  258. package/es/organism/accordion/toggler/index.js.map +1 -1
  259. package/es/organism/accordion/toggler/test/render.js +2 -2
  260. package/es/organism/accordion/toggler/test/render.js.map +1 -1
  261. package/es/organism/brand-form/test/fixtures/sso.js +3 -3
  262. package/es/organism/brand-form/test/fixtures/sso.js.map +1 -1
  263. package/es/organism/content-translation/index.js +2 -2
  264. package/es/organism/content-translation/index.js.map +1 -1
  265. package/es/organism/content-translation/test/fixtures/default.js +2 -2
  266. package/es/organism/content-translation/test/fixtures/default.js.map +1 -1
  267. package/es/organism/course-selection/test/fixtures/default.js +8 -8
  268. package/es/organism/course-selection/test/fixtures/default.js.map +1 -1
  269. package/es/organism/course-selection/test/fixtures/filtered.js +2 -2
  270. package/es/organism/course-selection/test/fixtures/filtered.js.map +1 -1
  271. package/es/organism/course-selection/test/fixtures/sorted-selected.js +5 -5
  272. package/es/organism/course-selection/test/fixtures/sorted-selected.js.map +1 -1
  273. package/es/organism/course-selection/test/fixtures/unsorted-selected.js +5 -5
  274. package/es/organism/course-selection/test/fixtures/unsorted-selected.js.map +1 -1
  275. package/es/organism/discussion/test/fixtures/default.js +1 -1
  276. package/es/organism/discussion/test/fixtures/default.js.map +1 -1
  277. package/es/organism/discussion/test/fixtures/loading-more.js +1 -1
  278. package/es/organism/discussion/test/fixtures/loading-more.js.map +1 -1
  279. package/es/organism/discussion/test/fixtures/new-discussion.js +1 -1
  280. package/es/organism/discussion/test/fixtures/new-discussion.js.map +1 -1
  281. package/es/organism/get-the-app/index.js +2 -2
  282. package/es/organism/get-the-app/index.js.map +1 -1
  283. package/es/organism/list-items/test/fixtures/archived.js +1 -1
  284. package/es/organism/list-items/test/fixtures/archived.js.map +1 -1
  285. package/es/organism/list-items/test/fixtures/draft.js +1 -1
  286. package/es/organism/list-items/test/fixtures/draft.js.map +1 -1
  287. package/es/organism/list-items/test/fixtures/published.js +1 -1
  288. package/es/organism/list-items/test/fixtures/published.js.map +1 -1
  289. package/es/organism/mooc/image-slider/test/fixtures/multiple-slides.js +2 -2
  290. package/es/organism/mooc/image-slider/test/fixtures/multiple-slides.js.map +1 -1
  291. package/es/organism/mooc-header/test/fixtures/default.js +1 -1
  292. package/es/organism/mooc-header/test/fixtures/default.js.map +1 -1
  293. package/es/organism/mooc-header/test/fixtures/logged-with-battle-notifications.js +1 -1
  294. package/es/organism/mooc-header/test/fixtures/logged-with-battle-notifications.js.map +1 -1
  295. package/es/organism/popin/test/fixtures/default.js.map +1 -1
  296. package/es/organism/resource-browser/test/fixtures/jwplayer-with-overlay.js +1 -1
  297. package/es/organism/resource-browser/test/fixtures/jwplayer-with-overlay.js.map +1 -1
  298. package/es/organism/resource-browser/test/fixtures/jwplayer.js +1 -1
  299. package/es/organism/resource-browser/test/fixtures/jwplayer.js.map +1 -1
  300. package/es/organism/resource-browser/test/fixtures/kontiki.js +1 -1
  301. package/es/organism/resource-browser/test/fixtures/kontiki.js.map +1 -1
  302. package/es/organism/resource-browser/test/fixtures/mp4.js +1 -1
  303. package/es/organism/resource-browser/test/fixtures/mp4.js.map +1 -1
  304. package/es/organism/settings/index.js +2 -3
  305. package/es/organism/settings/index.js.map +1 -1
  306. package/es/organism/setup-header/index.js +6 -17
  307. package/es/organism/setup-header/index.js.map +1 -1
  308. package/es/organism/setup-header/test/fixtures/default.js +4 -1
  309. package/es/organism/setup-header/test/fixtures/default.js.map +1 -1
  310. package/es/organism/sidebar/index.js +10 -11
  311. package/es/organism/sidebar/index.js.map +1 -1
  312. package/es/organism/user-preferences/index.js +2 -3
  313. package/es/organism/user-preferences/index.js.map +1 -1
  314. package/es/organism/wizard-contents/index.js +5 -5
  315. package/es/organism/wizard-contents/index.js.map +1 -1
  316. package/es/organism/wizard-contents/test/fixtures/playlist-add-courses-create.js +1 -1
  317. package/es/organism/wizard-contents/test/fixtures/playlist-add-courses-create.js.map +1 -1
  318. package/es/organism/wizard-contents/test/fixtures/playlist-general-settings-create.js +1 -1
  319. package/es/organism/wizard-contents/test/fixtures/playlist-general-settings-create.js.map +1 -1
  320. package/es/organism/wizard-contents/test/fixtures/playlist-general-settings-edit.js +1 -1
  321. package/es/organism/wizard-contents/test/fixtures/playlist-general-settings-edit.js.map +1 -1
  322. package/es/organism/wizard-contents/test/fixtures/playlist-populations-create.js +1 -1
  323. package/es/organism/wizard-contents/test/fixtures/playlist-populations-create.js.map +1 -1
  324. package/es/organism/wizard-contents/test/fixtures/playlist-translate-edit.js +1 -1
  325. package/es/organism/wizard-contents/test/fixtures/playlist-translate-edit.js.map +1 -1
  326. package/es/template/activity/index.js +1 -1
  327. package/es/template/activity/index.js.map +1 -1
  328. package/es/template/activity/test/progression-item-test.js +1 -1
  329. package/es/template/activity/test/progression-item-test.js.map +1 -1
  330. package/es/template/app-player/player/slides/footer/index.js +1 -1
  331. package/es/template/app-player/player/slides/footer/index.js.map +1 -1
  332. package/es/template/app-player/player/slides/index.js +11 -14
  333. package/es/template/app-player/player/slides/index.js.map +1 -1
  334. package/es/template/app-player/player/slides/test/fixtures/arabic-context.js +2 -2
  335. package/es/template/app-player/player/slides/test/fixtures/arabic-context.js.map +1 -1
  336. package/es/template/app-player/player/slides/test/fixtures/arabic-qcm.js +1 -1
  337. package/es/template/app-player/player/slides/test/fixtures/arabic-qcm.js.map +1 -1
  338. package/es/template/app-player/player/slides/test/fixtures/arabic-resources.js +2 -2
  339. package/es/template/app-player/player/slides/test/fixtures/arabic-resources.js.map +1 -1
  340. package/es/template/app-player/player/slides/test/fixtures/arabic.js +2 -2
  341. package/es/template/app-player/player/slides/test/fixtures/arabic.js.map +1 -1
  342. package/es/template/app-player/player/slides/test/fixtures/clue.js +2 -2
  343. package/es/template/app-player/player/slides/test/fixtures/clue.js.map +1 -1
  344. package/es/template/app-player/player/slides/test/fixtures/context-with-audio.js +2 -2
  345. package/es/template/app-player/player/slides/test/fixtures/context-with-audio.js.map +1 -1
  346. package/es/template/app-player/player/slides/test/fixtures/context-with-image.js +2 -2
  347. package/es/template/app-player/player/slides/test/fixtures/context-with-image.js.map +1 -1
  348. package/es/template/app-player/player/slides/test/fixtures/context-with-pdf.js +2 -2
  349. package/es/template/app-player/player/slides/test/fixtures/context-with-pdf.js.map +1 -1
  350. package/es/template/app-player/player/slides/test/fixtures/context-with-video.js +2 -2
  351. package/es/template/app-player/player/slides/test/fixtures/context-with-video.js.map +1 -1
  352. package/es/template/app-player/player/slides/test/fixtures/context.js +2 -2
  353. package/es/template/app-player/player/slides/test/fixtures/context.js.map +1 -1
  354. package/es/template/app-player/player/slides/test/fixtures/default.js +2 -2
  355. package/es/template/app-player/player/slides/test/fixtures/default.js.map +1 -1
  356. package/es/template/app-player/player/slides/test/fixtures/drop-down.js +1 -1
  357. package/es/template/app-player/player/slides/test/fixtures/drop-down.js.map +1 -1
  358. package/es/template/app-player/player/slides/test/fixtures/free-text.js +1 -1
  359. package/es/template/app-player/player/slides/test/fixtures/free-text.js.map +1 -1
  360. package/es/template/app-player/player/slides/test/fixtures/media-h5p.js +2 -2
  361. package/es/template/app-player/player/slides/test/fixtures/media-h5p.js.map +1 -1
  362. package/es/template/app-player/player/slides/test/fixtures/media-omni-player.js +2 -2
  363. package/es/template/app-player/player/slides/test/fixtures/media-omni-player.js.map +1 -1
  364. package/es/template/app-player/player/slides/test/fixtures/media.js +2 -2
  365. package/es/template/app-player/player/slides/test/fixtures/media.js.map +1 -1
  366. package/es/template/app-player/player/slides/test/fixtures/no-clue.js +2 -2
  367. package/es/template/app-player/player/slides/test/fixtures/no-clue.js.map +1 -1
  368. package/es/template/app-player/player/slides/test/fixtures/no-question.js +2 -2
  369. package/es/template/app-player/player/slides/test/fixtures/no-question.js.map +1 -1
  370. package/es/template/app-player/player/slides/test/fixtures/no-total.js +1 -1
  371. package/es/template/app-player/player/slides/test/fixtures/no-total.js.map +1 -1
  372. package/es/template/app-player/player/slides/test/fixtures/only-clue.js +2 -2
  373. package/es/template/app-player/player/slides/test/fixtures/only-clue.js.map +1 -1
  374. package/es/template/app-player/player/slides/test/fixtures/qcm-drag.js +1 -1
  375. package/es/template/app-player/player/slides/test/fixtures/qcm-drag.js.map +1 -1
  376. package/es/template/app-player/player/slides/test/fixtures/qcm-graphic.js +1 -1
  377. package/es/template/app-player/player/slides/test/fixtures/qcm-graphic.js.map +1 -1
  378. package/es/template/app-player/player/slides/test/fixtures/qcm-see-lesson-no-step.js +1 -1
  379. package/es/template/app-player/player/slides/test/fixtures/qcm-see-lesson-no-step.js.map +1 -1
  380. package/es/template/app-player/player/slides/test/fixtures/qcm-see-lesson.js +1 -1
  381. package/es/template/app-player/player/slides/test/fixtures/qcm-see-lesson.js.map +1 -1
  382. package/es/template/app-player/player/slides/test/fixtures/qcm-short.js +1 -1
  383. package/es/template/app-player/player/slides/test/fixtures/qcm-short.js.map +1 -1
  384. package/es/template/app-player/player/slides/test/fixtures/qcm-template.js +1 -1
  385. package/es/template/app-player/player/slides/test/fixtures/qcm-template.js.map +1 -1
  386. package/es/template/app-player/player/slides/test/fixtures/qcm-with-review-lesson.js +1 -1
  387. package/es/template/app-player/player/slides/test/fixtures/qcm-with-review-lesson.js.map +1 -1
  388. package/es/template/app-player/player/slides/test/fixtures/qcm.js +1 -1
  389. package/es/template/app-player/player/slides/test/fixtures/qcm.js.map +1 -1
  390. package/es/template/app-player/player/slides/test/fixtures/range.js +1 -1
  391. package/es/template/app-player/player/slides/test/fixtures/range.js.map +1 -1
  392. package/es/template/app-player/player/slides/test/fixtures/template.js +1 -1
  393. package/es/template/app-player/player/slides/test/fixtures/template.js.map +1 -1
  394. package/es/template/app-player/player/slides/test/fixtures/with-min-height.js +1 -1
  395. package/es/template/app-player/player/slides/test/fixtures/with-min-height.js.map +1 -1
  396. package/es/template/app-player/player/test/fixtures/background.js +1 -1
  397. package/es/template/app-player/player/test/fixtures/background.js.map +1 -1
  398. package/es/template/app-player/popin-correction/index.js +2 -3
  399. package/es/template/app-player/popin-correction/index.js.map +1 -1
  400. package/es/template/app-player/popin-correction/test/fixtures/correct-closed-without-klf-and-tips.js +1 -1
  401. package/es/template/app-player/popin-correction/test/fixtures/correct-closed-without-klf-and-tips.js.map +1 -1
  402. package/es/template/app-player/popin-correction/test/fixtures/correct-closed.js +1 -1
  403. package/es/template/app-player/popin-correction/test/fixtures/correct-closed.js.map +1 -1
  404. package/es/template/app-player/popin-end/summary.js +7 -11
  405. package/es/template/app-player/popin-end/summary.js.map +1 -1
  406. package/es/template/app-player/popin-end/test/fixtures/adaptive.js +2 -2
  407. package/es/template/app-player/popin-end/test/fixtures/adaptive.js.map +1 -1
  408. package/es/template/app-player/popin-end/test/fixtures/infinite-lives.js +2 -2
  409. package/es/template/app-player/popin-end/test/fixtures/infinite-lives.js.map +1 -1
  410. package/es/template/app-player/popin-header/index.js +3 -4
  411. package/es/template/app-player/popin-header/index.js.map +1 -1
  412. package/es/template/back-office/brand-create/test/fixtures/default.js +1 -1
  413. package/es/template/back-office/brand-create/test/fixtures/default.js.map +1 -1
  414. package/es/template/back-office/brand-create/test/fixtures/loading.js +1 -1
  415. package/es/template/back-office/brand-create/test/fixtures/loading.js.map +1 -1
  416. package/es/template/back-office/brand-create/test/fixtures/modified.js +1 -1
  417. package/es/template/back-office/brand-create/test/fixtures/modified.js.map +1 -1
  418. package/es/template/back-office/brand-list/test/fixtures/default.js +1 -1
  419. package/es/template/back-office/brand-list/test/fixtures/default.js.map +1 -1
  420. package/es/template/back-office/brand-list/test/fixtures/rh.js +1 -1
  421. package/es/template/back-office/brand-list/test/fixtures/rh.js.map +1 -1
  422. package/es/template/back-office/brand-update/index.js +8 -8
  423. package/es/template/back-office/brand-update/index.js.map +1 -1
  424. package/es/template/back-office/brand-update/test/fixtures/list-items-archived.js +1 -1
  425. package/es/template/back-office/brand-update/test/fixtures/list-items-archived.js.map +1 -1
  426. package/es/template/back-office/brand-update/test/fixtures/list-items-draft.js +1 -1
  427. package/es/template/back-office/brand-update/test/fixtures/list-items-draft.js.map +1 -1
  428. package/es/template/back-office/brand-update/test/fixtures/list-items-published-with-popin.js +1 -1
  429. package/es/template/back-office/brand-update/test/fixtures/list-items-published-with-popin.js.map +1 -1
  430. package/es/template/back-office/brand-update/test/fixtures/list-items-published.js +1 -1
  431. package/es/template/back-office/brand-update/test/fixtures/list-items-published.js.map +1 -1
  432. package/es/template/back-office/brand-update/test/fixtures/manageusers-edit.js +1 -1
  433. package/es/template/back-office/brand-update/test/fixtures/manageusers-edit.js.map +1 -1
  434. package/es/template/back-office/brand-update/test/fixtures/quick-access.js +1 -1
  435. package/es/template/back-office/brand-update/test/fixtures/quick-access.js.map +1 -1
  436. package/es/template/back-office/brand-update/test/fixtures/uploadusers-loading.js +1 -1
  437. package/es/template/back-office/brand-update/test/fixtures/uploadusers-loading.js.map +1 -1
  438. package/es/template/back-office/brand-update/test/fixtures/uploadusers-successful.js +1 -1
  439. package/es/template/back-office/brand-update/test/fixtures/uploadusers-successful.js.map +1 -1
  440. package/es/template/back-office/brand-update/test/fixtures/uploadusers.js +1 -1
  441. package/es/template/back-office/brand-update/test/fixtures/uploadusers.js.map +1 -1
  442. package/es/template/back-office/brand-update/test/fixtures/wizard-add-courses-playlist.js +1 -1
  443. package/es/template/back-office/brand-update/test/fixtures/wizard-add-courses-playlist.js.map +1 -1
  444. package/es/template/back-office/brand-update/test/fixtures/wizard-form-create-playlist.js +1 -1
  445. package/es/template/back-office/brand-update/test/fixtures/wizard-form-create-playlist.js.map +1 -1
  446. package/es/template/back-office/brand-update/test/fixtures/wizard-form-edit-playlist.js +1 -1
  447. package/es/template/back-office/brand-update/test/fixtures/wizard-form-edit-playlist.js.map +1 -1
  448. package/es/template/back-office/brand-update/test/fixtures/wizard-populations-playlist-with-popin.js +1 -1
  449. package/es/template/back-office/brand-update/test/fixtures/wizard-populations-playlist-with-popin.js.map +1 -1
  450. package/es/template/back-office/brand-update/test/fixtures/wizard-populations-playlist.js +1 -1
  451. package/es/template/back-office/brand-update/test/fixtures/wizard-populations-playlist.js.map +1 -1
  452. package/es/template/back-office/brand-update/test/fixtures/wizard-translate-playlist.js +1 -1
  453. package/es/template/back-office/brand-update/test/fixtures/wizard-translate-playlist.js.map +1 -1
  454. package/es/template/cockpit/jw-uploader/index.js +1 -1
  455. package/es/template/cockpit/jw-uploader/index.js.map +1 -1
  456. package/es/template/common/dashboard/index.js +1 -1
  457. package/es/template/common/dashboard/index.js.map +1 -1
  458. package/es/template/common/dashboard/test/fixtures/empty-requests.js +1 -1
  459. package/es/template/common/dashboard/test/fixtures/empty-requests.js.map +1 -1
  460. package/es/template/common/dashboard/test/fixtures/with-hero-card.js +1 -1
  461. package/es/template/common/dashboard/test/fixtures/with-hero-card.js.map +1 -1
  462. package/es/template/common/discipline/test/fixtures/add-to-my-list.js +1 -1
  463. package/es/template/common/discipline/test/fixtures/add-to-my-list.js.map +1 -1
  464. package/es/template/common/discipline/test/fixtures/arabic.js +1 -1
  465. package/es/template/common/discipline/test/fixtures/arabic.js.map +1 -1
  466. package/es/template/common/discipline/test/fixtures/default.js +2 -2
  467. package/es/template/common/discipline/test/fixtures/default.js.map +1 -1
  468. package/es/template/common/discipline/test/fixtures/external-course-with-video.js +2 -2
  469. package/es/template/common/discipline/test/fixtures/external-course-with-video.js.map +1 -1
  470. package/es/template/common/discipline/test/fixtures/external-course-without-image.js +2 -2
  471. package/es/template/common/discipline/test/fixtures/external-course-without-image.js.map +1 -1
  472. package/es/template/common/discipline/test/fixtures/external-course.js +2 -2
  473. package/es/template/common/discipline/test/fixtures/external-course.js.map +1 -1
  474. package/es/template/common/discipline/test/fixtures/share.js +1 -1
  475. package/es/template/common/discipline/test/fixtures/share.js.map +1 -1
  476. package/es/template/teams-dashboard/test/fixtures/default.js +1 -1
  477. package/es/template/teams-dashboard/test/fixtures/default.js.map +1 -1
  478. package/es/template/teams-dashboard/test/fixtures/is-loading.js +1 -1
  479. package/es/template/teams-dashboard/test/fixtures/is-loading.js.map +1 -1
  480. package/es/template/teams-dashboard/test/fixtures/mobile.js +1 -1
  481. package/es/template/teams-dashboard/test/fixtures/mobile.js.map +1 -1
  482. package/es/util/shallow-compare.js.map +1 -1
  483. package/es/util/test/navigation.js +3 -4
  484. package/es/util/test/navigation.js.map +1 -1
  485. package/lib/atom/autocomplete/index.js +2 -2
  486. package/lib/atom/autocomplete/test/fixtures/error.js +1 -1
  487. package/lib/atom/autocomplete/test/fixtures/error.js.map +1 -1
  488. package/lib/atom/autocomplete/test/fixtures/filled.js +1 -1
  489. package/lib/atom/autocomplete/test/fixtures/filled.js.map +1 -1
  490. package/lib/atom/autocomplete/test/fixtures/modified.js +1 -1
  491. package/lib/atom/autocomplete/test/fixtures/modified.js.map +1 -1
  492. package/lib/atom/button-link/index.js +2 -2
  493. package/lib/atom/button-link-icon-only/index.js +2 -2
  494. package/lib/atom/button-menu/index.js +2 -2
  495. package/lib/atom/button-menu/test/fixtures/default.js +1 -1
  496. package/lib/atom/button-menu/test/fixtures/multiple-buttons.js +1 -1
  497. package/lib/atom/card-image-preview/index.js +47 -0
  498. package/lib/atom/card-image-preview/index.js.map +1 -0
  499. package/lib/atom/card-image-preview/style.css +34 -0
  500. package/lib/atom/card-image-preview/test/fixtures/default.js +11 -0
  501. package/lib/atom/card-image-preview/test/fixtures/default.js.map +1 -0
  502. package/lib/atom/card-image-preview/test/fixtures/empty.js +9 -0
  503. package/lib/atom/card-image-preview/test/fixtures/empty.js.map +1 -0
  504. package/lib/atom/chips/index.js +2 -2
  505. package/lib/atom/clue/index.js.map +1 -1
  506. package/lib/atom/cta/test/fixtures/certification.js +1 -1
  507. package/lib/atom/cta/test/fixtures/certification.js.map +1 -1
  508. package/lib/atom/cta/test/fixtures/disabled.js +1 -1
  509. package/lib/atom/cta/test/fixtures/disabled.js.map +1 -1
  510. package/lib/atom/cta/test/fixtures/light-small.js +1 -1
  511. package/lib/atom/cta/test/fixtures/light-small.js.map +1 -1
  512. package/lib/atom/cta/test/fixtures/light.js +1 -1
  513. package/lib/atom/cta/test/fixtures/light.js.map +1 -1
  514. package/lib/atom/cta/test/fixtures/logout.js +1 -1
  515. package/lib/atom/cta/test/fixtures/logout.js.map +1 -1
  516. package/lib/atom/cta/test/fixtures/primary-small.js +1 -1
  517. package/lib/atom/cta/test/fixtures/primary-small.js.map +1 -1
  518. package/lib/atom/cta/test/fixtures/rectangular-secondary-fullwidth.js +1 -1
  519. package/lib/atom/cta/test/fixtures/rectangular-secondary-fullwidth.js.map +1 -1
  520. package/lib/atom/cta/test/fixtures/rectangular-secondary.js +1 -1
  521. package/lib/atom/cta/test/fixtures/rectangular-secondary.js.map +1 -1
  522. package/lib/atom/cta/test/fixtures/rectangular.js +1 -1
  523. package/lib/atom/cta/test/fixtures/rectangular.js.map +1 -1
  524. package/lib/atom/cta/test/fixtures/secondary-small.js +1 -1
  525. package/lib/atom/cta/test/fixtures/secondary-small.js.map +1 -1
  526. package/lib/atom/cta/test/fixtures/secondary.js +1 -1
  527. package/lib/atom/cta/test/fixtures/secondary.js.map +1 -1
  528. package/lib/atom/drag-and-drop/index.js +1 -1
  529. package/lib/atom/drag-and-drop/index.js.map +1 -1
  530. package/lib/atom/drag-and-drop/test/fixtures/loading.js +1 -1
  531. package/lib/atom/drag-and-drop/test/fixtures/loading.js.map +1 -1
  532. package/lib/atom/drag-and-drop/test/fixtures/with-image-reset.js +1 -1
  533. package/lib/atom/drag-and-drop/test/fixtures/with-image-reset.js.map +1 -1
  534. package/lib/atom/image-upload/index.js +3 -3
  535. package/lib/atom/image-upload/index.js.map +1 -1
  536. package/lib/atom/image-upload/test/fixtures/desktop-reset-description-multiple.js +1 -1
  537. package/lib/atom/image-upload/test/fixtures/desktop-reset-description-multiple.js.map +1 -1
  538. package/lib/atom/image-upload/test/fixtures/desktop-reset-description-only-png.js +1 -1
  539. package/lib/atom/image-upload/test/fixtures/desktop-reset-description-only-png.js.map +1 -1
  540. package/lib/atom/image-upload/test/fixtures/desktop-reset-description.js +1 -1
  541. package/lib/atom/image-upload/test/fixtures/desktop-reset-description.js.map +1 -1
  542. package/lib/atom/image-upload/test/fixtures/desktop-reset-no-description.js +1 -1
  543. package/lib/atom/image-upload/test/fixtures/desktop-reset-no-description.js.map +1 -1
  544. package/lib/atom/image-upload/test/fixtures/email.js +1 -1
  545. package/lib/atom/image-upload/test/fixtures/email.js.map +1 -1
  546. package/lib/atom/image-upload/test/fixtures/mobile.js +1 -1
  547. package/lib/atom/image-upload/test/fixtures/mobile.js.map +1 -1
  548. package/lib/atom/image-upload/test/fixtures/modified.js +1 -1
  549. package/lib/atom/image-upload/test/fixtures/modified.js.map +1 -1
  550. package/lib/atom/input-checkbox/index.js +2 -2
  551. package/lib/atom/input-color/index.js +2 -2
  552. package/lib/atom/input-doublestep/index.js +2 -2
  553. package/lib/atom/input-html/index.js.map +1 -1
  554. package/lib/atom/input-search/index.js +2 -2
  555. package/lib/atom/input-switch/index.js +2 -2
  556. package/lib/atom/input-switch/test/fixtures/disabled.js +1 -1
  557. package/lib/atom/input-switch/test/fixtures/disabled.js.map +1 -1
  558. package/lib/atom/input-text/index.js +2 -2
  559. package/lib/atom/input-textarea/index.js +2 -2
  560. package/lib/atom/link/index.js +2 -4
  561. package/lib/atom/link/index.js.map +1 -1
  562. package/lib/atom/loader/test/fixtures.js +3 -0
  563. package/lib/atom/loader/test/fixtures.js.map +1 -1
  564. package/lib/atom/promo-code/index.js.map +1 -1
  565. package/lib/atom/provider/index.js.map +1 -1
  566. package/lib/atom/provider/test/index.js +1 -1
  567. package/lib/atom/provider/test/index.js.map +1 -1
  568. package/lib/atom/range/index.js +1 -1
  569. package/lib/atom/range/index.js.map +1 -1
  570. package/lib/atom/range/test/fixtures/multi.js +1 -1
  571. package/lib/atom/range/test/fixtures/multi.js.map +1 -1
  572. package/lib/atom/range/test/index.js +9 -9
  573. package/lib/atom/range/test/index.js.map +1 -1
  574. package/lib/atom/select/index.js +2 -2
  575. package/lib/atom/tab/index.js +2 -2
  576. package/lib/atom/video-upload/index.js +1 -1
  577. package/lib/atom/video-upload/index.js.map +1 -1
  578. package/lib/atom/video-upload/test/fixtures/loading.js +1 -1
  579. package/lib/atom/video-upload/test/fixtures/loading.js.map +1 -1
  580. package/lib/atom/video-upload/test/fixtures/modified.js +1 -1
  581. package/lib/atom/video-upload/test/fixtures/modified.js.map +1 -1
  582. package/lib/hoc/animation/index.js +1 -1
  583. package/lib/hoc/animation/test/on-mount.js +2 -2
  584. package/lib/hoc/animation-scheduler/index.js +4 -4
  585. package/lib/hoc/animation-scheduler/index.js.map +1 -1
  586. package/lib/hoc/animation-scheduler/test/fixtures/parallel.js +3 -3
  587. package/lib/hoc/animation-scheduler/test/fixtures/series.js +2 -2
  588. package/lib/hoc/animation-scheduler/test/on-mount.js +2 -2
  589. package/lib/hoc/swapper/index.js +3 -5
  590. package/lib/hoc/swapper/index.js.map +1 -1
  591. package/lib/hoc/swapper/test/on-mount.js +2 -2
  592. package/lib/hoc/transition/index.js +3 -3
  593. package/lib/hoc/transition/index.js.map +1 -1
  594. package/lib/molecule/add-to-my-list/index.js +4 -4
  595. package/lib/molecule/add-to-my-list/index.js.map +1 -1
  596. package/lib/molecule/answer/index.js +3 -5
  597. package/lib/molecule/answer/index.js.map +1 -1
  598. package/lib/molecule/answer/test/fixtures/audio.js +1 -1
  599. package/lib/molecule/answer/test/fixtures/audio.js.map +1 -1
  600. package/lib/molecule/answer/test/fixtures/default.js +1 -1
  601. package/lib/molecule/answer/test/fixtures/default.js.map +1 -1
  602. package/lib/molecule/answer/test/fixtures/drop-down.js +1 -1
  603. package/lib/molecule/answer/test/fixtures/drop-down.js.map +1 -1
  604. package/lib/molecule/answer/test/fixtures/qcm-arabic.js +1 -1
  605. package/lib/molecule/answer/test/fixtures/qcm-arabic.js.map +1 -1
  606. package/lib/molecule/answer/test/fixtures/qcm-drag.js +1 -1
  607. package/lib/molecule/answer/test/fixtures/qcm-drag.js.map +1 -1
  608. package/lib/molecule/answer/test/fixtures/qcm-graphic.js +1 -1
  609. package/lib/molecule/answer/test/fixtures/qcm-graphic.js.map +1 -1
  610. package/lib/molecule/answer/test/fixtures/qcm-short-audio.js +1 -1
  611. package/lib/molecule/answer/test/fixtures/qcm-short-audio.js.map +1 -1
  612. package/lib/molecule/answer/test/fixtures/qcm-short-video.js +1 -1
  613. package/lib/molecule/answer/test/fixtures/qcm-short-video.js.map +1 -1
  614. package/lib/molecule/answer/test/fixtures/qcm-short.js +1 -1
  615. package/lib/molecule/answer/test/fixtures/qcm-short.js.map +1 -1
  616. package/lib/molecule/answer/test/fixtures/qcm.js +1 -1
  617. package/lib/molecule/answer/test/fixtures/qcm.js.map +1 -1
  618. package/lib/molecule/answer/test/fixtures/range.js +1 -1
  619. package/lib/molecule/answer/test/fixtures/range.js.map +1 -1
  620. package/lib/molecule/answer/test/fixtures/template.js +1 -1
  621. package/lib/molecule/answer/test/fixtures/template.js.map +1 -1
  622. package/lib/molecule/brand-create-form/index.js +2 -2
  623. package/lib/molecule/brand-form-group/index.js +18 -18
  624. package/lib/molecule/brand-form-group/index.js.map +1 -1
  625. package/lib/molecule/brand-form-group/test/fixtures/analytics.js +1 -1
  626. package/lib/molecule/brand-form-group/test/fixtures/analytics.js.map +1 -1
  627. package/lib/molecule/brand-form-group/test/fixtures/animations.js +2 -2
  628. package/lib/molecule/brand-form-group/test/fixtures/animations.js.map +1 -1
  629. package/lib/molecule/brand-form-group/test/fixtures/cohort.js +1 -1
  630. package/lib/molecule/brand-form-group/test/fixtures/cohort.js.map +1 -1
  631. package/lib/molecule/brand-form-group/test/fixtures/dashboard.js +1 -1
  632. package/lib/molecule/brand-form-group/test/fixtures/dashboard.js.map +1 -1
  633. package/lib/molecule/brand-form-group/test/fixtures/images.js +3 -3
  634. package/lib/molecule/brand-form-group/test/fixtures/images.js.map +1 -1
  635. package/lib/molecule/brand-form-group/test/fixtures/slider.js +1 -1
  636. package/lib/molecule/brand-form-group/test/fixtures/slider.js.map +1 -1
  637. package/lib/molecule/bullet-point-menu-button/index.js +2 -2
  638. package/lib/molecule/card/index.js +3 -3
  639. package/lib/molecule/card/index.js.map +1 -1
  640. package/lib/molecule/card/test/fixtures/adaptiv-and-disabled.js +1 -1
  641. package/lib/molecule/card/test/fixtures/adaptiv-and-disabled.js.map +1 -1
  642. package/lib/molecule/card/test/fixtures/adaptiv.js +1 -1
  643. package/lib/molecule/card/test/fixtures/adaptiv.js.map +1 -1
  644. package/lib/molecule/card/test/fixtures/disabled.js +1 -1
  645. package/lib/molecule/card/test/fixtures/disabled.js.map +1 -1
  646. package/lib/molecule/card/test/fixtures.js +3 -0
  647. package/lib/molecule/card/test/fixtures.js.map +1 -1
  648. package/lib/molecule/card-content/test/fixtures/adaptiv-and-disabled.js +1 -1
  649. package/lib/molecule/card-content/test/fixtures/adaptiv-and-disabled.js.map +1 -1
  650. package/lib/molecule/card-content/test/fixtures/adaptiv.js +1 -1
  651. package/lib/molecule/card-content/test/fixtures/adaptiv.js.map +1 -1
  652. package/lib/molecule/card-content/test/fixtures/disabled.js +1 -1
  653. package/lib/molecule/card-content/test/fixtures/disabled.js.map +1 -1
  654. package/lib/molecule/card-with-button/index.js.map +1 -1
  655. package/lib/molecule/cockpit-popin/test/fixtures.js +28 -0
  656. package/lib/molecule/cockpit-popin/test/fixtures.js.map +1 -0
  657. package/lib/molecule/coorp-manager-roles/index.js +1 -1
  658. package/lib/molecule/coorp-manager-roles/index.js.map +1 -1
  659. package/lib/molecule/dashboard/battle-request-list/index.js +1 -1
  660. package/lib/molecule/dashboard/battle-request-list/index.js.map +1 -1
  661. package/lib/molecule/dashboard/cards-list/test/fixtures/microlearning.js +1 -1
  662. package/lib/molecule/dashboard/cards-list/test/fixtures/microlearning.js.map +1 -1
  663. package/lib/molecule/dashboard/cards-list/test/fixtures/performance.js +1 -1
  664. package/lib/molecule/dashboard/cards-list/test/fixtures/performance.js.map +1 -1
  665. package/lib/molecule/dashboard/cards-list/test/index.js +1 -1
  666. package/lib/molecule/dashboard/cards-list/test/index.js.map +1 -1
  667. package/lib/molecule/dashboard/news-list/index.js +1 -1
  668. package/lib/molecule/dashboard/news-list/index.js.map +1 -1
  669. package/lib/molecule/dashboard/start-battle/index.js +1 -1
  670. package/lib/molecule/dashboard/start-battle/index.js.map +1 -1
  671. package/lib/molecule/discipline-header/test/fixtures/long-description.js.map +1 -1
  672. package/lib/molecule/drag-and-drop/index.js +3 -3
  673. package/lib/molecule/drag-and-drop/index.js.map +1 -1
  674. package/lib/molecule/drag-and-drop/test/fixtures/error.js +1 -1
  675. package/lib/molecule/drag-and-drop/test/fixtures/error.js.map +1 -1
  676. package/lib/molecule/drag-and-drop/test/fixtures/loading.js +1 -1
  677. package/lib/molecule/drag-and-drop/test/fixtures/loading.js.map +1 -1
  678. package/lib/molecule/drag-and-drop/test/fixtures/ready-invalid.js +1 -1
  679. package/lib/molecule/drag-and-drop/test/fixtures/ready-invalid.js.map +1 -1
  680. package/lib/molecule/drag-and-drop/test/fixtures/ready.js +1 -1
  681. package/lib/molecule/drag-and-drop/test/fixtures/ready.js.map +1 -1
  682. package/lib/molecule/drag-and-drop/test/fixtures/success-video.js +1 -1
  683. package/lib/molecule/drag-and-drop/test/fixtures/success-video.js.map +1 -1
  684. package/lib/molecule/drag-and-drop/test/fixtures/success.js +1 -1
  685. package/lib/molecule/drag-and-drop/test/fixtures/success.js.map +1 -1
  686. package/lib/molecule/drag-and-drop/test/on-click.js +2 -2
  687. package/lib/molecule/drag-and-drop/test/on-click.js.map +1 -1
  688. package/lib/molecule/drag-and-drop/upload-report.js +3 -3
  689. package/lib/molecule/drag-and-drop/upload-report.js.map +1 -1
  690. package/lib/molecule/feedback/index.js +3 -3
  691. package/lib/molecule/feedback/index.js.map +1 -1
  692. package/lib/molecule/filters/test/fixtures/default.js +4 -4
  693. package/lib/molecule/filters/test/fixtures/default.js.map +1 -1
  694. package/lib/molecule/filters/test/fixtures/filters-list.js +6 -6
  695. package/lib/molecule/filters/test/fixtures/filters-list.js.map +1 -1
  696. package/lib/molecule/filters/test/fixtures/one.js +2 -2
  697. package/lib/molecule/filters/test/fixtures/one.js.map +1 -1
  698. package/lib/molecule/filters/test/fixtures/only-radio-group.js +1 -1
  699. package/lib/molecule/filters/test/fixtures/only-radio-group.js.map +1 -1
  700. package/lib/molecule/filters/test/fixtures/only-timer.js +1 -1
  701. package/lib/molecule/filters/test/fixtures/only-timer.js.map +1 -1
  702. package/lib/molecule/filters/test/fixtures/three.js +3 -3
  703. package/lib/molecule/filters/test/fixtures/three.js.map +1 -1
  704. package/lib/molecule/filters/test/fixtures/two.js +3 -3
  705. package/lib/molecule/filters/test/fixtures/two.js.map +1 -1
  706. package/lib/molecule/filters/test/fixtures/zero.js +1 -1
  707. package/lib/molecule/filters/test/fixtures/zero.js.map +1 -1
  708. package/lib/molecule/forum/forum-thread/test/fixtures/deep-answers.js +4 -4
  709. package/lib/molecule/forum/forum-thread/test/fixtures/deep-answers.js.map +1 -1
  710. package/lib/molecule/forum/forum-thread/test/fixtures/with-answers.js +1 -1
  711. package/lib/molecule/forum/forum-thread/test/fixtures/with-answers.js.map +1 -1
  712. package/lib/molecule/hero/index.js +2 -2
  713. package/lib/molecule/hero/test/fixtures/arabic.js +1 -1
  714. package/lib/molecule/hero/test/fixtures/arabic.js.map +1 -1
  715. package/lib/molecule/hero/test/fixtures/hero.js +1 -1
  716. package/lib/molecule/hero/test/fixtures/hero.js.map +1 -1
  717. package/lib/molecule/news/test/fixtures/long-description.js +1 -1
  718. package/lib/molecule/news/test/fixtures/long-description.js.map +1 -1
  719. package/lib/molecule/news/test/fixtures/long-title.js +1 -1
  720. package/lib/molecule/news/test/fixtures/long-title.js.map +1 -1
  721. package/lib/molecule/news/test/fixtures/small-desciption.js +1 -1
  722. package/lib/molecule/news/test/fixtures/small-desciption.js.map +1 -1
  723. package/lib/molecule/news/test/fixtures/small-title.js +1 -1
  724. package/lib/molecule/news/test/fixtures/small-title.js.map +1 -1
  725. package/lib/molecule/popin/index.js +3 -3
  726. package/lib/molecule/popin/index.js.map +1 -1
  727. package/lib/molecule/progress-bar/index.js +1 -1
  728. package/lib/molecule/progress-bar/index.js.map +1 -1
  729. package/lib/molecule/questions/drop-down/index.js +3 -3
  730. package/lib/molecule/questions/drop-down/index.js.map +1 -1
  731. package/lib/molecule/questions/free-text/index.js +2 -2
  732. package/lib/molecule/questions/question-range/index.js +2 -4
  733. package/lib/molecule/questions/question-range/index.js.map +1 -1
  734. package/lib/molecule/questions/template/index.js +2 -2
  735. package/lib/molecule/questions/template/index.js.map +1 -1
  736. package/lib/molecule/questions/template/test/index.js +1 -1
  737. package/lib/molecule/questions/template/test/index.js.map +1 -1
  738. package/lib/molecule/quick-access-card/index.js.map +1 -1
  739. package/lib/molecule/resource-player/index.js +2 -4
  740. package/lib/molecule/resource-player/index.js.map +1 -1
  741. package/lib/molecule/scope-tabs/index.js +2 -2
  742. package/lib/molecule/search-form/index.js +2 -2
  743. package/lib/molecule/select-multiple/index.js +6 -6
  744. package/lib/molecule/select-multiple/index.js.map +1 -1
  745. package/lib/molecule/select-multiple/test/index.js +4 -4
  746. package/lib/molecule/select-multiple/test/index.js.map +1 -1
  747. package/lib/molecule/setup-section/index.js +1 -1
  748. package/lib/molecule/setup-section/index.js.map +1 -1
  749. package/lib/molecule/setup-section/test/fixtures/first.js +1 -1
  750. package/lib/molecule/setup-section/test/fixtures/first.js.map +1 -1
  751. package/lib/molecule/setup-sections/index.js +2 -2
  752. package/lib/molecule/setup-slide/index.js +8 -8
  753. package/lib/molecule/setup-slide/index.js.map +1 -1
  754. package/lib/molecule/share/index.js +4 -4
  755. package/lib/molecule/share/index.js.map +1 -1
  756. package/lib/molecule/titled-checkbox/index.js +2 -2
  757. package/lib/molecule/vertical-tabs/test/fixtures/default.js +1 -1
  758. package/lib/molecule/vertical-tabs/test/fixtures.js +3 -0
  759. package/lib/molecule/vertical-tabs/test/fixtures.js.map +1 -1
  760. package/lib/molecule/video-iframe/index.js +1 -1
  761. package/lib/molecule/video-iframe/index.js.map +1 -1
  762. package/lib/molecule/video-player/index.js +1 -3
  763. package/lib/molecule/video-player/index.js.map +1 -1
  764. package/lib/molecule/video-player/jwplayer.js +2 -2
  765. package/lib/molecule/video-player/jwplayer.js.map +1 -1
  766. package/lib/molecule/video-player/test/fixtures/youtube.js +1 -1
  767. package/lib/molecule/video-player/test/fixtures/youtube.js.map +1 -1
  768. package/lib/molecule/video-player/vimeo.js +1 -1
  769. package/lib/molecule/video-player/vimeo.js.map +1 -1
  770. package/lib/molecule/wizard-summary/index.js +2 -2
  771. package/lib/organism/accordion/container/index.js +2 -2
  772. package/lib/organism/accordion/coorp-manager/index.js +3 -3
  773. package/lib/organism/accordion/coorp-manager/index.js.map +1 -1
  774. package/lib/organism/accordion/toggler/index.js +1 -1
  775. package/lib/organism/accordion/toggler/index.js.map +1 -1
  776. package/lib/organism/accordion/toggler/test/render.js +2 -2
  777. package/lib/organism/accordion/toggler/test/render.js.map +1 -1
  778. package/lib/organism/brand-form/index.js +2 -2
  779. package/lib/organism/brand-form/test/fixtures/sso.js +3 -3
  780. package/lib/organism/brand-form/test/fixtures/sso.js.map +1 -1
  781. package/lib/organism/content-translation/index.js +2 -2
  782. package/lib/organism/content-translation/index.js.map +1 -1
  783. package/lib/organism/content-translation/test/fixtures/default.js +2 -2
  784. package/lib/organism/content-translation/test/fixtures/default.js.map +1 -1
  785. package/lib/organism/course-selection/test/fixtures/default.js +8 -8
  786. package/lib/organism/course-selection/test/fixtures/default.js.map +1 -1
  787. package/lib/organism/course-selection/test/fixtures/filtered.js +2 -2
  788. package/lib/organism/course-selection/test/fixtures/filtered.js.map +1 -1
  789. package/lib/organism/course-selection/test/fixtures/sorted-selected.js +5 -5
  790. package/lib/organism/course-selection/test/fixtures/sorted-selected.js.map +1 -1
  791. package/lib/organism/course-selection/test/fixtures/unsorted-selected.js +5 -5
  792. package/lib/organism/course-selection/test/fixtures/unsorted-selected.js.map +1 -1
  793. package/lib/organism/discussion/test/fixtures/default.js +1 -1
  794. package/lib/organism/discussion/test/fixtures/default.js.map +1 -1
  795. package/lib/organism/discussion/test/fixtures/loading-more.js +1 -1
  796. package/lib/organism/discussion/test/fixtures/loading-more.js.map +1 -1
  797. package/lib/organism/discussion/test/fixtures/new-discussion.js +1 -1
  798. package/lib/organism/discussion/test/fixtures/new-discussion.js.map +1 -1
  799. package/lib/organism/get-the-app/index.js +2 -2
  800. package/lib/organism/get-the-app/index.js.map +1 -1
  801. package/lib/organism/list-items/test/fixtures/archived.js +1 -1
  802. package/lib/organism/list-items/test/fixtures/archived.js.map +1 -1
  803. package/lib/organism/list-items/test/fixtures/draft.js +1 -1
  804. package/lib/organism/list-items/test/fixtures/draft.js.map +1 -1
  805. package/lib/organism/list-items/test/fixtures/published.js +1 -1
  806. package/lib/organism/list-items/test/fixtures/published.js.map +1 -1
  807. package/lib/organism/mooc/image-slider/test/fixtures/multiple-slides.js +2 -2
  808. package/lib/organism/mooc/image-slider/test/fixtures/multiple-slides.js.map +1 -1
  809. package/lib/organism/mooc-header/test/fixtures/default.js +1 -1
  810. package/lib/organism/mooc-header/test/fixtures/default.js.map +1 -1
  811. package/lib/organism/mooc-header/test/fixtures/logged-with-battle-notifications.js +1 -1
  812. package/lib/organism/mooc-header/test/fixtures/logged-with-battle-notifications.js.map +1 -1
  813. package/lib/organism/popin/test/fixtures/default.js.map +1 -1
  814. package/lib/organism/resource-browser/test/fixtures/jwplayer-with-overlay.js +1 -1
  815. package/lib/organism/resource-browser/test/fixtures/jwplayer-with-overlay.js.map +1 -1
  816. package/lib/organism/resource-browser/test/fixtures/jwplayer.js +1 -1
  817. package/lib/organism/resource-browser/test/fixtures/jwplayer.js.map +1 -1
  818. package/lib/organism/resource-browser/test/fixtures/kontiki.js +1 -1
  819. package/lib/organism/resource-browser/test/fixtures/kontiki.js.map +1 -1
  820. package/lib/organism/resource-browser/test/fixtures/mp4.js +1 -1
  821. package/lib/organism/resource-browser/test/fixtures/mp4.js.map +1 -1
  822. package/lib/organism/settings/index.js +2 -4
  823. package/lib/organism/settings/index.js.map +1 -1
  824. package/lib/organism/setup-header/index.js +6 -17
  825. package/lib/organism/setup-header/index.js.map +1 -1
  826. package/lib/organism/setup-header/test/fixtures/default.js +4 -1
  827. package/lib/organism/setup-header/test/fixtures/default.js.map +1 -1
  828. package/lib/organism/sidebar/index.js +13 -15
  829. package/lib/organism/sidebar/index.js.map +1 -1
  830. package/lib/organism/user-preferences/index.js +2 -4
  831. package/lib/organism/user-preferences/index.js.map +1 -1
  832. package/lib/organism/wizard-contents/index.js +5 -5
  833. package/lib/organism/wizard-contents/index.js.map +1 -1
  834. package/lib/organism/wizard-contents/test/fixtures/playlist-add-courses-create.js +1 -1
  835. package/lib/organism/wizard-contents/test/fixtures/playlist-add-courses-create.js.map +1 -1
  836. package/lib/organism/wizard-contents/test/fixtures/playlist-general-settings-create.js +1 -1
  837. package/lib/organism/wizard-contents/test/fixtures/playlist-general-settings-create.js.map +1 -1
  838. package/lib/organism/wizard-contents/test/fixtures/playlist-general-settings-edit.js +1 -1
  839. package/lib/organism/wizard-contents/test/fixtures/playlist-general-settings-edit.js.map +1 -1
  840. package/lib/organism/wizard-contents/test/fixtures/playlist-populations-create.js +1 -1
  841. package/lib/organism/wizard-contents/test/fixtures/playlist-populations-create.js.map +1 -1
  842. package/lib/organism/wizard-contents/test/fixtures/playlist-translate-edit.js +1 -1
  843. package/lib/organism/wizard-contents/test/fixtures/playlist-translate-edit.js.map +1 -1
  844. package/lib/template/activity/index.js +1 -1
  845. package/lib/template/activity/index.js.map +1 -1
  846. package/lib/template/activity/progression-item.js +2 -2
  847. package/lib/template/activity/test/progression-item-test.js +1 -1
  848. package/lib/template/activity/test/progression-item-test.js.map +1 -1
  849. package/lib/template/app-player/player/slides/footer/index.js +1 -1
  850. package/lib/template/app-player/player/slides/footer/index.js.map +1 -1
  851. package/lib/template/app-player/player/slides/index.js +11 -15
  852. package/lib/template/app-player/player/slides/index.js.map +1 -1
  853. package/lib/template/app-player/player/slides/test/fixtures/arabic-context.js +2 -2
  854. package/lib/template/app-player/player/slides/test/fixtures/arabic-context.js.map +1 -1
  855. package/lib/template/app-player/player/slides/test/fixtures/arabic-qcm.js +1 -1
  856. package/lib/template/app-player/player/slides/test/fixtures/arabic-qcm.js.map +1 -1
  857. package/lib/template/app-player/player/slides/test/fixtures/arabic-resources.js +2 -2
  858. package/lib/template/app-player/player/slides/test/fixtures/arabic-resources.js.map +1 -1
  859. package/lib/template/app-player/player/slides/test/fixtures/arabic.js +2 -2
  860. package/lib/template/app-player/player/slides/test/fixtures/arabic.js.map +1 -1
  861. package/lib/template/app-player/player/slides/test/fixtures/clue.js +2 -2
  862. package/lib/template/app-player/player/slides/test/fixtures/clue.js.map +1 -1
  863. package/lib/template/app-player/player/slides/test/fixtures/context-with-audio.js +2 -2
  864. package/lib/template/app-player/player/slides/test/fixtures/context-with-audio.js.map +1 -1
  865. package/lib/template/app-player/player/slides/test/fixtures/context-with-image.js +2 -2
  866. package/lib/template/app-player/player/slides/test/fixtures/context-with-image.js.map +1 -1
  867. package/lib/template/app-player/player/slides/test/fixtures/context-with-pdf.js +2 -2
  868. package/lib/template/app-player/player/slides/test/fixtures/context-with-pdf.js.map +1 -1
  869. package/lib/template/app-player/player/slides/test/fixtures/context-with-video.js +2 -2
  870. package/lib/template/app-player/player/slides/test/fixtures/context-with-video.js.map +1 -1
  871. package/lib/template/app-player/player/slides/test/fixtures/context.js +2 -2
  872. package/lib/template/app-player/player/slides/test/fixtures/context.js.map +1 -1
  873. package/lib/template/app-player/player/slides/test/fixtures/default.js +2 -2
  874. package/lib/template/app-player/player/slides/test/fixtures/default.js.map +1 -1
  875. package/lib/template/app-player/player/slides/test/fixtures/drop-down.js +1 -1
  876. package/lib/template/app-player/player/slides/test/fixtures/drop-down.js.map +1 -1
  877. package/lib/template/app-player/player/slides/test/fixtures/free-text.js +1 -1
  878. package/lib/template/app-player/player/slides/test/fixtures/free-text.js.map +1 -1
  879. package/lib/template/app-player/player/slides/test/fixtures/media-h5p.js +2 -2
  880. package/lib/template/app-player/player/slides/test/fixtures/media-h5p.js.map +1 -1
  881. package/lib/template/app-player/player/slides/test/fixtures/media-omni-player.js +2 -2
  882. package/lib/template/app-player/player/slides/test/fixtures/media-omni-player.js.map +1 -1
  883. package/lib/template/app-player/player/slides/test/fixtures/media.js +2 -2
  884. package/lib/template/app-player/player/slides/test/fixtures/media.js.map +1 -1
  885. package/lib/template/app-player/player/slides/test/fixtures/no-clue.js +2 -2
  886. package/lib/template/app-player/player/slides/test/fixtures/no-clue.js.map +1 -1
  887. package/lib/template/app-player/player/slides/test/fixtures/no-question.js +2 -2
  888. package/lib/template/app-player/player/slides/test/fixtures/no-question.js.map +1 -1
  889. package/lib/template/app-player/player/slides/test/fixtures/no-total.js +1 -1
  890. package/lib/template/app-player/player/slides/test/fixtures/no-total.js.map +1 -1
  891. package/lib/template/app-player/player/slides/test/fixtures/only-clue.js +2 -2
  892. package/lib/template/app-player/player/slides/test/fixtures/only-clue.js.map +1 -1
  893. package/lib/template/app-player/player/slides/test/fixtures/qcm-drag.js +1 -1
  894. package/lib/template/app-player/player/slides/test/fixtures/qcm-drag.js.map +1 -1
  895. package/lib/template/app-player/player/slides/test/fixtures/qcm-graphic.js +1 -1
  896. package/lib/template/app-player/player/slides/test/fixtures/qcm-graphic.js.map +1 -1
  897. package/lib/template/app-player/player/slides/test/fixtures/qcm-see-lesson-no-step.js +1 -1
  898. package/lib/template/app-player/player/slides/test/fixtures/qcm-see-lesson-no-step.js.map +1 -1
  899. package/lib/template/app-player/player/slides/test/fixtures/qcm-see-lesson.js +1 -1
  900. package/lib/template/app-player/player/slides/test/fixtures/qcm-see-lesson.js.map +1 -1
  901. package/lib/template/app-player/player/slides/test/fixtures/qcm-short.js +1 -1
  902. package/lib/template/app-player/player/slides/test/fixtures/qcm-short.js.map +1 -1
  903. package/lib/template/app-player/player/slides/test/fixtures/qcm-template.js +1 -1
  904. package/lib/template/app-player/player/slides/test/fixtures/qcm-template.js.map +1 -1
  905. package/lib/template/app-player/player/slides/test/fixtures/qcm-with-review-lesson.js +1 -1
  906. package/lib/template/app-player/player/slides/test/fixtures/qcm-with-review-lesson.js.map +1 -1
  907. package/lib/template/app-player/player/slides/test/fixtures/qcm.js +1 -1
  908. package/lib/template/app-player/player/slides/test/fixtures/qcm.js.map +1 -1
  909. package/lib/template/app-player/player/slides/test/fixtures/range.js +1 -1
  910. package/lib/template/app-player/player/slides/test/fixtures/range.js.map +1 -1
  911. package/lib/template/app-player/player/slides/test/fixtures/template.js +1 -1
  912. package/lib/template/app-player/player/slides/test/fixtures/template.js.map +1 -1
  913. package/lib/template/app-player/player/slides/test/fixtures/with-min-height.js +1 -1
  914. package/lib/template/app-player/player/slides/test/fixtures/with-min-height.js.map +1 -1
  915. package/lib/template/app-player/player/test/fixtures/background.js +1 -1
  916. package/lib/template/app-player/player/test/fixtures/background.js.map +1 -1
  917. package/lib/template/app-player/popin-correction/index.js +4 -6
  918. package/lib/template/app-player/popin-correction/index.js.map +1 -1
  919. package/lib/template/app-player/popin-correction/test/fixtures/correct-closed-without-klf-and-tips.js +1 -1
  920. package/lib/template/app-player/popin-correction/test/fixtures/correct-closed-without-klf-and-tips.js.map +1 -1
  921. package/lib/template/app-player/popin-correction/test/fixtures/correct-closed.js +1 -1
  922. package/lib/template/app-player/popin-correction/test/fixtures/correct-closed.js.map +1 -1
  923. package/lib/template/app-player/popin-end/summary.js +7 -12
  924. package/lib/template/app-player/popin-end/summary.js.map +1 -1
  925. package/lib/template/app-player/popin-end/test/fixtures/adaptive.js +2 -2
  926. package/lib/template/app-player/popin-end/test/fixtures/adaptive.js.map +1 -1
  927. package/lib/template/app-player/popin-end/test/fixtures/infinite-lives.js +2 -2
  928. package/lib/template/app-player/popin-end/test/fixtures/infinite-lives.js.map +1 -1
  929. package/lib/template/app-player/popin-header/index.js +5 -7
  930. package/lib/template/app-player/popin-header/index.js.map +1 -1
  931. package/lib/template/back-office/brand-create/test/fixtures/default.js +1 -1
  932. package/lib/template/back-office/brand-create/test/fixtures/default.js.map +1 -1
  933. package/lib/template/back-office/brand-create/test/fixtures/loading.js +1 -1
  934. package/lib/template/back-office/brand-create/test/fixtures/loading.js.map +1 -1
  935. package/lib/template/back-office/brand-create/test/fixtures/modified.js +1 -1
  936. package/lib/template/back-office/brand-create/test/fixtures/modified.js.map +1 -1
  937. package/lib/template/back-office/brand-list/test/fixtures/default.js +1 -1
  938. package/lib/template/back-office/brand-list/test/fixtures/default.js.map +1 -1
  939. package/lib/template/back-office/brand-list/test/fixtures/rh.js +1 -1
  940. package/lib/template/back-office/brand-list/test/fixtures/rh.js.map +1 -1
  941. package/lib/template/back-office/brand-update/index.js +8 -8
  942. package/lib/template/back-office/brand-update/index.js.map +1 -1
  943. package/lib/template/back-office/brand-update/test/fixtures/analytics.js +2 -2
  944. package/lib/template/back-office/brand-update/test/fixtures/animations.js +2 -2
  945. package/lib/template/back-office/brand-update/test/fixtures/cohort-error.js +2 -2
  946. package/lib/template/back-office/brand-update/test/fixtures/cohort.js +2 -2
  947. package/lib/template/back-office/brand-update/test/fixtures/dashboard.js +2 -2
  948. package/lib/template/back-office/brand-update/test/fixtures/dashboards-analytics.js +2 -2
  949. package/lib/template/back-office/brand-update/test/fixtures/default.js +1 -1
  950. package/lib/template/back-office/brand-update/test/fixtures/list-items-archived.js +1 -1
  951. package/lib/template/back-office/brand-update/test/fixtures/list-items-archived.js.map +1 -1
  952. package/lib/template/back-office/brand-update/test/fixtures/list-items-draft.js +1 -1
  953. package/lib/template/back-office/brand-update/test/fixtures/list-items-draft.js.map +1 -1
  954. package/lib/template/back-office/brand-update/test/fixtures/list-items-published-with-popin.js +1 -1
  955. package/lib/template/back-office/brand-update/test/fixtures/list-items-published-with-popin.js.map +1 -1
  956. package/lib/template/back-office/brand-update/test/fixtures/list-items-published.js +1 -1
  957. package/lib/template/back-office/brand-update/test/fixtures/list-items-published.js.map +1 -1
  958. package/lib/template/back-office/brand-update/test/fixtures/lms-error.js +2 -2
  959. package/lib/template/back-office/brand-update/test/fixtures/lms-modified.js +2 -2
  960. package/lib/template/back-office/brand-update/test/fixtures/lms-success.js +2 -2
  961. package/lib/template/back-office/brand-update/test/fixtures/lms.js +2 -2
  962. package/lib/template/back-office/brand-update/test/fixtures/lookandfeel.js +2 -2
  963. package/lib/template/back-office/brand-update/test/fixtures/manageusers-edit.js +1 -1
  964. package/lib/template/back-office/brand-update/test/fixtures/manageusers-edit.js.map +1 -1
  965. package/lib/template/back-office/brand-update/test/fixtures/quick-access.js +1 -1
  966. package/lib/template/back-office/brand-update/test/fixtures/quick-access.js.map +1 -1
  967. package/lib/template/back-office/brand-update/test/fixtures/sso.js +2 -2
  968. package/lib/template/back-office/brand-update/test/fixtures/uploadusers-loading.js +1 -1
  969. package/lib/template/back-office/brand-update/test/fixtures/uploadusers-loading.js.map +1 -1
  970. package/lib/template/back-office/brand-update/test/fixtures/uploadusers-successful.js +1 -1
  971. package/lib/template/back-office/brand-update/test/fixtures/uploadusers-successful.js.map +1 -1
  972. package/lib/template/back-office/brand-update/test/fixtures/uploadusers.js +1 -1
  973. package/lib/template/back-office/brand-update/test/fixtures/uploadusers.js.map +1 -1
  974. package/lib/template/back-office/brand-update/test/fixtures/wizard-add-courses-playlist.js +1 -1
  975. package/lib/template/back-office/brand-update/test/fixtures/wizard-add-courses-playlist.js.map +1 -1
  976. package/lib/template/back-office/brand-update/test/fixtures/wizard-form-create-playlist.js +1 -1
  977. package/lib/template/back-office/brand-update/test/fixtures/wizard-form-create-playlist.js.map +1 -1
  978. package/lib/template/back-office/brand-update/test/fixtures/wizard-form-edit-playlist.js +1 -1
  979. package/lib/template/back-office/brand-update/test/fixtures/wizard-form-edit-playlist.js.map +1 -1
  980. package/lib/template/back-office/brand-update/test/fixtures/wizard-populations-playlist-with-popin.js +1 -1
  981. package/lib/template/back-office/brand-update/test/fixtures/wizard-populations-playlist-with-popin.js.map +1 -1
  982. package/lib/template/back-office/brand-update/test/fixtures/wizard-populations-playlist.js +1 -1
  983. package/lib/template/back-office/brand-update/test/fixtures/wizard-populations-playlist.js.map +1 -1
  984. package/lib/template/back-office/brand-update/test/fixtures/wizard-translate-playlist.js +1 -1
  985. package/lib/template/back-office/brand-update/test/fixtures/wizard-translate-playlist.js.map +1 -1
  986. package/lib/template/cockpit/jw-uploader/index.js +1 -1
  987. package/lib/template/cockpit/jw-uploader/index.js.map +1 -1
  988. package/lib/template/common/dashboard/index.js +1 -1
  989. package/lib/template/common/dashboard/index.js.map +1 -1
  990. package/lib/template/common/dashboard/test/fixtures/empty-requests.js +1 -1
  991. package/lib/template/common/dashboard/test/fixtures/empty-requests.js.map +1 -1
  992. package/lib/template/common/dashboard/test/fixtures/with-hero-card.js +1 -1
  993. package/lib/template/common/dashboard/test/fixtures/with-hero-card.js.map +1 -1
  994. package/lib/template/common/discipline/index.js +2 -2
  995. package/lib/template/common/discipline/test/fixtures/add-to-my-list.js +1 -1
  996. package/lib/template/common/discipline/test/fixtures/add-to-my-list.js.map +1 -1
  997. package/lib/template/common/discipline/test/fixtures/arabic.js +1 -1
  998. package/lib/template/common/discipline/test/fixtures/arabic.js.map +1 -1
  999. package/lib/template/common/discipline/test/fixtures/default.js +2 -2
  1000. package/lib/template/common/discipline/test/fixtures/default.js.map +1 -1
  1001. package/lib/template/common/discipline/test/fixtures/external-course-with-video.js +2 -2
  1002. package/lib/template/common/discipline/test/fixtures/external-course-with-video.js.map +1 -1
  1003. package/lib/template/common/discipline/test/fixtures/external-course-without-image.js +2 -2
  1004. package/lib/template/common/discipline/test/fixtures/external-course-without-image.js.map +1 -1
  1005. package/lib/template/common/discipline/test/fixtures/external-course.js +2 -2
  1006. package/lib/template/common/discipline/test/fixtures/external-course.js.map +1 -1
  1007. package/lib/template/common/discipline/test/fixtures/share.js +1 -1
  1008. package/lib/template/common/discipline/test/fixtures/share.js.map +1 -1
  1009. package/lib/template/teams-dashboard/index.js +2 -2
  1010. package/lib/template/teams-dashboard/test/fixtures/default.js +2 -2
  1011. package/lib/template/teams-dashboard/test/fixtures/default.js.map +1 -1
  1012. package/lib/template/teams-dashboard/test/fixtures/is-loading.js +1 -1
  1013. package/lib/template/teams-dashboard/test/fixtures/is-loading.js.map +1 -1
  1014. package/lib/template/teams-dashboard/test/fixtures/mobile.js +1 -1
  1015. package/lib/template/teams-dashboard/test/fixtures/mobile.js.map +1 -1
  1016. package/lib/test/helpers/render-component.js +1 -1
  1017. package/lib/util/external-content.js +1 -1
  1018. package/lib/util/proptypes.js +1 -1
  1019. package/lib/util/shallow-compare.js.map +1 -1
  1020. package/lib/util/test/navigation.js +3 -5
  1021. package/lib/util/test/navigation.js.map +1 -1
  1022. package/package.json +2 -2
@@ -16,9 +16,9 @@ var _ = _interopRequireWildcard(require(".."));
16
16
 
17
17
  var _checked = _interopRequireDefault(require("./fixtures/checked"));
18
18
 
19
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
19
+ function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
20
20
 
21
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
21
+ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
22
22
 
23
23
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
24
24
 
@@ -44,7 +44,7 @@ const setup = options => {
44
44
  (0, _ava.default)('should select array of choices when props.multiple is set', t => {
45
45
  t.plan(2);
46
46
 
47
- const props = _extends({}, _checked.default.props, {
47
+ const props = _extends(_extends({}, _checked.default.props), {}, {
48
48
  multiple: true,
49
49
  onChange: choices => {
50
50
  t.true(Array.isArray(choices), 'dffdff');
@@ -71,7 +71,7 @@ const setup = options => {
71
71
  const [getChoices, setChoices] = setup(props.options);
72
72
  const choices = getChoices();
73
73
  t.is(choices[0].selected, false, 'not setting correctly expected value for choice[0]');
74
- setChoices(_extends({}, props.options[0], {
74
+ setChoices(_extends(_extends({}, props.options[0]), {}, {
75
75
  i: 0
76
76
  }));
77
77
  t.is(getChoices()[0].selected, true, 'not updating correctly expected value for choice[0]');
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/molecule/select-multiple/test/index.js"],"names":["adapter","Adapter","setup","options","returnVal","TestComponent","push","t","plan","props","defaultFixture","multiple","onChange","choices","true","Array","isArray","pass","wrapper","update","checkbox","find","first","simulate","getChoices","is","length","setChoices","selected","i"],"mappings":";;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAEA;AACA,uBAA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,CAAC,IAAI;AAC9C,QAAME,KAAK,gBAAOC,iBAAeD,KAAtB,CAAX;;AACA,QAAM,CAACe,UAAD,EAAaG,UAAb,IAA2BzB,KAAK,CAACO,KAAK,CAACN,OAAP,CAAtC;AACA,QAAMU,OAAO,GAAGW,UAAU,EAA1B;AAEAjB,EAAAA,CAAC,CAACkB,EAAF,CAAKZ,OAAO,CAAC,CAAD,CAAP,CAAWe,QAAhB,EAA0B,KAA1B,EAAiC,oDAAjC;AAEAD,EAAAA,UAAU,cAAKlB,KAAK,CAACN,OAAN,CAAc,CAAd,CAAL;AAAuB0B,IAAAA,CAAC,EAAE;AAA1B,KAAV;AAEAtB,EAAAA,CAAC,CAACkB,EAAF,CAAKD,UAAU,GAAG,CAAH,CAAV,CAAgBI,QAArB,EAA+B,IAA/B,EAAqC,qDAArC;AACD,CAVD","sourcesContent":["import browserEnv from 'browser-env';\nimport test from 'ava';\nimport flatten from 'lodash/fp/flatten';\nimport React from 'react';\nimport {mount, configure} from 'enzyme';\nimport Adapter from 'enzyme-adapter-react-16';\nimport SelectMultiple, {useChoices} from '..';\nimport defaultFixture from './fixtures/checked';\n\nbrowserEnv();\nconfigure({adapter: new Adapter()});\n\nconst setup = options => {\n const returnVal = [];\n const TestComponent = () => {\n returnVal.push(useChoices(options));\n return null;\n };\n\n mount(<TestComponent />);\n return flatten(returnVal);\n};\n\ntest('should select array of choices when props.multiple is set', t => {\n t.plan(2);\n const props = {\n ...defaultFixture.props,\n multiple: true,\n onChange: choices => {\n t.true(Array.isArray(choices), 'dffdff');\n t.pass();\n }\n };\n\n const wrapper = mount(<SelectMultiple {...props} />);\n\n wrapper.update();\n\n const checkbox = wrapper.find('[checked=false]').first();\n\n checkbox.simulate('change', {props});\n});\n\ntest('should return choices (getter)', t => {\n const props = {...defaultFixture.props};\n const [getChoices] = setup(props.options);\n\n t.is(getChoices().length, 4, 'not returning expected choices');\n});\n\ntest('should set current choice (setter)', t => {\n const props = {...defaultFixture.props};\n const [getChoices, setChoices] = setup(props.options);\n const choices = getChoices();\n\n t.is(choices[0].selected, false, 'not setting correctly expected value for choice[0]');\n\n setChoices({...props.options[0], i: 0});\n\n t.is(getChoices()[0].selected, true, 'not updating correctly expected value for choice[0]');\n});\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../../../../src/molecule/select-multiple/test/index.js"],"names":["adapter","Adapter","setup","options","returnVal","TestComponent","push","t","plan","props","defaultFixture","multiple","onChange","choices","true","Array","isArray","pass","wrapper","update","checkbox","find","first","simulate","getChoices","is","length","setChoices","selected","i"],"mappings":";;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAEA;AACA,uBAAU;AAACA,EAAAA,OAAO,EAAE,IAAIC,2BAAJ;AAAV,CAAV;;AAEA,MAAMC,KAAK,GAAGC,OAAO,IAAI;AACvB,QAAMC,SAAS,GAAG,EAAlB;;AACA,QAAMC,aAAa,GAAG,MAAM;AAC1BD,IAAAA,SAAS,CAACE,IAAV,CAAe,kBAAWH,OAAX,CAAf;AACA,WAAO,IAAP;AACD,GAHD;;AAKA,mCAAM,6BAAC,aAAD,OAAN;AACA,SAAO,sBAAQC,SAAR,CAAP;AACD,CATD;;AAWA,kBAAK,2DAAL,EAAkEG,CAAC,IAAI;AACrEA,EAAAA,CAAC,CAACC,IAAF,CAAO,CAAP;;AACA,QAAMC,KAAK,yBACNC,iBAAeD,KADT;AAETE,IAAAA,QAAQ,EAAE,IAFD;AAGTC,IAAAA,QAAQ,EAAEC,OAAO,IAAI;AACnBN,MAAAA,CAAC,CAACO,IAAF,CAAOC,KAAK,CAACC,OAAN,CAAcH,OAAd,CAAP,EAA+B,QAA/B;AACAN,MAAAA,CAAC,CAACU,IAAF;AACD;AANQ,IAAX;;AASA,QAAMC,OAAO,GAAG,iCAAM,6BAAC,SAAD,EAAoBT,KAApB,CAAN,CAAhB;AAEAS,EAAAA,OAAO,CAACC,MAAR;AAEA,QAAMC,QAAQ,GAAGF,OAAO,CAACG,IAAR,CAAa,iBAAb,EAAgCC,KAAhC,EAAjB;AAEAF,EAAAA,QAAQ,CAACG,QAAT,CAAkB,QAAlB,EAA4B;AAACd,IAAAA;AAAD,GAA5B;AACD,CAlBD;AAoBA,kBAAK,gCAAL,EAAuCF,CAAC,IAAI;AAC1C,QAAME,KAAK,gBAAOC,iBAAeD,KAAtB,CAAX;;AACA,QAAM,CAACe,UAAD,IAAetB,KAAK,CAACO,KAAK,CAACN,OAAP,CAA1B;AAEAI,EAAAA,CAAC,CAACkB,EAAF,CAAKD,UAAU,GAAGE,MAAlB,EAA0B,CAA1B,EAA6B,gCAA7B;AACD,CALD;AAOA,kBAAK,oCAAL,EAA2CnB,CAAC,IAAI;AAC9C,QAAME,KAAK,gBAAOC,iBAAeD,KAAtB,CAAX;;AACA,QAAM,CAACe,UAAD,EAAaG,UAAb,IAA2BzB,KAAK,CAACO,KAAK,CAACN,OAAP,CAAtC;AACA,QAAMU,OAAO,GAAGW,UAAU,EAA1B;AAEAjB,EAAAA,CAAC,CAACkB,EAAF,CAAKZ,OAAO,CAAC,CAAD,CAAP,CAAWe,QAAhB,EAA0B,KAA1B,EAAiC,oDAAjC;AAEAD,EAAAA,UAAU,uBAAKlB,KAAK,CAACN,OAAN,CAAc,CAAd,CAAL;AAAuB0B,IAAAA,CAAC,EAAE;AAA1B,KAAV;AAEAtB,EAAAA,CAAC,CAACkB,EAAF,CAAKD,UAAU,GAAG,CAAH,CAAV,CAAgBI,QAArB,EAA+B,IAA/B,EAAqC,qDAArC;AACD,CAVD","sourcesContent":["import browserEnv from 'browser-env';\nimport test from 'ava';\nimport flatten from 'lodash/fp/flatten';\nimport React from 'react';\nimport {mount, configure} from 'enzyme';\nimport Adapter from 'enzyme-adapter-react-16';\nimport SelectMultiple, {useChoices} from '..';\nimport defaultFixture from './fixtures/checked';\n\nbrowserEnv();\nconfigure({adapter: new Adapter()});\n\nconst setup = options => {\n const returnVal = [];\n const TestComponent = () => {\n returnVal.push(useChoices(options));\n return null;\n };\n\n mount(<TestComponent />);\n return flatten(returnVal);\n};\n\ntest('should select array of choices when props.multiple is set', t => {\n t.plan(2);\n const props = {\n ...defaultFixture.props,\n multiple: true,\n onChange: choices => {\n t.true(Array.isArray(choices), 'dffdff');\n t.pass();\n }\n };\n\n const wrapper = mount(<SelectMultiple {...props} />);\n\n wrapper.update();\n\n const checkbox = wrapper.find('[checked=false]').first();\n\n checkbox.simulate('change', {props});\n});\n\ntest('should return choices (getter)', t => {\n const props = {...defaultFixture.props};\n const [getChoices] = setup(props.options);\n\n t.is(getChoices().length, 4, 'not returning expected choices');\n});\n\ntest('should set current choice (setter)', t => {\n const props = {...defaultFixture.props};\n const [getChoices, setChoices] = setup(props.options);\n const choices = getChoices();\n\n t.is(choices[0].selected, false, 'not setting correctly expected value for choice[0]');\n\n setChoices({...props.options[0], i: 0});\n\n t.is(getChoices()[0].selected, true, 'not updating correctly expected value for choice[0]');\n});\n"],"file":"index.js"}
@@ -49,7 +49,7 @@ ContentTypesToggler.contextTypes = {
49
49
  skin: _provider.default.childContextTypes.skin
50
50
  };
51
51
  ContentTypesToggler.propTypes = process.env.NODE_ENV !== "production" ? {
52
- contentTypes: _propTypes.default.shape(_extends({}, _radioGroup.default.propTypes, {
52
+ contentTypes: _propTypes.default.shape(_extends(_extends({}, _radioGroup.default.propTypes), {}, {
53
53
  modified: _propTypes.default.bool
54
54
  }))
55
55
  } : {};
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/molecule/setup-section/index.js"],"names":["ContentTypesToggler","props","context","skin","contentTypes","brand","orange","contentTypesColor","style","contentTypeWrapper","contextTypes","Provider","childContextTypes","propTypes","PropTypes","shape","RadioGroup","modified","bool","SetupSection","translate","medium","title","onUp","onDown","display","colorUp","colorDown","wrapper","settings","label","arrowSection","arrow","disabled","string","isRequired","func","InputSwitch"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AAKA;;AACA;;AACA;;AACA;;;;;;AAEA,MAAMA,mBAAmB,GAAG,CAACC,KAAD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;AAKvBT,EAAAA,YAAY,EAAEJ,mBAAmB,CAACa,SAApB,CAA8BT;AALrB,CAAzB;eAQee,Y","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {\n NovaCompositionNavigationArrowDown as ArrowDownIcon,\n NovaCompositionNavigationArrowTop as ArrowUpIcon\n} from '@coorpacademy/nova-icons';\nimport {get} from 'lodash/fp';\nimport Provider from '../../atom/provider';\nimport InputSwitch from '../../atom/input-switch';\nimport RadioGroup from '../../atom/radio-group';\nimport style from './style.css';\n\nconst ContentTypesToggler = (props, context) => {\n const {skin} = context;\n const {contentTypes} = props;\n\n if (!contentTypes) {\n return null;\n }\n\n const brand = get('common.brand', skin);\n const orange = get('common.orange', skin);\n const contentTypesColor = get('modified', contentTypes) ? orange : brand;\n\n return (\n <div className={style.contentTypeWrapper}>\n <RadioGroup {...contentTypes} color={contentTypesColor} />\n </div>\n );\n};\n\nContentTypesToggler.contextTypes = {\n skin: Provider.childContextTypes.skin\n};\n\nContentTypesToggler.propTypes = {\n contentTypes: PropTypes.shape({\n ...RadioGroup.propTypes,\n modified: PropTypes.bool\n })\n};\n\nconst SetupSection = (props, context) => {\n const {translate, skin} = context;\n const brand = get('common.brand', skin);\n const medium = get('common.medium', skin);\n\n const {title, onUp, onDown, display, contentTypes} = props;\n const colorUp = onDown ? brand : medium;\n const colorDown = onUp ? brand : medium;\n\n return (\n <div className={style.wrapper}>\n <div className={style.title}>{title}</div>\n <div className={style.settings}>\n <ContentTypesToggler contentTypes={contentTypes} />\n <div className={style.label}>{translate('Show')}</div>\n <InputSwitch {...display} />\n <div className={style.arrowSection}>\n <ArrowDownIcon\n color={colorUp}\n className={onDown ? style.arrow : style.disabled}\n onClick={onDown}\n />\n <ArrowUpIcon\n color={colorDown}\n className={onUp ? style.arrow : style.disabled}\n onClick={onUp}\n />\n </div>\n </div>\n </div>\n );\n};\n\nSetupSection.contextTypes = {\n translate: Provider.childContextTypes.translate,\n skin: Provider.childContextTypes.skin\n};\n\nSetupSection.propTypes = {\n title: PropTypes.string.isRequired,\n onUp: PropTypes.func,\n onDown: PropTypes.func,\n display: PropTypes.shape(InputSwitch.propTypes),\n contentTypes: ContentTypesToggler.propTypes.contentTypes\n};\n\nexport default SetupSection;\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../../../src/molecule/setup-section/index.js"],"names":["ContentTypesToggler","props","context","skin","contentTypes","brand","orange","contentTypesColor","style","contentTypeWrapper","contextTypes","Provider","childContextTypes","propTypes","PropTypes","shape","RadioGroup","modified","bool","SetupSection","translate","medium","title","onUp","onDown","display","colorUp","colorDown","wrapper","settings","label","arrowSection","arrow","disabled","string","isRequired","func","InputSwitch"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AAKA;;AACA;;AACA;;AACA;;;;;;AAEA,MAAMA,mBAAmB,GAAG,CAACC,KAAD,EAAQC,OAAR,KAAoB;AAC9C,QAAM;AAACC,IAAAA;AAAD,MAASD,OAAf;AACA,QAAM;AAACE,IAAAA;AAAD,MAAiBH,KAAvB;;AAEA,MAAI,CAACG,YAAL,EAAmB;AACjB,WAAO,IAAP;AACD;;AAED,QAAMC,KAAK,GAAG,mBAAI,cAAJ,EAAoBF,IAApB,CAAd;AACA,QAAMG,MAAM,GAAG,mBAAI,eAAJ,EAAqBH,IAArB,CAAf;AACA,QAAMI,iBAAiB,GAAG,mBAAI,UAAJ,EAAgBH,YAAhB,IAAgCE,MAAhC,GAAyCD,KAAnE;AAEA,sBACE;AAAK,IAAA,SAAS,EAAEG,eAAMC;AAAtB,kBACE,6BAAC,mBAAD,eAAgBL,YAAhB;AAA8B,IAAA,KAAK,EAAEG;AAArC,KADF,CADF;AAKD,CAjBD;;AAmBAP,mBAAmB,CAACU,YAApB,GAAmC;AACjCP,EAAAA,IAAI,EAAEQ,kBAASC,iBAAT,CAA2BT;AADA,CAAnC;AAIAH,mBAAmB,CAACa,SAApB,2CAAgC;AAC9BT,EAAAA,YAAY,EAAEU,mBAAUC,KAAV,uBACTC,oBAAWH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AMwB,KAAT,GAAiBxB,eAAMyB,QAFxC;AAGE,IAAA,OAAO,EAAEV;AAHX,IANF,CAJF,CAFF,CADF;AAsBD,CA/BD;;AAiCAJ,YAAY,CAACT,YAAb,GAA4B;AAC1BU,EAAAA,SAAS,EAAET,kBAASC,iBAAT,CAA2BQ,SADZ;AAE1BjB,EAAAA,IAAI,EAAEQ,kBAASC,iBAAT,CAA2BT;AAFP,CAA5B;AAKAgB,YAAY,CAACN,SAAb,2CAAyB;AACvBS,EAAAA,KAAK,EAAER,mBAAUoB,MAAV,CAAiBC,UADD;AAEvBZ,EAAAA,IAAI,EAAET,mBAAUsB,IAFO;AAGvBZ,EAAAA,MAAM,EAAEV,mBAAUsB,IAHK;AAIvBX,EAAAA,OAAO,EAAEX,mBAAUC,KAAV,CAAgBsB,qBAAYxB,SAA5B,CAJc;AAKvBT,EAAAA,YAAY,EAAEJ,mBAAmB,CAACa,SAApB,CAA8BT;AALrB,CAAzB;eAQee,Y","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {\n NovaCompositionNavigationArrowDown as ArrowDownIcon,\n NovaCompositionNavigationArrowTop as ArrowUpIcon\n} from '@coorpacademy/nova-icons';\nimport {get} from 'lodash/fp';\nimport Provider from '../../atom/provider';\nimport InputSwitch from '../../atom/input-switch';\nimport RadioGroup from '../../atom/radio-group';\nimport style from './style.css';\n\nconst ContentTypesToggler = (props, context) => {\n const {skin} = context;\n const {contentTypes} = props;\n\n if (!contentTypes) {\n return null;\n }\n\n const brand = get('common.brand', skin);\n const orange = get('common.orange', skin);\n const contentTypesColor = get('modified', contentTypes) ? orange : brand;\n\n return (\n <div className={style.contentTypeWrapper}>\n <RadioGroup {...contentTypes} color={contentTypesColor} />\n </div>\n );\n};\n\nContentTypesToggler.contextTypes = {\n skin: Provider.childContextTypes.skin\n};\n\nContentTypesToggler.propTypes = {\n contentTypes: PropTypes.shape({\n ...RadioGroup.propTypes,\n modified: PropTypes.bool\n })\n};\n\nconst SetupSection = (props, context) => {\n const {translate, skin} = context;\n const brand = get('common.brand', skin);\n const medium = get('common.medium', skin);\n\n const {title, onUp, onDown, display, contentTypes} = props;\n const colorUp = onDown ? brand : medium;\n const colorDown = onUp ? brand : medium;\n\n return (\n <div className={style.wrapper}>\n <div className={style.title}>{title}</div>\n <div className={style.settings}>\n <ContentTypesToggler contentTypes={contentTypes} />\n <div className={style.label}>{translate('Show')}</div>\n <InputSwitch {...display} />\n <div className={style.arrowSection}>\n <ArrowDownIcon\n color={colorUp}\n className={onDown ? style.arrow : style.disabled}\n onClick={onDown}\n />\n <ArrowUpIcon\n color={colorDown}\n className={onUp ? style.arrow : style.disabled}\n onClick={onUp}\n />\n </div>\n </div>\n </div>\n );\n};\n\nSetupSection.contextTypes = {\n translate: Provider.childContextTypes.translate,\n skin: Provider.childContextTypes.skin\n};\n\nSetupSection.propTypes = {\n title: PropTypes.string.isRequired,\n onUp: PropTypes.func,\n onDown: PropTypes.func,\n display: PropTypes.shape(InputSwitch.propTypes),\n contentTypes: ContentTypesToggler.propTypes.contentTypes\n};\n\nexport default SetupSection;\n"],"file":"index.js"}
@@ -25,7 +25,7 @@ var _default = {
25
25
  modified: true,
26
26
  onChange: value => console.log(value)
27
27
  },
28
- contentTypes: _extends({}, contentTypes, {
28
+ contentTypes: _extends(_extends({}, contentTypes), {}, {
29
29
  modified: true
30
30
  })
31
31
  }
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../src/molecule/setup-section/test/fixtures/first.js"],"names":["props","contentTypes","ContentTypes","id","title","onUp","onDown","e","console","log","display","value","modified","onChange"],"mappings":";;;;;AAAA;;;;;;AAEA,MAAM;AAACA,EAAAA,KAAK,EAAEC;AAAR,IAAwBC,iBAA9B;eAEe;AACbF,EAAAA,KAAK,EAAE;AACLG,IAAAA,EAAE,EAAE,OADC;AAELC,IAAAA,KAAK,EAAE,qBAFF;AAGLC,IAAAA,IAAI,EAAE,IAHD;AAILC,IAAAA,MAAM,EAAEC,CAAC,IAAI;AACXC,MAAAA,OAAO,CAACC,GAAR,CAAYF,CAAZ;AACD,KANI;AAOLG,IAAAA,OAAO,EAAE;AACPC,MAAAA,KAAK,EAAE,IADA;AAEPC,MAAAA,QAAQ,EAAE,IAFH;AAGPC,MAAAA,QAAQ,EAAEF,KAAK,IAAIH,OAAO,CAACC,GAAR,CAAYE,KAAZ;AAHZ,KAPJ;AAYLV,IAAAA,YAAY,eACPA,YADO;AAEVW,MAAAA,QAAQ,EAAE;AAFA;AAZP;AADM,C","sourcesContent":["import ContentTypes from '../../../../atom/radio-group/test/fixtures/default';\n\nconst {props: contentTypes} = ContentTypes;\n\nexport default {\n props: {\n id: 'first',\n title: 'Recommended for you',\n onUp: null,\n onDown: e => {\n console.log(e);\n },\n display: {\n value: true,\n modified: true,\n onChange: value => console.log(value)\n },\n contentTypes: {\n ...contentTypes,\n modified: true\n }\n }\n};\n"],"file":"first.js"}
1
+ {"version":3,"sources":["../../../../../src/molecule/setup-section/test/fixtures/first.js"],"names":["props","contentTypes","ContentTypes","id","title","onUp","onDown","e","console","log","display","value","modified","onChange"],"mappings":";;;;;AAAA;;;;;;AAEA,MAAM;AAACA,EAAAA,KAAK,EAAEC;AAAR,IAAwBC,iBAA9B;eAEe;AACbF,EAAAA,KAAK,EAAE;AACLG,IAAAA,EAAE,EAAE,OADC;AAELC,IAAAA,KAAK,EAAE,qBAFF;AAGLC,IAAAA,IAAI,EAAE,IAHD;AAILC,IAAAA,MAAM,EAAEC,CAAC,IAAI;AACXC,MAAAA,OAAO,CAACC,GAAR,CAAYF,CAAZ;AACD,KANI;AAOLG,IAAAA,OAAO,EAAE;AACPC,MAAAA,KAAK,EAAE,IADA;AAEPC,MAAAA,QAAQ,EAAE,IAFH;AAGPC,MAAAA,QAAQ,EAAEF,KAAK,IAAIH,OAAO,CAACC,GAAR,CAAYE,KAAZ;AAHZ,KAPJ;AAYLV,IAAAA,YAAY,wBACPA,YADO;AAEVW,MAAAA,QAAQ,EAAE;AAFA;AAZP;AADM,C","sourcesContent":["import ContentTypes from '../../../../atom/radio-group/test/fixtures/default';\n\nconst {props: contentTypes} = ContentTypes;\n\nexport default {\n props: {\n id: 'first',\n title: 'Recommended for you',\n onUp: null,\n onDown: e => {\n console.log(e);\n },\n display: {\n value: true,\n modified: true,\n onChange: value => console.log(value)\n },\n contentTypes: {\n ...contentTypes,\n modified: true\n }\n }\n};\n"],"file":"first.js"}
@@ -17,9 +17,9 @@ var _style = _interopRequireDefault(require("./style.css"));
17
17
 
18
18
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
19
 
20
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
20
+ function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
21
21
 
22
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
22
+ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
23
23
 
24
24
  function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
25
25
 
@@ -99,21 +99,21 @@ SetupSlide.defaultProps = {
99
99
  fields: []
100
100
  };
101
101
  SetupSlide.propTypes = process.env.NODE_ENV !== "production" ? {
102
- fields: _propTypes.default.arrayOf(_propTypes.default.oneOfType([_propTypes.default.shape(_extends({}, _inputSwitch.default.propTypes, {
102
+ fields: _propTypes.default.arrayOf(_propTypes.default.oneOfType([_propTypes.default.shape(_extends(_extends({}, _inputSwitch.default.propTypes), {}, {
103
103
  type: _propTypes.default.oneOf(['switch'])
104
- })), _propTypes.default.shape(_extends({}, _select.default.propTypes, {
104
+ })), _propTypes.default.shape(_extends(_extends({}, _select.default.propTypes), {}, {
105
105
  type: _propTypes.default.oneOf(['select'])
106
- })), _propTypes.default.shape(_extends({}, _inputCheckbox.default.propTypes, {
106
+ })), _propTypes.default.shape(_extends(_extends({}, _inputCheckbox.default.propTypes), {}, {
107
107
  type: _propTypes.default.oneOf(['checkbox'])
108
- })), _propTypes.default.shape(_extends({}, _imageUpload.default.propTypes, {
108
+ })), _propTypes.default.shape(_extends(_extends({}, _imageUpload.default.propTypes), {}, {
109
109
  type: _propTypes.default.oneOf(['image'])
110
- })), _propTypes.default.shape(_extends({}, _inputReadonly.default.propTypes, {
110
+ })), _propTypes.default.shape(_extends(_extends({}, _inputReadonly.default.propTypes), {}, {
111
111
  type: _propTypes.default.oneOf(['readonly'])
112
- })), _propTypes.default.shape(_extends({}, _inputDoublestep.default.propTypes, {
112
+ })), _propTypes.default.shape(_extends(_extends({}, _inputDoublestep.default.propTypes), {}, {
113
113
  type: _propTypes.default.oneOf(['doublestep'])
114
- })), _propTypes.default.shape(_extends({}, _setupCohortItem.default.propTypes, {
114
+ })), _propTypes.default.shape(_extends(_extends({}, _setupCohortItem.default.propTypes), {}, {
115
115
  type: _propTypes.default.oneOf(['splitForm'])
116
- })), _propTypes.default.shape(_extends({}, _messagePopin.default.propTypes, {
116
+ })), _propTypes.default.shape(_extends(_extends({}, _messagePopin.default.propTypes), {}, {
117
117
  type: _propTypes.default.oneOf(['alert'])
118
118
  })), _propTypes.default.shape(_inputText.default.propTypes)]))
119
119
  } : {};
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/molecule/setup-slide/index.js"],"names":["SetupSlide","props","fields","buildInput","field","type","title","subtitle","buildField","index","input","style","fieldsList","convert","cap","wrapper","defaultProps","propTypes","PropTypes","arrayOf","oneOfType","shape","InputSwitch","oneOf","Select","InputCheckbox","ImageUpload","InputReadonly","InputDoublestep","SetupCohortItem","MessagePopin","InputText"],"mappings":";;;;;;;AAAA;;AACA;;AAEA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;AAEA,MAAMA,UAAU,GAAGC,KAAK,IAAI;AAC1B,QAAM;AAACC,IAAAA;AAAD,MAAWD,KAAjB;;AACA,QAAME,UAAU,GAAGC,KAAK,IAAI;AAC1B,UAAM;AAACC,MAAAA;AAAD,QAASD,KAAf;;AACA,YAAQC,IAAR;AACE,WAAK,QAAL;AACE,4BAAO,6BAAC,oBAAD,EAAiBD,KAAjB,CAAP;;AACF,WAAK,QAAL;AACE,4BAAO,6BAAC,eAAD,EAAYA,KAAZ,CAAP;;AACF,WAAK,UAAL;AACE,4BAAO,6BAAC,sBAAD,EAAmBA,KAAnB,CAAP;;AACF,WAAK,OAAL;AACE,4BAAO,6BAAC,oBAAD,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;AAEEZ,IAAAA,IAAI,EAAEa,mBAAUK,KAAV,CAAgB,CAAC,QAAD,CAAhB;AAFR,KALkB,EASlBL,mBAAUG,KAAV,cACKI,uBAAcR,SADnB;AAEEZ,IAAAA,IAAI,EAAEa,mBAAUK,KAAV,CAAgB,CAAC,UAAD,CAAhB;AAFR,KATkB,EAalBL,mBAAUG,KAAV,cACKK,qBAAYT,SADjB;AAEEZ,IAAAA,IAAI,EAAEa,mBAAUK,KAAV,CAAgB,CAAC,OAAD,CAAhB;AAFR,KAbkB,EAiBlBL,mBAAUG,KAAV,cACKM,uBAAcV,SADnB;AAEEZ,IAAAA,IAAI,EAAEa,mBAAUK,KAAV,CAAgB,CAAC,UAAD,CAAhB;AAFR,KAjBkB,EAqBlBL,mBAAUG,KAAV,cACKO,yBAAgBX,SADrB;AAEEZ,IAAAA,IAAI,EAAEa,mBAAUK,KAAV,CAAgB,CAAC,YAAD,CAAhB;AAFR,KArBkB,EAyBlBL,mBAAUG,KAAV,cACKQ,yBAAgBZ,SADrB;AAEEZ,IAAAA,IAAI,EAAEa,mBAAUK,KAAV,CAAgB,CAAC,WAAD,CAAhB;AAFR,KAzBkB,EA6BlBL,mBAAUG,KAAV,cACKS,sBAAab,SADlB;AAEEZ,IAAAA,IAAI,EAAEa,mBAAUK,KAAV,CAAgB,CAAC,OAAD,CAAhB;AAFR,KA7BkB,EAiClBL,mBAAUG,KAAV,CAAgBU,mBAAUd,SAA1B,CAjCkB,CAApB,CADM;AADa,CAAvB;eAuCejB,U","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {map} from 'lodash/fp';\nimport Select from '../../atom/select';\nimport InputReadonly from '../../atom/input-readonly';\nimport InputText from '../../atom/input-text';\nimport InputCheckbox from '../../atom/input-checkbox';\nimport InputDoublestep from '../../atom/input-doublestep';\nimport InputSwitch from '../../atom/input-switch';\nimport ImageUpload from '../../atom/image-upload';\nimport SetupCohortItem from '../setup-cohort-item';\nimport MessagePopin from '../message-popin';\nimport style from './style.css';\n\nconst SetupSlide = props => {\n const {fields} = props;\n const buildInput = field => {\n const {type} = field;\n switch (type) {\n case 'switch':\n return <InputSwitch {...field} />;\n case 'select':\n return <Select {...field} />;\n case 'checkbox':\n return <InputCheckbox {...field} />;\n case 'image':\n return <ImageUpload {...field} />;\n case 'splitForm':\n return <SetupCohortItem field={field} />;\n case 'alert':\n return <MessagePopin header={field.title} content={field.subtitle} />;\n case 'readonly':\n return <InputReadonly {...field} />;\n case 'doublestep':\n return <InputDoublestep {...field} />;\n default:\n return <InputText {...field} />;\n }\n };\n\n const buildField = (field, index) => {\n const input = buildInput(field);\n return (\n <div className={style.field} key={index}>\n {input}\n </div>\n );\n };\n\n const fieldsList = map.convert({cap: false})(buildField, fields);\n\n return <div className={style.wrapper}>{fieldsList}</div>;\n};\n\nSetupSlide.defaultProps = {\n fields: []\n};\n\nSetupSlide.propTypes = {\n fields: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.shape({\n ...InputSwitch.propTypes,\n type: PropTypes.oneOf(['switch'])\n }),\n PropTypes.shape({\n ...Select.propTypes,\n type: PropTypes.oneOf(['select'])\n }),\n PropTypes.shape({\n ...InputCheckbox.propTypes,\n type: PropTypes.oneOf(['checkbox'])\n }),\n PropTypes.shape({\n ...ImageUpload.propTypes,\n type: PropTypes.oneOf(['image'])\n }),\n PropTypes.shape({\n ...InputReadonly.propTypes,\n type: PropTypes.oneOf(['readonly'])\n }),\n PropTypes.shape({\n ...InputDoublestep.propTypes,\n type: PropTypes.oneOf(['doublestep'])\n }),\n PropTypes.shape({\n ...SetupCohortItem.propTypes,\n type: PropTypes.oneOf(['splitForm'])\n }),\n PropTypes.shape({\n ...MessagePopin.propTypes,\n type: PropTypes.oneOf(['alert'])\n }),\n PropTypes.shape(InputText.propTypes)\n ])\n )\n};\nexport default SetupSlide;\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../../../src/molecule/setup-slide/index.js"],"names":["SetupSlide","props","fields","buildInput","field","type","title","subtitle","buildField","index","input","style","fieldsList","convert","cap","wrapper","defaultProps","propTypes","PropTypes","arrayOf","oneOfType","shape","InputSwitch","oneOf","Select","InputCheckbox","ImageUpload","InputReadonly","InputDoublestep","SetupCohortItem","MessagePopin","InputText"],"mappings":";;;;;;;AAAA;;AACA;;AAEA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;AAEA,MAAMA,UAAU,GAAGC,KAAK,IAAI;AAC1B,QAAM;AAACC,IAAAA;AAAD,MAAWD,KAAjB;;AACA,QAAME,UAAU,GAAGC,KAAK,IAAI;AAC1B,UAAM;AAACC,MAAAA;AAAD,QAASD,KAAf;;AACA,YAAQC,IAAR;AACE,WAAK,QAAL;AACE,4BAAO,6BAAC,oBAAD,EAAiBD,KAAjB,CAAP;;AACF,WAAK,QAAL;AACE,4BAAO,6BAAC,eAAD,EAAYA,KAAZ,CAAP;;AACF,WAAK,UAAL;AACE,4BAAO,6BAAC,sBAAD,EAAmBA,KAAnB,CAAP;;AACF,WAAK,OAAL;AACE,4BAAO,6BAAC,oBAAD,EAAiBA,KAAjB,CAAP;;AACF,WAAK,WAAL;AACE,4BAAO,6BAAC,wBAAD;AAAiB,UAAA,KAAK,EAAEA;AAAxB,UAAP;;AACF,WAAK,OAAL;AACE,4BAAO,6BAAC,qBAAD;AAAc,UAAA,MAAM,EAAEA,KAAK,CAACE,KAA5B;AAAmC,UAAA,OAAO,EAAEF,KAAK,CAACG;AAAlD,UAAP;;AACF,WAAK,UAAL;AACE,4BAAO,6BAAC,sBAAD,EAAmBH,KAAnB,CAAP;;AACF,WAAK,YAAL;AACE,4BAAO,6BAAC,wBAAD,EAAqBA,KAArB,CAAP;;AACF;AACE,4BAAO,6BAAC,kBAAD,EAAeA,KAAf,CAAP;AAlBJ;AAoBD,GAtBD;;AAwBA,QAAMI,UAAU,GAAG,CAACJ,KAAD,EAAQK,KAAR,KAAkB;AACnC,UAAMC,KAAK,GAAGP,UAAU,CAACC,KAAD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,CAAgB,CAAC,YAAD,CAAhB;AAFR,KArBkB,EAyBlBL,mBAAUG,KAAV,uBACKQ,yBAAgBZ,SADrB;AAEEZ,IAAAA,IAAI,EAAEa,mBAAUK,KAAV,CAAgB,CAAC,WAAD,CAAhB;AAFR,KAzBkB,EA6BlBL,mBAAUG,KAAV,uBACKS,sBAAab,SADlB;AAEEZ,IAAAA,IAAI,EAAEa,mBAAUK,KAAV,CAAgB,CAAC,OAAD,CAAhB;AAFR,KA7BkB,EAiClBL,mBAAUG,KAAV,CAAgBU,mBAAUd,SAA1B,CAjCkB,CAApB,CADM;AADa,CAAvB;eAuCejB,U","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {map} from 'lodash/fp';\nimport Select from '../../atom/select';\nimport InputReadonly from '../../atom/input-readonly';\nimport InputText from '../../atom/input-text';\nimport InputCheckbox from '../../atom/input-checkbox';\nimport InputDoublestep from '../../atom/input-doublestep';\nimport InputSwitch from '../../atom/input-switch';\nimport ImageUpload from '../../atom/image-upload';\nimport SetupCohortItem from '../setup-cohort-item';\nimport MessagePopin from '../message-popin';\nimport style from './style.css';\n\nconst SetupSlide = props => {\n const {fields} = props;\n const buildInput = field => {\n const {type} = field;\n switch (type) {\n case 'switch':\n return <InputSwitch {...field} />;\n case 'select':\n return <Select {...field} />;\n case 'checkbox':\n return <InputCheckbox {...field} />;\n case 'image':\n return <ImageUpload {...field} />;\n case 'splitForm':\n return <SetupCohortItem field={field} />;\n case 'alert':\n return <MessagePopin header={field.title} content={field.subtitle} />;\n case 'readonly':\n return <InputReadonly {...field} />;\n case 'doublestep':\n return <InputDoublestep {...field} />;\n default:\n return <InputText {...field} />;\n }\n };\n\n const buildField = (field, index) => {\n const input = buildInput(field);\n return (\n <div className={style.field} key={index}>\n {input}\n </div>\n );\n };\n\n const fieldsList = map.convert({cap: false})(buildField, fields);\n\n return <div className={style.wrapper}>{fieldsList}</div>;\n};\n\nSetupSlide.defaultProps = {\n fields: []\n};\n\nSetupSlide.propTypes = {\n fields: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.shape({\n ...InputSwitch.propTypes,\n type: PropTypes.oneOf(['switch'])\n }),\n PropTypes.shape({\n ...Select.propTypes,\n type: PropTypes.oneOf(['select'])\n }),\n PropTypes.shape({\n ...InputCheckbox.propTypes,\n type: PropTypes.oneOf(['checkbox'])\n }),\n PropTypes.shape({\n ...ImageUpload.propTypes,\n type: PropTypes.oneOf(['image'])\n }),\n PropTypes.shape({\n ...InputReadonly.propTypes,\n type: PropTypes.oneOf(['readonly'])\n }),\n PropTypes.shape({\n ...InputDoublestep.propTypes,\n type: PropTypes.oneOf(['doublestep'])\n }),\n PropTypes.shape({\n ...SetupCohortItem.propTypes,\n type: PropTypes.oneOf(['splitForm'])\n }),\n PropTypes.shape({\n ...MessagePopin.propTypes,\n type: PropTypes.oneOf(['alert'])\n }),\n PropTypes.shape(InputText.propTypes)\n ])\n )\n};\nexport default SetupSlide;\n"],"file":"index.js"}
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
 
3
3
  exports.__esModule = true;
4
- exports.default = exports.ShareStatusProvider = exports.ShareFeedback = void 0;
4
+ exports.default = exports.ShareFeedback = exports.ShareStatusProvider = void 0;
5
5
 
6
6
  var _react = _interopRequireWildcard(require("react"));
7
7
 
@@ -17,9 +17,9 @@ var _style = _interopRequireDefault(require("./style.css"));
17
17
 
18
18
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
19
 
20
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
20
+ function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
21
21
 
22
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
22
+ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
23
23
 
24
24
  const SHARE_STATUS = {
25
25
  IDLE: 'IDLE',
@@ -55,7 +55,7 @@ const copyTextViaExecCommand = text => {
55
55
  return status;
56
56
  };
57
57
 
58
- const StatusContext = /*#__PURE__*/_react.default.createContext(SHARE_STATUS.IDLE);
58
+ const StatusContext = _react.default.createContext(SHARE_STATUS.IDLE);
59
59
 
60
60
  const ShareStatusProvider = ({
61
61
  children
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/molecule/share/index.js"],"names":["SHARE_STATUS","IDLE","ERROR","SUCCESS","copyTextViaExecCommand","text","textarea","document","createElement","style","border","padding","visibility","position","setAttribute","value","body","appendChild","status","select","setSelectionRange","length","execCommand","error","removeChild","StatusContext","React","createContext","ShareStatusProvider","children","setStatus","timeoutId","DURATION","setTimeout","clearTimeout","ShareFeedback","successWording","errorWording","styles","feedback","errorFeedback","checkIcon","Share","wording","onClick","browserSupportsClipboardWriteText","navigator","clipboard","writeText","copyStatus","container","cta","wrapper","shareIcon","propTypes","PropTypes","node","string"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AAKA;;AACA;;;;;;;;AAEA,MAAMA,YAAY,GAAG;AACnBC,EAAAA,IAAI,EAAE,MADa;AAEnBC,EAAAA,KAAK,EAAE,OAFY;AAGnBC,EAAAA,OAAO,EAAE;AAHU,CAArB;;AAMA,MAAMC,sBAAsB,GAAGC,IAAI,IAAI;AACrC,QAAMC,QAAQ,GAAGC,QAAQ,CAACC,aAAT,CAAuB,UAAvB,CAAjB;AAEAF,EAAAA,QAAQ,CAACG,KAAT,CAAeC,MAAf,GAAwB,GAAxB;AACAJ,EAAAA,QAAQ,CAACG,KAAT,CAAeE,OAAf,GAAyB,GAAzB;AACAL,EAAAA,QAAQ,CAACG,KAAT,CAAeG,UAAf,GAA4B,QAA5B;AACAN,EAAAA,QAAQ,CAACG,KAAT,CAAeI,QAAf,GAA0B,UAA1B;AACAP,EAAAA,QAAQ,CAACQ,YAAT,CAAsB,UAAtB,EAAkC,EAAlC;AACAR,EAAAA,QAAQ,CAACS,KAAT,GAAiBV,IAAjB,CARqC,CAUrC;AACA;;AACAE,EAAAA,QAAQ,CAACS,IAAT,CAAcC,WAAd,CAA0BX,QAA1B;AACA,MAAIY,MAAM,GAAGlB,YAAY,CAACC,IAA1B;;AAEA,MAAI;AACFK,IAAAA,QAAQ,CAACa,MAAT;AACAb,IAAAA,QAAQ,CAACc,iBAAT,CAA2B,CAA3B,EAA8Bd,QAAQ,CAACS,KAAT,CAAeM,MAA7C;AACAd,IAAAA,QAAQ,CAACe,WAAT,CAAqB,MAArB;AACAJ,IAAAA,MAAM,GAAGlB,YAAY,CAACG,OAAtB;AACD,GALD,CAKE,OAAOoB,KA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Ad,kBACE,6BAAC,aAAD;AAAM,IAAA,OAAO,EAAEmC,OAAf;AAAwB,IAAA,SAAS,EAAEN,eAAOa,GAA1C;AAA+C,iBAAW;AAA1D,kBACE;AAAK,IAAA,SAAS,EAAEb,eAAOc;AAAvB,kBACE,6BAAC,2CAAD;AAAW,IAAA,SAAS,EAAEd,eAAOe,SAA7B;AAAwC,IAAA,KAAK,EAAE,EAA/C;AAAmD,IAAA,MAAM,EAAE;AAA3D,IADF,eAEE,wCAAIV,OAAJ,CAFF,CADF,CADF,CADF;AAUD,CA9BD;;AAgCAf,mBAAmB,CAAC0B,SAApB,2CAAgC;AAC9BzB,EAAAA,QAAQ,EAAE0B,mBAAUC;AADU,CAAhC;AAIArB,aAAa,CAACmB,SAAd,2CAA0B;AACxBlB,EAAAA,cAAc,EAAEmB,mBAAUE,MADF;AAExBpB,EAAAA,YAAY,EAAEkB,mBAAUE;AAFA,CAA1B;AAKAf,KAAK,CAACY,SAAN,2CAAkB;AAChB7C,EAAAA,KAAK,EAAE8C,mBAAUE,MADD;AAEhBpD,EAAAA,IAAI,EAAEkD,mBAAUE,MAFA;AAGhBd,EAAAA,OAAO,EAAEY,mBAAUE;AAHH,CAAlB;eAMef,K","sourcesContent":["import React, {useState, useMemo, useCallback, useContext, useEffect} from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n NovaCompositionCoorpacademyCheck as CheckIcon,\n NovaCompositionCoorpacademyShare as ShareIcon,\n NovaCompositionCoorpacademyAttention as AttentionIcon\n} from '@coorpacademy/nova-icons';\nimport Link from '../../atom/link';\nimport styles from './style.css';\n\nconst SHARE_STATUS = {\n IDLE: 'IDLE',\n ERROR: 'ERROR',\n SUCCESS: 'SUCCESS'\n};\n\nconst copyTextViaExecCommand = text => {\n const textarea = document.createElement('textarea');\n\n textarea.style.border = '0';\n textarea.style.padding = '0';\n textarea.style.visibility = 'hidden';\n textarea.style.position = 'absolute';\n textarea.setAttribute('readonly', '');\n textarea.value = text;\n\n // Element.append is not supported on IE11 :/\n // eslint-disable-next-line unicorn/prefer-node-append\n document.body.appendChild(textarea);\n let status = SHARE_STATUS.IDLE;\n\n try {\n textarea.select();\n textarea.setSelectionRange(0, textarea.value.length);\n document.execCommand('copy');\n status = SHARE_STATUS.SUCCESS;\n } catch (error) {\n status = SHARE_STATUS.ERROR;\n }\n\n // Element.remove is not supported on IE11 :/\n // eslint-disable-next-line unicorn/prefer-node-remove\n document.body.removeChild(textarea);\n\n return status;\n};\n\nconst StatusContext = React.createContext(SHARE_STATUS.IDLE);\n\nexport const ShareStatusProvider = ({children}) => {\n const [status, setStatus] = useState(SHARE_STATUS.IDLE);\n useEffect(() => {\n let timeoutId;\n const DURATION = 3000;\n if (status !== SHARE_STATUS.IDLE) {\n timeoutId = setTimeout(() => setStatus(SHARE_STATUS.IDLE), DURATION);\n }\n return () => clearTimeout(timeoutId);\n }, [status]);\n\n const value = useMemo(() => [status, setStatus], [status]);\n\n return <StatusContext.Provider value={value}>{children}</StatusContext.Provider>;\n};\n\nexport const ShareFeedback = ({successWording, errorWording}) => {\n const [status] = useContext(StatusContext);\n if (status === SHARE_STATUS.IDLE) return null;\n\n return (\n <div\n className={classnames(styles.feedback, status === SHARE_STATUS.ERROR && styles.errorFeedback)}\n >\n {status === SHARE_STATUS.SUCCESS ? (\n <CheckIcon className={styles.checkIcon} width={13} height={13} />\n ) : (\n <AttentionIcon className={styles.checkIcon} width={13} height={13} />\n )}\n <p>{status === SHARE_STATUS.SUCCESS ? successWording : errorWording}</p>\n </div>\n );\n};\n\nconst Share = ({style, text, wording}) => {\n const [, setStatus] = useContext(StatusContext);\n const onClick = useCallback(async () => {\n const browserSupportsClipboardWriteText =\n 'clipboard' in navigator && 'writeText' in navigator.clipboard;\n if (browserSupportsClipboardWriteText) {\n try {\n await navigator.clipboard.writeText(text);\n setStatus(SHARE_STATUS.SUCCESS);\n } catch (error) {\n setStatus(SHARE_STATUS.ERROR);\n }\n return;\n } else {\n const copyStatus = copyTextViaExecCommand(text);\n setStatus(copyStatus);\n }\n return;\n }, [setStatus]);\n\n return (\n <div className={(styles.container, style)}>\n <Link onClick={onClick} className={styles.cta} data-name={'share-button'}>\n <div className={styles.wrapper}>\n <ShareIcon className={styles.shareIcon} width={18} height={18} />\n <p>{wording}</p>\n </div>\n </Link>\n </div>\n );\n};\n\nShareStatusProvider.propTypes = {\n children: PropTypes.node\n};\n\nShareFeedback.propTypes = {\n successWording: PropTypes.string,\n errorWording: PropTypes.string\n};\n\nShare.propTypes = {\n style: PropTypes.string,\n text: PropTypes.string,\n wording: PropTypes.string\n};\n\nexport default Share;\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../../../src/molecule/share/index.js"],"names":["SHARE_STATUS","IDLE","ERROR","SUCCESS","copyTextViaExecCommand","text","textarea","document","createElement","style","border","padding","visibility","position","setAttribute","value","body","appendChild","status","select","setSelectionRange","length","execCommand","error","removeChild","StatusContext","React","createContext","ShareStatusProvider","children","setStatus","timeoutId","DURATION","setTimeout","clearTimeout","ShareFeedback","successWording","errorWording","styles","feedback","errorFeedback","checkIcon","Share","wording","onClick","browserSupportsClipboardWriteText","navigator","clipboard","writeText","copyStatus","container","cta","wrapper","shareIcon","propTypes","PropTypes","node","string"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AAKA;;AACA;;;;;;;;AAEA,MAAMA,YAAY,GAAG;AACnBC,EAAAA,IAAI,EAAE,MADa;AAEnBC,EAAAA,KAAK,EAAE,OAFY;AAGnBC,EAAAA,OAAO,EAAE;AAHU,CAArB;;AAMA,MAAMC,sBAAsB,GAAGC,IAAI,IAAI;AACrC,QAAMC,QAAQ,GAAGC,QAAQ,CAACC,aAAT,CAAuB,UAAvB,CAAjB;AAEAF,EAAAA,QAAQ,CAACG,KAAT,CAAeC,MAAf,GAAwB,GAAxB;AACAJ,EAAAA,QAAQ,CAACG,KAAT,CAAeE,OAAf,GAAyB,GAAzB;AACAL,EAAAA,QAAQ,CAACG,KAAT,CAAeG,UAAf,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A,IAAI,EAAEkD,mBAAUE,MAFA;AAGhBd,EAAAA,OAAO,EAAEY,mBAAUE;AAHH,CAAlB;eAMef,K","sourcesContent":["import React, {useState, useMemo, useCallback, useContext, useEffect} from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n NovaCompositionCoorpacademyCheck as CheckIcon,\n NovaCompositionCoorpacademyShare as ShareIcon,\n NovaCompositionCoorpacademyAttention as AttentionIcon\n} from '@coorpacademy/nova-icons';\nimport Link from '../../atom/link';\nimport styles from './style.css';\n\nconst SHARE_STATUS = {\n IDLE: 'IDLE',\n ERROR: 'ERROR',\n SUCCESS: 'SUCCESS'\n};\n\nconst copyTextViaExecCommand = text => {\n const textarea = document.createElement('textarea');\n\n textarea.style.border = '0';\n textarea.style.padding = '0';\n textarea.style.visibility = 'hidden';\n textarea.style.position = 'absolute';\n textarea.setAttribute('readonly', '');\n textarea.value = text;\n\n // Element.append is not supported on IE11 :/\n // eslint-disable-next-line unicorn/prefer-node-append\n document.body.appendChild(textarea);\n let status = SHARE_STATUS.IDLE;\n\n try {\n textarea.select();\n textarea.setSelectionRange(0, textarea.value.length);\n document.execCommand('copy');\n status = SHARE_STATUS.SUCCESS;\n } catch (error) {\n status = SHARE_STATUS.ERROR;\n }\n\n // Element.remove is not supported on IE11 :/\n // eslint-disable-next-line unicorn/prefer-node-remove\n document.body.removeChild(textarea);\n\n return status;\n};\n\nconst StatusContext = React.createContext(SHARE_STATUS.IDLE);\n\nexport const ShareStatusProvider = ({children}) => {\n const [status, setStatus] = useState(SHARE_STATUS.IDLE);\n useEffect(() => {\n let timeoutId;\n const DURATION = 3000;\n if (status !== SHARE_STATUS.IDLE) {\n timeoutId = setTimeout(() => setStatus(SHARE_STATUS.IDLE), DURATION);\n }\n return () => clearTimeout(timeoutId);\n }, [status]);\n\n const value = useMemo(() => [status, setStatus], [status]);\n\n return <StatusContext.Provider value={value}>{children}</StatusContext.Provider>;\n};\n\nexport const ShareFeedback = ({successWording, errorWording}) => {\n const [status] = useContext(StatusContext);\n if (status === SHARE_STATUS.IDLE) return null;\n\n return (\n <div\n className={classnames(styles.feedback, status === SHARE_STATUS.ERROR && styles.errorFeedback)}\n >\n {status === SHARE_STATUS.SUCCESS ? (\n <CheckIcon className={styles.checkIcon} width={13} height={13} />\n ) : (\n <AttentionIcon className={styles.checkIcon} width={13} height={13} />\n )}\n <p>{status === SHARE_STATUS.SUCCESS ? successWording : errorWording}</p>\n </div>\n );\n};\n\nconst Share = ({style, text, wording}) => {\n const [, setStatus] = useContext(StatusContext);\n const onClick = useCallback(async () => {\n const browserSupportsClipboardWriteText =\n 'clipboard' in navigator && 'writeText' in navigator.clipboard;\n if (browserSupportsClipboardWriteText) {\n try {\n await navigator.clipboard.writeText(text);\n setStatus(SHARE_STATUS.SUCCESS);\n } catch (error) {\n setStatus(SHARE_STATUS.ERROR);\n }\n return;\n } else {\n const copyStatus = copyTextViaExecCommand(text);\n setStatus(copyStatus);\n }\n return;\n }, [setStatus]);\n\n return (\n <div className={(styles.container, style)}>\n <Link onClick={onClick} className={styles.cta} data-name={'share-button'}>\n <div className={styles.wrapper}>\n <ShareIcon className={styles.shareIcon} width={18} height={18} />\n <p>{wording}</p>\n </div>\n </Link>\n </div>\n );\n};\n\nShareStatusProvider.propTypes = {\n children: PropTypes.node\n};\n\nShareFeedback.propTypes = {\n successWording: PropTypes.string,\n errorWording: PropTypes.string\n};\n\nShare.propTypes = {\n style: PropTypes.string,\n text: PropTypes.string,\n wording: PropTypes.string\n};\n\nexport default Share;\n"],"file":"index.js"}
@@ -17,9 +17,9 @@ var _style = _interopRequireDefault(require("./style.css"));
17
17
 
18
18
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
19
 
20
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
20
+ function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
21
21
 
22
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
22
+ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
23
23
 
24
24
  const TitledCheckbox = props => {
25
25
  const {
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
 
3
3
  exports.__esModule = true;
4
- exports.iconAriaLabelSuccess = exports.iconAriaLabelError = exports.default = void 0;
4
+ exports.default = exports.iconAriaLabelSuccess = exports.iconAriaLabelError = void 0;
5
5
  const iconAriaLabelError = 'Locale with errors icon';
6
6
  exports.iconAriaLabelError = iconAriaLabelError;
7
7
  const iconAriaLabelSuccess = 'Validated locale icon';
@@ -10,6 +10,8 @@ var _ = _interopRequireDefault(require(".."));
10
10
 
11
11
  var _default = _interopRequireDefault(require("./fixtures/default"));
12
12
 
13
+ var _withMultipleErrors = _interopRequireDefault(require("./fixtures/with-multiple-errors"));
14
+
13
15
  var _withSelectedItem = _interopRequireDefault(require("./fixtures/with-selected-item"));
14
16
 
15
17
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
@@ -21,5 +23,6 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
21
23
  });
22
24
  });
23
25
  (0, _ava.default)('Molecule › MoleculeVerticalTabs › Default › should be rendered', _renderComponent.default, _.default, _default.default);
26
+ (0, _ava.default)('Molecule › MoleculeVerticalTabs › WithMultipleErrors › should be rendered', _renderComponent.default, _.default, _withMultipleErrors.default);
24
27
  (0, _ava.default)('Molecule › MoleculeVerticalTabs › WithSelectedItem › should be rendered', _renderComponent.default, _.default, _withSelectedItem.default);
25
28
  //# sourceMappingURL=fixtures.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/molecule/vertical-tabs/test/fixtures.js"],"names":["t","pass","MoleculeVerticalTabs","propTypes","value","key","not","undefined","renderComponentMacro","fixtureDefault","fixtureWithSelectedItem"],"mappings":";;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;AAEA,kBAAK,+DAAL,EAAsEA,CAAC,IAAI;AACzEA,EAAAA,CAAC,CAACC,IAAF;AACA,wBAAQC,UAAqBC,SAA7B,EAAwC,CAACC,KAAD,EAAQC,GAAR,KAAgB;AACtDL,IAAAA,CAAC,CAACM,GAAF,CAAMF,KAAN,EAAaG,SAAb,EAAyB,yDAAwDF,GAAI,mEAArF;AACD,GAFD;AAGD,CALD;AAOA,kBAAK,gEAAL,EAAuEG,wBAAvE,EAA6FN,SAA7F,EAAmHO,gBAAnH;AACA,kBAAK,yEAAL,EAAgFD,wBAAhF,EAAsGN,SAAtG,EAA4HQ,yBAA5H","sourcesContent":["import test from 'ava';\nimport forEach from 'lodash/forEach';\nimport renderComponentMacro from '../../../test/helpers/render-component';\nimport MoleculeVerticalTabs from '..';\nimport fixtureDefault from './fixtures/default';\nimport fixtureWithSelectedItem from './fixtures/with-selected-item';\n\ntest('Molecule › MoleculeVerticalTabs > should have valid propTypes', t => {\n t.pass();\n forEach(MoleculeVerticalTabs.propTypes, (value, key) => {\n t.not(value, undefined, `PropType for \"Molecule.MoleculeVerticalTabs.propTypes.${key}\" may not be undefined. Did you mistype the propTypes definition?`);\n });\n});\n\ntest('Molecule › MoleculeVerticalTabs › Default › should be rendered', renderComponentMacro, MoleculeVerticalTabs, fixtureDefault);\ntest('Molecule › MoleculeVerticalTabs › WithSelectedItem › should be rendered', renderComponentMacro, MoleculeVerticalTabs, fixtureWithSelectedItem);\n"],"file":"fixtures.js"}
1
+ {"version":3,"sources":["../../../../src/molecule/vertical-tabs/test/fixtures.js"],"names":["t","pass","MoleculeVerticalTabs","propTypes","value","key","not","undefined","renderComponentMacro","fixtureDefault","fixtureWithMultipleErrors","fixtureWithSelectedItem"],"mappings":";;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;AAEA,kBAAK,+DAAL,EAAsEA,CAAC,IAAI;AACzEA,EAAAA,CAAC,CAACC,IAAF;AACA,wBAAQC,UAAqBC,SAA7B,EAAwC,CAACC,KAAD,EAAQC,GAAR,KAAgB;AACtDL,IAAAA,CAAC,CAACM,GAAF,CAAMF,KAAN,EAAaG,SAAb,EAAyB,yDAAwDF,GAAI,mEAArF;AACD,GAFD;AAGD,CALD;AAOA,kBAAK,gEAAL,EAAuEG,wBAAvE,EAA6FN,SAA7F,EAAmHO,gBAAnH;AACA,kBAAK,2EAAL,EAAkFD,wBAAlF,EAAwGN,SAAxG,EAA8HQ,2BAA9H;AACA,kBAAK,yEAAL,EAAgFF,wBAAhF,EAAsGN,SAAtG,EAA4HS,yBAA5H","sourcesContent":["import test from 'ava';\nimport forEach from 'lodash/forEach';\nimport renderComponentMacro from '../../../test/helpers/render-component';\nimport MoleculeVerticalTabs from '..';\nimport fixtureDefault from './fixtures/default';\nimport fixtureWithMultipleErrors from './fixtures/with-multiple-errors';\nimport fixtureWithSelectedItem from './fixtures/with-selected-item';\n\ntest('Molecule › MoleculeVerticalTabs > should have valid propTypes', t => {\n t.pass();\n forEach(MoleculeVerticalTabs.propTypes, (value, key) => {\n t.not(value, undefined, `PropType for \"Molecule.MoleculeVerticalTabs.propTypes.${key}\" may not be undefined. Did you mistype the propTypes definition?`);\n });\n});\n\ntest('Molecule › MoleculeVerticalTabs › Default › should be rendered', renderComponentMacro, MoleculeVerticalTabs, fixtureDefault);\ntest('Molecule › MoleculeVerticalTabs › WithMultipleErrors › should be rendered', renderComponentMacro, MoleculeVerticalTabs, fixtureWithMultipleErrors);\ntest('Molecule › MoleculeVerticalTabs › WithSelectedItem › should be rendered', renderComponentMacro, MoleculeVerticalTabs, fixtureWithSelectedItem);\n"],"file":"fixtures.js"}
@@ -32,7 +32,7 @@ const getUrl = ({
32
32
  }) => {
33
33
  switch (type) {
34
34
  case 'youtube':
35
- return `https://www.youtube.com/embed/${id}?${_qs.default.stringify(_extends({}, query, opts))}`;
35
+ return `https://www.youtube.com/embed/${id}?${_qs.default.stringify(_extends(_extends({}, query), opts))}`;
36
36
 
37
37
  case 'uptale':
38
38
  return `https://my.uptale.io/Experience/Launch?id=${id}`;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/molecule/video-iframe/index.js"],"names":["getUrl","url","type","id","query","opts","qs","stringify","VideoIframe","React","Component","componentDidMount","props","onPlay","render","autoplay","width","height","src","style","iframe","Vimeo","Provider","childContextTypes","propTypes","PropTypes","oneOf","string","SrcPropType","bool","func"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AAEA;;AACA;;AACA;;;;;;;;AAEA,MAAMA,MAAM,GAAG,CAAC;AAACC,EAAAA,GAAD;AAAMC,EAAAA,IAAN;AAAYC,EAAAA,EAAZ;AAAg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AAK,QAAT,GAAoB,KAApB,GAA4B,IANvC;AAOE,MAAA,SAAS,EAAEA,IAAI,KAAK,QAAT,GAAoB,IAApB,GAA2B,IAPxC;AAQE,MAAA,eAAe;AARjB,MADF;AAYD;;AAvCuC;;gBAApCM,W,kBAWkB;AACpBa,EAAAA,KAAK,EAAEC,kBAASC,iBAAT,CAA2BF;AADd,C;;AAXlBb,W,CACGgB,S,2CAAY;AACjBtB,EAAAA,IAAI,EAAEuB,mBAAUC,KAAV,CAAgB,CAAC,SAAD,EAAY,QAAZ,EAAsB,SAAtB,EAAiC,UAAjC,EAA6C,YAA7C,EAA2D,KAA3D,CAAhB,CADW;AAEjBV,EAAAA,KAAK,EAAES,mBAAUE,MAFA;AAGjBV,EAAAA,MAAM,EAAEQ,mBAAUE,MAHD;AAIjB1B,EAAAA,GAAG,EAAE2B,sBAJY;AAKjBzB,EAAAA,EAAE,EAAEsB,mBAAUE,MALG;AAMjBZ,EAAAA,QAAQ,EAAEU,mBAAUI,IANH;AAOjBhB,EAAAA,MAAM,EAAEY,mBAAUK;AAPD,C;eAyCNtB,W","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport qs from 'qs';\nimport {noop} from 'lodash/fp';\nimport Provider from '../../atom/provider';\nimport {SrcPropType} from '../../util/proptypes';\nimport style from './style.css';\n\nconst getUrl = ({url, type, id, query = {}, opts = {}}) => {\n switch (type) {\n case 'youtube':\n return `https://www.youtube.com/embed/${id}?${qs.stringify({...query, ...opts})}`;\n case 'uptale':\n return `https://my.uptale.io/Experience/Launch?id=${id}`;\n case 'omniPlayer':\n return `https://mms.myomni.live/${id}`;\n case 'jwplayer':\n return `https://content.jwplatform.com/players/${id}-7IMa4DCK.html`;\n default:\n return url;\n }\n};\n\nclass VideoIframe extends React.Component {\n static propTypes = {\n type: PropTypes.oneOf(['youtube', 'uptale', 'kontiki', 'jwplayer', 'omniPlayer', 'h5p']),\n width: PropTypes.string,\n height: PropTypes.string,\n url: SrcPropType,\n id: PropTypes.string,\n autoplay: PropTypes.bool,\n onPlay: PropTypes.func\n };\n\n static contextTypes = {\n Vimeo: Provider.childContextTypes.Vimeo\n };\n\n componentDidMount() {\n const {type} = this.props;\n if (type === 'kontiki') {\n const {onPlay = noop} = this.props;\n onPlay();\n }\n }\n\n render() {\n const {type, id, url, autoplay = false, width = '100%', height = '400px'} = this.props;\n const src = getUrl({url, type, id, autoplay});\n\n return (\n <iframe\n src={src}\n width={width}\n height={height}\n frameBorder={0}\n className={style.iframe}\n allowvr={type === 'uptale' ? 'yes' : null}\n scrolling={type === 'uptale' ? 'no' : null}\n allowFullScreen\n />\n );\n }\n}\n\nexport default VideoIframe;\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../../../src/molecule/video-iframe/index.js"],"names":["getUrl","url","type","id","query","opts","qs","stringify","VideoIframe","React","Component","componentDidMount","props","onPlay","render","autoplay","width","height","src","style","iframe","Vimeo","Provider","childContextTypes","propTypes","PropTypes","oneOf","string","SrcPropType","bool","func"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AAEA;;AACA;;AACA;;;;;;;;AAEA,MAAMA,MAAM,GAAG,CAAC;AAACC,EAAAA,GAAD;AAAMC,EAAAA,IAAN;AAAYC,EAAAA,EAAZ;AAAgBC,EAAAA,KAAK,GAAG,EAAxB;AAA4BC,EAAAA,IAAI,GAAG;AAAnC,CAAD,KAA4C;AACzD,UAAQH,IAAR;AACE,SAAK,SAAL;AACE,aAAQ,iCAAgCC,EAAG,IAAGG,YAAGC,SAAH,uBAAiBH,KAAjB,GAA2BC,IAA3B,EAAkC,EAAhF;;AACF,SAAK,QAAL;AACE,aAAQ,6CAA4CF,EAAG,EAAvD;;AACF,SAAK,YAAL;AACE,aAAQ,2BAA0BA,EAAG,EAArC;;AACF,SAAK,UAAL;AACE,aAAQ,0CAAyCA,EAAG,gBAApD;;AACF;AACE,aAAOF,GAAP;AAVJ;AAYD,CAbD;;AAeA,MAAMO,WAAN,SAA0BC,eAAMC,SAAhC,CAA0C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AAAA,MAAM,EAAEQ,mBAAUE,MAHD;AAIjB1B,EAAAA,GAAG,EAAE2B,sBAJY;AAKjBzB,EAAAA,EAAE,EAAEsB,mBAAUE,MALG;AAMjBZ,EAAAA,QAAQ,EAAEU,mBAAUI,IANH;AAOjBhB,EAAAA,MAAM,EAAEY,mBAAUK;AAPD,C;eAyCNtB,W","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport qs from 'qs';\nimport {noop} from 'lodash/fp';\nimport Provider from '../../atom/provider';\nimport {SrcPropType} from '../../util/proptypes';\nimport style from './style.css';\n\nconst getUrl = ({url, type, id, query = {}, opts = {}}) => {\n switch (type) {\n case 'youtube':\n return `https://www.youtube.com/embed/${id}?${qs.stringify({...query, ...opts})}`;\n case 'uptale':\n return `https://my.uptale.io/Experience/Launch?id=${id}`;\n case 'omniPlayer':\n return `https://mms.myomni.live/${id}`;\n case 'jwplayer':\n return `https://content.jwplatform.com/players/${id}-7IMa4DCK.html`;\n default:\n return url;\n }\n};\n\nclass VideoIframe extends React.Component {\n static propTypes = {\n type: PropTypes.oneOf(['youtube', 'uptale', 'kontiki', 'jwplayer', 'omniPlayer', 'h5p']),\n width: PropTypes.string,\n height: PropTypes.string,\n url: SrcPropType,\n id: PropTypes.string,\n autoplay: PropTypes.bool,\n onPlay: PropTypes.func\n };\n\n static contextTypes = {\n Vimeo: Provider.childContextTypes.Vimeo\n };\n\n componentDidMount() {\n const {type} = this.props;\n if (type === 'kontiki') {\n const {onPlay = noop} = this.props;\n onPlay();\n }\n }\n\n render() {\n const {type, id, url, autoplay = false, width = '100%', height = '400px'} = this.props;\n const src = getUrl({url, type, id, autoplay});\n\n return (\n <iframe\n src={src}\n width={width}\n height={height}\n frameBorder={0}\n className={style.iframe}\n allowvr={type === 'uptale' ? 'yes' : null}\n scrolling={type === 'uptale' ? 'no' : null}\n allowFullScreen\n />\n );\n }\n}\n\nexport default VideoIframe;\n"],"file":"index.js"}
@@ -17,8 +17,6 @@ var _vimeo = _interopRequireDefault(require("./vimeo"));
17
17
 
18
18
  var _style = _interopRequireDefault(require("./style.css"));
19
19
 
20
- const _excluded = ["disableAutostart", "jwpOptions"];
21
-
22
20
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
23
21
 
24
22
  function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
@@ -106,7 +104,7 @@ class VideoPlayer extends _react.default.Component {
106
104
  disableAutostart,
107
105
  jwpOptions
108
106
  } = _this$props,
109
- otherProps = _objectWithoutPropertiesLoose(_this$props, _excluded);
107
+ otherProps = _objectWithoutPropertiesLoose(_this$props, ["disableAutostart", "jwpOptions"]);
110
108
 
111
109
  return /*#__PURE__*/_react.default.createElement(_jwplayer.default, _extends({}, otherProps, {
112
110
  disableAutostart: disableAutostart,
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/molecule/video-player/index.js"],"names":["VideoPlayer","React","Component","getDerivedStateFromProps","props","state","id","played","constructor","e","onResume","onPlay","setState","mimeType","url","onPause","onEnded","width","height","style","wrapper","handleOnPlay","split","disableAutostart","jwpOptions","otherProps","render","renderPlayer","propTypes","PropTypes","string","SrcPropType","func","onError","autoplay","bool","JWPlayer","oneOf","isRequired"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;;;AAEA,MAAMA,WAAN,SAA0BC,eAAMC,SAAhC,CAA0C;AA0BT,SAAxBC,wBAAwB,CAACC,KAAD,EAAQC,KAAR,EAAe;AAC5C,QAAID,KAAK,CAACE,EAAN,KAAaD,KAAK,CAACC,EAAvB,EAA2B,OAAO,IAAP;AAE3B,WAAO;AACLA,MAAAA,EAAE,EAAEF,KAAK,CAACE,EADL;AAELC,MAAAA,MAAM,EAAE;AAFH,KAAP;AAID;;AAEDC,EAAA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,mBAAUG,IAPF;AAQjBhB,EAAAA,OAAO,EAAEa,mBAAUG,IARF;AASjBC,EAAAA,OAAO,EAAEJ,mBAAUG,IATF;AAUjBE,EAAAA,QAAQ,EAAEL,mBAAUM,IAVH;AAWjBZ,EAAAA,gBAAgB,EAAEM,mBAAUM,IAXX;AAYjBX,EAAAA,UAAU,EAAEY,kBAASR,SAAT,CAAmBJ,UAZd;AAajBX,EAAAA,QAAQ,EAAEgB,mBAAUQ,KAAV,CAAgB,CACxB,qBADwB,EAExB,oBAFwB,EAGxB,mBAHwB,EAIxB,qBAJwB,EAKxB,sBALwB,EAMxB,wBANwB,EAOxB,iBAPwB,EAQxB,WARwB,CAAhB,EASPC;AAtBc,C;eAmHNtC,W","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {SrcPropType} from '../../util/proptypes';\nimport VideoIframe from '../video-iframe';\nimport JWPlayer from './jwplayer';\nimport Vimeo from './vimeo';\nimport style from './style.css';\n\nclass VideoPlayer extends React.Component {\n static propTypes = {\n id: PropTypes.string,\n width: PropTypes.string,\n height: PropTypes.string,\n url: SrcPropType,\n onPlay: PropTypes.func,\n onResume: PropTypes.func,\n onPause: PropTypes.func,\n onEnded: PropTypes.func,\n onError: PropTypes.func,\n autoplay: PropTypes.bool,\n disableAutostart: PropTypes.bool,\n jwpOptions: JWPlayer.propTypes.jwpOptions,\n mimeType: PropTypes.oneOf([\n 'application/kontiki',\n 'application/uptale',\n 'application/vimeo',\n 'application/youtube',\n 'application/jwplayer',\n 'application/omniPlayer',\n 'application/h5p',\n 'video/mp4'\n ]).isRequired\n };\n\n static getDerivedStateFromProps(props, state) {\n if (props.id === state.id) return null;\n\n return {\n id: props.id,\n played: false\n };\n }\n\n constructor(props) {\n super(props);\n this.state = {\n played: false,\n id: props.id\n };\n }\n\n handleOnPlay = e => {\n const {played} = this.state;\n const {onResume, onPlay} = this.props;\n if (played) {\n if (onResume) onResume(e);\n } else if (onPlay) onPlay(e);\n this.setState({\n played: true\n });\n };\n\n renderPlayer = () => {\n const {mimeType, id, url, onPause, onEnded, width = '100%', height = '343px'} = this.props;\n switch (mimeType) {\n case 'application/vimeo':\n return (\n <Vimeo\n {...this.props}\n key={id}\n width={width}\n height={height}\n video={id}\n className={style.wrapper}\n onPlay={this.handleOnPlay}\n />\n );\n case 'application/youtube':\n case 'application/uptale':\n case 'application/h5p':\n case 'application/omniPlayer':\n return (\n <VideoIframe\n key={id}\n type={mimeType.split('application/')[1]}\n id={id}\n url={url}\n width={width}\n height={height}\n frameBorder={0}\n allowFullScreen\n onPlay={this.handleOnPlay}\n onPause={onPause}\n onEnded={onEnded}\n />\n );\n case 'application/kontiki':\n case 'application/jwplayer':\n case 'video/mp4': {\n const {disableAutostart, jwpOptions, ...otherProps} = this.props;\n\n return (\n <JWPlayer\n {...otherProps}\n disableAutostart={disableAutostart}\n jwpOptions={jwpOptions}\n onPlay={this.handleOnPlay}\n key={id}\n />\n );\n }\n }\n };\n\n render() {\n const {id} = this.props;\n return (\n <div data-name=\"video-player\" className={style.wrapper} key={id}>\n {this.renderPlayer()}\n </div>\n );\n }\n}\n\nexport default VideoPlayer;\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../../../src/molecule/video-player/index.js"],"names":["VideoPlayer","React","Component","getDerivedStateFromProps","props","state","id","played","constructor","e","onResume","onPlay","setState","mimeType","url","onPause","onEnded","width","height","style","wrapper","handleOnPlay","split","disableAutostart","jwpOptions","otherProps","render","renderPlayer","propTypes","PropTypes","string","SrcPropType","func","onError","autoplay","bool","JWPlayer","oneOf","isRequired"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAEA,MAAMA,WAAN,SAA0BC,eAAMC,SAAhC,CAA0C;AA0BxC,SAAOC,wBAAP,CAAgCC,KAAhC,EAAuCC,KAAvC,EAA8C;AAC5C,QAAID,KAAK,CAACE,EAAN,KAAaD,KAAK,CAACC,EAAvB,EAA2B,OAAO,IAAP;AAE3B,WAAO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AM,EAAEkB,mBAAUG,IALD;AAMjBtB,EAAAA,QAAQ,EAAEmB,mBAAUG,IANH;AAOjBjB,EAAAA,OAAO,EAAEc,mBAAUG,IAPF;AAQjBhB,EAAAA,OAAO,EAAEa,mBAAUG,IARF;AASjBC,EAAAA,OAAO,EAAEJ,mBAAUG,IATF;AAUjBE,EAAAA,QAAQ,EAAEL,mBAAUM,IAVH;AAWjBZ,EAAAA,gBAAgB,EAAEM,mBAAUM,IAXX;AAYjBX,EAAAA,UAAU,EAAEY,kBAASR,SAAT,CAAmBJ,UAZd;AAajBX,EAAAA,QAAQ,EAAEgB,mBAAUQ,KAAV,CAAgB,CACxB,qBADwB,EAExB,oBAFwB,EAGxB,mBAHwB,EAIxB,qBAJwB,EAKxB,sBALwB,EAMxB,wBANwB,EAOxB,iBAPwB,EAQxB,WARwB,CAAhB,EASPC;AAtBc,C;eAmHNtC,W","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {SrcPropType} from '../../util/proptypes';\nimport VideoIframe from '../video-iframe';\nimport JWPlayer from './jwplayer';\nimport Vimeo from './vimeo';\nimport style from './style.css';\n\nclass VideoPlayer extends React.Component {\n static propTypes = {\n id: PropTypes.string,\n width: PropTypes.string,\n height: PropTypes.string,\n url: SrcPropType,\n onPlay: PropTypes.func,\n onResume: PropTypes.func,\n onPause: PropTypes.func,\n onEnded: PropTypes.func,\n onError: PropTypes.func,\n autoplay: PropTypes.bool,\n disableAutostart: PropTypes.bool,\n jwpOptions: JWPlayer.propTypes.jwpOptions,\n mimeType: PropTypes.oneOf([\n 'application/kontiki',\n 'application/uptale',\n 'application/vimeo',\n 'application/youtube',\n 'application/jwplayer',\n 'application/omniPlayer',\n 'application/h5p',\n 'video/mp4'\n ]).isRequired\n };\n\n static getDerivedStateFromProps(props, state) {\n if (props.id === state.id) return null;\n\n return {\n id: props.id,\n played: false\n };\n }\n\n constructor(props) {\n super(props);\n this.state = {\n played: false,\n id: props.id\n };\n }\n\n handleOnPlay = e => {\n const {played} = this.state;\n const {onResume, onPlay} = this.props;\n if (played) {\n if (onResume) onResume(e);\n } else if (onPlay) onPlay(e);\n this.setState({\n played: true\n });\n };\n\n renderPlayer = () => {\n const {mimeType, id, url, onPause, onEnded, width = '100%', height = '343px'} = this.props;\n switch (mimeType) {\n case 'application/vimeo':\n return (\n <Vimeo\n {...this.props}\n key={id}\n width={width}\n height={height}\n video={id}\n className={style.wrapper}\n onPlay={this.handleOnPlay}\n />\n );\n case 'application/youtube':\n case 'application/uptale':\n case 'application/h5p':\n case 'application/omniPlayer':\n return (\n <VideoIframe\n key={id}\n type={mimeType.split('application/')[1]}\n id={id}\n url={url}\n width={width}\n height={height}\n frameBorder={0}\n allowFullScreen\n onPlay={this.handleOnPlay}\n onPause={onPause}\n onEnded={onEnded}\n />\n );\n case 'application/kontiki':\n case 'application/jwplayer':\n case 'video/mp4': {\n const {disableAutostart, jwpOptions, ...otherProps} = this.props;\n\n return (\n <JWPlayer\n {...otherProps}\n disableAutostart={disableAutostart}\n jwpOptions={jwpOptions}\n onPlay={this.handleOnPlay}\n key={id}\n />\n );\n }\n }\n };\n\n render() {\n const {id} = this.props;\n return (\n <div data-name=\"video-player\" className={style.wrapper} key={id}>\n {this.renderPlayer()}\n </div>\n );\n }\n}\n\nexport default VideoPlayer;\n"],"file":"index.js"}
@@ -202,8 +202,8 @@ class JWPlayer extends _react.default.Component {
202
202
  fileUrl
203
203
  } = this.state;
204
204
 
205
- const _jwpOptions = _extends({}, jwpOptions, {
206
- customProps: _extends({}, (0, _get2.default)('customProps', jwpOptions), {
205
+ const _jwpOptions = _extends(_extends({}, jwpOptions), {}, {
206
+ customProps: _extends(_extends({}, (0, _get2.default)('customProps', jwpOptions)), {}, {
207
207
  autostart: !disableAutostart && (0, _get2.default)('customProps.autostart', jwpOptions)
208
208
  })
209
209
  });
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/molecule/video-player/jwplayer.js"],"names":["JWPlayer","React","Component","constructor","props","context","state","fileUrl","scriptFailedLoading","handlePlay","bind","handleResume","handlePause","handleEnded","handleError","handleSetupError","handleScriptError","handlePlayAttemptFailed","handleAutostartNotAllowed","handleWarning","componentDidMount","jwPlayerScript","document","getElementById","onerror","setFileUrl","componentDidUpdate","prevProps","changes","filter","key","current","prev","shouldStart","window","jwplayer","jwpOptions","playerId","play","file","setState","e","onPlay","onResume","onPause","onEnded","script","parentNode","removeChild","error","onSetupError","onPlayAttemptFailed","onAutostartNotAllowed","onWarning","onError","mimeType","code","videoUrl","regex","matched","match","videoId","render","disableAutostart","scriptErrorMessage","_jwpOptions","customProps","autostart","style","errorMessage","wrapper","propTypes","PropTypes","string","bool","shape","SrcPropType","aspectratio","tracks","arrayOf","label","kind","default","boolean","oneOf","width","skin","name","licenseKey","isRequired","playerScript","func"],"mappings":";;;;;;;;;;;;;AAAA;;AACA;;AACA;;AAEA;;AACA;;;;;;AAEA,MAAMA,QAAN,SAAuBC,eAAMC,SAA7B,CAAuC;AAuCrCC,EAAAA,WAAW,CAACC,KAAD,EAAQC,OAAR,EAAiB;AAC1B,UAAMD,KAAN,EAAaC,OAAb;AACA,SAAKC,KAAL,GAAa;AACXC,MAAAA,OAAO,EAAE,EADE;AAEXC,MAAAA,mBAAmB,EAAE;AAFV,KAAb;AAKA,SAAKC,UAAL,GAAkB,KAAKA,UAAL,CAAgBC,IAAhB,CAAqB,IAArB,CAAlB;AACA,SAAKC,YAAL,GAAoB,KAAKA,YAAL,CAAkBD,IAAlB,CAAuB,IAAvB,CAApB;AACA,SAAKE,WAAL,GAAmB,KAAKA,WAAL,CAAiBF,IAAjB,CAAsB,IAAtB,CAAnB;AACA,SAAKG,WAAL,GAAmB,KAAKA,WAAL,CAAiBH,IAAjB,CAAsB,IAAtB,CAAnB;AACA,SAAKI,WAAL,GAAmB,KAAKA,WAAL,CAAiBJ,IAAjB,CAAsB,IAAtB,CAAnB;AACA,SAAKK,gBAAL,GAAwB,KAAKA,gBAAL,CAAsBL,IAAtB,CAA2B,IAA3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ent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport ReactJWPlayer from 'react-jw-player';\nimport {get, includes, isFunction, keys} from 'lodash/fp';\nimport {SrcPropType} from '../../util/proptypes';\nimport style from './jwplayer.css';\n\nclass JWPlayer extends React.Component {\n static propTypes = {\n mimeType: PropTypes.string,\n scriptErrorMessage: PropTypes.string,\n disableAutostart: PropTypes.bool,\n // https://developer.jwplayer.com/jwplayer/docs/jw8-player-configuration-reference\n jwpOptions: PropTypes.shape({\n file: SrcPropType,\n customProps: PropTypes.shape({\n aspectratio: PropTypes.string,\n tracks: PropTypes.arrayOf(\n PropTypes.shape({\n file: SrcPropType,\n label: PropTypes.string,\n kind: PropTypes.string,\n default: PropTypes.boolean\n })\n ),\n autostart: PropTypes.oneOf(['true', 'viewable', 'false']),\n width: PropTypes.string,\n skin: PropTypes.shape({\n name: PropTypes.string\n })\n }),\n licenseKey: PropTypes.string.isRequired,\n playerScript: SrcPropType.isRequired,\n playerId: PropTypes.string.isRequired\n }),\n onPlay: PropTypes.func,\n onResume: PropTypes.func,\n onPause: PropTypes.func,\n onEnded: PropTypes.func,\n onError: PropTypes.func,\n onPlayAttemptFailed: PropTypes.func,\n onAutostartNotAllowed: PropTypes.func,\n onSetupError: PropTypes.func,\n onWarning: PropTypes.func\n };\n\n constructor(props, context) {\n super(props, context);\n this.state = {\n fileUrl: '',\n scriptFailedLoading: false\n };\n\n this.handlePlay = this.handlePlay.bind(this);\n this.handleResume = this.handleResume.bind(this);\n this.handlePause = this.handlePause.bind(this);\n this.handleEnded = this.handleEnded.bind(this);\n this.handleError = this.handleError.bind(this);\n this.handleSetupError = this.handleSetupError.bind(this);\n this.handleScriptError = this.handleScriptError.bind(this);\n this.handlePlayAttemptFailed = this.handlePlayAttemptFailed.bind(this);\n this.handleAutostartNotAllowed = this.handleAutostartNotAllowed.bind(this);\n this.handleWarning = this.handleWarning.bind(this);\n }\n\n componentDidMount() {\n const jwPlayerScript = document.getElementById('jw-player-script');\n jwPlayerScript.onerror = () => this.handleScriptError(jwPlayerScript);\n this.setFileUrl();\n }\n\n componentDidUpdate(prevProps) {\n const changes = keys(this.props).filter(key => {\n const {[key]: current} = this.props;\n const {[key]: prev} = prevProps;\n return current !== prev;\n });\n const shouldStart = includes('autoplay', changes);\n if (shouldStart) {\n if (isFunction(window.jwplayer)) {\n window.jwplayer(prevProps.jwpOptions.playerId).play();\n }\n }\n const {jwpOptions} = this.props;\n if (prevProps.jwpOptions.file !== jwpOptions.file) {\n this.setFileUrl();\n }\n }\n\n setFileUrl() {\n const {jwpOptions} = this.props;\n const {file} = jwpOptions;\n\n return this.setState({fileUrl: file});\n }\n\n handlePlay(e) {\n const {onPlay} = this.props;\n if (onPlay) onPlay(e);\n }\n\n handleResume(e) {\n const {onResume} = this.props;\n if (onResume) onResume(e);\n }\n\n handlePause(e) {\n const {onPause} = this.props;\n if (onPause) onPause(e);\n }\n\n handleEnded(e) {\n const {onEnded} = this.props;\n if (onEnded) onEnded(e);\n }\n\n handleScriptError(script) {\n this.setState({scriptFailedLoading: true});\n if (script) {\n script.parentNode.removeChild();\n }\n }\n\n handleSetupError(error) {\n const {onSetupError} = this.props;\n if (onSetupError) onSetupError(error);\n }\n\n handlePlayAttemptFailed(error) {\n const {onPlayAttemptFailed} = this.props;\n if (onPlayAttemptFailed) onPlayAttemptFailed(error);\n }\n\n handleAutostartNotAllowed(error) {\n const {onAutostartNotAllowed} = this.props;\n if (onAutostartNotAllowed) onAutostartNotAllowed(error);\n }\n\n handleWarning(error) {\n const {onWarning} = this.props;\n if (onWarning) onWarning(error);\n }\n\n handleError(error) {\n const {onError, mimeType, jwpOptions} = this.props;\n const {code} = error;\n\n onError && onError(error);\n\n if (mimeType === 'application/kontiki') {\n return;\n }\n\n // This error mostly appears on IE11 on W7\n // Since IE11 dont kinda support M3U8 sometimes,\n // We've decided to switch from M3U8 to mp4 whenever it appears\n if (code === 214000) {\n const {file: videoUrl} = jwpOptions;\n const regex = /^https:\\/\\/content.jwplatform\\.com\\/manifests\\/(\\w+).m3u8/;\n const matched = videoUrl.match(regex);\n\n if (matched) {\n const videoId = matched[1];\n return this.setState({\n fileUrl: `https://content.jwplatform.com/videos/${videoId}-1080.mp4`\n });\n }\n }\n }\n\n render() {\n const {jwpOptions, disableAutostart, scriptErrorMessage} = this.props;\n const {scriptFailedLoading, fileUrl} = this.state;\n const _jwpOptions = {\n ...jwpOptions,\n customProps: {\n ...get('customProps', jwpOptions),\n autostart: !disableAutostart && get('customProps.autostart', jwpOptions)\n }\n };\n\n return (\n <>\n {scriptFailedLoading ? <p className={style.errorMessage}>{scriptErrorMessage} </p> : null}\n <ReactJWPlayer\n {..._jwpOptions}\n className={style.wrapper}\n onAutoStart={this.handlePlay}\n onPlay={this.handlePlay}\n onResume={this.handleResume}\n onPause={this.handlePause}\n onOneHundredPercent={this.handleEnded}\n onError={this.handleError}\n onSetupError={this.handleSetupError}\n onPlayAttemptFailed={this.handlePlayAttemptFailed}\n onWarning={this.handleWarning}\n onAutostartNotAllowed={this.handleAutostartNotAllowed}\n file={fileUrl}\n />\n </>\n );\n }\n}\n\nexport default JWPlayer;\n"],"file":"jwplayer.js"}
1
+ {"version":3,"sources":["../../../src/molecule/video-player/jwplayer.js"],"names":["JWPlayer","React","Component","constructor","props","context","state","fileUrl","scriptFailedLoading","handlePlay","bind","handleResume","handlePause","handleEnded","handleError","handleSetupError","handleScriptError","handlePlayAttemptFailed","handleAutostartNotAllowed","handleWarning","componentDidMount","jwPlayerScript","document","getElementById","onerror","setFileUrl","componentDidUpdate","prevProps","changes","filter","key","current","prev","shouldStart","window","jwplayer","jwpOptions","playerId","play","file","setState","e","onPlay","onResume","onPause","onEnded","script","parentNode","removeChild","error","onSetupError","onPlayAttemptFailed","onAutostartNotAllowed","onWarning","onError","mimeType","code","videoUrl","regex","matched","match","videoId","render","disableAutostart","scriptErrorMessage","_jwpOptions","customProps","autostart","style","errorMessage","wrapper","propTypes","PropTypes","string","bool","shape","SrcPropType","aspectratio","tracks","array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Eb,mBAAUC,MAXU;AAY3Ba,MAAAA,IAAI,EAAEd,mBAAUG,KAAV,CAAgB;AACpBY,QAAAA,IAAI,EAAEf,mBAAUC;AADI,OAAhB;AAZqB,KAAhB,CAFa;AAkB1Be,IAAAA,UAAU,EAAEhB,mBAAUC,MAAV,CAAiBgB,UAlBH;AAmB1BC,IAAAA,YAAY,EAAEd,uBAAYa,UAnBA;AAoB1BpD,IAAAA,QAAQ,EAAEmC,mBAAUC,MAAV,CAAiBgB;AApBD,GAAhB,CALK;AA2BjB/C,EAAAA,MAAM,EAAE8B,mBAAUmB,IA3BD;AA4BjBhD,EAAAA,QAAQ,EAAE6B,mBAAUmB,IA5BH;AA6BjB/C,EAAAA,OAAO,EAAE4B,mBAAUmB,IA7BF;AA8BjB9C,EAAAA,OAAO,EAAE2B,mBAAUmB,IA9BF;AA+BjBrC,EAAAA,OAAO,EAAEkB,mBAAUmB,IA/BF;AAgCjBxC,EAAAA,mBAAmB,EAAEqB,mBAAUmB,IAhCd;AAiCjBvC,EAAAA,qBAAqB,EAAEoB,mBAAUmB,IAjChB;AAkCjBzC,EAAAA,YAAY,EAAEsB,mBAAUmB,IAlCP;AAmCjBtC,EAAAA,SAAS,EAAEmB,mBAAUmB;AAnCJ,C;eAoMN3F,Q","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport ReactJWPlayer from 'react-jw-player';\nimport {get, includes, isFunction, keys} from 'lodash/fp';\nimport {SrcPropType} from '../../util/proptypes';\nimport style from './jwplayer.css';\n\nclass JWPlayer extends React.Component {\n static propTypes = {\n mimeType: PropTypes.string,\n scriptErrorMessage: PropTypes.string,\n disableAutostart: PropTypes.bool,\n // https://developer.jwplayer.com/jwplayer/docs/jw8-player-configuration-reference\n jwpOptions: PropTypes.shape({\n file: SrcPropType,\n customProps: PropTypes.shape({\n aspectratio: PropTypes.string,\n tracks: PropTypes.arrayOf(\n PropTypes.shape({\n file: SrcPropType,\n label: PropTypes.string,\n kind: PropTypes.string,\n default: PropTypes.boolean\n })\n ),\n autostart: PropTypes.oneOf(['true', 'viewable', 'false']),\n width: PropTypes.string,\n skin: PropTypes.shape({\n name: PropTypes.string\n })\n }),\n licenseKey: PropTypes.string.isRequired,\n playerScript: SrcPropType.isRequired,\n playerId: PropTypes.string.isRequired\n }),\n onPlay: PropTypes.func,\n onResume: PropTypes.func,\n onPause: PropTypes.func,\n onEnded: PropTypes.func,\n onError: PropTypes.func,\n onPlayAttemptFailed: PropTypes.func,\n onAutostartNotAllowed: PropTypes.func,\n onSetupError: PropTypes.func,\n onWarning: PropTypes.func\n };\n\n constructor(props, context) {\n super(props, context);\n this.state = {\n fileUrl: '',\n scriptFailedLoading: false\n };\n\n this.handlePlay = this.handlePlay.bind(this);\n this.handleResume = this.handleResume.bind(this);\n this.handlePause = this.handlePause.bind(this);\n this.handleEnded = this.handleEnded.bind(this);\n this.handleError = this.handleError.bind(this);\n this.handleSetupError = this.handleSetupError.bind(this);\n this.handleScriptError = this.handleScriptError.bind(this);\n this.handlePlayAttemptFailed = this.handlePlayAttemptFailed.bind(this);\n this.handleAutostartNotAllowed = this.handleAutostartNotAllowed.bind(this);\n this.handleWarning = this.handleWarning.bind(this);\n }\n\n componentDidMount() {\n const jwPlayerScript = document.getElementById('jw-player-script');\n jwPlayerScript.onerror = () => this.handleScriptError(jwPlayerScript);\n this.setFileUrl();\n }\n\n componentDidUpdate(prevProps) {\n const changes = keys(this.props).filter(key => {\n const {[key]: current} = this.props;\n const {[key]: prev} = prevProps;\n return current !== prev;\n });\n const shouldStart = includes('autoplay', changes);\n if (shouldStart) {\n if (isFunction(window.jwplayer)) {\n window.jwplayer(prevProps.jwpOptions.playerId).play();\n }\n }\n const {jwpOptions} = this.props;\n if (prevProps.jwpOptions.file !== jwpOptions.file) {\n this.setFileUrl();\n }\n }\n\n setFileUrl() {\n const {jwpOptions} = this.props;\n const {file} = jwpOptions;\n\n return this.setState({fileUrl: file});\n }\n\n handlePlay(e) {\n const {onPlay} = this.props;\n if (onPlay) onPlay(e);\n }\n\n handleResume(e) {\n const {onResume} = this.props;\n if (onResume) onResume(e);\n }\n\n handlePause(e) {\n const {onPause} = this.props;\n if (onPause) onPause(e);\n }\n\n handleEnded(e) {\n const {onEnded} = this.props;\n if (onEnded) onEnded(e);\n }\n\n handleScriptError(script) {\n this.setState({scriptFailedLoading: true});\n if (script) {\n script.parentNode.removeChild();\n }\n }\n\n handleSetupError(error) {\n const {onSetupError} = this.props;\n if (onSetupError) onSetupError(error);\n }\n\n handlePlayAttemptFailed(error) {\n const {onPlayAttemptFailed} = this.props;\n if (onPlayAttemptFailed) onPlayAttemptFailed(error);\n }\n\n handleAutostartNotAllowed(error) {\n const {onAutostartNotAllowed} = this.props;\n if (onAutostartNotAllowed) onAutostartNotAllowed(error);\n }\n\n handleWarning(error) {\n const {onWarning} = this.props;\n if (onWarning) onWarning(error);\n }\n\n handleError(error) {\n const {onError, mimeType, jwpOptions} = this.props;\n const {code} = error;\n\n onError && onError(error);\n\n if (mimeType === 'application/kontiki') {\n return;\n }\n\n // This error mostly appears on IE11 on W7\n // Since IE11 dont kinda support M3U8 sometimes,\n // We've decided to switch from M3U8 to mp4 whenever it appears\n if (code === 214000) {\n const {file: videoUrl} = jwpOptions;\n const regex = /^https:\\/\\/content.jwplatform\\.com\\/manifests\\/(\\w+).m3u8/;\n const matched = videoUrl.match(regex);\n\n if (matched) {\n const videoId = matched[1];\n return this.setState({\n fileUrl: `https://content.jwplatform.com/videos/${videoId}-1080.mp4`\n });\n }\n }\n }\n\n render() {\n const {jwpOptions, disableAutostart, scriptErrorMessage} = this.props;\n const {scriptFailedLoading, fileUrl} = this.state;\n const _jwpOptions = {\n ...jwpOptions,\n customProps: {\n ...get('customProps', jwpOptions),\n autostart: !disableAutostart && get('customProps.autostart', jwpOptions)\n }\n };\n\n return (\n <>\n {scriptFailedLoading ? <p className={style.errorMessage}>{scriptErrorMessage} </p> : null}\n <ReactJWPlayer\n {..._jwpOptions}\n className={style.wrapper}\n onAutoStart={this.handlePlay}\n onPlay={this.handlePlay}\n onResume={this.handleResume}\n onPause={this.handlePause}\n onOneHundredPercent={this.handleEnded}\n onError={this.handleError}\n onSetupError={this.handleSetupError}\n onPlayAttemptFailed={this.handlePlayAttemptFailed}\n onWarning={this.handleWarning}\n onAutostartNotAllowed={this.handleAutostartNotAllowed}\n file={fileUrl}\n />\n </>\n );\n }\n}\n\nexport default JWPlayer;\n"],"file":"jwplayer.js"}
@@ -10,7 +10,7 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
10
10
  function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
11
11
 
12
12
  var _default = {
13
- props: _extends({}, _vimeo.default.props, {
13
+ props: _extends(_extends({}, _vimeo.default.props), {}, {
14
14
  mimeType: 'application/youtube',
15
15
  id: 'nLMZd05FQKc'
16
16
  })
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../src/molecule/video-player/test/fixtures/youtube.js"],"names":["props","Default","mimeType","id"],"mappings":";;;;;AAAA;;;;;;eAEe;AACbA,EAAAA,KAAK,eACAC,eAAQD,KADR;AAEHE,IAAAA,QAAQ,EAAE,qBAFP;AAGHC,IAAAA,EAAE,EAAE;AAHD;AADQ,C","sourcesContent":["import Default from './vimeo';\n\nexport default {\n props: {\n ...Default.props,\n mimeType: 'application/youtube',\n id: 'nLMZd05FQKc'\n }\n};\n"],"file":"youtube.js"}
1
+ {"version":3,"sources":["../../../../../src/molecule/video-player/test/fixtures/youtube.js"],"names":["props","Default","mimeType","id"],"mappings":";;;;;AAAA;;;;;;eAEe;AACbA,EAAAA,KAAK,wBACAC,eAAQD,KADR;AAEHE,IAAAA,QAAQ,EAAE,qBAFP;AAGHC,IAAAA,EAAE,EAAE;AAHD;AADQ,C","sourcesContent":["import Default from './vimeo';\n\nexport default {\n props: {\n ...Default.props,\n mimeType: 'application/youtube',\n id: 'nLMZd05FQKc'\n }\n};\n"],"file":"youtube.js"}
@@ -126,7 +126,7 @@ class Vimeo extends _react.default.Component {
126
126
  const {
127
127
  Player
128
128
  } = V;
129
- this.player = new Player(this.container, _extends({}, options, {
129
+ this.player = new Player(this.container, _extends(_extends({}, options), {}, {
130
130
  width: '1',
131
131
  height: '1'
132
132
  }));