@coorpacademy/components 10.1.2 → 10.1.6

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 (353) hide show
  1. package/es/atom/button-link/index.js +108 -0
  2. package/es/atom/button-link/index.js.map +1 -0
  3. package/es/atom/button-link/style.css +93 -0
  4. package/es/atom/button-link/test/fixtures/button-dangerous-no-icon.js +10 -0
  5. package/es/atom/button-link/test/fixtures/button-dangerous-no-icon.js.map +1 -0
  6. package/es/atom/button-link/test/fixtures/button-primary-icon-left.js +14 -0
  7. package/es/atom/button-link/test/fixtures/button-primary-icon-left.js.map +1 -0
  8. package/es/atom/button-link/test/fixtures/button-primary-no-icon.js +10 -0
  9. package/es/atom/button-link/test/fixtures/button-primary-no-icon.js.map +1 -0
  10. package/es/atom/button-link/test/fixtures/button-secondary-no-icon-disabled.js +11 -0
  11. package/es/atom/button-link/test/fixtures/button-secondary-no-icon-disabled.js.map +1 -0
  12. package/es/atom/button-link/test/fixtures/button-tertiary-icon-left.js +14 -0
  13. package/es/atom/button-link/test/fixtures/button-tertiary-icon-left.js.map +1 -0
  14. package/es/atom/button-link/test/fixtures/icon-button.js +13 -0
  15. package/es/atom/button-link/test/fixtures/icon-button.js.map +1 -0
  16. package/es/atom/button-link/test/fixtures/link-primary-disabled-icon-right.js +17 -0
  17. package/es/atom/button-link/test/fixtures/link-primary-disabled-icon-right.js.map +1 -0
  18. package/es/atom/button-link/test/fixtures/link-secondary-icon-right.js +20 -0
  19. package/es/atom/button-link/test/fixtures/link-secondary-icon-right.js.map +1 -0
  20. package/es/atom/button-link/test/fixtures/link-tertiary-no-icon.js +16 -0
  21. package/es/atom/button-link/test/fixtures/link-tertiary-no-icon.js.map +1 -0
  22. package/es/atom/button-link/test/fixtures/link-text-icon-right-target-blank.js +17 -0
  23. package/es/atom/button-link/test/fixtures/link-text-icon-right-target-blank.js.map +1 -0
  24. package/es/atom/button-link/test/fixtures/link-text-no-icon-download.js +13 -0
  25. package/es/atom/button-link/test/fixtures/link-text-no-icon-download.js.map +1 -0
  26. package/es/atom/button-link/test/fixtures.js +33 -0
  27. package/es/atom/button-link/test/fixtures.js.map +1 -0
  28. package/es/atom/chips/index.js +8 -4
  29. package/es/atom/chips/index.js.map +1 -1
  30. package/es/atom/chips/style.css +17 -2
  31. package/es/atom/chips/test/fixtures/long-text.js +9 -0
  32. package/es/atom/chips/test/fixtures/long-text.js.map +1 -0
  33. package/es/atom/chips/test/fixtures.js +17 -0
  34. package/es/atom/chips/test/fixtures.js.map +1 -0
  35. package/es/atom/content-badge/test/fixtures.js +27 -0
  36. package/es/atom/content-badge/test/fixtures.js.map +1 -0
  37. package/es/atom/input-checkbox/test/fixtures.js +2 -0
  38. package/es/atom/input-checkbox/test/fixtures.js.map +1 -1
  39. package/es/atom/input-search/index.js +65 -0
  40. package/es/atom/input-search/index.js.map +1 -0
  41. package/es/atom/input-search/style.css +202 -0
  42. package/es/{molecule/search → atom/input-search}/test/change.js +0 -0
  43. package/es/atom/input-search/test/change.js.map +1 -0
  44. package/es/atom/input-search/test/fixtures/coorpmanager-with-value.js +14 -0
  45. package/es/atom/input-search/test/fixtures/coorpmanager-with-value.js.map +1 -0
  46. package/es/atom/input-search/test/fixtures/coorpmanager.js +13 -0
  47. package/es/atom/input-search/test/fixtures/coorpmanager.js.map +1 -0
  48. package/es/{molecule/search → atom/input-search}/test/fixtures/default.js +0 -0
  49. package/es/atom/input-search/test/fixtures/default.js.map +1 -0
  50. package/es/{molecule/search → atom/input-search}/test/fixtures/with-value.js +0 -0
  51. package/es/atom/input-search/test/fixtures/with-value.js.map +1 -0
  52. package/es/atom/input-search/test/fixtures.js +19 -0
  53. package/es/atom/input-search/test/fixtures.js.map +1 -0
  54. package/es/atom/input-text/style.css +6 -2
  55. package/es/atom/input-text/test/fixtures.js +2 -0
  56. package/es/atom/input-text/test/fixtures.js.map +1 -1
  57. package/es/atom/input-textarea/style.css +3 -3
  58. package/es/atom/input-textarea/test/fixtures.js +4 -0
  59. package/es/atom/input-textarea/test/fixtures.js.map +1 -1
  60. package/es/atom/tag/index.js +27 -0
  61. package/es/atom/tag/index.js.map +1 -0
  62. package/es/atom/tag/style.css +38 -0
  63. package/es/atom/tag/test/fixtures/archived.js +7 -0
  64. package/es/atom/tag/test/fixtures/archived.js.map +1 -0
  65. package/es/atom/tag/test/fixtures/default.js +7 -0
  66. package/es/atom/tag/test/fixtures/default.js.map +1 -0
  67. package/es/atom/tag/test/fixtures/published.js +7 -0
  68. package/es/atom/tag/test/fixtures/published.js.map +1 -0
  69. package/es/atom/tag/test/fixtures/revision.js +7 -0
  70. package/es/atom/tag/test/fixtures/revision.js.map +1 -0
  71. package/es/atom/tag/test/fixtures.js +19 -0
  72. package/es/atom/tag/test/fixtures.js.map +1 -0
  73. package/es/atom/title/test/fixtures.js +6 -2
  74. package/es/atom/title/test/fixtures.js.map +1 -1
  75. package/es/atom/wizard-steps/test/fixtures.js +17 -0
  76. package/es/atom/wizard-steps/test/fixtures.js.map +1 -0
  77. package/es/molecule/banner/index.js +19 -10
  78. package/es/molecule/banner/index.js.map +1 -1
  79. package/es/molecule/banner/style.css +13 -11
  80. package/es/molecule/banner/test/fixtures.js +15 -0
  81. package/es/molecule/banner/test/fixtures.js.map +1 -0
  82. package/es/molecule/brand-form-group/index.js +20 -5
  83. package/es/molecule/brand-form-group/index.js.map +1 -1
  84. package/es/molecule/brand-form-group/style.css +19 -0
  85. package/es/molecule/brand-form-group/test/fixtures.js +2 -0
  86. package/es/molecule/brand-form-group/test/fixtures.js.map +1 -1
  87. package/es/molecule/card/test/fixtures.js +4 -0
  88. package/es/molecule/card/test/fixtures.js.map +1 -1
  89. package/es/molecule/cm-popin/index.js +21 -15
  90. package/es/molecule/cm-popin/index.js.map +1 -1
  91. package/es/molecule/cm-popin/style.css +2 -44
  92. package/es/molecule/cm-popin/test/fixtures/dangerous.js +3 -0
  93. package/es/molecule/cm-popin/test/fixtures/dangerous.js.map +1 -1
  94. package/es/molecule/cm-popin/test/fixtures/default.js +6 -3
  95. package/es/molecule/cm-popin/test/fixtures/default.js.map +1 -1
  96. package/es/molecule/cm-popin/test/fixtures/warning-with-close.js +4 -1
  97. package/es/molecule/cm-popin/test/fixtures/warning-with-close.js.map +1 -1
  98. package/es/molecule/cm-popin/test/fixtures.js +17 -0
  99. package/es/molecule/cm-popin/test/fixtures.js.map +1 -0
  100. package/es/molecule/coorp-manager-roles/test/fixtures.js +13 -0
  101. package/es/molecule/coorp-manager-roles/test/fixtures.js.map +1 -0
  102. package/es/molecule/quick-access-card/test/fixtures.js +21 -0
  103. package/es/molecule/quick-access-card/test/fixtures.js.map +1 -0
  104. package/es/molecule/quick-access-cards-group/test/fixtures.js +21 -0
  105. package/es/molecule/quick-access-cards-group/test/fixtures.js.map +1 -0
  106. package/es/molecule/search-form/index.js +1 -1
  107. package/es/molecule/search-form/index.js.map +1 -1
  108. package/es/molecule/select-multiple/index.js +113 -146
  109. package/es/molecule/select-multiple/index.js.map +1 -1
  110. package/es/molecule/select-multiple/test/index.js +20 -79
  111. package/es/molecule/select-multiple/test/index.js.map +1 -1
  112. package/es/molecule/vertical-tabs/test/fixtures.js +15 -0
  113. package/es/molecule/vertical-tabs/test/fixtures.js.map +1 -0
  114. package/es/molecule/wizard-summary/index.js +20 -10
  115. package/es/molecule/wizard-summary/index.js.map +1 -1
  116. package/es/molecule/wizard-summary/style.css +12 -21
  117. package/es/molecule/wizard-summary/test/fixtures/default.js +2 -1
  118. package/es/molecule/wizard-summary/test/fixtures/default.js.map +1 -1
  119. package/es/molecule/wizard-summary/test/fixtures/one-section.js +2 -1
  120. package/es/molecule/wizard-summary/test/fixtures/one-section.js.map +1 -1
  121. package/es/molecule/wizard-summary/test/fixtures/tablet-closed.js +2 -1
  122. package/es/molecule/wizard-summary/test/fixtures/tablet-closed.js.map +1 -1
  123. package/es/molecule/wizard-summary/test/fixtures/three-sections.js +2 -1
  124. package/es/molecule/wizard-summary/test/fixtures/three-sections.js.map +1 -1
  125. package/es/molecule/wizard-summary/test/fixtures/two-sections.js +2 -1
  126. package/es/molecule/wizard-summary/test/fixtures/two-sections.js.map +1 -1
  127. package/es/molecule/wizard-summary/test/fixtures.js +21 -0
  128. package/es/molecule/wizard-summary/test/fixtures.js.map +1 -0
  129. package/es/organism/accordion/coorp-manager/part/test/fixtures.js +4 -0
  130. package/es/organism/accordion/coorp-manager/part/test/fixtures.js.map +1 -1
  131. package/es/organism/brand-dashboard/test/fixtures.js +2 -0
  132. package/es/organism/brand-dashboard/test/fixtures.js.map +1 -1
  133. package/es/organism/brand-form/test/fixtures/wizard-playlists.js +26 -0
  134. package/es/organism/brand-form/test/fixtures/wizard-playlists.js.map +1 -0
  135. package/es/organism/brand-form/test/fixtures.js +2 -0
  136. package/es/organism/brand-form/test/fixtures.js.map +1 -1
  137. package/es/organism/brand-table/index.js +1 -1
  138. package/es/organism/brand-table/index.js.map +1 -1
  139. package/es/organism/mooc-header/index.js +1 -1
  140. package/es/organism/mooc-header/index.js.map +1 -1
  141. package/es/organism/mooc-header/test/fixtures/default.js +1 -1
  142. package/es/organism/mooc-header/test/fixtures/default.js.map +1 -1
  143. package/es/organism/mooc-header/test/fixtures/logged-with-battle-notifications.js +1 -1
  144. package/es/organism/mooc-header/test/fixtures/logged-with-battle-notifications.js.map +1 -1
  145. package/es/organism/search-and-chips-results/index.js +92 -0
  146. package/es/organism/search-and-chips-results/index.js.map +1 -0
  147. package/es/organism/search-and-chips-results/style.css +57 -0
  148. package/es/organism/search-and-chips-results/test/fixtures/default.js +46 -0
  149. package/es/organism/search-and-chips-results/test/fixtures/default.js.map +1 -0
  150. package/es/organism/search-and-chips-results/test/fixtures/empty.js +23 -0
  151. package/es/organism/search-and-chips-results/test/fixtures/empty.js.map +1 -0
  152. package/es/organism/search-and-chips-results/test/fixtures/filtered.js +26 -0
  153. package/es/organism/search-and-chips-results/test/fixtures/filtered.js.map +1 -0
  154. package/es/organism/search-and-chips-results/test/fixtures/sorted-selected.js +49 -0
  155. package/es/organism/search-and-chips-results/test/fixtures/sorted-selected.js.map +1 -0
  156. package/es/organism/search-and-chips-results/test/fixtures/unsorted-selected.js +49 -0
  157. package/es/organism/search-and-chips-results/test/fixtures/unsorted-selected.js.map +1 -0
  158. package/es/organism/search-and-chips-results/test/fixtures.js +21 -0
  159. package/es/organism/search-and-chips-results/test/fixtures.js.map +1 -0
  160. package/es/template/back-office/brand-list/index.js +6 -2
  161. package/es/template/back-office/brand-list/index.js.map +1 -1
  162. package/es/template/back-office/brand-list/style.css +1 -0
  163. package/es/template/back-office/brand-update/test/fixtures.js +2 -2
  164. package/es/template/back-office/brand-update/test/fixtures.js.map +1 -1
  165. package/es/variables/colors.css +2 -2
  166. package/lib/atom/button-link/index.js +125 -0
  167. package/lib/atom/button-link/index.js.map +1 -0
  168. package/lib/atom/button-link/style.css +93 -0
  169. package/lib/atom/button-link/test/fixtures/button-dangerous-no-icon.js +15 -0
  170. package/lib/atom/button-link/test/fixtures/button-dangerous-no-icon.js.map +1 -0
  171. package/lib/atom/button-link/test/fixtures/button-primary-icon-left.js +19 -0
  172. package/lib/atom/button-link/test/fixtures/button-primary-icon-left.js.map +1 -0
  173. package/lib/atom/button-link/test/fixtures/button-primary-no-icon.js +15 -0
  174. package/lib/atom/button-link/test/fixtures/button-primary-no-icon.js.map +1 -0
  175. package/lib/atom/button-link/test/fixtures/button-secondary-no-icon-disabled.js +16 -0
  176. package/lib/atom/button-link/test/fixtures/button-secondary-no-icon-disabled.js.map +1 -0
  177. package/lib/atom/button-link/test/fixtures/button-tertiary-icon-left.js +19 -0
  178. package/lib/atom/button-link/test/fixtures/button-tertiary-icon-left.js.map +1 -0
  179. package/lib/atom/button-link/test/fixtures/icon-button.js +18 -0
  180. package/lib/atom/button-link/test/fixtures/icon-button.js.map +1 -0
  181. package/lib/atom/button-link/test/fixtures/link-primary-disabled-icon-right.js +22 -0
  182. package/lib/atom/button-link/test/fixtures/link-primary-disabled-icon-right.js.map +1 -0
  183. package/lib/atom/button-link/test/fixtures/link-secondary-icon-right.js +25 -0
  184. package/lib/atom/button-link/test/fixtures/link-secondary-icon-right.js.map +1 -0
  185. package/lib/atom/button-link/test/fixtures/link-tertiary-no-icon.js +21 -0
  186. package/lib/atom/button-link/test/fixtures/link-tertiary-no-icon.js.map +1 -0
  187. package/lib/atom/button-link/test/fixtures/link-text-icon-right-target-blank.js +22 -0
  188. package/lib/atom/button-link/test/fixtures/link-text-icon-right-target-blank.js.map +1 -0
  189. package/lib/atom/button-link/test/fixtures/link-text-no-icon-download.js +18 -0
  190. package/lib/atom/button-link/test/fixtures/link-text-no-icon-download.js.map +1 -0
  191. package/lib/atom/button-link/test/fixtures.js +52 -0
  192. package/lib/atom/button-link/test/fixtures.js.map +1 -0
  193. package/lib/atom/chips/index.js +8 -4
  194. package/lib/atom/chips/index.js.map +1 -1
  195. package/lib/atom/chips/style.css +17 -2
  196. package/lib/atom/chips/test/fixtures/long-text.js +14 -0
  197. package/lib/atom/chips/test/fixtures/long-text.js.map +1 -0
  198. package/lib/atom/chips/test/fixtures.js +28 -0
  199. package/lib/atom/chips/test/fixtures.js.map +1 -0
  200. package/lib/atom/content-badge/test/fixtures.js +43 -0
  201. package/lib/atom/content-badge/test/fixtures.js.map +1 -0
  202. package/lib/atom/input-checkbox/test/fixtures.js +3 -0
  203. package/lib/atom/input-checkbox/test/fixtures.js.map +1 -1
  204. package/lib/{molecule/search → atom/input-search}/index.js +29 -18
  205. package/lib/atom/input-search/index.js.map +1 -0
  206. package/lib/atom/input-search/style.css +202 -0
  207. package/lib/{molecule/search → atom/input-search}/test/change.js +0 -0
  208. package/lib/atom/input-search/test/change.js.map +1 -0
  209. package/lib/atom/input-search/test/fixtures/coorpmanager-with-value.js +19 -0
  210. package/lib/atom/input-search/test/fixtures/coorpmanager-with-value.js.map +1 -0
  211. package/lib/atom/input-search/test/fixtures/coorpmanager.js +18 -0
  212. package/lib/atom/input-search/test/fixtures/coorpmanager.js.map +1 -0
  213. package/lib/{molecule/search → atom/input-search}/test/fixtures/default.js +0 -0
  214. package/lib/atom/input-search/test/fixtures/default.js.map +1 -0
  215. package/lib/{molecule/search → atom/input-search}/test/fixtures/with-value.js +0 -0
  216. package/lib/atom/input-search/test/fixtures/with-value.js.map +1 -0
  217. package/lib/atom/input-search/test/fixtures.js +31 -0
  218. package/lib/atom/input-search/test/fixtures.js.map +1 -0
  219. package/lib/atom/input-text/style.css +6 -2
  220. package/lib/atom/input-text/test/fixtures.js +3 -0
  221. package/lib/atom/input-text/test/fixtures.js.map +1 -1
  222. package/lib/atom/input-textarea/style.css +3 -3
  223. package/lib/atom/input-textarea/test/fixtures.js +6 -0
  224. package/lib/atom/input-textarea/test/fixtures.js.map +1 -1
  225. package/lib/atom/tag/index.js +39 -0
  226. package/lib/atom/tag/index.js.map +1 -0
  227. package/lib/atom/tag/style.css +38 -0
  228. package/lib/atom/tag/test/fixtures/archived.js +12 -0
  229. package/lib/atom/tag/test/fixtures/archived.js.map +1 -0
  230. package/lib/atom/tag/test/fixtures/default.js +12 -0
  231. package/lib/atom/tag/test/fixtures/default.js.map +1 -0
  232. package/lib/atom/tag/test/fixtures/published.js +12 -0
  233. package/lib/atom/tag/test/fixtures/published.js.map +1 -0
  234. package/lib/atom/tag/test/fixtures/revision.js +12 -0
  235. package/lib/atom/tag/test/fixtures/revision.js.map +1 -0
  236. package/lib/atom/tag/test/fixtures.js +31 -0
  237. package/lib/atom/tag/test/fixtures.js.map +1 -0
  238. package/lib/atom/title/test/fixtures.js +8 -2
  239. package/lib/atom/title/test/fixtures.js.map +1 -1
  240. package/lib/atom/wizard-steps/test/fixtures.js +28 -0
  241. package/lib/atom/wizard-steps/test/fixtures.js.map +1 -0
  242. package/lib/molecule/banner/index.js +19 -10
  243. package/lib/molecule/banner/index.js.map +1 -1
  244. package/lib/molecule/banner/style.css +13 -11
  245. package/lib/molecule/{search → banner}/test/fixtures.js +5 -5
  246. package/lib/molecule/banner/test/fixtures.js.map +1 -0
  247. package/lib/molecule/brand-form-group/index.js +22 -5
  248. package/lib/molecule/brand-form-group/index.js.map +1 -1
  249. package/lib/molecule/brand-form-group/style.css +19 -0
  250. package/lib/molecule/brand-form-group/test/fixtures.js +3 -0
  251. package/lib/molecule/brand-form-group/test/fixtures.js.map +1 -1
  252. package/lib/molecule/card/test/fixtures.js +6 -0
  253. package/lib/molecule/card/test/fixtures.js.map +1 -1
  254. package/lib/molecule/cm-popin/index.js +21 -16
  255. package/lib/molecule/cm-popin/index.js.map +1 -1
  256. package/lib/molecule/cm-popin/style.css +2 -44
  257. package/lib/molecule/cm-popin/test/fixtures/dangerous.js +3 -0
  258. package/lib/molecule/cm-popin/test/fixtures/dangerous.js.map +1 -1
  259. package/lib/molecule/cm-popin/test/fixtures/default.js +6 -3
  260. package/lib/molecule/cm-popin/test/fixtures/default.js.map +1 -1
  261. package/lib/molecule/cm-popin/test/fixtures/warning-with-close.js +4 -1
  262. package/lib/molecule/cm-popin/test/fixtures/warning-with-close.js.map +1 -1
  263. package/lib/molecule/cm-popin/test/fixtures.js +28 -0
  264. package/lib/molecule/cm-popin/test/fixtures.js.map +1 -0
  265. package/lib/molecule/coorp-manager-roles/test/fixtures.js +22 -0
  266. package/lib/molecule/coorp-manager-roles/test/fixtures.js.map +1 -0
  267. package/lib/molecule/quick-access-card/test/fixtures.js +34 -0
  268. package/lib/molecule/quick-access-card/test/fixtures.js.map +1 -0
  269. package/lib/molecule/quick-access-cards-group/test/fixtures.js +34 -0
  270. package/lib/molecule/quick-access-cards-group/test/fixtures.js.map +1 -0
  271. package/lib/molecule/search-form/index.js +3 -3
  272. package/lib/molecule/search-form/index.js.map +1 -1
  273. package/lib/molecule/select-multiple/index.js +117 -143
  274. package/lib/molecule/select-multiple/index.js.map +1 -1
  275. package/lib/molecule/select-multiple/test/index.js +25 -79
  276. package/lib/molecule/select-multiple/test/index.js.map +1 -1
  277. package/lib/molecule/vertical-tabs/test/fixtures.js +25 -0
  278. package/lib/molecule/vertical-tabs/test/fixtures.js.map +1 -0
  279. package/lib/molecule/wizard-summary/index.js +20 -10
  280. package/lib/molecule/wizard-summary/index.js.map +1 -1
  281. package/lib/molecule/wizard-summary/style.css +12 -21
  282. package/lib/molecule/wizard-summary/test/fixtures/default.js +2 -1
  283. package/lib/molecule/wizard-summary/test/fixtures/default.js.map +1 -1
  284. package/lib/molecule/wizard-summary/test/fixtures/one-section.js +2 -1
  285. package/lib/molecule/wizard-summary/test/fixtures/one-section.js.map +1 -1
  286. package/lib/molecule/wizard-summary/test/fixtures/tablet-closed.js +2 -1
  287. package/lib/molecule/wizard-summary/test/fixtures/tablet-closed.js.map +1 -1
  288. package/lib/molecule/wizard-summary/test/fixtures/three-sections.js +2 -1
  289. package/lib/molecule/wizard-summary/test/fixtures/three-sections.js.map +1 -1
  290. package/lib/molecule/wizard-summary/test/fixtures/two-sections.js +2 -1
  291. package/lib/molecule/wizard-summary/test/fixtures/two-sections.js.map +1 -1
  292. package/lib/molecule/wizard-summary/test/fixtures.js +34 -0
  293. package/lib/molecule/wizard-summary/test/fixtures.js.map +1 -0
  294. package/lib/organism/accordion/coorp-manager/part/test/fixtures.js +6 -0
  295. package/lib/organism/accordion/coorp-manager/part/test/fixtures.js.map +1 -1
  296. package/lib/organism/brand-dashboard/test/fixtures.js +3 -0
  297. package/lib/organism/brand-dashboard/test/fixtures.js.map +1 -1
  298. package/lib/organism/brand-form/test/fixtures/wizard-playlists.js +31 -0
  299. package/lib/organism/brand-form/test/fixtures/wizard-playlists.js.map +1 -0
  300. package/lib/organism/brand-form/test/fixtures.js +3 -0
  301. package/lib/organism/brand-form/test/fixtures.js.map +1 -1
  302. package/lib/organism/brand-table/index.js +3 -3
  303. package/lib/organism/brand-table/index.js.map +1 -1
  304. package/lib/organism/mooc-header/index.js +2 -2
  305. package/lib/organism/mooc-header/index.js.map +1 -1
  306. package/lib/organism/mooc-header/test/fixtures/default.js +1 -1
  307. package/lib/organism/mooc-header/test/fixtures/default.js.map +1 -1
  308. package/lib/organism/mooc-header/test/fixtures/logged-with-battle-notifications.js +1 -1
  309. package/lib/organism/mooc-header/test/fixtures/logged-with-battle-notifications.js.map +1 -1
  310. package/lib/organism/search-and-chips-results/index.js +105 -0
  311. package/lib/organism/search-and-chips-results/index.js.map +1 -0
  312. package/lib/organism/search-and-chips-results/style.css +57 -0
  313. package/lib/organism/search-and-chips-results/test/fixtures/default.js +51 -0
  314. package/lib/organism/search-and-chips-results/test/fixtures/default.js.map +1 -0
  315. package/lib/organism/search-and-chips-results/test/fixtures/empty.js +28 -0
  316. package/lib/organism/search-and-chips-results/test/fixtures/empty.js.map +1 -0
  317. package/lib/organism/search-and-chips-results/test/fixtures/filtered.js +31 -0
  318. package/lib/organism/search-and-chips-results/test/fixtures/filtered.js.map +1 -0
  319. package/lib/organism/search-and-chips-results/test/fixtures/sorted-selected.js +54 -0
  320. package/lib/organism/search-and-chips-results/test/fixtures/sorted-selected.js.map +1 -0
  321. package/lib/organism/search-and-chips-results/test/fixtures/unsorted-selected.js +54 -0
  322. package/lib/organism/search-and-chips-results/test/fixtures/unsorted-selected.js.map +1 -0
  323. package/lib/organism/search-and-chips-results/test/fixtures.js +34 -0
  324. package/lib/organism/search-and-chips-results/test/fixtures.js.map +1 -0
  325. package/lib/template/back-office/brand-list/index.js +7 -3
  326. package/lib/template/back-office/brand-list/index.js.map +1 -1
  327. package/lib/template/back-office/brand-list/style.css +1 -0
  328. package/lib/template/back-office/brand-update/test/fixtures.js +3 -3
  329. package/lib/template/back-office/brand-update/test/fixtures.js.map +1 -1
  330. package/lib/variables/colors.css +2 -2
  331. package/package.json +3 -3
  332. package/es/atom/bullet-point-menu-button/test/fixtures.js +0 -27
  333. package/es/atom/bullet-point-menu-button/test/fixtures.js.map +0 -1
  334. package/es/molecule/cockpit-popin/test/fixtures.js +0 -17
  335. package/es/molecule/cockpit-popin/test/fixtures.js.map +0 -1
  336. package/es/molecule/search/index.js +0 -57
  337. package/es/molecule/search/index.js.map +0 -1
  338. package/es/molecule/search/style.css +0 -86
  339. package/es/molecule/search/test/change.js.map +0 -1
  340. package/es/molecule/search/test/fixtures/default.js.map +0 -1
  341. package/es/molecule/search/test/fixtures/with-value.js.map +0 -1
  342. package/es/molecule/search/test/fixtures.js +0 -15
  343. package/es/molecule/search/test/fixtures.js.map +0 -1
  344. package/lib/atom/bullet-point-menu-button/test/fixtures.js +0 -43
  345. package/lib/atom/bullet-point-menu-button/test/fixtures.js.map +0 -1
  346. package/lib/molecule/cockpit-popin/test/fixtures.js +0 -28
  347. package/lib/molecule/cockpit-popin/test/fixtures.js.map +0 -1
  348. package/lib/molecule/search/index.js.map +0 -1
  349. package/lib/molecule/search/style.css +0 -86
  350. package/lib/molecule/search/test/change.js.map +0 -1
  351. package/lib/molecule/search/test/fixtures/default.js.map +0 -1
  352. package/lib/molecule/search/test/fixtures/with-value.js.map +0 -1
  353. package/lib/molecule/search/test/fixtures.js.map +0 -1
@@ -0,0 +1,108 @@
1
+ import _getOr from "lodash/fp/getOr";
2
+
3
+ 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); }
4
+
5
+ import React, { useMemo } from 'react';
6
+ import PropTypes from 'prop-types';
7
+ import classnames from 'classnames';
8
+ import { NovaSolidRemoveAddAddCircle1 as AddIcon, NovaCompositionNavigationArrowLeft as ChevronLeftIcon, NovaCompositionNavigationArrowRight as ChevronRightIcon, NovaCompositionCoorpacademyEye as EyeIcon, NovaCompositionCoorpacademyAnalytics as AnalyticsIcon, NovaCompositionCoorpacademyNext as CloseIcon, NovaSolidComputersSdCard as SaveIcon, NovaSolidContentEditionPencilWrite as EditIcon } from '@coorpacademy/nova-icons';
9
+ import Link from '../link';
10
+ import style from './style.css';
11
+ const ICONS = {
12
+ add: AddIcon,
13
+ analytics: AnalyticsIcon,
14
+ 'chevron-left': ChevronLeftIcon,
15
+ 'chevron-right': ChevronRightIcon,
16
+ close: CloseIcon,
17
+ edit: EditIcon,
18
+ save: SaveIcon,
19
+ see: EyeIcon
20
+ };
21
+
22
+ const getButtonContent = (icon, label) => {
23
+ const {
24
+ type,
25
+ position
26
+ } = icon;
27
+
28
+ const Icon = _getOr(null, type, ICONS);
29
+
30
+ if (!Icon) {
31
+ return /*#__PURE__*/React.createElement("div", {
32
+ className: style.buttonContent
33
+ }, /*#__PURE__*/React.createElement("span", {
34
+ className: style.label
35
+ }, label));
36
+ }
37
+
38
+ if (position === 'center' && Icon) {
39
+ return /*#__PURE__*/React.createElement("div", {
40
+ className: style.buttonContent
41
+ }, /*#__PURE__*/React.createElement(Icon, {
42
+ className: style.icon
43
+ }));
44
+ }
45
+
46
+ return /*#__PURE__*/React.createElement("div", {
47
+ className: style.buttonContent
48
+ }, position === 'left' ? /*#__PURE__*/React.createElement(Icon, {
49
+ className: style.icon
50
+ }) : null, /*#__PURE__*/React.createElement("span", {
51
+ className: style.label
52
+ }, label), position === 'right' ? /*#__PURE__*/React.createElement(Icon, {
53
+ className: style.icon
54
+ }) : null);
55
+ };
56
+
57
+ const ButtonLink = props => {
58
+ const {
59
+ type,
60
+ label,
61
+ disabled,
62
+ icon = {},
63
+ 'data-name': dataName,
64
+ 'aria-label': ariaLabel,
65
+ link,
66
+ onClick
67
+ } = props;
68
+ const contentView = getButtonContent(icon, label);
69
+ const styleButton = classnames(style.button, type === 'primary' && style.primary, type === 'secondary' && style.secondary, type === 'tertiary' && style.tertiary, type === 'text' && style.text, type === 'dangerous' && style.dangerous, link && style.link, disabled && style.disabled);
70
+
71
+ if (link) {
72
+ return /*#__PURE__*/React.createElement(Link, _extends({}, link, {
73
+ className: styleButton,
74
+ "data-name": dataName,
75
+ "aria-label": ariaLabel || label,
76
+ title: ariaLabel || label
77
+ }), contentView);
78
+ }
79
+
80
+ const handleOnClick = useMemo(() => () => onClick(), [onClick]);
81
+ return /*#__PURE__*/React.createElement("button", {
82
+ type: "button",
83
+ "aria-label": ariaLabel || label,
84
+ title: ariaLabel || label,
85
+ className: styleButton,
86
+ onClick: handleOnClick
87
+ }, contentView);
88
+ };
89
+
90
+ ButtonLink.propTypes = process.env.NODE_ENV !== "production" ? {
91
+ type: PropTypes.oneOf(['primary', 'secondary', 'tertiary', 'text', 'dangerous']),
92
+ label: PropTypes.string,
93
+ 'aria-label': PropTypes.string,
94
+ 'data-name': PropTypes.string,
95
+ icon: PropTypes.shape({
96
+ position: PropTypes.oneOf(['right', 'left', 'center']),
97
+ type: PropTypes.string
98
+ }),
99
+ onClick: PropTypes.func,
100
+ link: PropTypes.shape({
101
+ href: PropTypes.string,
102
+ download: PropTypes.bool,
103
+ target: PropTypes.oneOf(['_self', '_blank', '_parent', '_top'])
104
+ }),
105
+ disabled: PropTypes.bool
106
+ } : {};
107
+ export default ButtonLink;
108
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/atom/button-link/index.js"],"names":["React","useMemo","PropTypes","classnames","NovaSolidRemoveAddAddCircle1","AddIcon","NovaCompositionNavigationArrowLeft","ChevronLeftIcon","NovaCompositionNavigationArrowRight","ChevronRightIcon","NovaCompositionCoorpacademyEye","EyeIcon","NovaCompositionCoorpacademyAnalytics","AnalyticsIcon","NovaCompositionCoorpacademyNext","CloseIcon","NovaSolidComputersSdCard","SaveIcon","NovaSolidContentEditionPencilWrite","EditIcon","Link","style","ICONS","add","analytics","close","edit","save","see","getButtonContent","icon","label","type","position","Icon","buttonContent","ButtonLink","props","disabled","dataName","ariaLabel","link","onClick","contentView","styleButton","button","primary","secondary","tertiary","text","dangerous","handleOnClick","propTypes","oneOf","string","shape","func","href","download","bool","target"],"mappings":"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","sourcesContent":["import React, {useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport {getOr} from 'lodash/fp';\nimport classnames from 'classnames';\nimport {\n NovaSolidRemoveAddAddCircle1 as AddIcon,\n NovaCompositionNavigationArrowLeft as ChevronLeftIcon,\n NovaCompositionNavigationArrowRight as ChevronRightIcon,\n NovaCompositionCoorpacademyEye as EyeIcon,\n NovaCompositionCoorpacademyAnalytics as AnalyticsIcon,\n NovaCompositionCoorpacademyNext as CloseIcon,\n NovaSolidComputersSdCard as SaveIcon,\n NovaSolidContentEditionPencilWrite as EditIcon\n} from '@coorpacademy/nova-icons';\nimport Link from '../link';\nimport style from './style.css';\n\nconst ICONS = {\n add: AddIcon,\n analytics: AnalyticsIcon,\n 'chevron-left': ChevronLeftIcon,\n 'chevron-right': ChevronRightIcon,\n close: CloseIcon,\n edit: EditIcon,\n save: SaveIcon,\n see: EyeIcon\n};\n\nconst getButtonContent = (icon, label) => {\n const {type, position} = icon;\n const Icon = getOr(null, type, ICONS);\n\n if (!Icon) {\n return (\n <div className={style.buttonContent}>\n <span className={style.label}>{label}</span>\n </div>\n );\n }\n\n if (position === 'center' && Icon) {\n return (\n <div className={style.buttonContent}>\n <Icon className={style.icon} />\n </div>\n );\n }\n\n return (\n <div className={style.buttonContent}>\n {position === 'left' ? <Icon className={style.icon} /> : null}\n <span className={style.label}>{label}</span>\n {position === 'right' ? <Icon className={style.icon} /> : null}\n </div>\n );\n};\n\nconst ButtonLink = props => {\n const {\n type,\n label,\n disabled,\n icon = {},\n 'data-name': dataName,\n 'aria-label': ariaLabel,\n link,\n onClick\n } = props;\n const contentView = getButtonContent(icon, label);\n const styleButton = classnames(\n style.button,\n type === 'primary' && style.primary,\n type === 'secondary' && style.secondary,\n type === 'tertiary' && style.tertiary,\n type === 'text' && style.text,\n type === 'dangerous' && style.dangerous,\n link && style.link,\n disabled && style.disabled\n );\n\n if (link) {\n return (\n <Link\n {...link}\n className={styleButton}\n data-name={dataName}\n aria-label={ariaLabel || label}\n title={ariaLabel || label}\n >\n {contentView}\n </Link>\n );\n }\n\n const handleOnClick = useMemo(() => () => onClick(), [onClick]);\n return (\n <button\n type=\"button\"\n aria-label={ariaLabel || label}\n title={ariaLabel || label}\n className={styleButton}\n onClick={handleOnClick}\n >\n {contentView}\n </button>\n );\n};\n\nButtonLink.propTypes = {\n type: PropTypes.oneOf(['primary', 'secondary', 'tertiary', 'text', 'dangerous']),\n label: PropTypes.string,\n 'aria-label': PropTypes.string,\n 'data-name': PropTypes.string,\n icon: PropTypes.shape({\n position: PropTypes.oneOf(['right', 'left', 'center']),\n type: PropTypes.string\n }),\n onClick: PropTypes.func,\n link: PropTypes.shape({\n href: PropTypes.string,\n download: PropTypes.bool,\n target: PropTypes.oneOf(['_self', '_blank', '_parent', '_top'])\n }),\n disabled: PropTypes.bool\n};\n\nexport default ButtonLink;\n"],"file":"index.js"}
@@ -0,0 +1,93 @@
1
+ @value colors: "../../variables/colors.css";
2
+ @value cm_primary_blue from colors;
3
+ @value cm_blue_600 from colors;
4
+ @value cm_grey_50 from colors;
5
+ @value cm_grey_100 from colors;
6
+ @value cm_grey_200 from colors;
7
+ @value cm_grey_900 from colors;
8
+ @value cm_negative_100 from colors;
9
+ @value cm_negative_200 from colors;
10
+ @value white from colors;
11
+
12
+ .button {
13
+ width: 100%;
14
+ height: 44px;
15
+ border-radius: 7px;
16
+ font-family: Gilroy;
17
+ font-size: 14px;
18
+ font-weight: bold;
19
+ display: flex;
20
+ justify-content: center;
21
+ align-items: center;
22
+ cursor: pointer;
23
+ border: none;
24
+ }
25
+
26
+ .disabled {
27
+ opacity: 0.1;
28
+ pointer-events: none;
29
+ }
30
+
31
+ .buttonContent {
32
+ display: flex;
33
+ justify-content: center;
34
+ align-items: center;
35
+ }
36
+
37
+ .link {
38
+ color: inherit;
39
+ text-decoration: none;
40
+ }
41
+
42
+ .icon {
43
+ width: 12px;
44
+ height: 12px;
45
+ }
46
+
47
+ .label {
48
+ margin: 0 8px 0 8px;
49
+ display: block;
50
+ }
51
+
52
+ .primary {
53
+ background-color: cm_primary_blue;
54
+ color: white;
55
+ }
56
+
57
+ .primary:hover {
58
+ background-color: cm_blue_600;
59
+ }
60
+
61
+ .secondary {
62
+ background-color: cm_grey_100;
63
+ color: cm_grey_900;
64
+ }
65
+
66
+ .secondary:hover {
67
+ background-color: cm_grey_200;
68
+ }
69
+
70
+ .tertiary {
71
+ background-color: cm_grey_50;
72
+ color: cm_grey_900;
73
+ border-radius: 0px;
74
+ }
75
+
76
+ .tertiary:hover {
77
+ background-color: cm_grey_100;
78
+ }
79
+
80
+ .dangerous {
81
+ background-color: cm_negative_100;
82
+ }
83
+
84
+ .dangerous:hover {
85
+ background-color: cm_negative_200;
86
+ }
87
+
88
+ .text {
89
+ background: transparent;
90
+ color: inherit;
91
+ border-radius: 0px;
92
+ height: auto;
93
+ }
@@ -0,0 +1,10 @@
1
+ export default {
2
+ props: {
3
+ type: 'dangerous',
4
+ label: 'Delete',
5
+ 'aria-label': 'aria button',
6
+ 'data-name': 'default-button',
7
+ onClick: () => console.log('click')
8
+ }
9
+ };
10
+ //# sourceMappingURL=button-dangerous-no-icon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/button-dangerous-no-icon.js"],"names":["props","type","label","onClick","console","log"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,WADD;AAELC,IAAAA,KAAK,EAAE,QAFF;AAGL,kBAAc,aAHT;AAIL,iBAAa,gBAJR;AAKLC,IAAAA,OAAO,EAAE,MAAMC,OAAO,CAACC,GAAR,CAAY,OAAZ;AALV;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'dangerous',\n label: 'Delete',\n 'aria-label': 'aria button',\n 'data-name': 'default-button',\n onClick: () => console.log('click')\n }\n};\n"],"file":"button-dangerous-no-icon.js"}
@@ -0,0 +1,14 @@
1
+ export default {
2
+ props: {
3
+ type: 'primary',
4
+ label: 'See my platform',
5
+ 'aria-label': 'aria button',
6
+ 'data-name': 'default-button',
7
+ icon: {
8
+ position: 'left',
9
+ type: 'chevron-left'
10
+ },
11
+ onClick: () => console.log('click')
12
+ }
13
+ };
14
+ //# sourceMappingURL=button-primary-icon-left.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/button-primary-icon-left.js"],"names":["props","type","label","icon","position","onClick","console","log"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,SADD;AAELC,IAAAA,KAAK,EAAE,iBAFF;AAGL,kBAAc,aAHT;AAIL,iBAAa,gBAJR;AAKLC,IAAAA,IAAI,EAAE;AACJC,MAAAA,QAAQ,EAAE,MADN;AAEJH,MAAAA,IAAI,EAAE;AAFF,KALD;AASLI,IAAAA,OAAO,EAAE,MAAMC,OAAO,CAACC,GAAR,CAAY,OAAZ;AATV;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'primary',\n label: 'See my platform',\n 'aria-label': 'aria button',\n 'data-name': 'default-button',\n icon: {\n position: 'left',\n type: 'chevron-left'\n },\n onClick: () => console.log('click')\n }\n};\n"],"file":"button-primary-icon-left.js"}
@@ -0,0 +1,10 @@
1
+ export default {
2
+ props: {
3
+ type: 'primary',
4
+ label: 'See my platform',
5
+ 'aria-label': 'aria button',
6
+ 'data-name': 'default-button',
7
+ onClick: () => console.log('click')
8
+ }
9
+ };
10
+ //# sourceMappingURL=button-primary-no-icon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/button-primary-no-icon.js"],"names":["props","type","label","onClick","console","log"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,SADD;AAELC,IAAAA,KAAK,EAAE,iBAFF;AAGL,kBAAc,aAHT;AAIL,iBAAa,gBAJR;AAKLC,IAAAA,OAAO,EAAE,MAAMC,OAAO,CAACC,GAAR,CAAY,OAAZ;AALV;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'primary',\n label: 'See my platform',\n 'aria-label': 'aria button',\n 'data-name': 'default-button',\n onClick: () => console.log('click')\n }\n};\n"],"file":"button-primary-no-icon.js"}
@@ -0,0 +1,11 @@
1
+ export default {
2
+ props: {
3
+ type: 'secondary',
4
+ label: 'See my platform',
5
+ 'aria-label': 'aria button',
6
+ 'data-name': 'default-button',
7
+ onClick: () => console.log('click'),
8
+ disabled: true
9
+ }
10
+ };
11
+ //# sourceMappingURL=button-secondary-no-icon-disabled.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/button-secondary-no-icon-disabled.js"],"names":["props","type","label","onClick","console","log","disabled"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,WADD;AAELC,IAAAA,KAAK,EAAE,iBAFF;AAGL,kBAAc,aAHT;AAIL,iBAAa,gBAJR;AAKLC,IAAAA,OAAO,EAAE,MAAMC,OAAO,CAACC,GAAR,CAAY,OAAZ,CALV;AAMLC,IAAAA,QAAQ,EAAE;AANL;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'secondary',\n label: 'See my platform',\n 'aria-label': 'aria button',\n 'data-name': 'default-button',\n onClick: () => console.log('click'),\n disabled: true\n }\n};\n"],"file":"button-secondary-no-icon-disabled.js"}
@@ -0,0 +1,14 @@
1
+ export default {
2
+ props: {
3
+ type: 'tertiary',
4
+ label: 'Button',
5
+ 'aria-label': 'aria button',
6
+ 'data-name': 'default-button',
7
+ icon: {
8
+ position: 'left',
9
+ type: 'see'
10
+ },
11
+ onClick: () => console.log('click')
12
+ }
13
+ };
14
+ //# sourceMappingURL=button-tertiary-icon-left.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/button-tertiary-icon-left.js"],"names":["props","type","label","icon","position","onClick","console","log"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,UADD;AAELC,IAAAA,KAAK,EAAE,QAFF;AAGL,kBAAc,aAHT;AAIL,iBAAa,gBAJR;AAKLC,IAAAA,IAAI,EAAE;AACJC,MAAAA,QAAQ,EAAE,MADN;AAEJH,MAAAA,IAAI,EAAE;AAFF,KALD;AASLI,IAAAA,OAAO,EAAE,MAAMC,OAAO,CAACC,GAAR,CAAY,OAAZ;AATV;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'tertiary',\n label: 'Button',\n 'aria-label': 'aria button',\n 'data-name': 'default-button',\n icon: {\n position: 'left',\n type: 'see'\n },\n onClick: () => console.log('click')\n }\n};\n"],"file":"button-tertiary-icon-left.js"}
@@ -0,0 +1,13 @@
1
+ export default {
2
+ props: {
3
+ type: 'secondary',
4
+ 'data-name': 'default-button',
5
+ 'aria-label': 'aria button',
6
+ icon: {
7
+ position: 'center',
8
+ type: 'close'
9
+ },
10
+ onClick: () => console.log('click')
11
+ }
12
+ };
13
+ //# sourceMappingURL=icon-button.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/icon-button.js"],"names":["props","type","icon","position","onClick","console","log"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,WADD;AAEL,iBAAa,gBAFR;AAGL,kBAAc,aAHT;AAILC,IAAAA,IAAI,EAAE;AACJC,MAAAA,QAAQ,EAAE,QADN;AAEJF,MAAAA,IAAI,EAAE;AAFF,KAJD;AAQLG,IAAAA,OAAO,EAAE,MAAMC,OAAO,CAACC,GAAR,CAAY,OAAZ;AARV;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'secondary',\n 'data-name': 'default-button',\n 'aria-label': 'aria button',\n icon: {\n position: 'center',\n type: 'close'\n },\n onClick: () => console.log('click')\n }\n};\n"],"file":"icon-button.js"}
@@ -0,0 +1,17 @@
1
+ export default {
2
+ props: {
3
+ type: 'primary',
4
+ disabled: true,
5
+ label: 'Global Analytics',
6
+ 'aria-label': 'aria button',
7
+ 'data-name': 'default-button',
8
+ icon: {
9
+ position: 'right',
10
+ type: 'analytics'
11
+ },
12
+ link: {
13
+ href: 'https://www.google.com'
14
+ }
15
+ }
16
+ };
17
+ //# sourceMappingURL=link-primary-disabled-icon-right.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/link-primary-disabled-icon-right.js"],"names":["props","type","disabled","label","icon","position","link","href"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,SADD;AAELC,IAAAA,QAAQ,EAAE,IAFL;AAGLC,IAAAA,KAAK,EAAE,kBAHF;AAIL,kBAAc,aAJT;AAKL,iBAAa,gBALR;AAMLC,IAAAA,IAAI,EAAE;AACJC,MAAAA,QAAQ,EAAE,OADN;AAEJJ,MAAAA,IAAI,EAAE;AAFF,KAND;AAULK,IAAAA,IAAI,EAAE;AACJC,MAAAA,IAAI,EAAE;AADF;AAVD;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'primary',\n disabled: true,\n label: 'Global Analytics',\n 'aria-label': 'aria button',\n 'data-name': 'default-button',\n icon: {\n position: 'right',\n type: 'analytics'\n },\n link: {\n href: 'https://www.google.com'\n }\n }\n};\n"],"file":"link-primary-disabled-icon-right.js"}
@@ -0,0 +1,20 @@
1
+ export default {
2
+ props: {
3
+ type: 'secondary',
4
+ label: 'Global Analytics',
5
+ 'data-name': 'default-button',
6
+ 'aria-label': 'aria button',
7
+ icon: {
8
+ position: 'right',
9
+ type: 'analytics'
10
+ },
11
+ onClick: () => {
12
+ console.log('Click on link');
13
+ return;
14
+ },
15
+ link: {
16
+ href: 'https://www.google.com'
17
+ }
18
+ }
19
+ };
20
+ //# sourceMappingURL=link-secondary-icon-right.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/link-secondary-icon-right.js"],"names":["props","type","label","icon","position","onClick","console","log","link","href"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,WADD;AAELC,IAAAA,KAAK,EAAE,kBAFF;AAGL,iBAAa,gBAHR;AAIL,kBAAc,aAJT;AAKLC,IAAAA,IAAI,EAAE;AACJC,MAAAA,QAAQ,EAAE,OADN;AAEJH,MAAAA,IAAI,EAAE;AAFF,KALD;AASLI,IAAAA,OAAO,EAAE,MAAM;AACbC,MAAAA,OAAO,CAACC,GAAR,CAAY,eAAZ;AACA;AACD,KAZI;AAaLC,IAAAA,IAAI,EAAE;AACJC,MAAAA,IAAI,EAAE;AADF;AAbD;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'secondary',\n label: 'Global Analytics',\n 'data-name': 'default-button',\n 'aria-label': 'aria button',\n icon: {\n position: 'right',\n type: 'analytics'\n },\n onClick: () => {\n console.log('Click on link');\n return;\n },\n link: {\n href: 'https://www.google.com'\n }\n }\n};\n"],"file":"link-secondary-icon-right.js"}
@@ -0,0 +1,16 @@
1
+ export default {
2
+ props: {
3
+ type: 'tertiary',
4
+ label: 'Go to google',
5
+ 'data-name': 'default-button',
6
+ 'aria-label': 'aria button',
7
+ onClick: () => {
8
+ console.log('Click on link');
9
+ return;
10
+ },
11
+ link: {
12
+ href: 'https://www.google.com'
13
+ }
14
+ }
15
+ };
16
+ //# sourceMappingURL=link-tertiary-no-icon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/link-tertiary-no-icon.js"],"names":["props","type","label","onClick","console","log","link","href"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,UADD;AAELC,IAAAA,KAAK,EAAE,cAFF;AAGL,iBAAa,gBAHR;AAIL,kBAAc,aAJT;AAKLC,IAAAA,OAAO,EAAE,MAAM;AACbC,MAAAA,OAAO,CAACC,GAAR,CAAY,eAAZ;AACA;AACD,KARI;AASLC,IAAAA,IAAI,EAAE;AACJC,MAAAA,IAAI,EAAE;AADF;AATD;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'tertiary',\n label: 'Go to google',\n 'data-name': 'default-button',\n 'aria-label': 'aria button',\n onClick: () => {\n console.log('Click on link');\n return;\n },\n link: {\n href: 'https://www.google.com'\n }\n }\n};\n"],"file":"link-tertiary-no-icon.js"}
@@ -0,0 +1,17 @@
1
+ export default {
2
+ props: {
3
+ type: 'text',
4
+ label: 'Button',
5
+ 'data-name': 'default-button',
6
+ 'aria-label': 'aria button',
7
+ icon: {
8
+ position: 'right',
9
+ type: 'chevron-left'
10
+ },
11
+ link: {
12
+ href: 'http://www.google.com',
13
+ target: '_blank'
14
+ }
15
+ }
16
+ };
17
+ //# sourceMappingURL=link-text-icon-right-target-blank.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/link-text-icon-right-target-blank.js"],"names":["props","type","label","icon","position","link","href","target"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,MADD;AAELC,IAAAA,KAAK,EAAE,QAFF;AAGL,iBAAa,gBAHR;AAIL,kBAAc,aAJT;AAKLC,IAAAA,IAAI,EAAE;AACJC,MAAAA,QAAQ,EAAE,OADN;AAEJH,MAAAA,IAAI,EAAE;AAFF,KALD;AASLI,IAAAA,IAAI,EAAE;AACJC,MAAAA,IAAI,EAAE,uBADF;AAEJC,MAAAA,MAAM,EAAE;AAFJ;AATD;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'text',\n label: 'Button',\n 'data-name': 'default-button',\n 'aria-label': 'aria button',\n icon: {\n position: 'right',\n type: 'chevron-left'\n },\n link: {\n href: 'http://www.google.com',\n target: '_blank'\n }\n }\n};\n"],"file":"link-text-icon-right-target-blank.js"}
@@ -0,0 +1,13 @@
1
+ export default {
2
+ props: {
3
+ type: 'text',
4
+ label: 'Download',
5
+ 'data-name': 'default-button',
6
+ 'aria-label': 'aria button',
7
+ link: {
8
+ href: 'https://setup.coorpacademy.com/assets/templates/import-users-template.xlsx',
9
+ download: true
10
+ }
11
+ }
12
+ };
13
+ //# sourceMappingURL=link-text-no-icon-download.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/button-link/test/fixtures/link-text-no-icon-download.js"],"names":["props","type","label","link","href","download"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,MADD;AAELC,IAAAA,KAAK,EAAE,UAFF;AAGL,iBAAa,gBAHR;AAIL,kBAAc,aAJT;AAKLC,IAAAA,IAAI,EAAE;AACJC,MAAAA,IAAI,EAAE,4EADF;AAEJC,MAAAA,QAAQ,EAAE;AAFN;AALD;AADM,CAAf","sourcesContent":["export default {\n props: {\n type: 'text',\n label: 'Download',\n 'data-name': 'default-button',\n 'aria-label': 'aria button',\n link: {\n href: 'https://setup.coorpacademy.com/assets/templates/import-users-template.xlsx',\n download: true\n }\n }\n};\n"],"file":"link-text-no-icon-download.js"}
@@ -0,0 +1,33 @@
1
+ import test from 'ava';
2
+ import forEach from 'lodash/forEach';
3
+ import renderComponentMacro from '../../../test/helpers/render-component';
4
+ import AtomButtonLink from '..';
5
+ import fixtureButtonDangerousNoIcon from './fixtures/button-dangerous-no-icon';
6
+ import fixtureButtonPrimaryIconLeft from './fixtures/button-primary-icon-left';
7
+ import fixtureButtonPrimaryNoIcon from './fixtures/button-primary-no-icon';
8
+ import fixtureButtonSecondaryNoIconDisabled from './fixtures/button-secondary-no-icon-disabled';
9
+ import fixtureButtonTertiaryIconLeft from './fixtures/button-tertiary-icon-left';
10
+ import fixtureIconButton from './fixtures/icon-button';
11
+ import fixtureLinkPrimaryDisabledIconRight from './fixtures/link-primary-disabled-icon-right';
12
+ import fixtureLinkSecondaryIconRight from './fixtures/link-secondary-icon-right';
13
+ import fixtureLinkTertiaryNoIcon from './fixtures/link-tertiary-no-icon';
14
+ import fixtureLinkTextIconRightTargetBlank from './fixtures/link-text-icon-right-target-blank';
15
+ import fixtureLinkTextNoIconDownload from './fixtures/link-text-no-icon-download';
16
+ test('Atom › AtomButtonLink > should have valid propTypes', t => {
17
+ t.pass();
18
+ forEach(AtomButtonLink.propTypes, (value, key) => {
19
+ t.not(value, undefined, `PropType for "Atom.AtomButtonLink.propTypes.${key}" may not be undefined. Did you mistype the propTypes definition?`);
20
+ });
21
+ });
22
+ test('Atom › AtomButtonLink › ButtonDangerousNoIcon › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonDangerousNoIcon);
23
+ test('Atom › AtomButtonLink › ButtonPrimaryIconLeft › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonPrimaryIconLeft);
24
+ test('Atom › AtomButtonLink › ButtonPrimaryNoIcon › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonPrimaryNoIcon);
25
+ test('Atom › AtomButtonLink › ButtonSecondaryNoIconDisabled › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonSecondaryNoIconDisabled);
26
+ test('Atom › AtomButtonLink › ButtonTertiaryIconLeft › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonTertiaryIconLeft);
27
+ test('Atom › AtomButtonLink › IconButton › should be rendered', renderComponentMacro, AtomButtonLink, fixtureIconButton);
28
+ test('Atom › AtomButtonLink › LinkPrimaryDisabledIconRight › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkPrimaryDisabledIconRight);
29
+ test('Atom › AtomButtonLink › LinkSecondaryIconRight › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkSecondaryIconRight);
30
+ test('Atom › AtomButtonLink › LinkTertiaryNoIcon › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkTertiaryNoIcon);
31
+ test('Atom › AtomButtonLink › LinkTextIconRightTargetBlank › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkTextIconRightTargetBlank);
32
+ test('Atom › AtomButtonLink › LinkTextNoIconDownload › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkTextNoIconDownload);
33
+ //# sourceMappingURL=fixtures.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../src/atom/button-link/test/fixtures.js"],"names":["test","forEach","renderComponentMacro","AtomButtonLink","fixtureButtonDangerousNoIcon","fixtureButtonPrimaryIconLeft","fixtureButtonPrimaryNoIcon","fixtureButtonSecondaryNoIconDisabled","fixtureButtonTertiaryIconLeft","fixtureIconButton","fixtureLinkPrimaryDisabledIconRight","fixtureLinkSecondaryIconRight","fixtureLinkTertiaryNoIcon","fixtureLinkTextIconRightTargetBlank","fixtureLinkTextNoIconDownload","t","pass","propTypes","value","key","not","undefined"],"mappings":"AAAA,OAAOA,IAAP,MAAiB,KAAjB;AACA,OAAOC,OAAP,MAAoB,gBAApB;AACA,OAAOC,oBAAP,MAAiC,wCAAjC;AACA,OAAOC,cAAP,MAA2B,IAA3B;AACA,OAAOC,4BAAP,MAAyC,qCAAzC;AACA,OAAOC,4BAAP,MAAyC,qCAAzC;AACA,OAAOC,0BAAP,MAAuC,mCAAvC;AACA,OAAOC,oCAAP,MAAiD,8CAAjD;AACA,OAAOC,6BAAP,MAA0C,sCAA1C;AACA,OAAOC,iBAAP,MAA8B,wBAA9B;AACA,OAAOC,mCAAP,MAAgD,6CAAhD;AACA,OAAOC,6BAAP,MAA0C,sCAA1C;AACA,OAAOC,yBAAP,MAAsC,kCAAtC;AACA,OAAOC,mCAAP,MAAgD,8CAAhD;AACA,OAAOC,6BAAP,MAA0C,uCAA1C;AAEAd,IAAI,CAAC,qDAAD,EAAwDe,CAAC,IAAI;AAC/DA,EAAAA,CAAC,CAACC,IAAF;AACAf,EAAAA,OAAO,CAACE,cAAc,CAACc,SAAhB,EAA2B,CAACC,KAAD,EAAQC,GAAR,KAAgB;AAChDJ,IAAAA,CAAC,CAACK,GAAF,CAAMF,KAAN,EAAaG,SAAb,EAAyB,+CAA8CF,GAAI,mEAA3E;AACD,GAFM,CAAP;AAGD,CALG,CAAJ;AAOAnB,IAAI,CAAC,oEAAD,EAAuEE,oBAAvE,EAA6FC,cAA7F,EAA6GC,4BAA7G,CAAJ;AACAJ,IAAI,CAAC,oEAAD,EAAuEE,oBAAvE,EAA6FC,cAA7F,EAA6GE,4BAA7G,CAAJ;AACAL,IAAI,CAAC,kEAAD,EAAqEE,oBAArE,EAA2FC,cAA3F,EAA2GG,0BAA3G,CAAJ;AACAN,IAAI,CAAC,4EAAD,EAA+EE,oBAA/E,EAAqGC,cAArG,EAAqHI,oCAArH,CAAJ;AACAP,IAAI,CAAC,qEAAD,EAAwEE,oBAAxE,EAA8FC,cAA9F,EAA8GK,6BAA9G,CAAJ;AACAR,IAAI,CAAC,yDAAD,EAA4DE,oBAA5D,EAAkFC,cAAlF,EAAkGM,iBAAlG,CAAJ;AACAT,IAAI,CAAC,2EAAD,EAA8EE,oBAA9E,EAAoGC,cAApG,EAAoHO,mCAApH,CAAJ;AACAV,IAAI,CAAC,qEAAD,EAAwEE,oBAAxE,EAA8FC,cAA9F,EAA8GQ,6BAA9G,CAAJ;AACAX,IAAI,CAAC,iEAAD,EAAoEE,oBAApE,EAA0FC,cAA1F,EAA0GS,yBAA1G,CAAJ;AACAZ,IAAI,CAAC,2EAAD,EAA8EE,oBAA9E,EAAoGC,cAApG,EAAoHU,mCAApH,CAAJ;AACAb,IAAI,CAAC,qEAAD,EAAwEE,oBAAxE,EAA8FC,cAA9F,EAA8GW,6BAA9G,CAAJ","sourcesContent":["import test from 'ava';\nimport forEach from 'lodash/forEach';\nimport renderComponentMacro from '../../../test/helpers/render-component';\nimport AtomButtonLink from '..';\nimport fixtureButtonDangerousNoIcon from './fixtures/button-dangerous-no-icon';\nimport fixtureButtonPrimaryIconLeft from './fixtures/button-primary-icon-left';\nimport fixtureButtonPrimaryNoIcon from './fixtures/button-primary-no-icon';\nimport fixtureButtonSecondaryNoIconDisabled from './fixtures/button-secondary-no-icon-disabled';\nimport fixtureButtonTertiaryIconLeft from './fixtures/button-tertiary-icon-left';\nimport fixtureIconButton from './fixtures/icon-button';\nimport fixtureLinkPrimaryDisabledIconRight from './fixtures/link-primary-disabled-icon-right';\nimport fixtureLinkSecondaryIconRight from './fixtures/link-secondary-icon-right';\nimport fixtureLinkTertiaryNoIcon from './fixtures/link-tertiary-no-icon';\nimport fixtureLinkTextIconRightTargetBlank from './fixtures/link-text-icon-right-target-blank';\nimport fixtureLinkTextNoIconDownload from './fixtures/link-text-no-icon-download';\n\ntest('Atom › AtomButtonLink > should have valid propTypes', t => {\n t.pass();\n forEach(AtomButtonLink.propTypes, (value, key) => {\n t.not(value, undefined, `PropType for \"Atom.AtomButtonLink.propTypes.${key}\" may not be undefined. Did you mistype the propTypes definition?`);\n });\n});\n\ntest('Atom › AtomButtonLink › ButtonDangerousNoIcon › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonDangerousNoIcon);\ntest('Atom › AtomButtonLink › ButtonPrimaryIconLeft › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonPrimaryIconLeft);\ntest('Atom › AtomButtonLink › ButtonPrimaryNoIcon › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonPrimaryNoIcon);\ntest('Atom › AtomButtonLink › ButtonSecondaryNoIconDisabled › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonSecondaryNoIconDisabled);\ntest('Atom › AtomButtonLink › ButtonTertiaryIconLeft › should be rendered', renderComponentMacro, AtomButtonLink, fixtureButtonTertiaryIconLeft);\ntest('Atom › AtomButtonLink › IconButton › should be rendered', renderComponentMacro, AtomButtonLink, fixtureIconButton);\ntest('Atom › AtomButtonLink › LinkPrimaryDisabledIconRight › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkPrimaryDisabledIconRight);\ntest('Atom › AtomButtonLink › LinkSecondaryIconRight › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkSecondaryIconRight);\ntest('Atom › AtomButtonLink › LinkTertiaryNoIcon › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkTertiaryNoIcon);\ntest('Atom › AtomButtonLink › LinkTextIconRightTargetBlank › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkTextIconRightTargetBlank);\ntest('Atom › AtomButtonLink › LinkTextNoIconDownload › should be rendered', renderComponentMacro, AtomButtonLink, fixtureLinkTextNoIconDownload);\n"],"file":"fixtures.js"}
@@ -8,18 +8,22 @@ const Chips = props => {
8
8
  const {
9
9
  text,
10
10
  information,
11
- selected,
11
+ selected = false,
12
12
  onClick
13
13
  } = props;
14
14
  const handleClick = useMemo(() => () => onClick(), [onClick]);
15
15
  return /*#__PURE__*/React.createElement("div", {
16
16
  className: classnames(style.container, selected ? style.selected : style.unselected),
17
- onClick: handleClick
17
+ onClick: handleClick,
18
+ "aria-label": `${text} ${information}`
18
19
  }, /*#__PURE__*/React.createElement("div", {
20
+ className: style.textZone,
21
+ title: text
22
+ }, /*#__PURE__*/React.createElement("span", {
19
23
  className: style.text
20
- }, text), /*#__PURE__*/React.createElement("div", {
24
+ }, text), /*#__PURE__*/React.createElement("span", {
21
25
  className: style.information
22
- }, information), selected ? /*#__PURE__*/React.createElement(SelectedIcon, {
26
+ }, information)), selected ? /*#__PURE__*/React.createElement(SelectedIcon, {
23
27
  className: style.selectedIconWrapper
24
28
  }) : /*#__PURE__*/React.createElement(AddIcon, {
25
29
  className: style.unselectedIconWrapper
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/atom/chips/index.js"],"names":["React","useMemo","PropTypes","classnames","NovaSolidRemoveAddAddCircle1","AddIcon","NovaSolidStatusCheckCircle2","SelectedIcon","style","Chips","props","text","information","selected","onClick","handleClick","container","unselected","selectedIconWrapper","unselectedIconWrapper","propTypes","string","bool","func"],"mappings":"AAAA,OAAOA,KAAP,IAAeC,OAAf,QAA6B,OAA7B;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,UAAP,MAAuB,YAAvB;AACA,SACEC,4BAA4B,IAAIC,OADlC,EAEEC,2BAA2B,IAAIC,YAFjC,QAGO,0BAHP;AAIA,OAAOC,KAAP,MAAkB,aAAlB;;AAEA,MAAMC,KAAK,GAAGC,KAAK,IAAI;AACrB,QAAM;AAACC,IAAAA,IAAD;AAAOC,IAAAA,WAAP;AAAoBC,IAAAA,QAApB;AAA8BC,IAAAA;AAA9B,MAAyCJ,KAA/C;AAEA,QAAMK,WAAW,GAAGd,OAAO,CAAC,MAAM,MAAMa,OAAO,EAApB,EAAwB,CAACA,OAAD,CAAxB,CAA3B;AAEA,sBACE;AACE,IAAA,SAAS,EAAEX,UAAU,CAACK,KAAK,CAACQ,SAAP,EAAkBH,QAAQ,GAAGL,KAAK,CAACK,QAAT,GAAoBL,KAAK,CAACS,UAApD,CADvB;AAEE,IAAA,OAAO,EAAEF;AAFX,kBAIE;AAAK,IAAA,SAAS,EAAEP,KAAK,CAACG;AAAtB,KAA6BA,IAA7B,CAJF,eAKE;AAAK,IAAA,SAAS,EAAEH,KAAK,CAACI;AAAtB,KAAoCA,WAApC,CALF,EAMGC,QAAQ,gBACP,oBAAC,YAAD;AAAc,IAAA,SAAS,EAAEL,KAAK,CAACU;AAA/B,IADO,gBAGP,oBAAC,OAAD;AAAS,IAAA,SAAS,EAAEV,KAAK,CAACW;AAA1B,IATJ,CADF;AAcD,CAnBD;;AAqBAV,KAAK,CAACW,SAAN,2CAAkB;AAChBT,EAAAA,IAAI,EAAET,SAAS,CAACmB,MADA;AAEhBT,EAAAA,WAAW,EAAEV,SAAS,CAACmB,MAFP;AAGhBR,EAAAA,QAAQ,EAAEX,SAAS,CAACoB,IAHJ;AAIhBR,EAAAA,OAAO,EAAEZ,SAAS,CAACqB;AAJH,CAAlB;AAOA,eAAed,KAAf","sourcesContent":["import React, {useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n NovaSolidRemoveAddAddCircle1 as AddIcon,\n NovaSolidStatusCheckCircle2 as SelectedIcon\n} from '@coorpacademy/nova-icons';\nimport style from './style.css';\n\nconst Chips = props => {\n const {text, information, selected, onClick} = props;\n\n const handleClick = useMemo(() => () => onClick(), [onClick]);\n\n return (\n <div\n className={classnames(style.container, selected ? style.selected : style.unselected)}\n onClick={handleClick}\n >\n <div className={style.text}>{text}</div>\n <div className={style.information}>{information}</div>\n {selected ? (\n <SelectedIcon className={style.selectedIconWrapper} />\n ) : (\n <AddIcon className={style.unselectedIconWrapper} />\n )}\n </div>\n );\n};\n\nChips.propTypes = {\n text: PropTypes.string,\n information: PropTypes.string,\n selected: PropTypes.bool,\n onClick: PropTypes.func\n};\n\nexport default Chips;\n"],"file":"index.js"}
1
+ {"version":3,"sources":["../../../src/atom/chips/index.js"],"names":["React","useMemo","PropTypes","classnames","NovaSolidRemoveAddAddCircle1","AddIcon","NovaSolidStatusCheckCircle2","SelectedIcon","style","Chips","props","text","information","selected","onClick","handleClick","container","unselected","textZone","selectedIconWrapper","unselectedIconWrapper","propTypes","string","bool","func"],"mappings":"AAAA,OAAOA,KAAP,IAAeC,OAAf,QAA6B,OAA7B;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,UAAP,MAAuB,YAAvB;AACA,SACEC,4BAA4B,IAAIC,OADlC,EAEEC,2BAA2B,IAAIC,YAFjC,QAGO,0BAHP;AAIA,OAAOC,KAAP,MAAkB,aAAlB;;AAEA,MAAMC,KAAK,GAAGC,KAAK,IAAI;AACrB,QAAM;AAACC,IAAAA,IAAD;AAAOC,IAAAA,WAAP;AAAoBC,IAAAA,QAAQ,GAAG,KAA/B;AAAsCC,IAAAA;AAAtC,MAAiDJ,KAAvD;AAEA,QAAMK,WAAW,GAAGd,OAAO,CAAC,MAAM,MAAMa,OAAO,EAApB,EAAwB,CAACA,OAAD,CAAxB,CAA3B;AAEA,sBACE;AACE,IAAA,SAAS,EAAEX,UAAU,CAACK,KAAK,CAACQ,SAAP,EAAkBH,QAAQ,GAAGL,KAAK,CAACK,QAAT,GAAoBL,KAAK,CAACS,UAApD,CADvB;AAEE,IAAA,OAAO,EAAEF,WAFX;AAGE,kBAAa,GAAEJ,IAAK,IAAGC,WAAY;AAHrC,kBAKE;AAAK,IAAA,SAAS,EAAEJ,KAAK,CAACU,QAAtB;AAAgC,IAAA,KAAK,EAAEP;AAAvC,kBACE;AAAM,IAAA,SAAS,EAAEH,KAAK,CAACG;AAAvB,KAA8BA,IAA9B,CADF,eAEE;AAAM,IAAA,SAAS,EAAEH,KAAK,CAACI;AAAvB,KAAqCA,WAArC,CAFF,CALF,EASGC,QAAQ,gBACP,oBAAC,YAAD;AAAc,IAAA,SAAS,EAAEL,KAAK,CAACW;AAA/B,IADO,gBAGP,oBAAC,OAAD;AAAS,IAAA,SAAS,EAAEX,KAAK,CAACY;AAA1B,IAZJ,CADF;AAiBD,CAtBD;;AAwBAX,KAAK,CAACY,SAAN,2CAAkB;AAChBV,EAAAA,IAAI,EAAET,SAAS,CAACoB,MADA;AAEhBV,EAAAA,WAAW,EAAEV,SAAS,CAACoB,MAFP;AAGhBT,EAAAA,QAAQ,EAAEX,SAAS,CAACqB,IAHJ;AAIhBT,EAAAA,OAAO,EAAEZ,SAAS,CAACsB;AAJH,CAAlB;AAOA,eAAef,KAAf","sourcesContent":["import React, {useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n NovaSolidRemoveAddAddCircle1 as AddIcon,\n NovaSolidStatusCheckCircle2 as SelectedIcon\n} from '@coorpacademy/nova-icons';\nimport style from './style.css';\n\nconst Chips = props => {\n const {text, information, selected = false, onClick} = props;\n\n const handleClick = useMemo(() => () => onClick(), [onClick]);\n\n return (\n <div\n className={classnames(style.container, selected ? style.selected : style.unselected)}\n onClick={handleClick}\n aria-label={`${text} ${information}`}\n >\n <div className={style.textZone} title={text}>\n <span className={style.text}>{text}</span>\n <span className={style.information}>{information}</span>\n </div>\n {selected ? (\n <SelectedIcon className={style.selectedIconWrapper} />\n ) : (\n <AddIcon className={style.unselectedIconWrapper} />\n )}\n </div>\n );\n};\n\nChips.propTypes = {\n text: PropTypes.string,\n information: PropTypes.string,\n selected: PropTypes.bool,\n onClick: PropTypes.func\n};\n\nexport default Chips;\n"],"file":"index.js"}
@@ -7,11 +7,15 @@
7
7
  @value white from colors;
8
8
 
9
9
  .container {
10
- width: 25%;
11
- height: 32px;
10
+ width: 100%;
11
+ height: 52px;
12
12
  border-radius: 10px;
13
13
  padding: 10px 16px;
14
14
  position: relative;
15
+ display: flex;
16
+ align-items: center;
17
+ box-sizing: border-box;
18
+ cursor: pointer;
15
19
  }
16
20
 
17
21
  .selected {
@@ -30,12 +34,22 @@
30
34
  background-color: cm_grey_200;
31
35
  }
32
36
 
37
+ .textZone {
38
+ flex: 1 1 100%;
39
+ padding-right: 32px;
40
+ width: calc(100% - 32px);
41
+ }
42
+
33
43
  .text {
34
44
  font-family: 'Gilroy';
35
45
  font-style: normal;
36
46
  font-weight: 600;
37
47
  font-size: 14px;
38
48
  color: cm_grey_700;
49
+ text-overflow: ellipsis;
50
+ white-space: nowrap;
51
+ overflow: hidden;
52
+ display: block;
39
53
  }
40
54
 
41
55
  .information {
@@ -45,6 +59,7 @@
45
59
  font-size: 10px;
46
60
  opacity: 0.4;
47
61
  color: cm_grey_700;
62
+ display: block;
48
63
  }
49
64
 
50
65
  .icon{
@@ -0,0 +1,9 @@
1
+ export default {
2
+ props: {
3
+ text: 'Population Human resourses filiale Singapour and lots and lots of text that should be cut somewhere because the chip item it should not take all the width of the component and and ellipsis should be shown.',
4
+ information: '345 users',
5
+ select: false,
6
+ onClick: () => console.log('click')
7
+ }
8
+ };
9
+ //# sourceMappingURL=long-text.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../../src/atom/chips/test/fixtures/long-text.js"],"names":["props","text","information","select","onClick","console","log"],"mappings":"AAAA,eAAe;AACbA,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EACF,+MAFG;AAGLC,IAAAA,WAAW,EAAE,WAHR;AAILC,IAAAA,MAAM,EAAE,KAJH;AAKLC,IAAAA,OAAO,EAAE,MAAMC,OAAO,CAACC,GAAR,CAAY,OAAZ;AALV;AADM,CAAf","sourcesContent":["export default {\n props: {\n text:\n 'Population Human resourses filiale Singapour and lots and lots of text that should be cut somewhere because the chip item it should not take all the width of the component and and ellipsis should be shown.',\n information: '345 users',\n select: false,\n onClick: () => console.log('click')\n }\n};\n"],"file":"long-text.js"}
@@ -0,0 +1,17 @@
1
+ import test from 'ava';
2
+ import forEach from 'lodash/forEach';
3
+ import renderComponentMacro from '../../../test/helpers/render-component';
4
+ import AtomChips from '..';
5
+ import fixtureDefault from './fixtures/default';
6
+ import fixtureLongText from './fixtures/long-text';
7
+ import fixtureNonSelected from './fixtures/non-selected';
8
+ test('Atom › AtomChips > should have valid propTypes', t => {
9
+ t.pass();
10
+ forEach(AtomChips.propTypes, (value, key) => {
11
+ t.not(value, undefined, `PropType for "Atom.AtomChips.propTypes.${key}" may not be undefined. Did you mistype the propTypes definition?`);
12
+ });
13
+ });
14
+ test('Atom › AtomChips › Default › should be rendered', renderComponentMacro, AtomChips, fixtureDefault);
15
+ test('Atom › AtomChips › LongText › should be rendered', renderComponentMacro, AtomChips, fixtureLongText);
16
+ test('Atom › AtomChips › NonSelected › should be rendered', renderComponentMacro, AtomChips, fixtureNonSelected);
17
+ //# sourceMappingURL=fixtures.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../src/atom/chips/test/fixtures.js"],"names":["test","forEach","renderComponentMacro","AtomChips","fixtureDefault","fixtureLongText","fixtureNonSelected","t","pass","propTypes","value","key","not","undefined"],"mappings":"AAAA,OAAOA,IAAP,MAAiB,KAAjB;AACA,OAAOC,OAAP,MAAoB,gBAApB;AACA,OAAOC,oBAAP,MAAiC,wCAAjC;AACA,OAAOC,SAAP,MAAsB,IAAtB;AACA,OAAOC,cAAP,MAA2B,oBAA3B;AACA,OAAOC,eAAP,MAA4B,sBAA5B;AACA,OAAOC,kBAAP,MAA+B,yBAA/B;AAEAN,IAAI,CAAC,gDAAD,EAAmDO,CAAC,IAAI;AAC1DA,EAAAA,CAAC,CAACC,IAAF;AACAP,EAAAA,OAAO,CAACE,SAAS,CAACM,SAAX,EAAsB,CAACC,KAAD,EAAQC,GAAR,KAAgB;AAC3CJ,IAAAA,CAAC,CAACK,GAAF,CAAMF,KAAN,EAAaG,SAAb,EAAyB,0CAAyCF,GAAI,mEAAtE;AACD,GAFM,CAAP;AAGD,CALG,CAAJ;AAOAX,IAAI,CAAC,iDAAD,EAAoDE,oBAApD,EAA0EC,SAA1E,EAAqFC,cAArF,CAAJ;AACAJ,IAAI,CAAC,kDAAD,EAAqDE,oBAArD,EAA2EC,SAA3E,EAAsFE,eAAtF,CAAJ;AACAL,IAAI,CAAC,qDAAD,EAAwDE,oBAAxD,EAA8EC,SAA9E,EAAyFG,kBAAzF,CAAJ","sourcesContent":["import test from 'ava';\nimport forEach from 'lodash/forEach';\nimport renderComponentMacro from '../../../test/helpers/render-component';\nimport AtomChips from '..';\nimport fixtureDefault from './fixtures/default';\nimport fixtureLongText from './fixtures/long-text';\nimport fixtureNonSelected from './fixtures/non-selected';\n\ntest('Atom › AtomChips > should have valid propTypes', t => {\n t.pass();\n forEach(AtomChips.propTypes, (value, key) => {\n t.not(value, undefined, `PropType for \"Atom.AtomChips.propTypes.${key}\" may not be undefined. Did you mistype the propTypes definition?`);\n });\n});\n\ntest('Atom › AtomChips › Default › should be rendered', renderComponentMacro, AtomChips, fixtureDefault);\ntest('Atom › AtomChips › LongText › should be rendered', renderComponentMacro, AtomChips, fixtureLongText);\ntest('Atom › AtomChips › NonSelected › should be rendered', renderComponentMacro, AtomChips, fixtureNonSelected);\n"],"file":"fixtures.js"}