@helsenorge/designsystem-react 2.17.0 → 3.0.1

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 (1006) hide show
  1. package/AnchorLink.js +1 -1
  2. package/AnchorLink.js.map +1 -1
  3. package/Avatar.js +1 -1
  4. package/Avatar.js.map +1 -1
  5. package/Badge.js +1 -1
  6. package/Badge.js.map +1 -1
  7. package/Button.js +1 -1
  8. package/Button.js.map +1 -1
  9. package/CHANGELOG.md +60 -2
  10. package/Checkbox.js +1 -1
  11. package/Checkbox.js.map +1 -1
  12. package/Close.js +1 -1
  13. package/Close.js.map +1 -1
  14. package/ErrorWrapper.js +1 -1
  15. package/ErrorWrapper.js.map +1 -1
  16. package/FormGroup.js +1 -1
  17. package/FormGroup.js.map +1 -1
  18. package/FormLayout.js +1 -1
  19. package/FormLayout.js.map +1 -1
  20. package/HelpBubble.js +1 -1
  21. package/HelpBubble.js.map +1 -1
  22. package/HorizontalScroll.js +1 -1
  23. package/HorizontalScroll.js.map +1 -1
  24. package/Input.js +1 -1
  25. package/Input.js.map +1 -1
  26. package/ListHeader.js +1 -1
  27. package/ListHeader.js.map +1 -1
  28. package/ListHeaderText.js +1 -1
  29. package/ListHeaderText.js.map +1 -1
  30. package/MaxCharacters.js +1 -1
  31. package/MaxCharacters.js.map +1 -1
  32. package/Modal.js +1 -1
  33. package/Modal.js.map +1 -1
  34. package/Panel.js +1 -1
  35. package/Panel.js.map +1 -1
  36. package/PopOver.js +2 -0
  37. package/PopOver.js.map +1 -0
  38. package/RadioButton.js +1 -1
  39. package/RadioButton.js.map +1 -1
  40. package/Select.js +1 -1
  41. package/Select.js.map +1 -1
  42. package/Spacer.js +1 -1
  43. package/Spacer.js.map +1 -1
  44. package/StatusDot.js +1 -1
  45. package/StatusDot.js.map +1 -1
  46. package/TableBody.js +1 -1
  47. package/TableBody.js.map +1 -1
  48. package/TableCell.js +1 -1
  49. package/TableCell.js.map +1 -1
  50. package/TableExpandedRow.js +1 -1
  51. package/TableExpandedRow.js.map +1 -1
  52. package/TableExpanderCell.js +1 -1
  53. package/TableExpanderCell.js.map +1 -1
  54. package/TableHead.js +1 -1
  55. package/TableHead.js.map +1 -1
  56. package/TableHeadCell.js +1 -1
  57. package/TableHeadCell.js.map +1 -1
  58. package/TableRow.js +1 -1
  59. package/TableRow.js.map +1 -1
  60. package/Textarea.js +1 -1
  61. package/Textarea.js.map +1 -1
  62. package/Title.js +1 -1
  63. package/Title.js.map +1 -1
  64. package/Tooltip.js +1 -1
  65. package/Tooltip.js.map +1 -1
  66. package/TooltipWord.js +1 -1
  67. package/TooltipWord.js.map +1 -1
  68. package/Validation.js +1 -1
  69. package/Validation.js.map +1 -1
  70. package/__mocks__/matchMedia.d.ts +1 -1
  71. package/__mocks__/matchMedia.d.ts.map +1 -1
  72. package/components/AnchorLink/AnchorLink.d.ts +2 -2
  73. package/components/AnchorLink/AnchorLink.d.ts.map +1 -1
  74. package/components/AnchorLink/index.js +1 -1
  75. package/components/AnchorLink/styles.module.scss +19 -11
  76. package/components/Avatar/Avatar.d.ts +1 -1
  77. package/components/Avatar/Avatar.d.ts.map +1 -1
  78. package/components/Avatar/index.js +1 -1
  79. package/components/Avatar/styles.module.scss +2 -2
  80. package/components/Badge/Badge.d.ts +3 -3
  81. package/components/Badge/Badge.d.ts.map +1 -1
  82. package/components/Badge/index.js +1 -1
  83. package/components/Badge/styles.module.scss +7 -1
  84. package/components/Button/Button.d.ts +7 -7
  85. package/components/Button/Button.d.ts.map +1 -1
  86. package/components/Button/componentdata.json +1 -1
  87. package/components/Button/index.js +1 -1
  88. package/components/Button/styles.module.scss +35 -21
  89. package/components/ButtonWithModal/ButtonWithModal.d.ts.map +1 -1
  90. package/components/ButtonWithModal/index.js +1 -1
  91. package/components/ButtonWithModal/index.js.map +1 -1
  92. package/components/Checkbox/Checkbox.d.ts.map +1 -1
  93. package/components/Checkbox/componentdata.json +1 -1
  94. package/components/Checkbox/index.js +1 -1
  95. package/components/Checkbox/styles.module.scss +12 -12
  96. package/components/Close/Close.d.ts +8 -2
  97. package/components/Close/Close.d.ts.map +1 -1
  98. package/components/Close/componentdata.json +1 -1
  99. package/components/Close/index.js +1 -1
  100. package/components/Close/styles.module.scss +16 -8
  101. package/components/Dropdown/Dropdown.d.ts.map +1 -1
  102. package/components/Dropdown/componentdata.json +1 -1
  103. package/components/Dropdown/index.js +1 -1
  104. package/components/Dropdown/index.js.map +1 -1
  105. package/components/Dropdown/styles.module.scss +31 -10
  106. package/components/Duolist/Duolist.d.ts +4 -4
  107. package/components/Duolist/Duolist.d.ts.map +1 -1
  108. package/components/Duolist/index.js +1 -1
  109. package/components/Duolist/index.js.map +1 -1
  110. package/components/Duolist/styles.module.scss +5 -3
  111. package/components/ErrorWrapper/ErrorWrapper.d.ts.map +1 -1
  112. package/components/ErrorWrapper/componentdata.json +1 -1
  113. package/components/ErrorWrapper/index.js +1 -1
  114. package/components/ErrorWrapper/styles.module.scss +8 -6
  115. package/components/Expander/Expander.d.ts +2 -2
  116. package/components/Expander/Expander.d.ts.map +1 -1
  117. package/components/Expander/componentdata.json +1 -1
  118. package/components/Expander/index.js +1 -1
  119. package/components/Expander/index.js.map +1 -1
  120. package/components/Expander/styles.module.scss +46 -15
  121. package/components/ExpanderHierarchy/Expander.d.ts +18 -0
  122. package/components/ExpanderHierarchy/Expander.d.ts.map +1 -0
  123. package/components/ExpanderHierarchy/ExpanderButton.d.ts +11 -0
  124. package/components/ExpanderHierarchy/ExpanderButton.d.ts.map +1 -0
  125. package/components/ExpanderHierarchy/ExpanderHierarchy.d.ts +22 -0
  126. package/components/ExpanderHierarchy/ExpanderHierarchy.d.ts.map +1 -0
  127. package/components/ExpanderHierarchy/componentdata.json +1 -0
  128. package/components/ExpanderHierarchy/expander.module.scss +152 -0
  129. package/components/ExpanderHierarchy/expander.module.scss.d.ts +25 -0
  130. package/components/ExpanderHierarchy/index.d.ts +4 -0
  131. package/components/ExpanderHierarchy/index.d.ts.map +1 -0
  132. package/components/ExpanderHierarchy/index.js +2 -0
  133. package/components/ExpanderHierarchy/index.js.map +1 -0
  134. package/components/ExpanderHierarchy/styles.module.scss +17 -0
  135. package/components/ExpanderHierarchy/styles.module.scss.d.ts +11 -0
  136. package/components/ExpanderHierarchy/utils.d.ts +3 -0
  137. package/components/ExpanderHierarchy/utils.d.ts.map +1 -0
  138. package/components/ExpanderList/ExpanderList.d.ts +4 -4
  139. package/components/ExpanderList/ExpanderList.d.ts.map +1 -1
  140. package/components/ExpanderList/index.js +1 -1
  141. package/components/ExpanderList/index.js.map +1 -1
  142. package/components/ExpanderList/styles.module.scss +17 -6
  143. package/components/FormExample/FormExample.d.ts.map +1 -1
  144. package/components/FormExample/index.js +3 -3
  145. package/components/FormExample/index.js.map +1 -1
  146. package/components/FormExample/styles.module.scss +6 -6
  147. package/components/FormGroup/FormGroup.d.ts +1 -1
  148. package/components/FormGroup/FormGroup.d.ts.map +1 -1
  149. package/components/FormGroup/index.js +1 -1
  150. package/components/FormGroup/styles.module.scss +5 -4
  151. package/components/FormLayout/FormLayout.d.ts.map +1 -1
  152. package/components/FormLayout/index.js +1 -1
  153. package/components/FormLayout/styles.module.scss +5 -2
  154. package/components/GridExample/index.js +1 -1
  155. package/components/GridExample/index.js.map +1 -1
  156. package/components/HelpBubble/HelpBubble.d.ts +5 -8
  157. package/components/HelpBubble/HelpBubble.d.ts.map +1 -1
  158. package/components/HelpBubble/index.js +1 -1
  159. package/components/HelpBubble/styles.module.scss +10 -51
  160. package/components/HelpBubble/styles.module.scss.d.ts +0 -4
  161. package/components/HelpBubbleExample/componentdata.json +1 -1
  162. package/components/HelpBubbleExample/index.js +1 -1
  163. package/components/HelpBubbleExample/index.js.map +1 -1
  164. package/components/HighlightBox/HighlightBox.d.ts +2 -2
  165. package/components/HighlightBox/HighlightBox.d.ts.map +1 -1
  166. package/components/HighlightBox/componentdata.json +1 -1
  167. package/components/HighlightBox/index.js +1 -1
  168. package/components/HighlightBox/index.js.map +1 -1
  169. package/components/HighlightBox/styles.module.scss +38 -29
  170. package/components/HorizontalScroll/HorizontalScroll.d.ts.map +1 -1
  171. package/components/HorizontalScroll/index.js +1 -1
  172. package/components/HorizontalScroll/styles.module.scss +10 -3
  173. package/components/Icons/ActiveMonitoring.d.ts.map +1 -1
  174. package/components/Icons/ActiveMonitoring.js.map +1 -1
  175. package/components/Icons/AcupunctureBack.d.ts.map +1 -1
  176. package/components/Icons/AcupunctureBack.js.map +1 -1
  177. package/components/Icons/AlarmClock.d.ts.map +1 -1
  178. package/components/Icons/AlarmClock.js.map +1 -1
  179. package/components/Icons/AlertSignFill.d.ts.map +1 -1
  180. package/components/Icons/AlertSignFill.js.map +1 -1
  181. package/components/Icons/AlertSignStroke.d.ts.map +1 -1
  182. package/components/Icons/AlertSignStroke.js.map +1 -1
  183. package/components/Icons/Amputation.d.ts.map +1 -1
  184. package/components/Icons/Amputation.js.map +1 -1
  185. package/components/Icons/Anxiety.d.ts.map +1 -1
  186. package/components/Icons/Anxiety.js.map +1 -1
  187. package/components/Icons/Apple.d.ts.map +1 -1
  188. package/components/Icons/Apple.js.map +1 -1
  189. package/components/Icons/Archive.d.ts.map +1 -1
  190. package/components/Icons/Archive.js.map +1 -1
  191. package/components/Icons/ArmFlexing.d.ts.map +1 -1
  192. package/components/Icons/ArmFlexing.js.map +1 -1
  193. package/components/Icons/ArrowDown.d.ts.map +1 -1
  194. package/components/Icons/ArrowDown.js.map +1 -1
  195. package/components/Icons/ArrowLeft.d.ts.map +1 -1
  196. package/components/Icons/ArrowLeft.js.map +1 -1
  197. package/components/Icons/ArrowRight.d.ts.map +1 -1
  198. package/components/Icons/ArrowRight.js.map +1 -1
  199. package/components/Icons/ArrowUp.d.ts.map +1 -1
  200. package/components/Icons/ArrowUp.js.map +1 -1
  201. package/components/Icons/ArrowUpRight.d.ts.map +1 -1
  202. package/components/Icons/ArrowUpRight.js.map +1 -1
  203. package/components/Icons/Attachment.d.ts.map +1 -1
  204. package/components/Icons/Attachment.js.map +1 -1
  205. package/components/Icons/Atv.d.ts.map +1 -1
  206. package/components/Icons/Atv.js.map +1 -1
  207. package/components/Icons/Avatar.d.ts.map +1 -1
  208. package/components/Icons/Avatar.js.map +1 -1
  209. package/components/Icons/AwakePersonOnPillow.d.ts.map +1 -1
  210. package/components/Icons/AwakePersonOnPillow.js.map +1 -1
  211. package/components/Icons/Baby.d.ts.map +1 -1
  212. package/components/Icons/Baby.js.map +1 -1
  213. package/components/Icons/BandAid.d.ts.map +1 -1
  214. package/components/Icons/BandAid.js.map +1 -1
  215. package/components/Icons/BeerAndPills.d.ts.map +1 -1
  216. package/components/Icons/BeerAndPills.js.map +1 -1
  217. package/components/Icons/Bell.d.ts.map +1 -1
  218. package/components/Icons/Bell.js.map +1 -1
  219. package/components/Icons/Bike.d.ts.map +1 -1
  220. package/components/Icons/Bike.js.map +1 -1
  221. package/components/Icons/BirthControl.d.ts.map +1 -1
  222. package/components/Icons/BirthControl.js.map +1 -1
  223. package/components/Icons/BirthdayCake.d.ts.map +1 -1
  224. package/components/Icons/BirthdayCake.js.map +1 -1
  225. package/components/Icons/Boat.d.ts.map +1 -1
  226. package/components/Icons/Boat.js.map +1 -1
  227. package/components/Icons/Body.d.ts.map +1 -1
  228. package/components/Icons/Body.js.map +1 -1
  229. package/components/Icons/Brain.d.ts.map +1 -1
  230. package/components/Icons/Brain.js.map +1 -1
  231. package/components/Icons/BreastReconstruction.d.ts.map +1 -1
  232. package/components/Icons/BreastReconstruction.js.map +1 -1
  233. package/components/Icons/BreastRemoval.d.ts.map +1 -1
  234. package/components/Icons/BreastRemoval.js.map +1 -1
  235. package/components/Icons/Breasts.d.ts.map +1 -1
  236. package/components/Icons/Breasts.js.map +1 -1
  237. package/components/Icons/BrokenHeart.d.ts.map +1 -1
  238. package/components/Icons/BrokenHeart.js.map +1 -1
  239. package/components/Icons/BrokenPuzzle.d.ts.map +1 -1
  240. package/components/Icons/BrokenPuzzle.js.map +1 -1
  241. package/components/Icons/Bus.d.ts.map +1 -1
  242. package/components/Icons/Bus.js.map +1 -1
  243. package/components/Icons/Calendar.d.ts.map +1 -1
  244. package/components/Icons/Calendar.js.map +1 -1
  245. package/components/Icons/CalendarChange.d.ts.map +1 -1
  246. package/components/Icons/CalendarChange.js.map +1 -1
  247. package/components/Icons/CalendarCheck.d.ts.map +1 -1
  248. package/components/Icons/CalendarCheck.js.map +1 -1
  249. package/components/Icons/CalendarEvent.d.ts.map +1 -1
  250. package/components/Icons/CalendarEvent.js.map +1 -1
  251. package/components/Icons/CalendarSave.d.ts.map +1 -1
  252. package/components/Icons/CalendarSave.js.map +1 -1
  253. package/components/Icons/Cancer.d.ts.map +1 -1
  254. package/components/Icons/Cancer.js.map +1 -1
  255. package/components/Icons/Car.d.ts.map +1 -1
  256. package/components/Icons/Car.js.map +1 -1
  257. package/components/Icons/Change.d.ts.map +1 -1
  258. package/components/Icons/Change.js.map +1 -1
  259. package/components/Icons/Check.d.ts.map +1 -1
  260. package/components/Icons/Check.js.map +1 -1
  261. package/components/Icons/CheckFill.d.ts.map +1 -1
  262. package/components/Icons/CheckFill.js.map +1 -1
  263. package/components/Icons/CheckOutline.d.ts.map +1 -1
  264. package/components/Icons/CheckOutline.js.map +1 -1
  265. package/components/Icons/Chest.d.ts.map +1 -1
  266. package/components/Icons/Chest.js.map +1 -1
  267. package/components/Icons/ChevronDown.d.ts.map +1 -1
  268. package/components/Icons/ChevronDown.js.map +1 -1
  269. package/components/Icons/ChevronLeft.d.ts.map +1 -1
  270. package/components/Icons/ChevronLeft.js.map +1 -1
  271. package/components/Icons/ChevronRight.d.ts.map +1 -1
  272. package/components/Icons/ChevronRight.js.map +1 -1
  273. package/components/Icons/ChevronUp.d.ts.map +1 -1
  274. package/components/Icons/ChevronUp.js.map +1 -1
  275. package/components/Icons/ChevronsDown.d.ts.map +1 -1
  276. package/components/Icons/ChevronsDown.js.map +1 -1
  277. package/components/Icons/ChevronsUp.d.ts.map +1 -1
  278. package/components/Icons/ChevronsUp.js.map +1 -1
  279. package/components/Icons/ChildPlaying.d.ts.map +1 -1
  280. package/components/Icons/ChildPlaying.js.map +1 -1
  281. package/components/Icons/Cigarette.d.ts.map +1 -1
  282. package/components/Icons/Cigarette.js.map +1 -1
  283. package/components/Icons/Coins.d.ts.map +1 -1
  284. package/components/Icons/Coins.js.map +1 -1
  285. package/components/Icons/Contacts.d.ts.map +1 -1
  286. package/components/Icons/Contacts.js.map +1 -1
  287. package/components/Icons/Copy.d.ts.map +1 -1
  288. package/components/Icons/Copy.js.map +1 -1
  289. package/components/Icons/CoronaCertificate.d.ts.map +1 -1
  290. package/components/Icons/CoronaCertificate.js.map +1 -1
  291. package/components/Icons/Coronavirus.d.ts.map +1 -1
  292. package/components/Icons/Coronavirus.js.map +1 -1
  293. package/components/Icons/Cough.d.ts.map +1 -1
  294. package/components/Icons/Cough.js.map +1 -1
  295. package/components/Icons/CriticalHealthInfo.d.ts.map +1 -1
  296. package/components/Icons/CriticalHealthInfo.js.map +1 -1
  297. package/components/Icons/Cross.d.ts.map +1 -1
  298. package/components/Icons/Cross.js.map +1 -1
  299. package/components/Icons/DataExchange.d.ts.map +1 -1
  300. package/components/Icons/DataExchange.js.map +1 -1
  301. package/components/Icons/DataReceived.d.ts.map +1 -1
  302. package/components/Icons/DataReceived.js.map +1 -1
  303. package/components/Icons/DataSent.d.ts.map +1 -1
  304. package/components/Icons/DataSent.js.map +1 -1
  305. package/components/Icons/Depression.d.ts.map +1 -1
  306. package/components/Icons/Depression.js.map +1 -1
  307. package/components/Icons/DigestiveSystem.d.ts.map +1 -1
  308. package/components/Icons/DigestiveSystem.js.map +1 -1
  309. package/components/Icons/Dizzy.d.ts.map +1 -1
  310. package/components/Icons/Dizzy.js.map +1 -1
  311. package/components/Icons/Documents.d.ts.map +1 -1
  312. package/components/Icons/Documents.js.map +1 -1
  313. package/components/Icons/Dog.d.ts.map +1 -1
  314. package/components/Icons/Dog.js.map +1 -1
  315. package/components/Icons/DonorCard.d.ts.map +1 -1
  316. package/components/Icons/DonorCard.js.map +1 -1
  317. package/components/Icons/Download.d.ts.map +1 -1
  318. package/components/Icons/Download.js.map +1 -1
  319. package/components/Icons/Draft.d.ts.map +1 -1
  320. package/components/Icons/Draft.js.map +1 -1
  321. package/components/Icons/EChat.d.ts.map +1 -1
  322. package/components/Icons/EChat.js.map +1 -1
  323. package/components/Icons/EarNoseThroat.d.ts.map +1 -1
  324. package/components/Icons/EarNoseThroat.js.map +1 -1
  325. package/components/Icons/ElderlyPerson.d.ts.map +1 -1
  326. package/components/Icons/ElderlyPerson.js.map +1 -1
  327. package/components/Icons/Embolization.d.ts.map +1 -1
  328. package/components/Icons/Embolization.js.map +1 -1
  329. package/components/Icons/EmoticonAnnoyed.d.ts.map +1 -1
  330. package/components/Icons/EmoticonAnnoyed.js.map +1 -1
  331. package/components/Icons/EmoticonDelighted.d.ts.map +1 -1
  332. package/components/Icons/EmoticonDelighted.js.map +1 -1
  333. package/components/Icons/EmoticonDisappointed.d.ts.map +1 -1
  334. package/components/Icons/EmoticonDisappointed.js.map +1 -1
  335. package/components/Icons/EmoticonHappy.d.ts.map +1 -1
  336. package/components/Icons/EmoticonHappy.js.map +1 -1
  337. package/components/Icons/EmoticonMeh.d.ts.map +1 -1
  338. package/components/Icons/EmoticonMeh.js.map +1 -1
  339. package/components/Icons/EnterFullScreen.d.ts.map +1 -1
  340. package/components/Icons/EnterFullScreen.js.map +1 -1
  341. package/components/Icons/Envelope.d.ts.map +1 -1
  342. package/components/Icons/Envelope.js.map +1 -1
  343. package/components/Icons/Epilepsy.d.ts.map +1 -1
  344. package/components/Icons/Epilepsy.js.map +1 -1
  345. package/components/Icons/Eraser.d.ts.map +1 -1
  346. package/components/Icons/Eraser.js.map +1 -1
  347. package/components/Icons/ErrorSignFill.d.ts.map +1 -1
  348. package/components/Icons/ErrorSignFill.js.map +1 -1
  349. package/components/Icons/ErrorSignStroke.d.ts.map +1 -1
  350. package/components/Icons/ErrorSignStroke.js.map +1 -1
  351. package/components/Icons/EuropeanHealthCard.d.ts.map +1 -1
  352. package/components/Icons/EuropeanHealthCard.js.map +1 -1
  353. package/components/Icons/ExitFullScreen.d.ts.map +1 -1
  354. package/components/Icons/ExitFullScreen.js.map +1 -1
  355. package/components/Icons/Eye.d.ts.map +1 -1
  356. package/components/Icons/Eye.js.map +1 -1
  357. package/components/Icons/Facebook.d.ts.map +1 -1
  358. package/components/Icons/Facebook.js.map +1 -1
  359. package/components/Icons/Female.d.ts.map +1 -1
  360. package/components/Icons/Female.js.map +1 -1
  361. package/components/Icons/FemaleDoctor.d.ts.map +1 -1
  362. package/components/Icons/FemaleDoctor.js.map +1 -1
  363. package/components/Icons/Ferry.d.ts.map +1 -1
  364. package/components/Icons/Ferry.js.map +1 -1
  365. package/components/Icons/File.d.ts.map +1 -1
  366. package/components/Icons/File.js.map +1 -1
  367. package/components/Icons/Filter.d.ts.map +1 -1
  368. package/components/Icons/Filter.js.map +1 -1
  369. package/components/Icons/FingerBleed.d.ts.map +1 -1
  370. package/components/Icons/FingerBleed.js.map +1 -1
  371. package/components/Icons/FirstAidKit.d.ts.map +1 -1
  372. package/components/Icons/FirstAidKit.js.map +1 -1
  373. package/components/Icons/FloppyDisk.d.ts.map +1 -1
  374. package/components/Icons/FloppyDisk.js.map +1 -1
  375. package/components/Icons/Football.d.ts.map +1 -1
  376. package/components/Icons/Football.js.map +1 -1
  377. package/components/Icons/Form.d.ts.map +1 -1
  378. package/components/Icons/Form.js.map +1 -1
  379. package/components/Icons/Forward.d.ts.map +1 -1
  380. package/components/Icons/Forward.js.map +1 -1
  381. package/components/Icons/Gallery.d.ts.map +1 -1
  382. package/components/Icons/Gallery.js.map +1 -1
  383. package/components/Icons/Garden.d.ts.map +1 -1
  384. package/components/Icons/Garden.js.map +1 -1
  385. package/components/Icons/GasCan.d.ts.map +1 -1
  386. package/components/Icons/GasCan.js.map +1 -1
  387. package/components/Icons/GenderIdentity.d.ts.map +1 -1
  388. package/components/Icons/GenderIdentity.js.map +1 -1
  389. package/components/Icons/Globe.d.ts.map +1 -1
  390. package/components/Icons/Globe.js.map +1 -1
  391. package/components/Icons/Group.d.ts.map +1 -1
  392. package/components/Icons/Group.js.map +1 -1
  393. package/components/Icons/HandWaving.d.ts.map +1 -1
  394. package/components/Icons/HandWaving.js.map +1 -1
  395. package/components/Icons/HandWithDisease.d.ts.map +1 -1
  396. package/components/Icons/HandWithDisease.js.map +1 -1
  397. package/components/Icons/HealthClinic.d.ts.map +1 -1
  398. package/components/Icons/HealthClinic.js.map +1 -1
  399. package/components/Icons/HealthWarning.d.ts.map +1 -1
  400. package/components/Icons/HealthWarning.js.map +1 -1
  401. package/components/Icons/Heart.d.ts.map +1 -1
  402. package/components/Icons/Heart.js.map +1 -1
  403. package/components/Icons/HeartHands.d.ts.map +1 -1
  404. package/components/Icons/HeartHands.js.map +1 -1
  405. package/components/Icons/HelpSign.d.ts.map +1 -1
  406. package/components/Icons/HelpSign.js.map +1 -1
  407. package/components/Icons/HelpingHand.d.ts.map +1 -1
  408. package/components/Icons/HelpingHand.js.map +1 -1
  409. package/components/Icons/Hemodialysis.d.ts.map +1 -1
  410. package/components/Icons/Hemodialysis.js.map +1 -1
  411. package/components/Icons/Hiker.d.ts.map +1 -1
  412. package/components/Icons/Hiker.js.map +1 -1
  413. package/components/Icons/Hipprosthesis.d.ts.map +1 -1
  414. package/components/Icons/Hipprosthesis.js.map +1 -1
  415. package/components/Icons/History.d.ts.map +1 -1
  416. package/components/Icons/History.js.map +1 -1
  417. package/components/Icons/HivAndAids.d.ts.map +1 -1
  418. package/components/Icons/HivAndAids.js.map +1 -1
  419. package/components/Icons/Home.d.ts.map +1 -1
  420. package/components/Icons/Home.js.map +1 -1
  421. package/components/Icons/Hormone.d.ts.map +1 -1
  422. package/components/Icons/Hormone.js.map +1 -1
  423. package/components/Icons/Hospital.d.ts.map +1 -1
  424. package/components/Icons/Hospital.js.map +1 -1
  425. package/components/Icons/Hourglass.d.ts.map +1 -1
  426. package/components/Icons/Hourglass.js.map +1 -1
  427. package/components/Icons/Icon.d.ts +1 -1
  428. package/components/Icons/Icon.d.ts.map +1 -1
  429. package/components/Icons/Icon.js +1 -1
  430. package/components/Icons/Icon.js.map +1 -1
  431. package/components/Icons/ImgFile.d.ts.map +1 -1
  432. package/components/Icons/ImgFile.js.map +1 -1
  433. package/components/Icons/Inbox.d.ts.map +1 -1
  434. package/components/Icons/Inbox.js.map +1 -1
  435. package/components/Icons/InfoSignFill.d.ts.map +1 -1
  436. package/components/Icons/InfoSignFill.js.map +1 -1
  437. package/components/Icons/InfoSignStroke.d.ts.map +1 -1
  438. package/components/Icons/InfoSignStroke.js.map +1 -1
  439. package/components/Icons/Instagram.d.ts.map +1 -1
  440. package/components/Icons/Instagram.js.map +1 -1
  441. package/components/Icons/Intravenous.d.ts.map +1 -1
  442. package/components/Icons/Intravenous.js.map +1 -1
  443. package/components/Icons/JointPain.d.ts.map +1 -1
  444. package/components/Icons/JointPain.js.map +1 -1
  445. package/components/Icons/Journal.d.ts.map +1 -1
  446. package/components/Icons/Journal.js.map +1 -1
  447. package/components/Icons/JpgFile.d.ts.map +1 -1
  448. package/components/Icons/JpgFile.js.map +1 -1
  449. package/components/Icons/Kidney.d.ts.map +1 -1
  450. package/components/Icons/Kidney.js.map +1 -1
  451. package/components/Icons/KitchenScale.d.ts.map +1 -1
  452. package/components/Icons/KitchenScale.js.map +1 -1
  453. package/components/Icons/Kjernejournal.d.ts.map +1 -1
  454. package/components/Icons/Kjernejournal.js.map +1 -1
  455. package/components/Icons/Laboratory.d.ts.map +1 -1
  456. package/components/Icons/Laboratory.js.map +1 -1
  457. package/components/Icons/LaptopBlog.d.ts.map +1 -1
  458. package/components/Icons/LaptopBlog.js.map +1 -1
  459. package/components/Icons/LawBook.d.ts.map +1 -1
  460. package/components/Icons/LawBook.js.map +1 -1
  461. package/components/Icons/LightBulb.d.ts.map +1 -1
  462. package/components/Icons/LightBulb.js.map +1 -1
  463. package/components/Icons/List.d.ts.map +1 -1
  464. package/components/Icons/List.js.map +1 -1
  465. package/components/Icons/Location.d.ts.map +1 -1
  466. package/components/Icons/Location.js.map +1 -1
  467. package/components/Icons/Lock.d.ts.map +1 -1
  468. package/components/Icons/Lock.js.map +1 -1
  469. package/components/Icons/Login.d.ts.map +1 -1
  470. package/components/Icons/Login.js.map +1 -1
  471. package/components/Icons/Logout.d.ts.map +1 -1
  472. package/components/Icons/Logout.js.map +1 -1
  473. package/components/Icons/Lungs.d.ts.map +1 -1
  474. package/components/Icons/Lungs.js.map +1 -1
  475. package/components/Icons/Makeup.d.ts.map +1 -1
  476. package/components/Icons/Makeup.js.map +1 -1
  477. package/components/Icons/MaleDoctor.d.ts.map +1 -1
  478. package/components/Icons/MaleDoctor.js.map +1 -1
  479. package/components/Icons/MaleDoctorAndPerson.d.ts.map +1 -1
  480. package/components/Icons/MaleDoctorAndPerson.js.map +1 -1
  481. package/components/Icons/MaleGenitalia.d.ts.map +1 -1
  482. package/components/Icons/MaleGenitalia.js.map +1 -1
  483. package/components/Icons/Medicine.d.ts.map +1 -1
  484. package/components/Icons/Medicine.js.map +1 -1
  485. package/components/Icons/MedicineWarning.d.ts.map +1 -1
  486. package/components/Icons/MedicineWarning.js.map +1 -1
  487. package/components/Icons/MentalHealthAdult.d.ts.map +1 -1
  488. package/components/Icons/MentalHealthAdult.js.map +1 -1
  489. package/components/Icons/MentalHealthChild.d.ts.map +1 -1
  490. package/components/Icons/MentalHealthChild.js.map +1 -1
  491. package/components/Icons/Menu.d.ts.map +1 -1
  492. package/components/Icons/Menu.js.map +1 -1
  493. package/components/Icons/Microscope.d.ts.map +1 -1
  494. package/components/Icons/Microscope.js.map +1 -1
  495. package/components/Icons/Minus.d.ts.map +1 -1
  496. package/components/Icons/Minus.js.map +1 -1
  497. package/components/Icons/Mirror.d.ts.map +1 -1
  498. package/components/Icons/Mirror.js.map +1 -1
  499. package/components/Icons/MobilePhone.d.ts.map +1 -1
  500. package/components/Icons/MobilePhone.js.map +1 -1
  501. package/components/Icons/MotherHoldingBaby.d.ts.map +1 -1
  502. package/components/Icons/MotherHoldingBaby.js.map +1 -1
  503. package/components/Icons/MuscleBack.d.ts.map +1 -1
  504. package/components/Icons/MuscleBack.js.map +1 -1
  505. package/components/Icons/MuscleLeg.d.ts.map +1 -1
  506. package/components/Icons/MuscleLeg.js.map +1 -1
  507. package/components/Icons/Mushroom.d.ts.map +1 -1
  508. package/components/Icons/Mushroom.js.map +1 -1
  509. package/components/Icons/Music.d.ts.map +1 -1
  510. package/components/Icons/Music.js.map +1 -1
  511. package/components/Icons/MusselsAndSalt.d.ts.map +1 -1
  512. package/components/Icons/MusselsAndSalt.js.map +1 -1
  513. package/components/Icons/NoAccess.d.ts.map +1 -1
  514. package/components/Icons/NoAccess.js.map +1 -1
  515. package/components/Icons/NoEye.d.ts.map +1 -1
  516. package/components/Icons/NoEye.js.map +1 -1
  517. package/components/Icons/NoFilter.d.ts.map +1 -1
  518. package/components/Icons/NoFilter.js.map +1 -1
  519. package/components/Icons/Notepad.d.ts.map +1 -1
  520. package/components/Icons/Notepad.js.map +1 -1
  521. package/components/Icons/Osteotomy.d.ts.map +1 -1
  522. package/components/Icons/Osteotomy.js.map +1 -1
  523. package/components/Icons/PaintRoller.d.ts.map +1 -1
  524. package/components/Icons/PaintRoller.js.map +1 -1
  525. package/components/Icons/PaperPlane.d.ts.map +1 -1
  526. package/components/Icons/PaperPlane.js.map +1 -1
  527. package/components/Icons/PatientAndPerson.d.ts.map +1 -1
  528. package/components/Icons/PatientAndPerson.js.map +1 -1
  529. package/components/Icons/Pause.d.ts.map +1 -1
  530. package/components/Icons/Pause.js.map +1 -1
  531. package/components/Icons/PdfFile.d.ts.map +1 -1
  532. package/components/Icons/PdfFile.js.map +1 -1
  533. package/components/Icons/Pencil.d.ts.map +1 -1
  534. package/components/Icons/Pencil.js.map +1 -1
  535. package/components/Icons/PeopleTalking.d.ts.map +1 -1
  536. package/components/Icons/PeopleTalking.js.map +1 -1
  537. package/components/Icons/Peritonealdialysis.d.ts.map +1 -1
  538. package/components/Icons/Peritonealdialysis.js.map +1 -1
  539. package/components/Icons/Person.d.ts.map +1 -1
  540. package/components/Icons/Person.js.map +1 -1
  541. package/components/Icons/PersonAndPatient.d.ts.map +1 -1
  542. package/components/Icons/PersonAndPatient.js.map +1 -1
  543. package/components/Icons/PersonCancel.d.ts.map +1 -1
  544. package/components/Icons/PersonCancel.js.map +1 -1
  545. package/components/Icons/PersonInXRayMachine.d.ts.map +1 -1
  546. package/components/Icons/PersonInXRayMachine.js.map +1 -1
  547. package/components/Icons/PersonOverweight.d.ts.map +1 -1
  548. package/components/Icons/PersonOverweight.js.map +1 -1
  549. package/components/Icons/PersonRelaxing.d.ts.map +1 -1
  550. package/components/Icons/PersonRelaxing.js.map +1 -1
  551. package/components/Icons/PersonWithBrain.d.ts.map +1 -1
  552. package/components/Icons/PersonWithBrain.js.map +1 -1
  553. package/components/Icons/PersonWithBrokenArm.d.ts.map +1 -1
  554. package/components/Icons/PersonWithBrokenArm.js.map +1 -1
  555. package/components/Icons/PersonWithCrutches.d.ts.map +1 -1
  556. package/components/Icons/PersonWithCrutches.js.map +1 -1
  557. package/components/Icons/PersonWithJaw.d.ts.map +1 -1
  558. package/components/Icons/PersonWithJaw.js.map +1 -1
  559. package/components/Icons/PersonWithMagnifyingGlass.d.ts.map +1 -1
  560. package/components/Icons/PersonWithMagnifyingGlass.js.map +1 -1
  561. package/components/Icons/PersonWithSenses.d.ts.map +1 -1
  562. package/components/Icons/PersonWithSenses.js.map +1 -1
  563. package/components/Icons/PersonWorking.d.ts.map +1 -1
  564. package/components/Icons/PersonWorking.js.map +1 -1
  565. package/components/Icons/PersonalPlan.d.ts.map +1 -1
  566. package/components/Icons/PersonalPlan.js.map +1 -1
  567. package/components/Icons/PizzaSlice.d.ts.map +1 -1
  568. package/components/Icons/PizzaSlice.js.map +1 -1
  569. package/components/Icons/Plane.d.ts.map +1 -1
  570. package/components/Icons/Plane.js.map +1 -1
  571. package/components/Icons/Plant.d.ts.map +1 -1
  572. package/components/Icons/Plant.js.map +1 -1
  573. package/components/Icons/Play.d.ts.map +1 -1
  574. package/components/Icons/Play.js.map +1 -1
  575. package/components/Icons/PlusLarge.d.ts.map +1 -1
  576. package/components/Icons/PlusLarge.js.map +1 -1
  577. package/components/Icons/PlusSmall.d.ts.map +1 -1
  578. package/components/Icons/PlusSmall.js.map +1 -1
  579. package/components/Icons/PngFile.d.ts.map +1 -1
  580. package/components/Icons/PngFile.js.map +1 -1
  581. package/components/Icons/Podcast.d.ts.map +1 -1
  582. package/components/Icons/Podcast.js.map +1 -1
  583. package/components/Icons/PoisonInformation.d.ts.map +1 -1
  584. package/components/Icons/PoisonInformation.js.map +1 -1
  585. package/components/Icons/Pregnant.d.ts.map +1 -1
  586. package/components/Icons/Pregnant.js.map +1 -1
  587. package/components/Icons/Printer.d.ts.map +1 -1
  588. package/components/Icons/Printer.js.map +1 -1
  589. package/components/Icons/Psychosis.d.ts.map +1 -1
  590. package/components/Icons/Psychosis.js.map +1 -1
  591. package/components/Icons/Publication.d.ts.map +1 -1
  592. package/components/Icons/Publication.js.map +1 -1
  593. package/components/Icons/Puzzle.d.ts.map +1 -1
  594. package/components/Icons/Puzzle.js.map +1 -1
  595. package/components/Icons/QrCode.d.ts.map +1 -1
  596. package/components/Icons/QrCode.js.map +1 -1
  597. package/components/Icons/Quarrel.d.ts.map +1 -1
  598. package/components/Icons/Quarrel.js.map +1 -1
  599. package/components/Icons/RadioTherapy.d.ts.map +1 -1
  600. package/components/Icons/RadioTherapy.js.map +1 -1
  601. package/components/Icons/RadioactiveTreatment.d.ts.map +1 -1
  602. package/components/Icons/RadioactiveTreatment.js.map +1 -1
  603. package/components/Icons/Radioiodine.d.ts.map +1 -1
  604. package/components/Icons/Radioiodine.js.map +1 -1
  605. package/components/Icons/Receipt.d.ts.map +1 -1
  606. package/components/Icons/Receipt.js.map +1 -1
  607. package/components/Icons/Receptionist.d.ts.map +1 -1
  608. package/components/Icons/Receptionist.js.map +1 -1
  609. package/components/Icons/Recovery.d.ts.map +1 -1
  610. package/components/Icons/Recovery.js.map +1 -1
  611. package/components/Icons/Referral.d.ts.map +1 -1
  612. package/components/Icons/Referral.js.map +1 -1
  613. package/components/Icons/Refresh.d.ts.map +1 -1
  614. package/components/Icons/Refresh.js.map +1 -1
  615. package/components/Icons/Refund.d.ts.map +1 -1
  616. package/components/Icons/Refund.js.map +1 -1
  617. package/components/Icons/Reply.d.ts.map +1 -1
  618. package/components/Icons/Reply.js.map +1 -1
  619. package/components/Icons/Rocket.d.ts.map +1 -1
  620. package/components/Icons/Rocket.js.map +1 -1
  621. package/components/Icons/RtfFile.d.ts.map +1 -1
  622. package/components/Icons/RtfFile.js.map +1 -1
  623. package/components/Icons/STDs.d.ts.map +1 -1
  624. package/components/Icons/STDs.js.map +1 -1
  625. package/components/Icons/Save.d.ts.map +1 -1
  626. package/components/Icons/Save.js.map +1 -1
  627. package/components/Icons/Scale.d.ts.map +1 -1
  628. package/components/Icons/Scale.js.map +1 -1
  629. package/components/Icons/Search.d.ts.map +1 -1
  630. package/components/Icons/Search.js.map +1 -1
  631. package/components/Icons/SectionSign.d.ts.map +1 -1
  632. package/components/Icons/SectionSign.js.map +1 -1
  633. package/components/Icons/Settings.d.ts.map +1 -1
  634. package/components/Icons/Settings.js.map +1 -1
  635. package/components/Icons/Sexualorientation.d.ts.map +1 -1
  636. package/components/Icons/Sexualorientation.js.map +1 -1
  637. package/components/Icons/ShakingHand.d.ts.map +1 -1
  638. package/components/Icons/ShakingHand.js.map +1 -1
  639. package/components/Icons/Share.d.ts.map +1 -1
  640. package/components/Icons/Share.js.map +1 -1
  641. package/components/Icons/Shield.d.ts.map +1 -1
  642. package/components/Icons/Shield.js.map +1 -1
  643. package/components/Icons/ShuntOperation.d.ts.map +1 -1
  644. package/components/Icons/ShuntOperation.js.map +1 -1
  645. package/components/Icons/Skeleton.d.ts.map +1 -1
  646. package/components/Icons/Skeleton.js.map +1 -1
  647. package/components/Icons/Skin.d.ts.map +1 -1
  648. package/components/Icons/Skin.js.map +1 -1
  649. package/components/Icons/Snake.d.ts.map +1 -1
  650. package/components/Icons/Snake.js.map +1 -1
  651. package/components/Icons/Snapchat.d.ts.map +1 -1
  652. package/components/Icons/Snapchat.js.map +1 -1
  653. package/components/Icons/SortDown.d.ts.map +1 -1
  654. package/components/Icons/SortDown.js.map +1 -1
  655. package/components/Icons/SortUp.d.ts.map +1 -1
  656. package/components/Icons/SortUp.js +1 -1
  657. package/components/Icons/SortUp.js.map +1 -1
  658. package/components/Icons/SpeechBubble.d.ts.map +1 -1
  659. package/components/Icons/SpeechBubble.js.map +1 -1
  660. package/components/Icons/Spray.d.ts.map +1 -1
  661. package/components/Icons/Spray.js.map +1 -1
  662. package/components/Icons/Stopwatch.d.ts.map +1 -1
  663. package/components/Icons/Stopwatch.js.map +1 -1
  664. package/components/Icons/SupportingPerson.js +1 -1
  665. package/components/Icons/SupportingPerson.js.map +1 -1
  666. package/components/Icons/Surgery.d.ts.map +1 -1
  667. package/components/Icons/Surgery.js.map +1 -1
  668. package/components/Icons/Syringe.d.ts.map +1 -1
  669. package/components/Icons/Syringe.js.map +1 -1
  670. package/components/Icons/Taxi.d.ts.map +1 -1
  671. package/components/Icons/Taxi.js.map +1 -1
  672. package/components/Icons/TeddyBear.d.ts.map +1 -1
  673. package/components/Icons/TeddyBear.js.map +1 -1
  674. package/components/Icons/Teenagers.d.ts.map +1 -1
  675. package/components/Icons/Teenagers.js.map +1 -1
  676. package/components/Icons/ThinkingAboutBaby.d.ts.map +1 -1
  677. package/components/Icons/ThinkingAboutBaby.js.map +1 -1
  678. package/components/Icons/Ticket.d.ts.map +1 -1
  679. package/components/Icons/Ticket.js.map +1 -1
  680. package/components/Icons/TimePassing.d.ts.map +1 -1
  681. package/components/Icons/TimePassing.js.map +1 -1
  682. package/components/Icons/Toolbox.d.ts.map +1 -1
  683. package/components/Icons/Toolbox.js.map +1 -1
  684. package/components/Icons/Tooth.d.ts.map +1 -1
  685. package/components/Icons/Tooth.js.map +1 -1
  686. package/components/Icons/TotalKneeProsthesis.d.ts.map +1 -1
  687. package/components/Icons/TotalKneeProsthesis.js.map +1 -1
  688. package/components/Icons/Train.d.ts.map +1 -1
  689. package/components/Icons/Train.js.map +1 -1
  690. package/components/Icons/Transplantation.d.ts.map +1 -1
  691. package/components/Icons/Transplantation.js.map +1 -1
  692. package/components/Icons/TrashCan.d.ts.map +1 -1
  693. package/components/Icons/TrashCan.js.map +1 -1
  694. package/components/Icons/TravelRoute.d.ts.map +1 -1
  695. package/components/Icons/TravelRoute.js.map +1 -1
  696. package/components/Icons/TriangleX.d.ts.map +1 -1
  697. package/components/Icons/TriangleX.js.map +1 -1
  698. package/components/Icons/Twitter.d.ts.map +1 -1
  699. package/components/Icons/Twitter.js.map +1 -1
  700. package/components/Icons/Undo.d.ts.map +1 -1
  701. package/components/Icons/Undo.js.map +1 -1
  702. package/components/Icons/UniProsthesis.d.ts.map +1 -1
  703. package/components/Icons/UniProsthesis.js.map +1 -1
  704. package/components/Icons/Upload.d.ts.map +1 -1
  705. package/components/Icons/Upload.js.map +1 -1
  706. package/components/Icons/UserOrganization.d.ts.map +1 -1
  707. package/components/Icons/UserOrganization.js.map +1 -1
  708. package/components/Icons/Vaccine.d.ts.map +1 -1
  709. package/components/Icons/Vaccine.js.map +1 -1
  710. package/components/Icons/VerticalDots.d.ts.map +1 -1
  711. package/components/Icons/VerticalDots.js.map +1 -1
  712. package/components/Icons/VideoCamera.d.ts.map +1 -1
  713. package/components/Icons/VideoCamera.js.map +1 -1
  714. package/components/Icons/VideoChat.d.ts.map +1 -1
  715. package/components/Icons/VideoChat.js.map +1 -1
  716. package/components/Icons/Wallet.d.ts.map +1 -1
  717. package/components/Icons/Wallet.js.map +1 -1
  718. package/components/Icons/Watch.d.ts.map +1 -1
  719. package/components/Icons/Watch.js.map +1 -1
  720. package/components/Icons/Website.d.ts.map +1 -1
  721. package/components/Icons/Website.js.map +1 -1
  722. package/components/Icons/Wheelchair.d.ts.map +1 -1
  723. package/components/Icons/Wheelchair.js.map +1 -1
  724. package/components/Icons/WheelchairActive.d.ts.map +1 -1
  725. package/components/Icons/WheelchairActive.js.map +1 -1
  726. package/components/Icons/Window.d.ts.map +1 -1
  727. package/components/Icons/Window.js.map +1 -1
  728. package/components/Icons/WordDocument.d.ts.map +1 -1
  729. package/components/Icons/WordDocument.js.map +1 -1
  730. package/components/Icons/WorkSuitcase.d.ts.map +1 -1
  731. package/components/Icons/WorkSuitcase.js.map +1 -1
  732. package/components/Icons/X.d.ts.map +1 -1
  733. package/components/Icons/X.js.map +1 -1
  734. package/components/Icons/XOutline.d.ts.map +1 -1
  735. package/components/Icons/XOutline.js.map +1 -1
  736. package/components/Icons/XmlFile.d.ts.map +1 -1
  737. package/components/Icons/XmlFile.js.map +1 -1
  738. package/components/Icons/YouTube.d.ts.map +1 -1
  739. package/components/Icons/YouTube.js.map +1 -1
  740. package/components/Icons/Zoom.d.ts.map +1 -1
  741. package/components/Icons/Zoom.js.map +1 -1
  742. package/components/Icons/index.js +1 -1
  743. package/components/Input/Input.d.ts.map +1 -1
  744. package/components/Input/componentdata.json +1 -1
  745. package/components/Input/index.js +1 -1
  746. package/components/Input/styles.module.scss +8 -7
  747. package/components/LinkList/LinkList.d.ts +8 -8
  748. package/components/LinkList/LinkList.d.ts.map +1 -1
  749. package/components/LinkList/index.js +1 -1
  750. package/components/LinkList/index.js.map +1 -1
  751. package/components/LinkList/styles.module.scss +23 -5
  752. package/components/List/List.d.ts +17 -3
  753. package/components/List/List.d.ts.map +1 -1
  754. package/components/List/componentdata.json +1 -1
  755. package/components/List/index.js +1 -1
  756. package/components/List/index.js.map +1 -1
  757. package/components/List/styles.module.scss +55 -5
  758. package/components/List/styles.module.scss.d.ts +5 -0
  759. package/components/ListHeader/ListHeader.d.ts +12 -10
  760. package/components/ListHeader/ListHeader.d.ts.map +1 -1
  761. package/components/ListHeader/ListHeaderText/ListHeaderText.d.ts +1 -1
  762. package/components/ListHeader/ListHeaderText/ListHeaderText.d.ts.map +1 -1
  763. package/components/ListHeader/ListHeaderText/index.js +1 -1
  764. package/components/ListHeader/index.js +1 -1
  765. package/components/ListHeader/styles.module.scss +36 -11
  766. package/components/Loader/Loader.d.ts +2 -2
  767. package/components/Loader/Loader.d.ts.map +1 -1
  768. package/components/Loader/index.js +1 -1
  769. package/components/Loader/index.js.map +1 -1
  770. package/components/Loader/styles.module.scss +40 -18
  771. package/components/Logo/Logo.d.ts +1 -1
  772. package/components/Logo/Logo.d.ts.map +1 -1
  773. package/components/Logo/index.js +1 -1
  774. package/components/Logo/index.js.map +1 -1
  775. package/components/MaxCharacters/MaxCharacters.d.ts.map +1 -1
  776. package/components/MaxCharacters/styles.module.scss +7 -5
  777. package/components/Modal/Modal.d.ts.map +1 -1
  778. package/components/Modal/index.js +1 -1
  779. package/components/Modal/styles.module.scss +39 -23
  780. package/components/NotificationPanel/DetailButton/DetailButton.d.ts +10 -0
  781. package/components/NotificationPanel/DetailButton/DetailButton.d.ts.map +1 -0
  782. package/components/NotificationPanel/DetailButton/componentdata.json +1 -0
  783. package/components/NotificationPanel/DetailButton/styles.module.scss +38 -0
  784. package/components/NotificationPanel/DetailButton/styles.module.scss.d.ts +13 -0
  785. package/components/NotificationPanel/NotificationPanel.d.ts +16 -7
  786. package/components/NotificationPanel/NotificationPanel.d.ts.map +1 -1
  787. package/components/NotificationPanel/componentdata.json +1 -1
  788. package/components/NotificationPanel/index.js +1 -1
  789. package/components/NotificationPanel/index.js.map +1 -1
  790. package/components/NotificationPanel/styles.module.scss +131 -97
  791. package/components/NotificationPanel/styles.module.scss.d.ts +10 -10
  792. package/components/Panel/Panel.d.ts +2 -2
  793. package/components/Panel/Panel.d.ts.map +1 -1
  794. package/components/Panel/index.js +1 -1
  795. package/components/Panel/styles.module.scss +53 -29
  796. package/components/PanelList/PanelList.d.ts.map +1 -1
  797. package/components/PanelList/index.js +1 -1
  798. package/components/PanelList/index.js.map +1 -1
  799. package/components/PanelList/styles.module.scss +6 -5
  800. package/components/PopMenu/PopMenu.d.ts +30 -0
  801. package/components/PopMenu/PopMenu.d.ts.map +1 -0
  802. package/components/PopMenu/componentdata.json +1 -0
  803. package/components/PopMenu/story.module.scss +5 -0
  804. package/components/PopMenu/story.module.scss.d.ts +9 -0
  805. package/components/PopMenu/styles.module.scss +138 -0
  806. package/components/PopMenu/styles.module.scss.d.ts +14 -0
  807. package/components/PopOver/PopOver.d.ts +34 -0
  808. package/components/PopOver/PopOver.d.ts.map +1 -0
  809. package/components/PopOver/componentdata.json +1 -0
  810. package/components/PopOver/index.d.ts +4 -0
  811. package/components/PopOver/index.d.ts.map +1 -0
  812. package/components/PopOver/index.js +2 -0
  813. package/components/PopOver/index.js.map +1 -0
  814. package/components/PopOver/styles.module.scss +66 -0
  815. package/components/PopOver/styles.module.scss.d.ts +16 -0
  816. package/components/{HelpBubble → PopOver}/utils.d.ts +4 -4
  817. package/components/PopOver/utils.d.ts.map +1 -0
  818. package/components/Portal/index.d.ts.map +1 -1
  819. package/components/Portal/index.js +1 -1
  820. package/components/Portal/index.js.map +1 -1
  821. package/components/RadioButton/RadioButton.d.ts.map +1 -1
  822. package/components/RadioButton/componentdata.json +1 -1
  823. package/components/RadioButton/index.js +1 -1
  824. package/components/RadioButton/styles.module.scss +12 -14
  825. package/components/Select/Select.d.ts +1 -1
  826. package/components/Select/Select.d.ts.map +1 -1
  827. package/components/Select/componentdata.json +1 -1
  828. package/components/Select/index.js +1 -1
  829. package/components/Select/styles.module.scss +14 -8
  830. package/components/Slider/Slider.d.ts.map +1 -1
  831. package/components/Slider/index.js +1 -1
  832. package/components/Slider/index.js.map +1 -1
  833. package/components/Slider/styles.module.scss +2 -1
  834. package/components/Spacer/Spacer.d.ts.map +1 -1
  835. package/components/Spacer/index.js +1 -1
  836. package/components/Spacer/styles.module.scss +13 -1
  837. package/components/StatusDot/index.js +1 -1
  838. package/components/StatusDot/styles.module.scss +2 -2
  839. package/components/Stepper/Dot.d.ts.map +1 -0
  840. package/components/Stepper/DotList.d.ts.map +1 -0
  841. package/components/{Progressbar/Progressbar.d.ts → Stepper/Stepper.d.ts} +6 -6
  842. package/components/Stepper/Stepper.d.ts.map +1 -0
  843. package/components/Stepper/componentdata.json +1 -0
  844. package/components/Stepper/index.d.ts +4 -0
  845. package/components/Stepper/index.d.ts.map +1 -0
  846. package/components/Stepper/index.js +2 -0
  847. package/components/Stepper/index.js.map +1 -0
  848. package/components/Stepper/styles.module.scss +105 -0
  849. package/components/Stepper/styles.module.scss.d.ts +16 -0
  850. package/components/{Progressbar → Stepper}/utils.d.ts +7 -7
  851. package/components/Stepper/utils.d.ts.map +1 -0
  852. package/components/Table/Table.d.ts +7 -6
  853. package/components/Table/Table.d.ts.map +1 -1
  854. package/components/Table/TableBody/index.js +1 -1
  855. package/components/Table/TableCell/TableCell.d.ts.map +1 -1
  856. package/components/Table/TableCell/index.js +1 -1
  857. package/components/Table/TableExpandedRow/TableExpandedRow.d.ts.map +1 -1
  858. package/components/Table/TableExpandedRow/index.js +1 -1
  859. package/components/Table/TableExpanderCell/TableExpanderCell.d.ts.map +1 -1
  860. package/components/Table/TableExpanderCell/TableExpanderCellMobile.d.ts +2 -2
  861. package/components/Table/TableExpanderCell/TableExpanderCellMobile.d.ts.map +1 -1
  862. package/components/Table/TableExpanderCell/index.js +1 -1
  863. package/components/Table/TableHead/TableHead.d.ts.map +1 -1
  864. package/components/Table/TableHead/index.js +1 -1
  865. package/components/Table/TableHeadCell/TableHeadCell.d.ts.map +1 -1
  866. package/components/Table/TableHeadCell/index.js +1 -1
  867. package/components/Table/TableRow/TableRow.d.ts.map +1 -1
  868. package/components/Table/TableRow/componentdata.json +1 -1
  869. package/components/Table/TableRow/index.js +1 -1
  870. package/components/Table/index.js +1 -1
  871. package/components/Table/index.js.map +1 -1
  872. package/components/Table/styles.module.scss +32 -20
  873. package/components/Table/utils.d.ts +3 -7
  874. package/components/Table/utils.d.ts.map +1 -1
  875. package/components/Tag/Tag.d.ts +2 -2
  876. package/components/Tag/Tag.d.ts.map +1 -1
  877. package/components/Tag/componentdata.json +1 -1
  878. package/components/Tag/index.js +1 -1
  879. package/components/Tag/index.js.map +1 -1
  880. package/components/Tag/styles.module.scss +39 -27
  881. package/components/TagList/index.js +1 -1
  882. package/components/TagList/index.js.map +1 -1
  883. package/components/TagList/styles.module.scss +3 -3
  884. package/components/Textarea/Textarea.d.ts.map +1 -1
  885. package/components/Textarea/componentdata.json +1 -1
  886. package/components/Textarea/index.js +1 -1
  887. package/components/Textarea/styles.module.scss +6 -5
  888. package/components/Tile/Tile.d.ts +2 -2
  889. package/components/Tile/Tile.d.ts.map +1 -1
  890. package/components/Tile/index.js +1 -1
  891. package/components/Tile/index.js.map +1 -1
  892. package/components/Tile/styles.module.scss +11 -6
  893. package/components/Title/Title.d.ts +3 -3
  894. package/components/Title/Title.d.ts.map +1 -1
  895. package/components/Title/index.js +1 -1
  896. package/components/Title/styles.module.scss +5 -0
  897. package/components/Tooltip/Tooltip.d.ts +1 -1
  898. package/components/Tooltip/Tooltip.d.ts.map +1 -1
  899. package/components/Tooltip/TooltipWord/TooltipWord.d.ts +1 -1
  900. package/components/Tooltip/TooltipWord/TooltipWord.d.ts.map +1 -1
  901. package/components/Tooltip/TooltipWord/index.js +1 -1
  902. package/components/Tooltip/TooltipWord/styles.module.scss +3 -3
  903. package/components/Tooltip/componentdata.json +1 -1
  904. package/components/Tooltip/index.js +1 -1
  905. package/components/TooltipExample/TooltipExample.d.ts.map +1 -1
  906. package/components/TooltipExample/componentdata.json +1 -1
  907. package/components/TooltipExample/index.js +1 -1
  908. package/components/TooltipExample/index.js.map +1 -1
  909. package/components/Validation/Validation.d.ts.map +1 -1
  910. package/components/Validation/index.js +1 -1
  911. package/components/Validation/styles.module.scss +3 -3
  912. package/constants.d.ts +7 -3
  913. package/constants.d.ts.map +1 -1
  914. package/constants.js +1 -1
  915. package/constants.js.map +1 -1
  916. package/hoc/withBreakpoint/index.js +1 -1
  917. package/hoc/withBreakpoint/withBreakpoint.d.ts +1 -1
  918. package/hoc/withBreakpoint/withBreakpoint.d.ts.map +1 -1
  919. package/hoc/withBreakpoint/withBreakpoint.js.map +1 -1
  920. package/hooks/useBreakpoint.d.ts.map +1 -1
  921. package/hooks/useBreakpoint.js +1 -1
  922. package/hooks/useBreakpoint.js.map +1 -1
  923. package/hooks/useExpand.d.ts +3 -0
  924. package/hooks/useExpand.d.ts.map +1 -0
  925. package/hooks/useExpand.js +2 -0
  926. package/hooks/useExpand.js.map +1 -0
  927. package/hooks/useFocusToggle.d.ts.map +1 -1
  928. package/hooks/useFocusToggle.js.map +1 -1
  929. package/hooks/useFocusTrap.d.ts.map +1 -1
  930. package/hooks/useFocusTrap.js +1 -1
  931. package/hooks/useFocusTrap.js.map +1 -1
  932. package/hooks/useIcons.js.map +1 -1
  933. package/hooks/useIsVisible.d.ts.map +1 -1
  934. package/hooks/useIsVisible.js.map +1 -1
  935. package/hooks/useKeyboardEvent.d.ts +1 -1
  936. package/hooks/useKeyboardEvent.d.ts.map +1 -1
  937. package/hooks/useOutsideEvent.d.ts +1 -1
  938. package/hooks/useOutsideEvent.d.ts.map +1 -1
  939. package/hooks/useResizeObserver.js.map +1 -1
  940. package/hooks/useSize.d.ts.map +1 -1
  941. package/hooks/useSize.js.map +1 -1
  942. package/hooks/useSticky.d.ts.map +1 -1
  943. package/hooks/useSticky.js +1 -1
  944. package/hooks/useSticky.js.map +1 -1
  945. package/hooks/useToggle.d.ts.map +1 -1
  946. package/hooks/useToggle.js.map +1 -1
  947. package/hooks/useUuid.d.ts.map +1 -1
  948. package/hooks/useUuid.js.map +1 -1
  949. package/index.js +1 -1
  950. package/package.json +1 -1
  951. package/scss/_body.scss +3 -1
  952. package/scss/_breakpoints.scss +5 -8
  953. package/scss/_figma-tokens.scss +2 -2
  954. package/scss/_fonts.scss +36 -21
  955. package/scss/_grid.scss +5 -4
  956. package/scss/_input.scss +20 -11
  957. package/scss/_palette.scss +7 -15
  958. package/scss/_print.scss +58 -18
  959. package/scss/_screen-reader.scss +0 -2
  960. package/scss/_spacers.scss +17 -15
  961. package/scss/_title.scss +11 -5
  962. package/scss/helsenorge.scss +1 -1
  963. package/scss/typography.module.scss +20 -13
  964. package/theme/currys/color.d.ts.map +1 -1
  965. package/theme/currys/color.js +1 -1
  966. package/theme/currys/color.js.map +1 -1
  967. package/theme/currys/index.js +1 -1
  968. package/theme/currys/spacing.js.map +1 -1
  969. package/theme/index.js +1 -1
  970. package/theme/index.js.map +1 -1
  971. package/theme/palette.d.ts +3 -3
  972. package/theme/palette.d.ts.map +1 -1
  973. package/theme/palette.js +1 -1
  974. package/theme/palette.js.map +1 -1
  975. package/theme/spacers.d.ts +1 -1
  976. package/theme/spacers.d.ts.map +1 -1
  977. package/utils/accessibility.d.ts +1 -1
  978. package/utils/accessibility.d.ts.map +1 -1
  979. package/utils/component.d.ts +2 -1
  980. package/utils/component.d.ts.map +1 -1
  981. package/utils/component.js +1 -1
  982. package/utils/component.js.map +1 -1
  983. package/utils/debounce.d.ts +1 -2
  984. package/utils/debounce.d.ts.map +1 -1
  985. package/utils/debounce.js +1 -1
  986. package/utils/debounce.js.map +1 -1
  987. package/utils/environment.js.map +1 -1
  988. package/utils/focus.js +1 -1
  989. package/utils/focus.js.map +1 -1
  990. package/utils/viewport.js +1 -1
  991. package/utils/viewport.js.map +1 -1
  992. package/uuid.js +1 -1
  993. package/components/HelpBubble/utils.d.ts.map +0 -1
  994. package/components/Progressbar/Dot.d.ts.map +0 -1
  995. package/components/Progressbar/DotList.d.ts.map +0 -1
  996. package/components/Progressbar/Progressbar.d.ts.map +0 -1
  997. package/components/Progressbar/componentdata.json +0 -1
  998. package/components/Progressbar/index.d.ts +0 -4
  999. package/components/Progressbar/index.d.ts.map +0 -1
  1000. package/components/Progressbar/index.js +0 -2
  1001. package/components/Progressbar/index.js.map +0 -1
  1002. package/components/Progressbar/styles.module.scss +0 -91
  1003. package/components/Progressbar/styles.module.scss.d.ts +0 -16
  1004. package/components/Progressbar/utils.d.ts.map +0 -1
  1005. /package/components/{Progressbar → Stepper}/Dot.d.ts +0 -0
  1006. /package/components/{Progressbar → Stepper}/DotList.d.ts +0 -0
package/Textarea.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"Textarea.js","sources":["../src/components/Textarea/Textarea.tsx"],"sourcesContent":["import React, { useState, useRef, useEffect } from 'react';\nimport cn from 'classnames';\n\nimport styles from './styles.module.scss';\nimport { AnalyticsId, AVERAGE_CHARACTER_WIDTH_PX, FormMode } from '../../constants';\nimport { uuid } from '../../utils/uuid';\nimport ErrorWrapper from '../ErrorWrapper';\nimport MaxCharacters from '../MaxCharacters/MaxCharacters';\n\ninterface TextareaProps\n extends Pick<\n React.InputHTMLAttributes<HTMLTextAreaElement>,\n 'autoFocus' | 'disabled' | 'name' | 'autoComplete' | 'placeholder' | 'readOnly' | 'required' | 'defaultValue' | 'onChange'\n > {\n /** max character limit in textarea */\n maxCharacters?: number;\n /** The text is displayed in the end of the text-counter */\n maxText?: string;\n /** Width of textarea in characters (approximate) */\n width?: number;\n /** Sets the data-testid attribute. */\n testId?: string;\n /** If true, the component will have a bottom margin. */\n marginBottom?: boolean;\n /** If true, the component will be transparent. */\n transparent?: boolean;\n /** Changes the visuals of the textarea */\n mode?: keyof typeof FormMode;\n /** Label of the input */\n label?: string;\n /** id of the textarea */\n textareaId?: string;\n /** max rows */\n maxRows?: number;\n /** min rows */\n minRows?: number;\n /** auto-grows until maxRows */\n grow?: boolean;\n /** Error text to show above the component */\n errorText?: string;\n /** Component shown after label */\n afterLabelChildren?: React.ReactNode;\n /** Component shown under label */\n belowLabelChildren?: React.ReactNode;\n}\n\nconst getTextareaMaxWidth = (characters: number): string => {\n const paddingWidth = '2rem';\n const scrollbarWidth = '16px';\n const borderWidth = '4px';\n\n return `calc(${characters * AVERAGE_CHARACTER_WIDTH_PX}px + ${paddingWidth} + ${scrollbarWidth} + ${borderWidth})`;\n};\n\nconst Textarea = React.forwardRef((props: TextareaProps, ref: React.Ref<HTMLTextAreaElement>) => {\n const {\n maxCharacters,\n maxText,\n width,\n testId,\n defaultValue,\n marginBottom: gutterBottom,\n transparent,\n mode,\n label,\n textareaId = uuid(),\n minRows = 3,\n maxRows = 10,\n grow,\n errorText,\n afterLabelChildren,\n belowLabelChildren,\n autoFocus,\n disabled,\n name,\n autoComplete,\n placeholder,\n readOnly,\n required,\n onChange,\n ...rest\n } = props;\n\n const [rows, setRows] = useState(minRows);\n const [textareaInput, setTextareaInput] = useState(defaultValue || '');\n const referanse = useRef<HTMLDivElement>(null);\n\n const resizeHeight = (target: HTMLTextAreaElement): void => {\n const textareaLineHeight = 28;\n\n const previousRows = target.rows;\n target.rows = minRows; // reset number of rows in textarea\n\n const currentRows = Math.floor((target.scrollHeight - 16) / textareaLineHeight); // scrollHeight - 16px of padding to calculate the rows\n\n if (currentRows === previousRows) {\n target.rows = currentRows;\n }\n\n if (currentRows >= maxRows) {\n target.rows = maxRows;\n target.scrollTop = target.scrollHeight;\n }\n\n if (currentRows < maxRows) {\n setRows(currentRows);\n } else {\n setRows(maxRows);\n }\n };\n\n const onDark = mode === FormMode.ondark;\n const onBlueberry = mode === FormMode.onblueberry;\n const maxCharactersExceeded = !!maxCharacters && textareaInput.toString().length > maxCharacters;\n const onError = mode === FormMode.oninvalid || !!errorText || maxCharactersExceeded;\n\n const textareaWrapperClass = cn(styles.textarea, {\n [styles['textarea--gutterBottom']]: gutterBottom,\n });\n\n const labelWrapperClass = cn(styles['textarea__label-wrapper'], {\n [styles[`textarea__label-wrapper--on-dark`]]: onDark,\n });\n\n const contentWrapperClass = cn(styles['content-wrapper'], {\n [styles['content-wrapper--transparent']]: transparent,\n [styles['content-wrapper--on-blueberry']]: onBlueberry,\n [styles['content-wrapper--on-dark']]: onDark,\n [styles['content-wrapper--invalid']]: onError,\n [styles['content-wrapper--disabled']]: props.disabled,\n });\n\n const textareaClass = cn(styles['content-wrapper__input'], {\n [styles[`content-wrapper__input--disabled`]]: props.disabled,\n });\n\n useEffect(() => {\n if (grow && referanse.current?.children && referanse.current?.children[0]) {\n const textarea = referanse.current?.children[0] as HTMLTextAreaElement;\n resizeHeight(textarea);\n }\n }, []);\n\n const handleChange = (e: React.ChangeEvent<HTMLTextAreaElement>): void => {\n if (grow) {\n resizeHeight(e.target);\n }\n setTextareaInput(e.target.value);\n };\n\n const onChangeHandler = (e: React.ChangeEvent<HTMLTextAreaElement>) => {\n if (onChange) {\n onChange(e);\n }\n handleChange(e);\n };\n\n const maxWidth = width ? getTextareaMaxWidth(width) : undefined;\n\n return (\n <ErrorWrapper errorText={errorText}>\n <div data-testid={testId} data-analyticsid={AnalyticsId.Textarea} className={textareaWrapperClass}>\n {label && (\n <div className={labelWrapperClass}>\n <label htmlFor={textareaId}>{label}</label>\n {afterLabelChildren && <div className={styles['textarea__after-label-children']}>{afterLabelChildren}</div>}\n </div>\n )}\n {belowLabelChildren && <div>{belowLabelChildren}</div>}\n <div className={contentWrapperClass} ref={referanse} style={{ maxWidth }}>\n <textarea\n rows={rows}\n defaultValue={defaultValue}\n id={textareaId}\n className={textareaClass}\n ref={ref}\n aria-invalid={!!onError}\n autoFocus={autoFocus}\n disabled={disabled}\n name={name}\n autoComplete={autoComplete}\n placeholder={placeholder}\n readOnly={readOnly}\n required={required}\n onChange={onChangeHandler}\n {...rest}\n />\n </div>\n {maxCharacters && (\n <MaxCharacters\n maxCharacters={maxCharacters}\n length={textareaInput.toString().length}\n maxText={maxText}\n mode={mode}\n maxWidth={maxWidth}\n />\n )}\n </div>\n </ErrorWrapper>\n );\n});\n\nexport default Textarea;\n"],"names":["getTextareaMaxWidth","characters","paddingWidth","scrollbarWidth","borderWidth","AVERAGE_CHARACTER_WIDTH_PX","Textarea","React","props","ref","maxCharacters","maxText","width","testId","defaultValue","gutterBottom","transparent","mode","label","textareaId","uuid","minRows","maxRows","grow","errorText","afterLabelChildren","belowLabelChildren","autoFocus","disabled","name","autoComplete","placeholder","readOnly","required","onChange","rest","rows","setRows","useState","textareaInput","setTextareaInput","referanse","useRef","resizeHeight","target","previousRows","currentRows","onDark","FormMode","onBlueberry","maxCharactersExceeded","onError","textareaWrapperClass","cn","styles","labelWrapperClass","contentWrapperClass","textareaClass","useEffect","_a","_b","textarea","_c","handleChange","onChangeHandler","maxWidth","ErrorWrapper","AnalyticsId","MaxCharacters"],"mappings":"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"}
1
+ {"version":3,"file":"Textarea.js","sources":["../src/components/Textarea/Textarea.tsx"],"sourcesContent":["import React, { useState, useRef, useEffect } from 'react';\n\nimport cn from 'classnames';\n\nimport { AnalyticsId, AVERAGE_CHARACTER_WIDTH_PX, FormMode } from '../../constants';\nimport { uuid } from '../../utils/uuid';\nimport ErrorWrapper from '../ErrorWrapper';\nimport MaxCharacters from '../MaxCharacters/MaxCharacters';\n\nimport styles from './styles.module.scss';\n\ninterface TextareaProps\n extends Pick<\n React.InputHTMLAttributes<HTMLTextAreaElement>,\n 'autoFocus' | 'disabled' | 'name' | 'autoComplete' | 'placeholder' | 'readOnly' | 'required' | 'defaultValue' | 'onChange'\n > {\n /** max character limit in textarea */\n maxCharacters?: number;\n /** The text is displayed in the end of the text-counter */\n maxText?: string;\n /** Width of textarea in characters (approximate) */\n width?: number;\n /** Sets the data-testid attribute. */\n testId?: string;\n /** If true, the component will have a bottom margin. */\n marginBottom?: boolean;\n /** If true, the component will be transparent. */\n transparent?: boolean;\n /** Changes the visuals of the textarea */\n mode?: keyof typeof FormMode;\n /** Label of the input */\n label?: string;\n /** id of the textarea */\n textareaId?: string;\n /** max rows */\n maxRows?: number;\n /** min rows */\n minRows?: number;\n /** auto-grows until maxRows */\n grow?: boolean;\n /** Error text to show above the component */\n errorText?: string;\n /** Component shown after label */\n afterLabelChildren?: React.ReactNode;\n /** Component shown under label */\n belowLabelChildren?: React.ReactNode;\n}\n\nconst getTextareaMaxWidth = (characters: number): string => {\n const paddingWidth = '2rem';\n const scrollbarWidth = '16px';\n const borderWidth = '4px';\n\n return `calc(${characters * AVERAGE_CHARACTER_WIDTH_PX}px + ${paddingWidth} + ${scrollbarWidth} + ${borderWidth})`;\n};\n\nconst Textarea = React.forwardRef((props: TextareaProps, ref: React.Ref<HTMLTextAreaElement>) => {\n const {\n maxCharacters,\n maxText,\n width,\n testId,\n defaultValue,\n marginBottom: gutterBottom,\n transparent,\n mode,\n label,\n textareaId = uuid(),\n minRows = 3,\n maxRows = 10,\n grow,\n errorText,\n afterLabelChildren,\n belowLabelChildren,\n autoFocus,\n disabled,\n name,\n autoComplete,\n placeholder,\n readOnly,\n required,\n onChange,\n ...rest\n } = props;\n\n const [rows, setRows] = useState(minRows);\n const [textareaInput, setTextareaInput] = useState(defaultValue || '');\n const referanse = useRef<HTMLDivElement>(null);\n\n const resizeHeight = (target: HTMLTextAreaElement): void => {\n const textareaLineHeight = 28;\n\n const previousRows = target.rows;\n target.rows = minRows; // reset number of rows in textarea\n\n const currentRows = Math.floor((target.scrollHeight - 16) / textareaLineHeight); // scrollHeight - 16px of padding to calculate the rows\n\n if (currentRows === previousRows) {\n target.rows = currentRows;\n }\n\n if (currentRows >= maxRows) {\n target.rows = maxRows;\n target.scrollTop = target.scrollHeight;\n }\n\n if (currentRows < maxRows) {\n setRows(currentRows);\n } else {\n setRows(maxRows);\n }\n };\n\n const onDark = mode === FormMode.ondark;\n const onBlueberry = mode === FormMode.onblueberry;\n const maxCharactersExceeded = !!maxCharacters && textareaInput.toString().length > maxCharacters;\n const onError = mode === FormMode.oninvalid || !!errorText || maxCharactersExceeded;\n\n const textareaWrapperClass = cn(styles.textarea, {\n [styles['textarea--gutterBottom']]: gutterBottom,\n });\n\n const labelWrapperClass = cn(styles['textarea__label-wrapper'], {\n [styles[`textarea__label-wrapper--on-dark`]]: onDark,\n });\n\n const contentWrapperClass = cn(styles['content-wrapper'], {\n [styles['content-wrapper--transparent']]: transparent,\n [styles['content-wrapper--on-blueberry']]: onBlueberry,\n [styles['content-wrapper--on-dark']]: onDark,\n [styles['content-wrapper--invalid']]: onError,\n [styles['content-wrapper--disabled']]: props.disabled,\n });\n\n const textareaClass = cn(styles['content-wrapper__input'], {\n [styles[`content-wrapper__input--disabled`]]: props.disabled,\n });\n\n useEffect(() => {\n if (grow && referanse.current?.children && referanse.current?.children[0]) {\n const textarea = referanse.current?.children[0] as HTMLTextAreaElement;\n resizeHeight(textarea);\n }\n }, []);\n\n const handleChange = (e: React.ChangeEvent<HTMLTextAreaElement>): void => {\n if (grow) {\n resizeHeight(e.target);\n }\n setTextareaInput(e.target.value);\n };\n\n const onChangeHandler = (e: React.ChangeEvent<HTMLTextAreaElement>) => {\n if (onChange) {\n onChange(e);\n }\n handleChange(e);\n };\n\n const maxWidth = width ? getTextareaMaxWidth(width) : undefined;\n\n return (\n <ErrorWrapper errorText={errorText}>\n <div data-testid={testId} data-analyticsid={AnalyticsId.Textarea} className={textareaWrapperClass}>\n {label && (\n <div className={labelWrapperClass}>\n <label htmlFor={textareaId}>{label}</label>\n {afterLabelChildren && <div className={styles['textarea__after-label-children']}>{afterLabelChildren}</div>}\n </div>\n )}\n {belowLabelChildren && <div>{belowLabelChildren}</div>}\n <div className={contentWrapperClass} ref={referanse} style={{ maxWidth }}>\n <textarea\n rows={rows}\n defaultValue={defaultValue}\n id={textareaId}\n className={textareaClass}\n ref={ref}\n aria-invalid={!!onError}\n // eslint-disable-next-line jsx-a11y/no-autofocus\n autoFocus={autoFocus}\n disabled={disabled}\n name={name}\n autoComplete={autoComplete}\n placeholder={placeholder}\n readOnly={readOnly}\n required={required}\n onChange={onChangeHandler}\n {...rest}\n />\n </div>\n {maxCharacters && (\n <MaxCharacters\n maxCharacters={maxCharacters}\n length={textareaInput.toString().length}\n maxText={maxText}\n mode={mode}\n maxWidth={maxWidth}\n />\n )}\n </div>\n </ErrorWrapper>\n );\n});\n\nTextarea.displayName = 'Textarea';\n\nexport default Textarea;\n"],"names":["getTextareaMaxWidth","characters","paddingWidth","scrollbarWidth","borderWidth","AVERAGE_CHARACTER_WIDTH_PX","Textarea","React","props","ref","maxCharacters","maxText","width","testId","defaultValue","gutterBottom","transparent","mode","label","textareaId","uuid","minRows","maxRows","grow","errorText","afterLabelChildren","belowLabelChildren","autoFocus","disabled","name","autoComplete","placeholder","readOnly","required","onChange","rest","rows","setRows","useState","textareaInput","setTextareaInput","referanse","useRef","resizeHeight","target","previousRows","currentRows","onDark","FormMode","onBlueberry","maxCharactersExceeded","onError","textareaWrapperClass","cn","styles","labelWrapperClass","contentWrapperClass","textareaClass","useEffect","_a","_b","textarea","_c","handleChange","onChangeHandler","maxWidth","ErrorWrapper","AnalyticsId","MaxCharacters","Textarea$1"],"mappings":"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"}
package/Title.js CHANGED
@@ -1,2 +1,2 @@
1
- import r from"react";import T from"classnames";import t from"./components/Title/styles.module.scss";import{AnalyticsId as y}from"./constants.js";const $=r.forwardRef(function(a,o){const{id:m,children:n,className:s,htmlMarkup:c="h1",appearance:e="title1",margin:i=0,testId:p}=a,d=T(t.title,{[t["title--feature"]]:e==="titleFeature",[t["title--title1"]]:e==="title1",[t["title--title2"]]:e==="title2",[t["title--title3"]]:e==="title3",[t["title--title4"]]:e==="title4",[t["title--title5"]]:e==="title5"},s),f=c,g=u(i)?{marginTop:`${i.marginTop}rem`,marginBottom:`${i.marginBottom}rem`}:{marginTop:`${i}rem`,marginBottom:`${i}rem`};return r.createElement(f,{id:m,className:d,style:g,ref:o,"data-testid":p,"data-analyticsid":y.Title},n)}),u=l=>Object.prototype.hasOwnProperty.call(l,"marginTop")&&Object.prototype.hasOwnProperty.call(l,"marginBottom");export{$ as T,u as i};
1
+ import l from"react";import g from"classnames";import{AnalyticsId as y}from"./constants.js";import t from"./components/Title/styles.module.scss";const u=l.forwardRef(function(r,o){const{id:n,children:m,className:s,htmlMarkup:c="h1",appearance:e="title1",margin:i=0,testId:p}=r,d=g(t.title,{[t["title--feature"]]:e==="titleFeature",[t["title--title1"]]:e==="title1",[t["title--title2"]]:e==="title2",[t["title--title3"]]:e==="title3",[t["title--title4"]]:e==="title4",[t["title--title5"]]:e==="title5"},s),T=c,f=h(i)?{marginTop:`${i.marginTop}rem`,marginBottom:`${i.marginBottom}rem`}:{marginTop:`${i}rem`,marginBottom:`${i}rem`};return l.createElement(T,{id:n,className:d,style:f,ref:o,"data-testid":p,"data-analyticsid":y.Title},m)}),h=a=>Object.prototype.hasOwnProperty.call(a,"marginTop")&&Object.prototype.hasOwnProperty.call(a,"marginBottom"),N=u;export{N as T,u as a,h as i};
2
2
  //# sourceMappingURL=Title.js.map
package/Title.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"Title.js","sources":["../src/components/Title/Title.tsx"],"sourcesContent":["import React from 'react';\nimport classNames from 'classnames';\n\nimport titleStyles from './styles.module.scss';\nimport { AnalyticsId } from '../../constants';\n\nexport type TitleTags = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'span';\nexport type TitleAppearances = 'titleFeature' | 'title1' | 'title2' | 'title3' | 'title4' | 'title5';\n\nexport interface TitleProps {\n children: React.ReactNode;\n /** Gives a unique id to the title */\n id?: string;\n /** Adds custom classes to the element. */\n className?: string;\n /** Adds top and bottom margin in rem. */\n margin?: number | TitleMargin;\n /** Changes the underlying element of the title. */\n htmlMarkup?: TitleTags;\n /** Changes the appearance of the title. */\n appearance?: TitleAppearances;\n /** Sets the data-testid attribute. */\n testId?: string;\n}\n\nexport const Title = React.forwardRef(function TitleForwardedRef(props: TitleProps, ref: React.ForwardedRef<HTMLHeadingElement>) {\n const { id, children, className, htmlMarkup = 'h1', appearance = 'title1', margin = 0, testId } = props;\n const titleClasses = classNames(\n titleStyles.title,\n {\n [titleStyles['title--feature']]: appearance === 'titleFeature',\n [titleStyles['title--title1']]: appearance === 'title1',\n [titleStyles['title--title2']]: appearance === 'title2',\n [titleStyles['title--title3']]: appearance === 'title3',\n [titleStyles['title--title4']]: appearance === 'title4',\n [titleStyles['title--title5']]: appearance === 'title5',\n },\n className\n );\n const CustomTag = htmlMarkup;\n\n const inlineStyle = instanceOfTitleMargin(margin)\n ? { marginTop: `${margin.marginTop}rem`, marginBottom: `${margin.marginBottom}rem` }\n : { marginTop: `${margin}rem`, marginBottom: `${margin}rem` };\n\n return (\n <CustomTag id={id} className={titleClasses} style={inlineStyle} ref={ref} data-testid={testId} data-analyticsid={AnalyticsId.Title}>\n {children}\n </CustomTag>\n );\n});\n\nexport interface TitleMargin {\n marginTop: number;\n marginBottom: number;\n}\n\nexport const instanceOfTitleMargin = (margin: any): margin is TitleMargin => {\n return Object.prototype.hasOwnProperty.call(margin, 'marginTop') && Object.prototype.hasOwnProperty.call(margin, 'marginBottom');\n};\n\nexport default Title;\n"],"names":["Title","React","props","ref","id","children","className","htmlMarkup","appearance","margin","testId","titleClasses","classNames","titleStyles","CustomTag","inlineStyle","instanceOfTitleMargin","AnalyticsId"],"mappings":"iJAyBO,MAAMA,EAAQC,EAAM,WAAW,SAA2BC,EAAmBC,EAA6C,CACzH,KAAA,CAAE,GAAAC,EAAI,SAAAC,EAAU,UAAAC,EAAW,WAAAC,EAAa,KAAM,WAAAC,EAAa,SAAU,OAAAC,EAAS,EAAG,OAAAC,CAAA,EAAWR,EAC5FS,EAAeC,EACnBC,EAAY,MACZ,CACE,CAACA,EAAY,mBAAoBL,IAAe,eAChD,CAACK,EAAY,kBAAmBL,IAAe,SAC/C,CAACK,EAAY,kBAAmBL,IAAe,SAC/C,CAACK,EAAY,kBAAmBL,IAAe,SAC/C,CAACK,EAAY,kBAAmBL,IAAe,SAC/C,CAACK,EAAY,kBAAmBL,IAAe,QACjD,EACAF,CAAA,EAEIQ,EAAYP,EAEZQ,EAAcC,EAAsBP,CAAM,EAC5C,CAAE,UAAW,GAAGA,EAAO,eAAgB,aAAc,GAAGA,EAAO,mBAC/D,CAAE,UAAW,GAAGA,OAAa,aAAc,GAAGA,MAAY,EAE9D,OACGR,EAAA,cAAAa,EAAA,CAAU,GAAAV,EAAQ,UAAWO,EAAc,MAAOI,EAAa,IAAAZ,EAAU,cAAaO,EAAQ,mBAAkBO,EAAY,KAAA,EAC1HZ,CACH,CAEJ,CAAC,EAOYW,EAAyBP,GAC7B,OAAO,UAAU,eAAe,KAAKA,EAAQ,WAAW,GAAK,OAAO,UAAU,eAAe,KAAKA,EAAQ,cAAc"}
1
+ {"version":3,"file":"Title.js","sources":["../src/components/Title/Title.tsx"],"sourcesContent":["import React from 'react';\n\nimport classNames from 'classnames';\n\nimport { AnalyticsId } from '../../constants';\n\nimport titleStyles from './styles.module.scss';\n\nexport type TitleTags = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'span';\nexport type TitleAppearances = 'titleFeature' | 'title1' | 'title2' | 'title3' | 'title4' | 'title5';\n\nexport interface TitleProps {\n children: React.ReactNode;\n /** Gives a unique id to the title */\n id?: string;\n /** Adds custom classes to the element. */\n className?: string;\n /** Adds top and bottom margin in rem. */\n margin?: number | TitleMargin;\n /** Changes the underlying element of the title. */\n htmlMarkup?: TitleTags;\n /** Changes the appearance of the title. */\n appearance?: TitleAppearances;\n /** Sets the data-testid attribute. */\n testId?: string;\n}\n\nexport const Title = React.forwardRef(function TitleForwardedRef(props: TitleProps, ref: React.ForwardedRef<HTMLHeadingElement>) {\n const { id, children, className, htmlMarkup = 'h1', appearance = 'title1', margin = 0, testId } = props;\n const titleClasses = classNames(\n titleStyles.title,\n {\n [titleStyles['title--feature']]: appearance === 'titleFeature',\n [titleStyles['title--title1']]: appearance === 'title1',\n [titleStyles['title--title2']]: appearance === 'title2',\n [titleStyles['title--title3']]: appearance === 'title3',\n [titleStyles['title--title4']]: appearance === 'title4',\n [titleStyles['title--title5']]: appearance === 'title5',\n },\n className\n );\n const CustomTag = htmlMarkup;\n\n const inlineStyle = instanceOfTitleMargin(margin)\n ? { marginTop: `${margin.marginTop}rem`, marginBottom: `${margin.marginBottom}rem` }\n : { marginTop: `${margin}rem`, marginBottom: `${margin}rem` };\n\n return (\n <CustomTag id={id} className={titleClasses} style={inlineStyle} ref={ref} data-testid={testId} data-analyticsid={AnalyticsId.Title}>\n {children}\n </CustomTag>\n );\n});\n\nexport interface TitleMargin {\n marginTop: number;\n marginBottom: number;\n}\n\nexport const instanceOfTitleMargin = (margin: unknown): margin is TitleMargin => {\n return Object.prototype.hasOwnProperty.call(margin, 'marginTop') && Object.prototype.hasOwnProperty.call(margin, 'marginBottom');\n};\n\nexport default Title;\n"],"names":["Title","React","props","ref","id","children","className","htmlMarkup","appearance","margin","testId","titleClasses","classNames","titleStyles","CustomTag","inlineStyle","instanceOfTitleMargin","AnalyticsId","Title$1"],"mappings":"iJA2BO,MAAMA,EAAQC,EAAM,WAAW,SAA2BC,EAAmBC,EAA6C,CACzH,KAAA,CAAE,GAAAC,EAAI,SAAAC,EAAU,UAAAC,EAAW,WAAAC,EAAa,KAAM,WAAAC,EAAa,SAAU,OAAAC,EAAS,EAAG,OAAAC,CAAA,EAAWR,EAC5FS,EAAeC,EACnBC,EAAY,MACZ,CACE,CAACA,EAAY,gBAAgB,CAAC,EAAGL,IAAe,eAChD,CAACK,EAAY,eAAe,CAAC,EAAGL,IAAe,SAC/C,CAACK,EAAY,eAAe,CAAC,EAAGL,IAAe,SAC/C,CAACK,EAAY,eAAe,CAAC,EAAGL,IAAe,SAC/C,CAACK,EAAY,eAAe,CAAC,EAAGL,IAAe,SAC/C,CAACK,EAAY,eAAe,CAAC,EAAGL,IAAe,QACjD,EACAF,CAAA,EAEIQ,EAAYP,EAEZQ,EAAcC,EAAsBP,CAAM,EAC5C,CAAE,UAAW,GAAGA,EAAO,eAAgB,aAAc,GAAGA,EAAO,mBAC/D,CAAE,UAAW,GAAGA,OAAa,aAAc,GAAGA,MAAY,EAE9D,OACGR,EAAA,cAAAa,EAAA,CAAU,GAAAV,EAAQ,UAAWO,EAAc,MAAOI,EAAa,IAAAZ,EAAU,cAAaO,EAAQ,mBAAkBO,EAAY,OAC1HZ,CACH,CAEJ,CAAC,EAOYW,EAAyBP,GAC7B,OAAO,UAAU,eAAe,KAAKA,EAAQ,WAAW,GAAK,OAAO,UAAU,eAAe,KAAKA,EAAQ,cAAc,EAGjIS,EAAelB"}
package/Tooltip.js CHANGED
@@ -1,2 +1,2 @@
1
- import t,{useRef as y,useContext as C,useEffect as u,useState as b}from"react";import{useDelayedState as D}from"./hooks/useDelayedState.js";import{useUuid as v}from"./hooks/useUuid.js";import{H as B}from"./HelpBubble.js";import{T as R}from"./TooltipWord.js";const x=200,K=({children:s,description:r,testId:i})=>{const n=v(),a=y(null),{currentTooltip:p,setCurrentTooltip:c}=C(d),[{showTooltip:l,keepOpen:m},h,o]=D({showTooltip:!1,keepOpen:!1},x);u(()=>{!c||c(l?n:void 0)},[l]),u(()=>{p!==n&&typeof p<"u"&&o(e=>({showTooltip:!1,keepOpen:e.keepOpen}))},[p]);const f=()=>{l||o({showTooltip:!1,keepOpen:!1})};u(()=>(document.addEventListener("mouseup",f),()=>{document.removeEventListener("mouseup",f)}),[]);const k=()=>{o(e=>({showTooltip:!e.showTooltip,keepOpen:!e.keepOpen}))},w=()=>{p||h(e=>({showTooltip:!0,keepOpen:e.keepOpen}))},O=()=>{o(e=>({showTooltip:!1,keepOpen:e.keepOpen}))},E=e=>{e.key==="Enter"&&o(T=>({showTooltip:!T.showTooltip,keepOpen:!T.keepOpen})),e.key==="Escape"&&o({showTooltip:!1,keepOpen:!1})};return t.createElement(t.Fragment,null,t.createElement(R,{ref:a,onClick:k,onFocus:w,onBlur:O,onKeyDown:E,ariaDescribedById:n,testId:i},s),t.createElement(B,{helpBubbleId:n,controllerRef:a,role:"tooltip",showBubble:l||m},r))},d=t.createContext({currentTooltip:void 0}),P=({children:s})=>{const[r,i]=b();return t.createElement(d.Provider,{value:{currentTooltip:r,setCurrentTooltip:i}},s)};export{K as T,P as a};
1
+ import t,{useRef as b,useContext as y,useEffect as u,useState as C}from"react";import{T as D}from"./TooltipWord.js";import{useDelayedState as v}from"./hooks/useDelayedState.js";import{useUuid as B}from"./hooks/useUuid.js";import{H as R}from"./HelpBubble.js";const x=200,F=({children:s,description:r,testId:i})=>{const n=B(),a=b(null),{currentTooltip:p,setCurrentTooltip:c}=y(d),[{showTooltip:l,keepOpen:m},h,o]=v({showTooltip:!1,keepOpen:!1},x);u(()=>{c&&c(l?n:void 0)},[l]),u(()=>{p!==n&&typeof p<"u"&&o(e=>({showTooltip:!1,keepOpen:e.keepOpen}))},[p]);const f=()=>{l||o({showTooltip:!1,keepOpen:!1})};u(()=>(document.addEventListener("mouseup",f),()=>{document.removeEventListener("mouseup",f)}),[]);const k=()=>{o(e=>({showTooltip:!e.showTooltip,keepOpen:!e.keepOpen}))},w=()=>{p||h(e=>({showTooltip:!0,keepOpen:e.keepOpen}))},O=()=>{o(e=>({showTooltip:!1,keepOpen:e.keepOpen}))},E=e=>{e.key==="Enter"&&o(T=>({showTooltip:!T.showTooltip,keepOpen:!T.keepOpen})),e.key==="Escape"&&o({showTooltip:!1,keepOpen:!1})};return t.createElement(t.Fragment,null,t.createElement(D,{ref:a,onClick:k,onFocus:w,onBlur:O,onKeyDown:E,ariaDescribedById:n,testId:i},s),t.createElement(R,{helpBubbleId:n,controllerRef:a,role:"tooltip",showBubble:l||m},r))},d=t.createContext({currentTooltip:void 0}),P=({children:s})=>{const[r,i]=C();return t.createElement(d.Provider,{value:{currentTooltip:r,setCurrentTooltip:i}},s)},_=F;export{_ as T,F as a,P as b};
2
2
  //# sourceMappingURL=Tooltip.js.map
package/Tooltip.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"Tooltip.js","sources":["../src/components/Tooltip/Tooltip.tsx"],"sourcesContent":["import React, { useContext, useState, useEffect, useRef } from 'react';\nimport { useDelayedState } from '../../hooks/useDelayedState';\n\nimport { useUuid } from '../../hooks/useUuid';\nimport HelpBubble from '../HelpBubble';\n\nimport TooltipWord from './TooltipWord';\n\nconst HOVER_DELAY_MS = 200;\n\nexport interface TooltipProps {\n /** Ordet som skal ha en tilhørende tooltip */\n children: string;\n /** Teksten som skal vises i tooltip */\n description: React.ReactNode;\n /** Valgfri test-id */\n testId?: string;\n}\n\nexport const Tooltip: React.FC<TooltipProps> = ({ children, description, testId }) => {\n const helpBubbleId = useUuid();\n const wordRef = useRef<HTMLSpanElement>(null);\n const { currentTooltip, setCurrentTooltip } = useContext(TooltipOpenContext);\n const [{ showTooltip, keepOpen }, setShowTooltipDelayed, setShowTooltip] = useDelayedState(\n { showTooltip: false, keepOpen: false },\n HOVER_DELAY_MS\n );\n\n useEffect(() => {\n if (!setCurrentTooltip) {\n return;\n }\n if (showTooltip) {\n setCurrentTooltip(helpBubbleId);\n } else {\n setCurrentTooltip(undefined);\n }\n }, [showTooltip]);\n\n useEffect(() => {\n if (currentTooltip !== helpBubbleId && typeof currentTooltip !== 'undefined') {\n setShowTooltip(prevState => ({ showTooltip: false, keepOpen: prevState.keepOpen }));\n }\n }, [currentTooltip]);\n\n const handleDocumentClick = (): void => {\n if (!showTooltip) {\n setShowTooltip({ showTooltip: false, keepOpen: false });\n }\n };\n\n useEffect(() => {\n document.addEventListener('mouseup', handleDocumentClick);\n return (): void => {\n document.removeEventListener('mouseup', handleDocumentClick);\n };\n }, []);\n\n const handleTooltipClick = (): void => {\n setShowTooltip(prevState => ({ showTooltip: !prevState.showTooltip, keepOpen: !prevState.keepOpen }));\n };\n\n const handleFocus = (): void => {\n if (!currentTooltip) {\n setShowTooltipDelayed(prevState => ({ showTooltip: true, keepOpen: prevState.keepOpen }));\n }\n };\n\n const handleBlur = (): void => {\n setShowTooltip(prevState => ({ showTooltip: false, keepOpen: prevState.keepOpen }));\n };\n\n const handleKeyDown = (e: React.KeyboardEvent<HTMLSpanElement>): void => {\n if (e.key === 'Enter') {\n setShowTooltip(prevState => ({ showTooltip: !prevState.showTooltip, keepOpen: !prevState.keepOpen }));\n }\n if (e.key === 'Escape') {\n setShowTooltip({ showTooltip: false, keepOpen: false });\n }\n };\n\n return (\n <>\n <TooltipWord\n ref={wordRef}\n onClick={handleTooltipClick}\n onFocus={handleFocus}\n onBlur={handleBlur}\n onKeyDown={handleKeyDown}\n ariaDescribedById={helpBubbleId}\n testId={testId}\n >\n {children}\n </TooltipWord>\n <HelpBubble helpBubbleId={helpBubbleId} controllerRef={wordRef} role=\"tooltip\" showBubble={showTooltip || keepOpen}>\n {description}\n </HelpBubble>\n </>\n );\n};\n\nexport type TooltipContext = {\n currentTooltip?: string;\n setCurrentTooltip?: (id?: string) => void;\n};\n\nconst TooltipOpenContext = React.createContext<TooltipContext>({\n currentTooltip: undefined,\n});\n\nexport const TooltipOpenProvider: React.FC = ({ children }) => {\n const [currentTooltip, setCurrentTooltip] = useState<string>();\n\n return <TooltipOpenContext.Provider value={{ currentTooltip, setCurrentTooltip }}>{children}</TooltipOpenContext.Provider>;\n};\n\nexport default Tooltip;\n"],"names":["HOVER_DELAY_MS","Tooltip","children","description","testId","helpBubbleId","useUuid","wordRef","useRef","currentTooltip","setCurrentTooltip","useContext","TooltipOpenContext","showTooltip","keepOpen","setShowTooltipDelayed","setShowTooltip","useDelayedState","useEffect","prevState","handleDocumentClick","handleTooltipClick","handleFocus","handleBlur","handleKeyDown","React","TooltipWord","HelpBubble","TooltipOpenProvider","useState"],"mappings":"kQAQA,MAAMA,EAAiB,IAWVC,EAAkC,CAAC,CAAE,SAAAC,EAAU,YAAAC,EAAa,OAAAC,KAAa,CACpF,MAAMC,EAAeC,IACfC,EAAUC,EAAwB,IAAI,EACtC,CAAE,eAAAC,EAAgB,kBAAAC,CAAkB,EAAIC,EAAWC,CAAkB,EACrE,CAAC,CAAE,YAAAC,EAAa,SAAAC,CAAY,EAAAC,EAAuBC,CAAc,EAAIC,EACzE,CAAE,YAAa,GAAO,SAAU,EAAM,EACtCjB,CAAA,EAGFkB,EAAU,IAAM,CACV,CAACR,GAIHA,EADEG,EACgBR,EAEA,MAFY,CAGhC,EACC,CAACQ,CAAW,CAAC,EAEhBK,EAAU,IAAM,CACVT,IAAmBJ,GAAgB,OAAOI,EAAmB,KAC/DO,MAA6B,CAAE,YAAa,GAAO,SAAUG,EAAU,QAAW,EAAA,CACpF,EACC,CAACV,CAAc,CAAC,EAEnB,MAAMW,EAAsB,IAAY,CACjCP,GACHG,EAAe,CAAE,YAAa,GAAO,SAAU,EAAO,CAAA,CACxD,EAGFE,EAAU,KACC,SAAA,iBAAiB,UAAWE,CAAmB,EACjD,IAAY,CACR,SAAA,oBAAoB,UAAWA,CAAmB,CAAA,GAE5D,CAAE,CAAA,EAEL,MAAMC,EAAqB,IAAY,CACtBL,EAAAG,IAAc,CAAE,YAAa,CAACA,EAAU,YAAa,SAAU,CAACA,EAAU,QAAA,EAAW,CAAA,EAGhGG,EAAc,IAAY,CACzBb,GACHM,MAAoC,CAAE,YAAa,GAAM,SAAUI,EAAU,QAAW,EAAA,CAC1F,EAGII,EAAa,IAAY,CAC7BP,MAA6B,CAAE,YAAa,GAAO,SAAUG,EAAU,QAAW,EAAA,CAAA,EAG9EK,EAAiB,GAAkD,CACnE,EAAE,MAAQ,SACGR,EAAAG,IAAc,CAAE,YAAa,CAACA,EAAU,YAAa,SAAU,CAACA,EAAU,QAAA,EAAW,EAElG,EAAE,MAAQ,UACZH,EAAe,CAAE,YAAa,GAAO,SAAU,EAAO,CAAA,CACxD,EAGF,uCAEKS,EAAA,cAAAC,EAAA,CACC,IAAKnB,EACL,QAASc,EACT,QAASC,EACT,OAAQC,EACR,UAAWC,EACX,kBAAmBnB,EACnB,OAAAD,CAEC,EAAAF,CACH,EACCuB,EAAA,cAAAE,EAAA,CAAW,aAAAtB,EAA4B,cAAeE,EAAS,KAAK,UAAU,WAAYM,GAAeC,CAAA,EACvGX,CACH,CACF,CAEJ,EAOMS,EAAqBa,EAAM,cAA8B,CAC7D,eAAgB,MAClB,CAAC,EAEYG,EAAgC,CAAC,CAAE,SAAA1B,KAAe,CAC7D,KAAM,CAACO,EAAgBC,CAAiB,EAAImB,EAAiB,EAEtD,OAAAJ,EAAA,cAACb,EAAmB,SAAnB,CAA4B,MAAO,CAAE,eAAAH,EAAgB,kBAAAC,CAAkB,CAAA,EAAIR,CAAS,CAC9F"}
1
+ {"version":3,"file":"Tooltip.js","sources":["../src/components/Tooltip/Tooltip.tsx"],"sourcesContent":["import React, { useContext, useState, useEffect, useRef } from 'react';\n\nimport TooltipWord from './TooltipWord';\nimport { useDelayedState } from '../../hooks/useDelayedState';\nimport { useUuid } from '../../hooks/useUuid';\nimport HelpBubble from '../HelpBubble';\n\nconst HOVER_DELAY_MS = 200;\n\nexport interface TooltipProps {\n /** Ordet som skal ha en tilhørende tooltip */\n children: string;\n /** Teksten som skal vises i tooltip */\n description: React.ReactNode;\n /** Valgfri test-id */\n testId?: string;\n}\n\nexport const Tooltip: React.FC<TooltipProps> = ({ children, description, testId }) => {\n const helpBubbleId = useUuid();\n const wordRef = useRef<HTMLButtonElement>(null);\n const { currentTooltip, setCurrentTooltip } = useContext(TooltipOpenContext);\n const [{ showTooltip, keepOpen }, setShowTooltipDelayed, setShowTooltip] = useDelayedState(\n { showTooltip: false, keepOpen: false },\n HOVER_DELAY_MS\n );\n\n useEffect(() => {\n if (!setCurrentTooltip) {\n return;\n }\n if (showTooltip) {\n setCurrentTooltip(helpBubbleId);\n } else {\n setCurrentTooltip(undefined);\n }\n }, [showTooltip]);\n\n useEffect(() => {\n if (currentTooltip !== helpBubbleId && typeof currentTooltip !== 'undefined') {\n setShowTooltip(prevState => ({ showTooltip: false, keepOpen: prevState.keepOpen }));\n }\n }, [currentTooltip]);\n\n const handleDocumentClick = (): void => {\n if (!showTooltip) {\n setShowTooltip({ showTooltip: false, keepOpen: false });\n }\n };\n\n useEffect(() => {\n document.addEventListener('mouseup', handleDocumentClick);\n return (): void => {\n document.removeEventListener('mouseup', handleDocumentClick);\n };\n }, []);\n\n const handleTooltipClick = (): void => {\n setShowTooltip(prevState => ({ showTooltip: !prevState.showTooltip, keepOpen: !prevState.keepOpen }));\n };\n\n const handleFocus = (): void => {\n if (!currentTooltip) {\n setShowTooltipDelayed(prevState => ({ showTooltip: true, keepOpen: prevState.keepOpen }));\n }\n };\n\n const handleBlur = (): void => {\n setShowTooltip(prevState => ({ showTooltip: false, keepOpen: prevState.keepOpen }));\n };\n\n const handleKeyDown = (e: React.KeyboardEvent<HTMLSpanElement>): void => {\n if (e.key === 'Enter') {\n setShowTooltip(prevState => ({ showTooltip: !prevState.showTooltip, keepOpen: !prevState.keepOpen }));\n }\n if (e.key === 'Escape') {\n setShowTooltip({ showTooltip: false, keepOpen: false });\n }\n };\n\n return (\n <>\n <TooltipWord\n ref={wordRef}\n onClick={handleTooltipClick}\n onFocus={handleFocus}\n onBlur={handleBlur}\n onKeyDown={handleKeyDown}\n ariaDescribedById={helpBubbleId}\n testId={testId}\n >\n {children}\n </TooltipWord>\n <HelpBubble helpBubbleId={helpBubbleId} controllerRef={wordRef} role=\"tooltip\" showBubble={showTooltip || keepOpen}>\n {description}\n </HelpBubble>\n </>\n );\n};\n\nexport type TooltipContext = {\n currentTooltip?: string;\n setCurrentTooltip?: (id?: string) => void;\n};\n\nconst TooltipOpenContext = React.createContext<TooltipContext>({\n currentTooltip: undefined,\n});\n\nexport const TooltipOpenProvider: React.FC = ({ children }) => {\n const [currentTooltip, setCurrentTooltip] = useState<string>();\n\n return <TooltipOpenContext.Provider value={{ currentTooltip, setCurrentTooltip }}>{children}</TooltipOpenContext.Provider>;\n};\n\nexport default Tooltip;\n"],"names":["HOVER_DELAY_MS","Tooltip","children","description","testId","helpBubbleId","useUuid","wordRef","useRef","currentTooltip","setCurrentTooltip","useContext","TooltipOpenContext","showTooltip","keepOpen","setShowTooltipDelayed","setShowTooltip","useDelayedState","useEffect","prevState","handleDocumentClick","handleTooltipClick","handleFocus","handleBlur","handleKeyDown","React","TooltipWord","HelpBubble","TooltipOpenProvider","useState","Tooltip$1"],"mappings":"kQAOA,MAAMA,EAAiB,IAWVC,EAAkC,CAAC,CAAE,SAAAC,EAAU,YAAAC,EAAa,OAAAC,KAAa,CACpF,MAAMC,EAAeC,IACfC,EAAUC,EAA0B,IAAI,EACxC,CAAE,eAAAC,EAAgB,kBAAAC,CAAkB,EAAIC,EAAWC,CAAkB,EACrE,CAAC,CAAE,YAAAC,EAAa,SAAAC,CAAY,EAAAC,EAAuBC,CAAc,EAAIC,EACzE,CAAE,YAAa,GAAO,SAAU,EAAM,EACtCjB,CAAA,EAGFkB,EAAU,IAAM,CACTR,GAIHA,EADEG,EACgBR,EAEA,MAFY,CAGhC,EACC,CAACQ,CAAW,CAAC,EAEhBK,EAAU,IAAM,CACVT,IAAmBJ,GAAgB,OAAOI,EAAmB,KAC/DO,MAA6B,CAAE,YAAa,GAAO,SAAUG,EAAU,QAAW,EAAA,CACpF,EACC,CAACV,CAAc,CAAC,EAEnB,MAAMW,EAAsB,IAAY,CACjCP,GACHG,EAAe,CAAE,YAAa,GAAO,SAAU,EAAO,CAAA,CACxD,EAGFE,EAAU,KACC,SAAA,iBAAiB,UAAWE,CAAmB,EACjD,IAAY,CACR,SAAA,oBAAoB,UAAWA,CAAmB,CAAA,GAE5D,CAAE,CAAA,EAEL,MAAMC,EAAqB,IAAY,CACtBL,EAAAG,IAAc,CAAE,YAAa,CAACA,EAAU,YAAa,SAAU,CAACA,EAAU,QAAA,EAAW,CAAA,EAGhGG,EAAc,IAAY,CACzBb,GACHM,MAAoC,CAAE,YAAa,GAAM,SAAUI,EAAU,QAAW,EAAA,CAC1F,EAGII,EAAa,IAAY,CAC7BP,MAA6B,CAAE,YAAa,GAAO,SAAUG,EAAU,QAAW,EAAA,CAAA,EAG9EK,EAAiB,GAAkD,CACnE,EAAE,MAAQ,SACGR,EAAAG,IAAc,CAAE,YAAa,CAACA,EAAU,YAAa,SAAU,CAACA,EAAU,QAAA,EAAW,EAElG,EAAE,MAAQ,UACZH,EAAe,CAAE,YAAa,GAAO,SAAU,EAAO,CAAA,CACxD,EAGF,OAEIS,EAAA,cAAAA,EAAA,SAAA,KAAAA,EAAA,cAACC,EAAA,CACC,IAAKnB,EACL,QAASc,EACT,QAASC,EACT,OAAQC,EACR,UAAWC,EACX,kBAAmBnB,EACnB,OAAAD,CAAA,EAECF,CAAA,EAEHuB,EAAA,cAACE,EAAW,CAAA,aAAAtB,EAA4B,cAAeE,EAAS,KAAK,UAAU,WAAYM,GAAeC,CACvG,EAAAX,CACH,CACF,CAEJ,EAOMS,EAAqBa,EAAM,cAA8B,CAC7D,eAAgB,MAClB,CAAC,EAEYG,EAAgC,CAAC,CAAE,SAAA1B,KAAe,CAC7D,KAAM,CAACO,EAAgBC,CAAiB,EAAImB,EAAiB,EAEtD,OAAAJ,EAAA,cAACb,EAAmB,SAAnB,CAA4B,MAAO,CAAE,eAAAH,EAAgB,kBAAAC,EAAkB,EAAIR,CAAS,CAC9F,EAEA4B,EAAe7B"}
package/TooltipWord.js CHANGED
@@ -1,2 +1,2 @@
1
- import e from"react";import{AnalyticsId as p}from"./constants.js";import l from"./components/Tooltip/TooltipWord/styles.module.scss";const n=e.forwardRef(({children:o,onClick:r,onFocus:a,onBlur:t,onKeyDown:d,testId:i,ariaDescribedById:s},m)=>e.createElement("span",{className:l.word,ref:m,tabIndex:0,onClick:r,onMouseEnter:a,onMouseLeave:t,onFocus:a,onBlur:t,onKeyDown:d,"aria-describedby":s,"data-testid":i,"data-analyticsid":p.Tooltip},o));n.displayName="TooltipWord";export{n as T};
1
+ import a from"react";import{AnalyticsId as p}from"./constants.js";import c from"./components/Tooltip/TooltipWord/styles.module.scss";const e=a.forwardRef(({children:r,onClick:i,onFocus:o,onBlur:t,onKeyDown:d,testId:s,ariaDescribedById:l},m)=>a.createElement("button",{className:c.word,ref:m,onClick:i,onMouseEnter:o,onMouseLeave:t,onFocus:o,onBlur:t,onKeyDown:d,"aria-describedby":l,"data-testid":s,"data-analyticsid":p.Tooltip},r));e.displayName="TooltipWord";const T=e;export{T};
2
2
  //# sourceMappingURL=TooltipWord.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"TooltipWord.js","sources":["../src/components/Tooltip/TooltipWord/TooltipWord.tsx"],"sourcesContent":["import React from 'react';\n\nimport { AnalyticsId } from '../../../constants';\n\nimport styles from './styles.module.scss';\n\nexport interface TooltipWordProps {\n /** Ordet som skal ha en tilhørende tooltip */\n children: string;\n /** Callback når ordet klikkes på */\n onClick: () => void;\n /** Callback når ordet får fokus eller hovres over */\n onFocus: () => void;\n /** Callback når ordet mister fokus eller hover forsvinner */\n onBlur: () => void;\n /** Callback når det skrives på tastaturet */\n onKeyDown: (e: React.KeyboardEvent<HTMLSpanElement>) => void;\n /** ID til element som beskriver ordet */\n ariaDescribedById: string;\n /** Valgfri test-id */\n testId?: string;\n}\n\nconst TooltipWord = React.forwardRef<HTMLSpanElement, TooltipWordProps>(\n ({ children, onClick, onFocus, onBlur, onKeyDown, testId, ariaDescribedById }, ref) => (\n <span\n className={styles.word}\n ref={ref}\n tabIndex={0}\n onClick={onClick}\n onMouseEnter={onFocus}\n onMouseLeave={onBlur}\n onFocus={onFocus}\n onBlur={onBlur}\n onKeyDown={onKeyDown}\n aria-describedby={ariaDescribedById}\n data-testid={testId}\n data-analyticsid={AnalyticsId.Tooltip}\n >\n {children}\n </span>\n )\n);\n\nTooltipWord.displayName = 'TooltipWord';\n\nexport default TooltipWord;\n"],"names":["TooltipWord","React","children","onClick","onFocus","onBlur","onKeyDown","testId","ariaDescribedById","ref","styles","AnalyticsId"],"mappings":"qIAuBA,MAAMA,EAAcC,EAAM,WACxB,CAAC,CAAE,SAAAC,EAAU,QAAAC,EAAS,QAAAC,EAAS,OAAAC,EAAQ,UAAAC,EAAW,OAAAC,EAAQ,kBAAAC,CAAqB,EAAAC,IAC5ER,EAAA,cAAA,OAAA,CACC,UAAWS,EAAO,KAClB,IAAAD,EACA,SAAU,EACV,QAAAN,EACA,aAAcC,EACd,aAAcC,EACd,QAAAD,EACA,OAAAC,EACA,UAAAC,EACA,mBAAkBE,EAClB,cAAaD,EACb,mBAAkBI,EAAY,OAAA,EAE7BT,CACH,CAEJ,EAEAF,EAAY,YAAc"}
1
+ {"version":3,"file":"TooltipWord.js","sources":["../src/components/Tooltip/TooltipWord/TooltipWord.tsx"],"sourcesContent":["import React from 'react';\n\nimport { AnalyticsId } from '../../../constants';\n\nimport styles from './styles.module.scss';\n\nexport interface TooltipWordProps {\n /** Ordet som skal ha en tilhørende tooltip */\n children: string;\n /** Callback når ordet klikkes på */\n onClick: () => void;\n /** Callback når ordet får fokus eller hovres over */\n onFocus: () => void;\n /** Callback når ordet mister fokus eller hover forsvinner */\n onBlur: () => void;\n /** Callback når det skrives på tastaturet */\n onKeyDown: (e: React.KeyboardEvent<HTMLSpanElement>) => void;\n /** ID til element som beskriver ordet */\n ariaDescribedById: string;\n /** Valgfri test-id */\n testId?: string;\n}\n\nconst TooltipWord = React.forwardRef<HTMLButtonElement, TooltipWordProps>(\n ({ children, onClick, onFocus, onBlur, onKeyDown, testId, ariaDescribedById }, ref) => (\n <button\n className={styles.word}\n ref={ref}\n onClick={onClick}\n onMouseEnter={onFocus}\n onMouseLeave={onBlur}\n onFocus={onFocus}\n onBlur={onBlur}\n onKeyDown={onKeyDown}\n aria-describedby={ariaDescribedById}\n data-testid={testId}\n data-analyticsid={AnalyticsId.Tooltip}\n >\n {children}\n </button>\n )\n);\n\nTooltipWord.displayName = 'TooltipWord';\n\nexport default TooltipWord;\n"],"names":["TooltipWord","React","children","onClick","onFocus","onBlur","onKeyDown","testId","ariaDescribedById","ref","styles","AnalyticsId","TooltipWord$1"],"mappings":"qIAuBA,MAAMA,EAAcC,EAAM,WACxB,CAAC,CAAE,SAAAC,EAAU,QAAAC,EAAS,QAAAC,EAAS,OAAAC,EAAQ,UAAAC,EAAW,OAAAC,EAAQ,kBAAAC,CAAkB,EAAGC,IAC7ER,EAAA,cAAC,SAAA,CACC,UAAWS,EAAO,KAClB,IAAAD,EACA,QAAAN,EACA,aAAcC,EACd,aAAcC,EACd,QAAAD,EACA,OAAAC,EACA,UAAAC,EACA,mBAAkBE,EAClB,cAAaD,EACb,mBAAkBI,EAAY,OAAA,EAE7BT,CACH,CAEJ,EAEAF,EAAY,YAAc,cAE1B,MAAAY,EAAeZ"}
package/Validation.js CHANGED
@@ -1,2 +1,2 @@
1
- import a from"react";import n from"classnames";import{F as s}from"./FormGroup.js";import o from"./components/Validation/styles.module.scss";import{AnalyticsId as l}from"./constants.js";const y=a.forwardRef((r,c)=>{const{errorSummary:e,className:i}=r,m=n(o.validation,i);return a.createElement(a.Fragment,null,a.createElement("div",{"data-testid":r.testId,"data-analyticsid":l.Validation,className:m},a.Children.map(r.children,t=>t.type===s?a.cloneElement(t,{className:e?o["form-group-wrapper--error-sibling"]:""}):t)),e&&a.createElement("p",{className:o.validation__errors},e))});export{y as V};
1
+ import a from"react";import s from"classnames";import{AnalyticsId as m}from"./constants.js";import{F as l}from"./FormGroup.js";import o from"./components/Validation/styles.module.scss";const c=a.forwardRef((r,d)=>{const{errorSummary:e,className:i}=r,n=s(o.validation,i);return a.createElement(a.Fragment,null,a.createElement("div",{"data-testid":r.testId,"data-analyticsid":m.Validation,className:n},a.Children.map(r.children,t=>t.type===l?a.cloneElement(t,{className:e?o["form-group-wrapper--error-sibling"]:""}):t)),e&&a.createElement("p",{className:o.validation__errors},e))}),N=c;export{N as V,c as a};
2
2
  //# sourceMappingURL=Validation.js.map
package/Validation.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"Validation.js","sources":["../src/components/Validation/Validation.tsx"],"sourcesContent":["import React from 'react';\n\nimport classNames from 'classnames';\n\nimport FormGroup, { FormGroupProps } from '../FormGroup/FormGroup';\n\nimport validationStyles from './styles.module.scss';\nimport { AnalyticsId, FormVariant } from '../../constants';\n\ninterface ValidationProps {\n /** text placed in the legend tag of the fieldset */\n errorSummary?: string;\n /** Items in the Validation compontent */\n children?: React.ReactNode;\n /** Adds custom classes to the element. */\n className?: string;\n /** Changes the visuals of the formgroup */\n variant?: keyof typeof FormVariant;\n /** Sets the data-testid attribute. */\n testId?: string;\n}\n\nexport const Validation = React.forwardRef((props: ValidationProps, ref: React.ForwardedRef<HTMLElement>) => {\n const { errorSummary, className } = props;\n const validationClasses = classNames(validationStyles['validation'], className);\n\n return (\n <>\n <div data-testid={props.testId} data-analyticsid={AnalyticsId.Validation} className={validationClasses}>\n {React.Children.map(props.children, (child: React.ReactNode) => {\n if ((child as React.ReactElement<FormGroupProps>).type === FormGroup) {\n return React.cloneElement(child as React.ReactElement<FormGroupProps>, {\n className: errorSummary ? validationStyles['form-group-wrapper--error-sibling'] : '',\n });\n }\n return child;\n })}\n </div>\n {errorSummary && <p className={validationStyles['validation__errors']}>{errorSummary}</p>}\n </>\n );\n});\n\nexport default Validation;\n"],"names":["Validation","React","props","ref","errorSummary","className","validationClasses","classNames","validationStyles","AnalyticsId","child","FormGroup"],"mappings":"yLAsBO,MAAMA,EAAaC,EAAM,WAAW,CAACC,EAAwBC,IAAyC,CACrG,KAAA,CAAE,aAAAC,EAAc,UAAAC,CAAc,EAAAH,EAC9BI,EAAoBC,EAAWC,EAAiB,WAAeH,CAAS,EAE9E,uCAEKJ,EAAA,cAAA,MAAA,CAAI,cAAaC,EAAM,OAAQ,mBAAkBO,EAAY,WAAY,UAAWH,CAAA,EAClFL,EAAM,SAAS,IAAIC,EAAM,SAAWQ,GAC9BA,EAA6C,OAASC,EAClDV,EAAM,aAAaS,EAA6C,CACrE,UAAWN,EAAeI,EAAiB,qCAAuC,EAAA,CACnF,EAEIE,CACR,CACH,EACCN,GAAiBH,EAAA,cAAA,IAAA,CAAE,UAAWO,EAAiB,kBAAA,EAAwBJ,CAAa,CACvF,CAEJ,CAAC"}
1
+ {"version":3,"file":"Validation.js","sources":["../src/components/Validation/Validation.tsx"],"sourcesContent":["import React from 'react';\n\nimport classNames from 'classnames';\n\nimport { AnalyticsId, FormVariant } from '../../constants';\nimport FormGroup, { FormGroupProps } from '../FormGroup/FormGroup';\n\nimport validationStyles from './styles.module.scss';\n\ninterface ValidationProps {\n /** text placed in the legend tag of the fieldset */\n errorSummary?: string;\n /** Items in the Validation compontent */\n children?: React.ReactNode;\n /** Adds custom classes to the element. */\n className?: string;\n /** Changes the visuals of the formgroup */\n variant?: keyof typeof FormVariant;\n /** Sets the data-testid attribute. */\n testId?: string;\n}\n\nexport const Validation = React.forwardRef((props: ValidationProps, ref: React.ForwardedRef<HTMLElement>) => {\n const { errorSummary, className } = props;\n const validationClasses = classNames(validationStyles['validation'], className);\n\n return (\n <>\n <div data-testid={props.testId} data-analyticsid={AnalyticsId.Validation} className={validationClasses}>\n {React.Children.map(props.children, (child: React.ReactNode) => {\n if ((child as React.ReactElement<FormGroupProps>).type === FormGroup) {\n return React.cloneElement(child as React.ReactElement<FormGroupProps>, {\n className: errorSummary ? validationStyles['form-group-wrapper--error-sibling'] : '',\n });\n }\n return child;\n })}\n </div>\n {errorSummary && <p className={validationStyles['validation__errors']}>{errorSummary}</p>}\n </>\n );\n});\n\nexport default Validation;\n"],"names":["Validation","React","props","ref","errorSummary","className","validationClasses","classNames","validationStyles","AnalyticsId","child","FormGroup","Validation$1"],"mappings":"yLAsBO,MAAMA,EAAaC,EAAM,WAAW,CAACC,EAAwBC,IAAyC,CACrG,KAAA,CAAE,aAAAC,EAAc,UAAAC,CAAc,EAAAH,EAC9BI,EAAoBC,EAAWC,EAAiB,WAAeH,CAAS,EAE9E,uCAEKJ,EAAA,cAAA,MAAA,CAAI,cAAaC,EAAM,OAAQ,mBAAkBO,EAAY,WAAY,UAAWH,GAClFL,EAAM,SAAS,IAAIC,EAAM,SAAWQ,GAC9BA,EAA6C,OAASC,EAClDV,EAAM,aAAaS,EAA6C,CACrE,UAAWN,EAAeI,EAAiB,mCAAmC,EAAI,EAAA,CACnF,EAEIE,CACR,CACH,EACCN,GAAgBH,EAAA,cAAC,IAAE,CAAA,UAAWO,EAAiB,oBAAwBJ,CAAa,CACvF,CAEJ,CAAC,EAEDQ,EAAeZ"}
@@ -1,3 +1,3 @@
1
1
  /// <reference types="jest" />
2
- export declare const mockWindowMatchMedia: jest.Mock<any, any>;
2
+ export declare const mockWindowMatchMedia: jest.Mock<any, any, any>;
3
3
  //# sourceMappingURL=matchMedia.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"matchMedia.d.ts","sourceRoot":"","sources":["../../src/__mocks__/matchMedia.ts"],"names":[],"mappings":";AAAA,eAAO,MAAM,oBAAoB,qBAI9B,CAAC"}
1
+ {"version":3,"file":"matchMedia.d.ts","sourceRoot":"","sources":["../../src/__mocks__/matchMedia.ts"],"names":[],"mappings":";AAAA,eAAO,MAAM,oBAAoB,0BAI9B,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
- export declare type AnchorLinkTargets = '_self' | '_blank' | '_parent';
3
- export declare type AnchorLinkTags = 'a' | 'button';
2
+ export type AnchorLinkTargets = '_self' | '_blank' | '_parent';
3
+ export type AnchorLinkTags = 'a' | 'button';
4
4
  interface AnchorLinkProps {
5
5
  /** Sets the content of the <a> tag */
6
6
  children: React.ReactNode;
@@ -1 +1 @@
1
- {"version":3,"file":"AnchorLink.d.ts","sourceRoot":"","sources":["../../../src/components/AnchorLink/AnchorLink.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAU1B,oBAAY,iBAAiB,GAAG,OAAO,GAAG,QAAQ,GAAG,SAAS,CAAC;AAE/D,oBAAY,cAAc,GAAG,GAAG,GAAG,QAAQ,CAAC;AAE5C,UAAU,eAAe;IACvB,sCAAsC;IACtC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,qBAAqB;IACrB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,8CAA8C;IAC9C,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,0CAA0C;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,4FAA4F;IAC5F,MAAM,CAAC,EAAE,iBAAiB,CAAC;IAC3B,8CAA8C;IAC9C,UAAU,CAAC,EAAE,cAAc,CAAC;IAC5B,2CAA2C;IAC3C,OAAO,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,WAAW,EAAE,UAAU,CAAC,GAAG,KAAK,CAAC,SAAS,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,aAAa,CAAC,gBAAgB,CAAC,GAAG,IAAI,KAAK,IAAI,CAAC;IACvI,sCAAsC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,QAAA,MAAM,UAAU,+GAyDd,CAAC;AAEH,eAAe,UAAU,CAAC"}
1
+ {"version":3,"file":"AnchorLink.d.ts","sourceRoot":"","sources":["../../../src/components/AnchorLink/AnchorLink.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAY1B,MAAM,MAAM,iBAAiB,GAAG,OAAO,GAAG,QAAQ,GAAG,SAAS,CAAC;AAE/D,MAAM,MAAM,cAAc,GAAG,GAAG,GAAG,QAAQ,CAAC;AAE5C,UAAU,eAAe;IACvB,sCAAsC;IACtC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,qBAAqB;IACrB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,8CAA8C;IAC9C,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,0CAA0C;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,4FAA4F;IAC5F,MAAM,CAAC,EAAE,iBAAiB,CAAC;IAC3B,8CAA8C;IAC9C,UAAU,CAAC,EAAE,cAAc,CAAC;IAC5B,2CAA2C;IAC3C,OAAO,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,WAAW,EAAE,UAAU,CAAC,GAAG,KAAK,CAAC,SAAS,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,aAAa,CAAC,gBAAgB,CAAC,GAAG,IAAI,KAAK,IAAI,CAAC;IACvI,sCAAsC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,QAAA,MAAM,UAAU,+GAyDd,CAAC;AAEH,eAAe,UAAU,CAAC"}
@@ -1,2 +1,2 @@
1
- import"../../AnchorLink.js";import{A as L}from"../../AnchorLink.js";import"react";import"../Icons/Icon.js";import"classnames";import"../../constants.js";import"../../hooks/useUuid.js";import"../../uuid.js";import"../../utils/environment.js";import"../Icons/ArrowUpRight.js";import"../../theme/currys/color.js";import"../../theme/index.js";import"../../theme/palette.js";import"../../theme/spacers.js";import"../../theme/grid.js";import"../../hooks/useHover.js";import"./styles.module.scss";export{L as default};
1
+ import{A as r}from"../../AnchorLink.js";import"react";import"classnames";import"../../constants.js";import"../../hooks/useHover.js";import"../../theme/currys/color.js";import"../../theme/index.js";import"../../theme/grid.js";import"../../theme/palette.js";import"../../theme/spacers.js";import"../Icons/Icon.js";import"../../hooks/useUuid.js";import"../../uuid.js";import"../../utils/environment.js";import"../Icons/ArrowUpRight.js";import"./styles.module.scss";export{r as default};
2
2
  //# sourceMappingURL=index.js.map
@@ -1,6 +1,10 @@
1
- @import '../../scss/_spacers.scss';
2
- @import '../../scss/_breakpoints.scss';
3
- @import '../../scss/_palette.scss';
1
+ @use 'sass:map';
2
+ @import '../../scss/spacers';
3
+ @import '../../scss/breakpoints';
4
+ @import '../../scss/palette';
5
+
6
+ $underline-width: 0.0625rem;
7
+ $focus-width: 0.15rem;
4
8
 
5
9
  @mixin anchorlink-hover {
6
10
  cursor: pointer;
@@ -8,28 +12,29 @@
8
12
  background-color: $blueberry50;
9
13
  border-bottom-color: $blueberry600;
10
14
  }
15
+
11
16
  @mixin anchorlink-focus {
12
- padding: 0 0 0.15rem 0;
13
17
  outline: none;
14
- border: 0.15rem solid $black;
15
- margin-top: -0.075rem;
18
+ border: $focus-width solid $black;
16
19
  }
17
20
 
18
21
  @mixin anchorlink {
19
22
  display: inline;
20
- -webkit-box-decoration-break: clone;
21
23
  box-decoration-break: clone;
22
24
  overflow-wrap: break-word;
23
25
  word-break: break-word;
24
26
  text-align: left;
25
27
  text-decoration: none;
26
28
  color: $blueberry600;
27
- padding: 0.15rem;
28
- border-bottom: 1px solid $neutral700;
29
+ border: $focus-width solid transparent;
30
+ border-bottom-color: $neutral700;
31
+ border-bottom-width: $underline-width;
32
+ padding-bottom: calc($focus-width - $underline-width);
29
33
 
30
34
  &:hover {
31
35
  @include anchorlink-hover;
32
36
  }
37
+
33
38
  &:focus {
34
39
  @include anchorlink-focus;
35
40
  }
@@ -47,14 +52,15 @@
47
52
  font-size: 1.125rem;
48
53
  line-height: 1.875rem;
49
54
  font-weight: 400;
50
- @media (min-width: map-get($grid-breakpoints, md)) {
55
+
56
+ @media (min-width: map.get($grid-breakpoints, md)) {
51
57
  font-size: 1.25rem;
52
58
  }
53
59
  }
54
60
 
55
61
  @mixin anchorlink-icon {
56
62
  &[target='_blank'] {
57
- &:after {
63
+ &::after {
58
64
  content: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='38px' height='38px' viewBox='0 0 48 48' fill='%2308667c'><polygon points='33.305,14.659,33.305,29.205,32.005,29.205,32.005,16.948,15.804,33.149,14.885,32.229,31.155,15.959,18.761,15.96,18.761,14.659' /></svg>");
59
65
  display: inline-block;
60
66
  vertical-align: bottom;
@@ -72,9 +78,11 @@
72
78
 
73
79
  .anchorlink-wrapper {
74
80
  all: unset;
81
+
75
82
  &:hover > span {
76
83
  @include anchorlink-hover;
77
84
  }
85
+
78
86
  &:focus > span {
79
87
  @include anchorlink-focus;
80
88
  }
@@ -17,7 +17,7 @@ export interface AvatarProps {
17
17
  /** Sets the data-testid attribute. */
18
18
  testId?: string;
19
19
  }
20
- export declare type AvatarType = React.ForwardRefExoticComponent<AvatarProps & React.RefAttributes<HTMLElement>>;
20
+ export type AvatarType = React.ForwardRefExoticComponent<AvatarProps & React.RefAttributes<HTMLElement>>;
21
21
  declare const Avatar: AvatarType;
22
22
  export default Avatar;
23
23
  //# sourceMappingURL=Avatar.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Avatar.d.ts","sourceRoot":"","sources":["../../../src/components/Avatar/Avatar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAU1B,oBAAY,UAAU;IACpB,MAAM,WAAW;IACjB,KAAK,UAAU;CAChB;AAED,MAAM,WAAW,WAAW;IAC1B,oFAAoF;IACpF,QAAQ,EAAE,MAAM,CAAC;IACjB,6DAA6D;IAC7D,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,0DAA0D;IAC1D,OAAO,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC;IAC7B,kCAAkC;IAClC,IAAI,CAAC,EAAE,MAAM,OAAO,UAAU,CAAC;IAC/B,0CAA0C;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sCAAsC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AACD,oBAAY,UAAU,GAAG,KAAK,CAAC,yBAAyB,CAAC,WAAW,GAAG,KAAK,CAAC,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC;AACzG,QAAA,MAAM,MAAM,EAAE,UAwBZ,CAAC;AAEH,eAAe,MAAM,CAAC"}
1
+ {"version":3,"file":"Avatar.d.ts","sourceRoot":"","sources":["../../../src/components/Avatar/Avatar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAW1B,oBAAY,UAAU;IACpB,MAAM,WAAW;IACjB,KAAK,UAAU;CAChB;AAED,MAAM,WAAW,WAAW;IAC1B,oFAAoF;IACpF,QAAQ,EAAE,MAAM,CAAC;IACjB,6DAA6D;IAC7D,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,0DAA0D;IAC1D,OAAO,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC;IAC7B,kCAAkC;IAClC,IAAI,CAAC,EAAE,MAAM,OAAO,UAAU,CAAC;IAC/B,0CAA0C;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sCAAsC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AACD,MAAM,MAAM,UAAU,GAAG,KAAK,CAAC,yBAAyB,CAAC,WAAW,GAAG,KAAK,CAAC,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC;AACzG,QAAA,MAAM,MAAM,EAAE,UAwBZ,CAAC;AAEH,eAAe,MAAM,CAAC"}
@@ -1,2 +1,2 @@
1
- import"../../Avatar.js";import{a as u,A as x}from"../../Avatar.js";import"react";import"../Icons/Icon.js";import"classnames";import"../../constants.js";import"../../hooks/useUuid.js";import"../../uuid.js";import"../../utils/environment.js";import"../Icons/Check.js";import"./styles.module.scss";import"../../theme/palette.js";export{u as AvatarSize,x as default};
1
+ import{A as t}from"../../Avatar.js";import{a as l}from"../../Avatar.js";import"react";import"classnames";import"../../constants.js";import"../../theme/palette.js";import"../Icons/Icon.js";import"../../hooks/useUuid.js";import"../../uuid.js";import"../../utils/environment.js";import"../Icons/Check.js";import"./styles.module.scss";export{l as AvatarSize,t as default};
2
2
  //# sourceMappingURL=index.js.map
@@ -1,5 +1,5 @@
1
- @import '../../scss/_palette.scss';
2
- @import '../../scss/_font-settings';
1
+ @import '../../scss/palette';
2
+ @import '../../scss/font-settings';
3
3
 
4
4
  .avatar {
5
5
  display: flex;
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import { PaletteNames } from '../../theme/palette';
3
- export declare type BadgeColors = PaletteNames;
4
- export declare type BadgeChildren = string | number;
3
+ export type BadgeColors = PaletteNames;
4
+ export type BadgeChildren = string | number;
5
5
  export interface BadgeProps {
6
6
  /** Sets the content of the badge. */
7
7
  children: BadgeChildren;
@@ -12,7 +12,7 @@ export interface BadgeProps {
12
12
  /** Sets the data-testid attribute. */
13
13
  testId?: string;
14
14
  }
15
- export declare type BadgeType = React.ForwardRefExoticComponent<BadgeProps & React.RefAttributes<HTMLElement>>;
15
+ export type BadgeType = React.ForwardRefExoticComponent<BadgeProps & React.RefAttributes<HTMLElement>>;
16
16
  declare const Badge: BadgeType;
17
17
  export default Badge;
18
18
  //# sourceMappingURL=Badge.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Badge.d.ts","sourceRoot":"","sources":["../../../src/components/Badge/Badge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAKnD,oBAAY,WAAW,GAAG,YAAY,CAAC;AACvC,oBAAY,aAAa,GAAG,MAAM,GAAG,MAAM,CAAC;AAE5C,MAAM,WAAW,UAAU;IACzB,qCAAqC;IACrC,QAAQ,EAAE,aAAa,CAAC;IACxB,0CAA0C;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,0CAA0C;IAC1C,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,sCAAsC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AACD,oBAAY,SAAS,GAAG,KAAK,CAAC,yBAAyB,CAAC,UAAU,GAAG,KAAK,CAAC,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC;AACvG,QAAA,MAAM,KAAK,EAAE,SAsBX,CAAC;AAEH,eAAe,KAAK,CAAC"}
1
+ {"version":3,"file":"Badge.d.ts","sourceRoot":"","sources":["../../../src/components/Badge/Badge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAInD,MAAM,MAAM,WAAW,GAAG,YAAY,CAAC;AACvC,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,MAAM,CAAC;AAE5C,MAAM,WAAW,UAAU;IACzB,qCAAqC;IACrC,QAAQ,EAAE,aAAa,CAAC;IACxB,0CAA0C;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,0CAA0C;IAC1C,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,sCAAsC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AACD,MAAM,MAAM,SAAS,GAAG,KAAK,CAAC,yBAAyB,CAAC,UAAU,GAAG,KAAK,CAAC,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC;AACvG,QAAA,MAAM,KAAK,EAAE,SAsBX,CAAC;AAEH,eAAe,KAAK,CAAC"}
@@ -1,2 +1,2 @@
1
- import"../../Badge.js";import{B as f}from"../../Badge.js";import"react";import"classnames";import"./styles.module.scss";import"../../constants.js";export{f as default};
1
+ import{B as r}from"../../Badge.js";import"react";import"classnames";import"../../constants.js";import"./styles.module.scss";export{r as default};
2
2
  //# sourceMappingURL=index.js.map
@@ -1,4 +1,4 @@
1
- @import '../../scss/_palette.scss';
1
+ @import '../../scss/palette';
2
2
 
3
3
  .badge {
4
4
  display: flex;
@@ -17,21 +17,27 @@
17
17
  color: $black;
18
18
  background-color: $white;
19
19
  }
20
+
20
21
  &--blueberry {
21
22
  background-color: $blueberry500;
22
23
  }
24
+
23
25
  &--banana {
24
26
  background-color: $banana500;
25
27
  }
28
+
26
29
  &--cherry {
27
30
  background-color: $cherry500;
28
31
  }
32
+
29
33
  &--kiwi {
30
34
  background-color: $kiwi500;
31
35
  }
36
+
32
37
  &--neutral {
33
38
  background-color: $neutral500;
34
39
  }
40
+
35
41
  &--plum {
36
42
  background-color: $plum500;
37
43
  }
@@ -1,11 +1,11 @@
1
- import React from 'react';
1
+ import React, { AriaAttributes } from 'react';
2
2
  import { HTMLButtonProps, HTMLAnchorProps } from '../../constants';
3
- export declare type ButtonConcept = 'normal' | 'destructive';
4
- export declare type ButtonVariant = 'fill' | 'outline' | 'borderless';
5
- export declare type ButtonSize = 'medium' | 'large';
6
- export declare type ButtonMode = 'onlight' | 'ondark';
7
- export declare type ButtonTags = 'button' | 'a';
8
- export interface ButtonProps extends HTMLButtonProps, HTMLAnchorProps {
3
+ export type ButtonConcept = 'normal' | 'destructive';
4
+ export type ButtonVariant = 'fill' | 'outline' | 'borderless';
5
+ export type ButtonSize = 'medium' | 'large';
6
+ export type ButtonMode = 'onlight' | 'ondark';
7
+ export type ButtonTags = 'button' | 'a';
8
+ export interface ButtonProps extends HTMLButtonProps, HTMLAnchorProps, AriaAttributes {
9
9
  /** Sets the aria-label of the button, use when the button only includes an icon */
10
10
  ariaLabel?: string;
11
11
  /** Gives a unique id to the button */
@@ -1 +1 @@
1
- {"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../src/components/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAEjD,OAAO,EAAE,eAAe,EAAE,eAAe,EAAe,MAAM,iBAAiB,CAAC;AAchF,oBAAY,aAAa,GAAG,QAAQ,GAAG,aAAa,CAAC;AACrD,oBAAY,aAAa,GAAG,MAAM,GAAG,SAAS,GAAG,YAAY,CAAC;AAC9D,oBAAY,UAAU,GAAG,QAAQ,GAAG,OAAO,CAAC;AAC5C,oBAAY,UAAU,GAAG,SAAS,GAAG,QAAQ,CAAC;AAC9C,oBAAY,UAAU,GAAG,QAAQ,GAAG,GAAG,CAAC;AAExC,MAAM,WAAW,WAAY,SAAQ,eAAe,EAAE,eAAe;IACnE,mFAAmF;IACnF,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sCAAsC;IACtC,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,sCAAsC;IACtC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,kDAAkD;IAClD,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,0CAA0C;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iGAAiG;IACjG,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,0EAA0E;IAC1E,OAAO,CAAC,EAAE,aAAa,CAAC;IACxB,mDAAmD;IACnD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,kEAAkE;IAClE,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,oDAAoD;IACpD,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,2DAA2D;IAC3D,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,2CAA2C;IAC3C,OAAO,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,WAAW,EAAE,UAAU,CAAC,GAAG,KAAK,CAAC,SAAS,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,aAAa,CAAC,gBAAgB,CAAC,GAAG,IAAI,KAAK,IAAI,CAAC;IACvI,uGAAuG;IACvG,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,uDAAuD;IACvD,OAAO,CAAC,EAAE,aAAa,CAAC;IACxB,uFAAuF;IACvF,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,sCAAsC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,mCAAmC;IACnC,IAAI,CAAC,EAAE,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,CAAC,MAAM,CAAC,CAAC;CAC9D;AAkCD,QAAA,MAAM,MAAM,2GAsKV,CAAC;AAEH,eAAe,MAAM,CAAC"}
1
+ {"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../src/components/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,cAAc,EAAqB,MAAM,OAAO,CAAC;AAKjE,OAAO,EAAE,eAAe,EAAE,eAAe,EAAe,MAAM,iBAAiB,CAAC;AAYhF,MAAM,MAAM,aAAa,GAAG,QAAQ,GAAG,aAAa,CAAC;AACrD,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,SAAS,GAAG,YAAY,CAAC;AAC9D,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,OAAO,CAAC;AAC5C,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,QAAQ,CAAC;AAC9C,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,GAAG,CAAC;AAExC,MAAM,WAAW,WAAY,SAAQ,eAAe,EAAE,eAAe,EAAE,cAAc;IACnF,mFAAmF;IACnF,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sCAAsC;IACtC,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,sCAAsC;IACtC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,kDAAkD;IAClD,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,0CAA0C;IAC1C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iGAAiG;IACjG,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,0EAA0E;IAC1E,OAAO,CAAC,EAAE,aAAa,CAAC;IACxB,mDAAmD;IACnD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,kEAAkE;IAClE,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,oDAAoD;IACpD,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB,2DAA2D;IAC3D,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,2CAA2C;IAC3C,OAAO,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,WAAW,EAAE,UAAU,CAAC,GAAG,KAAK,CAAC,SAAS,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,aAAa,CAAC,gBAAgB,CAAC,GAAG,IAAI,KAAK,IAAI,CAAC;IACvI,uGAAuG;IACvG,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,uDAAuD;IACvD,OAAO,CAAC,EAAE,aAAa,CAAC;IACxB,uFAAuF;IACvF,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,sCAAsC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,mCAAmC;IACnC,IAAI,CAAC,EAAE,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,CAAC,MAAM,CAAC,CAAC;CAC9D;AAkCD,QAAA,MAAM,MAAM,2GAsKV,CAAC;AAEH,eAAe,MAAM,CAAC"}