@pega/cosmos-react-core 4.0.0-dev.13.0 → 4.0.0-dev.14.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 (483) hide show
  1. package/README.md +2 -2
  2. package/lib/components/AppShell/AppHeader.styles.d.ts.map +1 -1
  3. package/lib/components/AppShell/AppHeader.styles.js +0 -2
  4. package/lib/components/AppShell/AppHeader.styles.js.map +1 -1
  5. package/lib/components/AppShell/AppShell.js.map +1 -1
  6. package/lib/components/AppShell/AppShell.styles.d.ts.map +1 -1
  7. package/lib/components/AppShell/AppShell.styles.js +10 -16
  8. package/lib/components/AppShell/AppShell.styles.js.map +1 -1
  9. package/lib/components/AppShell/AppShell.types.d.ts +12 -11
  10. package/lib/components/AppShell/AppShell.types.d.ts.map +1 -1
  11. package/lib/components/AppShell/AppShell.types.js.map +1 -1
  12. package/lib/components/AppShell/AppShellContext.d.ts +1 -1
  13. package/lib/components/AppShell/AppShellContext.d.ts.map +1 -1
  14. package/lib/components/AppShell/AppShellContext.js.map +1 -1
  15. package/lib/components/AppShell/AppShellList.d.ts +1 -1
  16. package/lib/components/AppShell/AppShellList.d.ts.map +1 -1
  17. package/lib/components/AppShell/AppShellList.js.map +1 -1
  18. package/lib/components/AppShell/AppShellList.styles.d.ts.map +1 -1
  19. package/lib/components/AppShell/AppShellList.styles.js +1 -2
  20. package/lib/components/AppShell/AppShellList.styles.js.map +1 -1
  21. package/lib/components/AppShell/NavigationList.d.ts.map +1 -1
  22. package/lib/components/AppShell/NavigationList.js.map +1 -1
  23. package/lib/components/AppShell/NavigationListItemWrapper.d.ts.map +1 -1
  24. package/lib/components/AppShell/NavigationListItemWrapper.js +31 -11
  25. package/lib/components/AppShell/NavigationListItemWrapper.js.map +1 -1
  26. package/lib/components/AppShell/Operator.d.ts.map +1 -1
  27. package/lib/components/AppShell/Operator.js +1 -3
  28. package/lib/components/AppShell/Operator.js.map +1 -1
  29. package/lib/components/Avatar/Avatar.d.ts +2 -2
  30. package/lib/components/Avatar/Avatar.js.map +1 -1
  31. package/lib/components/Backdrop/Backdrop.d.ts +9 -21
  32. package/lib/components/Backdrop/Backdrop.d.ts.map +1 -1
  33. package/lib/components/Backdrop/Backdrop.js +0 -2
  34. package/lib/components/Backdrop/Backdrop.js.map +1 -1
  35. package/lib/components/Badges/Count.d.ts +1 -1
  36. package/lib/components/Badges/Count.js.map +1 -1
  37. package/lib/components/Banner/Banner.d.ts +1 -1
  38. package/lib/components/Banner/Banner.d.ts.map +1 -1
  39. package/lib/components/Banner/Banner.js +3 -3
  40. package/lib/components/Banner/Banner.js.map +1 -1
  41. package/lib/components/Boolean/BooleanDisplay.d.ts +2 -2
  42. package/lib/components/Boolean/BooleanDisplay.js +2 -2
  43. package/lib/components/Boolean/BooleanDisplay.js.map +1 -1
  44. package/lib/components/Button/BareButton.d.ts +1 -1
  45. package/lib/components/Button/BareButton.js.map +1 -1
  46. package/lib/components/Button/Button.d.ts +7 -9
  47. package/lib/components/Button/Button.d.ts.map +1 -1
  48. package/lib/components/Button/Button.js +168 -142
  49. package/lib/components/Button/Button.js.map +1 -1
  50. package/lib/components/ColorPicker/ColorPicker.d.ts +1 -1
  51. package/lib/components/ColorPicker/ColorPicker.js +1 -1
  52. package/lib/components/ColorPicker/ColorPicker.js.map +1 -1
  53. package/lib/components/ColorPicker/ColorPicker.test-ids.d.ts +1 -1
  54. package/lib/components/ColorPicker/ColorPicker.test-ids.d.ts.map +1 -1
  55. package/lib/components/ColorPicker/ColorPicker.test-ids.js +5 -1
  56. package/lib/components/ColorPicker/ColorPicker.test-ids.js.map +1 -1
  57. package/lib/components/ComboBox/ComboBox.d.ts.map +1 -1
  58. package/lib/components/ComboBox/ComboBox.js +2 -10
  59. package/lib/components/ComboBox/ComboBox.js.map +1 -1
  60. package/lib/components/ComboBox/ComboxBox.test-ids.d.ts +1 -1
  61. package/lib/components/ComboBox/ComboxBox.test-ids.d.ts.map +1 -1
  62. package/lib/components/ComboBox/ComboxBox.test-ids.js +2 -1
  63. package/lib/components/ComboBox/ComboxBox.test-ids.js.map +1 -1
  64. package/lib/components/CompositeInput/CompositeInput.d.ts.map +1 -1
  65. package/lib/components/CompositeInput/CompositeInput.js +8 -10
  66. package/lib/components/CompositeInput/CompositeInput.js.map +1 -1
  67. package/lib/components/CompositeInput/CompositeInput.test-ids.d.ts +1 -1
  68. package/lib/components/CompositeInput/CompositeInput.test-ids.d.ts.map +1 -1
  69. package/lib/components/CompositeInput/CompositeInput.test-ids.js +5 -1
  70. package/lib/components/CompositeInput/CompositeInput.test-ids.js.map +1 -1
  71. package/lib/components/CompositeInput/CompositeInput.types.d.ts +2 -6
  72. package/lib/components/CompositeInput/CompositeInput.types.d.ts.map +1 -1
  73. package/lib/components/CompositeInput/CompositeInput.types.js.map +1 -1
  74. package/lib/components/Configuration/Configuration.d.ts +9 -27
  75. package/lib/components/Configuration/Configuration.d.ts.map +1 -1
  76. package/lib/components/Configuration/Configuration.js +5 -1
  77. package/lib/components/Configuration/Configuration.js.map +1 -1
  78. package/lib/components/CreditCard/utils.d.ts +1 -1
  79. package/lib/components/CreditCard/utils.d.ts.map +1 -1
  80. package/lib/components/CreditCard/utils.js +1 -1
  81. package/lib/components/CreditCard/utils.js.map +1 -1
  82. package/lib/components/Currency/Currency.test-ids.d.ts +1 -1
  83. package/lib/components/Currency/Currency.test-ids.d.ts.map +1 -1
  84. package/lib/components/Currency/Currency.test-ids.js +5 -1
  85. package/lib/components/Currency/Currency.test-ids.js.map +1 -1
  86. package/lib/components/Currency/CurrencyInput.js +1 -1
  87. package/lib/components/Currency/CurrencyInput.js.map +1 -1
  88. package/lib/components/Currency/CurrencyInput.types.d.ts +3 -7
  89. package/lib/components/Currency/CurrencyInput.types.d.ts.map +1 -1
  90. package/lib/components/Currency/CurrencyInput.types.js.map +1 -1
  91. package/lib/components/DateTime/DateTimeDisplay.d.ts +4 -10
  92. package/lib/components/DateTime/DateTimeDisplay.d.ts.map +1 -1
  93. package/lib/components/DateTime/DateTimeDisplay.js.map +1 -1
  94. package/lib/components/DateTime/Input/DateInput.d.ts.map +1 -1
  95. package/lib/components/DateTime/Input/DateInput.js +25 -32
  96. package/lib/components/DateTime/Input/DateInput.js.map +1 -1
  97. package/lib/components/DateTime/Input/DateTime.styles.d.ts +1 -0
  98. package/lib/components/DateTime/Input/DateTime.styles.d.ts.map +1 -1
  99. package/lib/components/DateTime/Input/DateTime.styles.js +3 -0
  100. package/lib/components/DateTime/Input/DateTime.styles.js.map +1 -1
  101. package/lib/components/DateTime/Input/DateTimeInput.d.ts +1 -3
  102. package/lib/components/DateTime/Input/DateTimeInput.d.ts.map +1 -1
  103. package/lib/components/DateTime/Input/DateTimeInput.js +20 -27
  104. package/lib/components/DateTime/Input/DateTimeInput.js.map +1 -1
  105. package/lib/components/DateTime/Input/TimeInput.d.ts +1 -3
  106. package/lib/components/DateTime/Input/TimeInput.d.ts.map +1 -1
  107. package/lib/components/DateTime/Input/TimeInput.js +1 -9
  108. package/lib/components/DateTime/Input/TimeInput.js.map +1 -1
  109. package/lib/components/DateTime/Input/TimeRangeInput.d.ts +1 -3
  110. package/lib/components/DateTime/Input/TimeRangeInput.d.ts.map +1 -1
  111. package/lib/components/DateTime/Input/TimeRangeInput.js.map +1 -1
  112. package/lib/components/DateTime/Input/WeekInput.d.ts.map +1 -1
  113. package/lib/components/DateTime/Input/WeekInput.js +11 -17
  114. package/lib/components/DateTime/Input/WeekInput.js.map +1 -1
  115. package/lib/components/DateTime/Input/usePickerButton.js +3 -3
  116. package/lib/components/DateTime/Input/usePickerButton.js.map +1 -1
  117. package/lib/components/DateTime/Picker/Calendar.d.ts +4 -6
  118. package/lib/components/DateTime/Picker/Calendar.d.ts.map +1 -1
  119. package/lib/components/DateTime/Picker/Calendar.js +1 -1
  120. package/lib/components/DateTime/Picker/Calendar.js.map +1 -1
  121. package/lib/components/DateTime/Picker/DatePicker.types.d.ts +2 -4
  122. package/lib/components/DateTime/Picker/DatePicker.types.d.ts.map +1 -1
  123. package/lib/components/DateTime/Picker/DatePicker.types.js.map +1 -1
  124. package/lib/components/DateTime/Picker/TimePicker.d.ts +1 -3
  125. package/lib/components/DateTime/Picker/TimePicker.d.ts.map +1 -1
  126. package/lib/components/DateTime/Picker/TimePicker.js.map +1 -1
  127. package/lib/components/DateTime/Picker/Weeks.d.ts +1 -3
  128. package/lib/components/DateTime/Picker/Weeks.d.ts.map +1 -1
  129. package/lib/components/DateTime/Picker/Weeks.js +1 -1
  130. package/lib/components/DateTime/Picker/Weeks.js.map +1 -1
  131. package/lib/components/DateTime/Picker/utils.js +1 -1
  132. package/lib/components/DateTime/Picker/utils.js.map +1 -1
  133. package/lib/components/DateTime/utils.d.ts.map +1 -1
  134. package/lib/components/DateTime/utils.js +8 -6
  135. package/lib/components/DateTime/utils.js.map +1 -1
  136. package/lib/components/Dialog/Dialog.d.ts.map +1 -1
  137. package/lib/components/Dialog/Dialog.js +2 -2
  138. package/lib/components/Dialog/Dialog.js.map +1 -1
  139. package/lib/components/Dialog/Dialog.styles.d.ts +3 -0
  140. package/lib/components/Dialog/Dialog.styles.d.ts.map +1 -1
  141. package/lib/components/Dialog/Dialog.styles.js +29 -2
  142. package/lib/components/Dialog/Dialog.styles.js.map +1 -1
  143. package/lib/components/Dialog/Dialog.types.d.ts +34 -34
  144. package/lib/components/Dialog/Dialog.types.d.ts.map +1 -1
  145. package/lib/components/Dialog/Dialog.types.js +0 -1
  146. package/lib/components/Dialog/Dialog.types.js.map +1 -1
  147. package/lib/components/Dialog/FormDialog.d.ts +4 -1
  148. package/lib/components/Dialog/FormDialog.d.ts.map +1 -1
  149. package/lib/components/Dialog/FormDialog.js +4 -5
  150. package/lib/components/Dialog/FormDialog.js.map +1 -1
  151. package/lib/components/Dialog/InfoDialog.d.ts +0 -1
  152. package/lib/components/Dialog/InfoDialog.d.ts.map +1 -1
  153. package/lib/components/Dialog/InfoDialog.js +15 -13
  154. package/lib/components/Dialog/InfoDialog.js.map +1 -1
  155. package/lib/components/Dialog/InfoDialog.styles.d.ts +6 -0
  156. package/lib/components/Dialog/InfoDialog.styles.d.ts.map +1 -0
  157. package/lib/components/Dialog/InfoDialog.styles.js +18 -0
  158. package/lib/components/Dialog/InfoDialog.styles.js.map +1 -0
  159. package/lib/components/Drawer/Drawer.d.ts +9 -9
  160. package/lib/components/Drawer/Drawer.d.ts.map +1 -1
  161. package/lib/components/Drawer/Drawer.js.map +1 -1
  162. package/lib/components/Email/EmailDisplay.d.ts +1 -1
  163. package/lib/components/Email/EmailDisplay.js.map +1 -1
  164. package/lib/components/EmojiPicker/EmojiPicker.styles.d.ts.map +1 -1
  165. package/lib/components/EmojiPicker/EmojiPicker.styles.js +2 -7
  166. package/lib/components/EmojiPicker/EmojiPicker.styles.js.map +1 -1
  167. package/lib/components/ExpandCollapse/ExpandCollapse.d.ts +6 -6
  168. package/lib/components/ExpandCollapse/ExpandCollapse.d.ts.map +1 -1
  169. package/lib/components/ExpandCollapse/ExpandCollapse.js.map +1 -1
  170. package/lib/components/FieldGroup/FieldGroup.d.ts +1 -3
  171. package/lib/components/FieldGroup/FieldGroup.d.ts.map +1 -1
  172. package/lib/components/FieldGroup/FieldGroup.js.map +1 -1
  173. package/lib/components/FieldValueList/FieldValueList.d.ts +5 -3
  174. package/lib/components/FieldValueList/FieldValueList.d.ts.map +1 -1
  175. package/lib/components/FieldValueList/FieldValueList.js.map +1 -1
  176. package/lib/components/FieldValueList/FieldValueList.test-ids.d.ts +2 -2
  177. package/lib/components/FieldValueList/FieldValueList.test-ids.d.ts.map +1 -1
  178. package/lib/components/FieldValueList/index.d.ts +1 -1
  179. package/lib/components/FieldValueList/index.d.ts.map +1 -1
  180. package/lib/components/FieldValueList/index.js.map +1 -1
  181. package/lib/components/File/File.test-ids.d.ts +1 -1
  182. package/lib/components/File/File.test-ids.d.ts.map +1 -1
  183. package/lib/components/File/File.test-ids.js +6 -1
  184. package/lib/components/File/File.test-ids.js.map +1 -1
  185. package/lib/components/File/FileDisplay.d.ts +2 -2
  186. package/lib/components/File/FileDisplay.d.ts.map +1 -1
  187. package/lib/components/File/FileDisplay.js.map +1 -1
  188. package/lib/components/File/FileInput.d.ts +1 -3
  189. package/lib/components/File/FileInput.d.ts.map +1 -1
  190. package/lib/components/File/FileInput.js +1 -1
  191. package/lib/components/File/FileInput.js.map +1 -1
  192. package/lib/components/Flex/Flex.d.ts +7 -1
  193. package/lib/components/Flex/Flex.d.ts.map +1 -1
  194. package/lib/components/Flex/Flex.js +37 -10
  195. package/lib/components/Flex/Flex.js.map +1 -1
  196. package/lib/components/FormControl/FormControl.d.ts +3 -2
  197. package/lib/components/FormControl/FormControl.d.ts.map +1 -1
  198. package/lib/components/FormControl/FormControl.js.map +1 -1
  199. package/lib/components/FormField/FormField.d.ts +4 -3
  200. package/lib/components/FormField/FormField.d.ts.map +1 -1
  201. package/lib/components/FormField/FormField.js +10 -14
  202. package/lib/components/FormField/FormField.js.map +1 -1
  203. package/lib/components/FormField/FormField.test-ids.d.ts +2 -1
  204. package/lib/components/FormField/FormField.test-ids.d.ts.map +1 -1
  205. package/lib/components/FormField/FormField.test-ids.js +3 -2
  206. package/lib/components/FormField/FormField.test-ids.js.map +1 -1
  207. package/lib/components/Grid/Grid.d.ts.map +1 -1
  208. package/lib/components/Grid/Grid.js +0 -3
  209. package/lib/components/Grid/Grid.js.map +1 -1
  210. package/lib/components/Grid/Grid.types.d.ts +6 -6
  211. package/lib/components/Grid/Grid.types.js.map +1 -1
  212. package/lib/components/Icon/iconNames.d.ts +2 -2
  213. package/lib/components/Icon/iconNames.d.ts.map +1 -1
  214. package/lib/components/Icon/iconNames.js +2 -0
  215. package/lib/components/Icon/iconNames.js.map +1 -1
  216. package/lib/components/Icon/icons/phone-merge-solid.icon.d.ts +4 -0
  217. package/lib/components/Icon/icons/phone-merge-solid.icon.d.ts.map +1 -0
  218. package/lib/components/Icon/icons/phone-merge-solid.icon.js +6 -0
  219. package/lib/components/Icon/icons/phone-merge-solid.icon.js.map +1 -0
  220. package/lib/components/Icon/icons/phone-merge.icon.d.ts +4 -0
  221. package/lib/components/Icon/icons/phone-merge.icon.d.ts.map +1 -0
  222. package/lib/components/Icon/icons/phone-merge.icon.js +6 -0
  223. package/lib/components/Icon/icons/phone-merge.icon.js.map +1 -0
  224. package/lib/components/IconPicker/IconPicker.js +2 -2
  225. package/lib/components/IconPicker/IconPicker.js.map +1 -1
  226. package/lib/components/Input/Input.d.ts +1 -1
  227. package/lib/components/Input/Input.js +1 -1
  228. package/lib/components/Input/Input.js.map +1 -1
  229. package/lib/components/Input/Input.test-ids.d.ts +1 -1
  230. package/lib/components/Input/Input.test-ids.d.ts.map +1 -1
  231. package/lib/components/Input/Input.test-ids.js +2 -1
  232. package/lib/components/Input/Input.test-ids.js.map +1 -1
  233. package/lib/components/Label/Label.d.ts +1 -1
  234. package/lib/components/Label/Label.js.map +1 -1
  235. package/lib/components/Lightbox/Lightbox.types.d.ts +1 -1
  236. package/lib/components/Lightbox/Lightbox.types.d.ts.map +1 -1
  237. package/lib/components/Lightbox/Lightbox.types.js.map +1 -1
  238. package/lib/components/Link/Link.d.ts +1 -1
  239. package/lib/components/Link/Link.js.map +1 -1
  240. package/lib/components/List/List.d.ts.map +1 -1
  241. package/lib/components/List/List.js.map +1 -1
  242. package/lib/components/ListToolbar/ListToolbar.d.ts +1 -1
  243. package/lib/components/ListToolbar/ListToolbar.d.ts.map +1 -1
  244. package/lib/components/ListToolbar/ListToolbar.js +49 -17
  245. package/lib/components/ListToolbar/ListToolbar.js.map +1 -1
  246. package/lib/components/ListToolbar/ListToolbar.styles.d.ts +3 -1
  247. package/lib/components/ListToolbar/ListToolbar.styles.d.ts.map +1 -1
  248. package/lib/components/ListToolbar/ListToolbar.styles.js +2 -3
  249. package/lib/components/ListToolbar/ListToolbar.styles.js.map +1 -1
  250. package/lib/components/ListToolbar/ListToolbar.test-ids.d.ts +2 -0
  251. package/lib/components/ListToolbar/ListToolbar.test-ids.d.ts.map +1 -0
  252. package/lib/components/ListToolbar/ListToolbar.test-ids.js +7 -0
  253. package/lib/components/ListToolbar/ListToolbar.test-ids.js.map +1 -0
  254. package/lib/components/ListToolbar/ListToolbar.types.d.ts +32 -9
  255. package/lib/components/ListToolbar/ListToolbar.types.d.ts.map +1 -1
  256. package/lib/components/ListToolbar/ListToolbar.types.js.map +1 -1
  257. package/lib/components/ListToolbar/helpers.d.ts +10 -0
  258. package/lib/components/ListToolbar/helpers.d.ts.map +1 -0
  259. package/lib/components/ListToolbar/helpers.js +46 -0
  260. package/lib/components/ListToolbar/helpers.js.map +1 -0
  261. package/lib/components/ListToolbar/index.d.ts +1 -0
  262. package/lib/components/ListToolbar/index.d.ts.map +1 -1
  263. package/lib/components/ListToolbar/index.js +1 -0
  264. package/lib/components/ListToolbar/index.js.map +1 -1
  265. package/lib/components/LiveLog/LiveLog.d.ts.map +1 -1
  266. package/lib/components/LiveLog/LiveLog.js +17 -16
  267. package/lib/components/LiveLog/LiveLog.js.map +1 -1
  268. package/lib/components/Location/Location.test-ids.d.ts +1 -1
  269. package/lib/components/Location/Location.test-ids.d.ts.map +1 -1
  270. package/lib/components/Location/Location.test-ids.js +5 -1
  271. package/lib/components/Location/Location.test-ids.js.map +1 -1
  272. package/lib/components/Location/LocationDisplay.d.ts +1 -1
  273. package/lib/components/Location/LocationDisplay.js.map +1 -1
  274. package/lib/components/Location/LocationInput.js +1 -1
  275. package/lib/components/Location/LocationInput.js.map +1 -1
  276. package/lib/components/Location/utils.d.ts +1 -1
  277. package/lib/components/Location/utils.d.ts.map +1 -1
  278. package/lib/components/Location/utils.js +1 -1
  279. package/lib/components/Location/utils.js.map +1 -1
  280. package/lib/components/Menu/Menu.styles.d.ts.map +1 -1
  281. package/lib/components/Menu/Menu.styles.js +1 -4
  282. package/lib/components/Menu/Menu.styles.js.map +1 -1
  283. package/lib/components/Menu/Menu.test-ids.d.ts +2 -2
  284. package/lib/components/Menu/Menu.test-ids.d.ts.map +1 -1
  285. package/lib/components/Menu/Menu.types.d.ts +6 -12
  286. package/lib/components/Menu/Menu.types.d.ts.map +1 -1
  287. package/lib/components/Menu/Menu.types.js.map +1 -1
  288. package/lib/components/Menu/NavItemsList.d.ts.map +1 -1
  289. package/lib/components/Menu/NavItemsList.js +2 -0
  290. package/lib/components/Menu/NavItemsList.js.map +1 -1
  291. package/lib/components/MenuButton/MenuButton.d.ts +3 -3
  292. package/lib/components/MenuButton/MenuButton.d.ts.map +1 -1
  293. package/lib/components/MenuButton/MenuButton.js +6 -4
  294. package/lib/components/MenuButton/MenuButton.js.map +1 -1
  295. package/lib/components/MenuButton/MenuButton.test-ids.d.ts +2 -0
  296. package/lib/components/MenuButton/MenuButton.test-ids.d.ts.map +1 -0
  297. package/lib/components/MenuButton/MenuButton.test-ids.js +3 -0
  298. package/lib/components/MenuButton/MenuButton.test-ids.js.map +1 -0
  299. package/lib/components/MetaList/MetaList.test-ids.d.ts +1 -1
  300. package/lib/components/MetaList/MetaList.test-ids.d.ts.map +1 -1
  301. package/lib/components/Modal/Modal.d.ts.map +1 -1
  302. package/lib/components/Modal/Modal.js +3 -5
  303. package/lib/components/Modal/Modal.js.map +1 -1
  304. package/lib/components/Modal/Modal.styles.js +1 -1
  305. package/lib/components/Modal/Modal.styles.js.map +1 -1
  306. package/lib/components/Modal/Modal.types.d.ts +25 -71
  307. package/lib/components/Modal/Modal.types.d.ts.map +1 -1
  308. package/lib/components/Modal/Modal.types.js.map +1 -1
  309. package/lib/components/Modal/ModalManager.d.ts.map +1 -1
  310. package/lib/components/Modal/ModalManager.js +5 -2
  311. package/lib/components/Modal/ModalManager.js.map +1 -1
  312. package/lib/components/MultiStepForm/HorizontalFormProgress.d.ts.map +1 -1
  313. package/lib/components/MultiStepForm/HorizontalFormProgress.js +4 -0
  314. package/lib/components/MultiStepForm/HorizontalFormProgress.js.map +1 -1
  315. package/lib/components/MultiStepForm/MultiStepForm.d.ts.map +1 -1
  316. package/lib/components/MultiStepForm/MultiStepForm.js +1 -1
  317. package/lib/components/MultiStepForm/MultiStepForm.js.map +1 -1
  318. package/lib/components/MultiStepForm/MultiStepForm.types.d.ts +1 -1
  319. package/lib/components/MultiStepForm/MultiStepForm.types.js.map +1 -1
  320. package/lib/components/Number/Number.test-ids.d.ts +2 -2
  321. package/lib/components/Number/Number.test-ids.d.ts.map +1 -1
  322. package/lib/components/Number/Number.test-ids.js +8 -2
  323. package/lib/components/Number/Number.test-ids.js.map +1 -1
  324. package/lib/components/Number/NumberInput.js +1 -1
  325. package/lib/components/Number/NumberInput.js.map +1 -1
  326. package/lib/components/Number/NumberRangeInput.js +1 -1
  327. package/lib/components/Number/NumberRangeInput.js.map +1 -1
  328. package/lib/components/PageTemplates/PageTemplates.js +2 -2
  329. package/lib/components/PageTemplates/PageTemplates.js.map +1 -1
  330. package/lib/components/Phone/Phone.test-ids.d.ts +1 -1
  331. package/lib/components/Phone/Phone.test-ids.d.ts.map +1 -1
  332. package/lib/components/Phone/Phone.test-ids.js +3 -1
  333. package/lib/components/Phone/Phone.test-ids.js.map +1 -1
  334. package/lib/components/Phone/PhoneDisplay.d.ts +1 -1
  335. package/lib/components/Phone/PhoneDisplay.js.map +1 -1
  336. package/lib/components/Phone/PhoneInput.js +2 -2
  337. package/lib/components/Phone/PhoneInput.js.map +1 -1
  338. package/lib/components/Popover/Popover.d.ts +4 -3
  339. package/lib/components/Popover/Popover.d.ts.map +1 -1
  340. package/lib/components/Popover/Popover.js +36 -24
  341. package/lib/components/Popover/Popover.js.map +1 -1
  342. package/lib/components/Popover/PopoverManager.d.ts.map +1 -1
  343. package/lib/components/Popover/PopoverManager.js +11 -10
  344. package/lib/components/Popover/PopoverManager.js.map +1 -1
  345. package/lib/components/Popover/modifiers.d.ts +1 -0
  346. package/lib/components/Popover/modifiers.d.ts.map +1 -1
  347. package/lib/components/Popover/modifiers.js +116 -1
  348. package/lib/components/Popover/modifiers.js.map +1 -1
  349. package/lib/components/Progress/Progress.styles.d.ts.map +1 -1
  350. package/lib/components/Progress/Progress.styles.js +25 -20
  351. package/lib/components/Progress/Progress.styles.js.map +1 -1
  352. package/lib/components/Progress/Progress.types.d.ts +2 -2
  353. package/lib/components/Progress/Progress.types.js.map +1 -1
  354. package/lib/components/RadioCheck/RadioCheck.js +2 -2
  355. package/lib/components/RadioCheck/RadioCheck.js.map +1 -1
  356. package/lib/components/SearchInput/SearchInput.d.ts +1 -1
  357. package/lib/components/SearchInput/SearchInput.d.ts.map +1 -1
  358. package/lib/components/SearchInput/SearchInput.js +1 -9
  359. package/lib/components/SearchInput/SearchInput.js.map +1 -1
  360. package/lib/components/Select/Select.js +2 -2
  361. package/lib/components/Select/Select.js.map +1 -1
  362. package/lib/components/Select/Select.test-ids.d.ts +1 -1
  363. package/lib/components/Select/Select.test-ids.d.ts.map +1 -1
  364. package/lib/components/Select/Select.test-ids.js +2 -1
  365. package/lib/components/Select/Select.test-ids.js.map +1 -1
  366. package/lib/components/Skeleton/LineSkeleton.d.ts +2 -2
  367. package/lib/components/Skeleton/LineSkeleton.js.map +1 -1
  368. package/lib/components/Skeleton/RectangleSkeleton.d.ts +3 -3
  369. package/lib/components/Skeleton/RectangleSkeleton.js.map +1 -1
  370. package/lib/components/Slider/Slider.js +1 -1
  371. package/lib/components/Slider/Slider.js.map +1 -1
  372. package/lib/components/Slider/Slider.styles.d.ts.map +1 -1
  373. package/lib/components/Slider/Slider.styles.js +114 -128
  374. package/lib/components/Slider/Slider.styles.js.map +1 -1
  375. package/lib/components/Slider/Slider.test-ids.d.ts +1 -1
  376. package/lib/components/Slider/Slider.test-ids.d.ts.map +1 -1
  377. package/lib/components/Slider/Slider.test-ids.js +2 -1
  378. package/lib/components/Slider/Slider.test-ids.js.map +1 -1
  379. package/lib/components/Slider/Slider.types.d.ts +3 -9
  380. package/lib/components/Slider/Slider.types.d.ts.map +1 -1
  381. package/lib/components/Slider/Slider.types.js.map +1 -1
  382. package/lib/components/Slider/utils.d.ts.map +1 -1
  383. package/lib/components/Slider/utils.js +0 -1
  384. package/lib/components/Slider/utils.js.map +1 -1
  385. package/lib/components/SummaryItem/SummaryItem.d.ts +2 -1
  386. package/lib/components/SummaryItem/SummaryItem.d.ts.map +1 -1
  387. package/lib/components/SummaryItem/SummaryItem.js.map +1 -1
  388. package/lib/components/SummaryItem/SummaryItem.test-ids.d.ts +1 -1
  389. package/lib/components/SummaryItem/SummaryItem.test-ids.d.ts.map +1 -1
  390. package/lib/components/SummaryList/SummaryList.d.ts +2 -2
  391. package/lib/components/SummaryList/SummaryList.d.ts.map +1 -1
  392. package/lib/components/SummaryList/SummaryList.js.map +1 -1
  393. package/lib/components/Table/Table.d.ts +1 -1
  394. package/lib/components/Table/Table.js.map +1 -1
  395. package/lib/components/Tabs/Tab.d.ts.map +1 -1
  396. package/lib/components/Tabs/Tab.js +21 -18
  397. package/lib/components/Tabs/Tab.js.map +1 -1
  398. package/lib/components/Tabs/TabPanel.d.ts +1 -1
  399. package/lib/components/Tabs/TabPanel.d.ts.map +1 -1
  400. package/lib/components/Tabs/TabPanel.js.map +1 -1
  401. package/lib/components/Tabs/Tabs.types.d.ts +1 -1
  402. package/lib/components/Tabs/Tabs.types.js.map +1 -1
  403. package/lib/components/Text/Text.d.ts +2 -4
  404. package/lib/components/Text/Text.d.ts.map +1 -1
  405. package/lib/components/Text/Text.js.map +1 -1
  406. package/lib/components/TextArea/TextArea.js +1 -1
  407. package/lib/components/TextArea/TextArea.js.map +1 -1
  408. package/lib/components/TextArea/TextArea.test-ids.d.ts +1 -1
  409. package/lib/components/TextArea/TextArea.test-ids.d.ts.map +1 -1
  410. package/lib/components/TextArea/TextArea.test-ids.js +2 -1
  411. package/lib/components/TextArea/TextArea.test-ids.js.map +1 -1
  412. package/lib/components/Toaster/Toaster.types.d.ts +1 -1
  413. package/lib/components/Toaster/Toaster.types.d.ts.map +1 -1
  414. package/lib/components/Toaster/Toaster.types.js.map +1 -1
  415. package/lib/components/Tooltip/Tooltip.d.ts +3 -3
  416. package/lib/components/Tooltip/Tooltip.js.map +1 -1
  417. package/lib/components/URL/URLDisplay.d.ts +1 -1
  418. package/lib/components/URL/URLDisplay.js +2 -2
  419. package/lib/components/URL/URLDisplay.js.map +1 -1
  420. package/lib/hooks/index.d.ts +1 -0
  421. package/lib/hooks/index.d.ts.map +1 -1
  422. package/lib/hooks/index.js +1 -0
  423. package/lib/hooks/index.js.map +1 -1
  424. package/lib/hooks/useArrows.js +1 -1
  425. package/lib/hooks/useArrows.js.map +1 -1
  426. package/lib/hooks/useBreakpoint.d.ts.map +1 -1
  427. package/lib/hooks/useBreakpoint.js +4 -1
  428. package/lib/hooks/useBreakpoint.js.map +1 -1
  429. package/lib/hooks/useChToPxConversionFactor.d.ts +3 -0
  430. package/lib/hooks/useChToPxConversionFactor.d.ts.map +1 -0
  431. package/lib/hooks/useChToPxConversionFactor.js +13 -0
  432. package/lib/hooks/useChToPxConversionFactor.js.map +1 -0
  433. package/lib/hooks/useElement.d.ts +1 -1
  434. package/lib/hooks/useElement.d.ts.map +1 -1
  435. package/lib/hooks/useI18n.d.ts +13 -0
  436. package/lib/hooks/useI18n.d.ts.map +1 -1
  437. package/lib/hooks/useScrollToggle.d.ts.map +1 -1
  438. package/lib/hooks/useScrollToggle.js +0 -1
  439. package/lib/hooks/useScrollToggle.js.map +1 -1
  440. package/lib/hooks/useTestIds.d.ts +1 -1
  441. package/lib/hooks/useTestIds.d.ts.map +1 -1
  442. package/lib/hooks/useTestIds.js +3 -0
  443. package/lib/hooks/useTestIds.js.map +1 -1
  444. package/lib/i18n/default.d.ts +13 -0
  445. package/lib/i18n/default.d.ts.map +1 -1
  446. package/lib/i18n/default.js +14 -0
  447. package/lib/i18n/default.js.map +1 -1
  448. package/lib/i18n/i18n.d.ts +13 -0
  449. package/lib/i18n/i18n.d.ts.map +1 -1
  450. package/lib/i18n/translate.d.ts +2 -6
  451. package/lib/i18n/translate.d.ts.map +1 -1
  452. package/lib/i18n/translate.js.map +1 -1
  453. package/lib/styles/gradients.d.ts.map +1 -1
  454. package/lib/styles/gradients.js.map +1 -1
  455. package/lib/theme/ThemeMachine.js.map +1 -1
  456. package/lib/types/types.d.ts +7 -2
  457. package/lib/types/types.d.ts.map +1 -1
  458. package/lib/types/types.js.map +1 -1
  459. package/lib/utils/createTestIds.d.ts +1 -6
  460. package/lib/utils/createTestIds.d.ts.map +1 -1
  461. package/lib/utils/createTestIds.js +2 -4
  462. package/lib/utils/createTestIds.js.map +1 -1
  463. package/lib/utils/debounce.d.ts +2 -2
  464. package/lib/utils/debounce.d.ts.map +1 -1
  465. package/lib/utils/debounce.js +9 -10
  466. package/lib/utils/debounce.js.map +1 -1
  467. package/lib/utils/getEdge.d.ts +7 -0
  468. package/lib/utils/getEdge.d.ts.map +1 -0
  469. package/lib/utils/getEdge.js +9 -0
  470. package/lib/utils/getEdge.js.map +1 -0
  471. package/lib/utils/index.d.ts +2 -1
  472. package/lib/utils/index.d.ts.map +1 -1
  473. package/lib/utils/index.js +2 -0
  474. package/lib/utils/index.js.map +1 -1
  475. package/lib/utils/kebabToCamel.d.ts +1 -3
  476. package/lib/utils/kebabToCamel.d.ts.map +1 -1
  477. package/lib/utils/kebabToCamel.js +1 -3
  478. package/lib/utils/kebabToCamel.js.map +1 -1
  479. package/lib/utils/throttle.d.ts +4 -0
  480. package/lib/utils/throttle.d.ts.map +1 -0
  481. package/lib/utils/throttle.js +15 -0
  482. package/lib/utils/throttle.js.map +1 -0
  483. package/package.json +2 -2
@@ -7,7 +7,7 @@ export interface EmailDisplayProps extends BaseProps, NoChildrenProp {
7
7
  displayText?: string;
8
8
  /**
9
9
  * Controls styling of the field.
10
- * @default "link"
10
+ * @default 'link'
11
11
  */
12
12
  variant?: 'link' | 'text';
13
13
  /** Ref for the wrapping element. */
@@ -1 +1 @@
1
- {"version":3,"file":"EmailDisplay.js","sourceRoot":"","sources":["../../../src/components/Email/EmailDisplay.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAA2C,MAAM,OAAO,CAAC;AAG5E,OAAO,IAAI,MAAM,SAAS,CAAC;AAgB3B,MAAM,YAAY,GAAwD,UAAU,CAClF,CACE,EAAE,KAAK,EAAE,WAAW,EAAE,OAAO,GAAG,MAAM,EAAE,GAAG,SAAS,EAAsC,EAC1F,GAA6B,EAC7B,EAAE;IACF,MAAM,YAAY,GAAG,KAAK,CAAC,CAAC,CAAC,CAC3B,WAAW,IAAI,KAAK,CACrB,CAAC,CAAC,CAAC,CACF,8BAAkB,MAAM,6BAAsB,CAC/C,CAAC;IACF,OAAO,OAAO,KAAK,MAAM,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CACpC,eAAM,GAAG,EAAE,GAAG,KAAM,SAAS,YAC1B,YAAY,GACR,CACR,CAAC,CAAC,CAAC,CACF,KAAC,IAAI,IAAC,GAAG,EAAE,GAA6B,KAAM,SAAS,EAAE,IAAI,EAAE,UAAU,KAAK,EAAE,YAC7E,YAAY,GACR,CACR,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["import { forwardRef, FunctionComponent, PropsWithoutRef, Ref } from 'react';\n\nimport { BaseProps, ForwardProps, NoChildrenProp } from '../../types';\nimport Link from '../Link';\n\nexport interface EmailDisplayProps extends BaseProps, NoChildrenProp {\n /** Email address, no 'mailto:' scheme */\n value?: string;\n /** The text to be displayed. */\n displayText?: string;\n /**\n * Controls styling of the field.\n * @default \"link\"\n */\n variant?: 'link' | 'text';\n /** Ref for the wrapping element. */\n ref?: Ref<HTMLAnchorElement | HTMLSpanElement>;\n}\n\nconst EmailDisplay: FunctionComponent<EmailDisplayProps & ForwardProps> = forwardRef(\n (\n { value, displayText, variant = 'link', ...restProps }: PropsWithoutRef<EmailDisplayProps>,\n ref: EmailDisplayProps['ref']\n ) => {\n const displayValue = value ? (\n displayText || value\n ) : (\n <span aria-hidden='true'>&ndash;&ndash;</span>\n );\n return variant === 'text' || !value ? (\n <span ref={ref} {...restProps}>\n {displayValue}\n </span>\n ) : (\n <Link ref={ref as Ref<HTMLAnchorElement>} {...restProps} href={`mailto:${value}`}>\n {displayValue}\n </Link>\n );\n }\n);\n\nexport default EmailDisplay;\n"]}
1
+ {"version":3,"file":"EmailDisplay.js","sourceRoot":"","sources":["../../../src/components/Email/EmailDisplay.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAA2C,MAAM,OAAO,CAAC;AAG5E,OAAO,IAAI,MAAM,SAAS,CAAC;AAgB3B,MAAM,YAAY,GAAwD,UAAU,CAClF,CACE,EAAE,KAAK,EAAE,WAAW,EAAE,OAAO,GAAG,MAAM,EAAE,GAAG,SAAS,EAAsC,EAC1F,GAA6B,EAC7B,EAAE;IACF,MAAM,YAAY,GAAG,KAAK,CAAC,CAAC,CAAC,CAC3B,WAAW,IAAI,KAAK,CACrB,CAAC,CAAC,CAAC,CACF,8BAAkB,MAAM,6BAAsB,CAC/C,CAAC;IACF,OAAO,OAAO,KAAK,MAAM,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CACpC,eAAM,GAAG,EAAE,GAAG,KAAM,SAAS,YAC1B,YAAY,GACR,CACR,CAAC,CAAC,CAAC,CACF,KAAC,IAAI,IAAC,GAAG,EAAE,GAA6B,KAAM,SAAS,EAAE,IAAI,EAAE,UAAU,KAAK,EAAE,YAC7E,YAAY,GACR,CACR,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["import { forwardRef, FunctionComponent, PropsWithoutRef, Ref } from 'react';\n\nimport { BaseProps, ForwardProps, NoChildrenProp } from '../../types';\nimport Link from '../Link';\n\nexport interface EmailDisplayProps extends BaseProps, NoChildrenProp {\n /** Email address, no 'mailto:' scheme */\n value?: string;\n /** The text to be displayed. */\n displayText?: string;\n /**\n * Controls styling of the field.\n * @default 'link'\n */\n variant?: 'link' | 'text';\n /** Ref for the wrapping element. */\n ref?: Ref<HTMLAnchorElement | HTMLSpanElement>;\n}\n\nconst EmailDisplay: FunctionComponent<EmailDisplayProps & ForwardProps> = forwardRef(\n (\n { value, displayText, variant = 'link', ...restProps }: PropsWithoutRef<EmailDisplayProps>,\n ref: EmailDisplayProps['ref']\n ) => {\n const displayValue = value ? (\n displayText || value\n ) : (\n <span aria-hidden='true'>&ndash;&ndash;</span>\n );\n return variant === 'text' || !value ? (\n <span ref={ref} {...restProps}>\n {displayValue}\n </span>\n ) : (\n <Link ref={ref as Ref<HTMLAnchorElement>} {...restProps} href={`mailto:${value}`}>\n {displayValue}\n </Link>\n );\n }\n);\n\nexport default EmailDisplay;\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"EmojiPicker.styles.d.ts","sourceRoot":"","sources":["../../../src/components/EmojiPicker/EmojiPicker.styles.ts"],"names":[],"mappings":"AAMA,QAAA,MAAM,iBAAiB;gBAA4B,OAAO;SA2hBzD,CAAC;AAIF,eAAe,iBAAiB,CAAC"}
1
+ {"version":3,"file":"EmojiPicker.styles.d.ts","sourceRoot":"","sources":["../../../src/components/EmojiPicker/EmojiPicker.styles.ts"],"names":[],"mappings":"AAMA,QAAA,MAAM,iBAAiB;gBAA4B,OAAO;SAshBzD,CAAC;AAIF,eAAe,iBAAiB,CAAC"}
@@ -7,13 +7,10 @@ const StyledEmojiPicker = styled.div(({ showFooter, theme: { base: { animation:
7
7
  const secondaryTextColor = transparentize(1 - transparency['transparent-2'], palette['foreground-color']);
8
8
  const fontSizes = calculateFontSize(fontSize, fontScale);
9
9
  return css `
10
- border-radius: inherit;
11
-
12
10
  /* stylelint-disable no-descending-specificity */
13
-
14
11
  /* stylelint-disable no-duplicate-selectors */
15
-
16
12
  /* stylelint-disable selector-max-class */
13
+ border-radius: inherit;
17
14
 
18
15
  .emoji-mart,
19
16
  .emoji-mart * {
@@ -192,7 +189,6 @@ const StyledEmojiPicker = styled.div(({ showFooter, theme: { base: { animation:
192
189
  position: relative;
193
190
  position: -webkit-sticky;
194
191
  position: sticky;
195
-
196
192
  /* stylelint-enable declaration-block-no-duplicate-properties */
197
193
  }
198
194
 
@@ -230,8 +226,7 @@ const StyledEmojiPicker = styled.div(({ showFooter, theme: { base: { animation:
230
226
  .emoji-mart-emoji-native {
231
227
  /* stylelint-disable font-family-no-missing-generic-family-keyword */
232
228
  font-family: 'Segoe UI Emoji', 'Segoe UI Symbol', 'Segoe UI', 'Apple Color Emoji',
233
- 'Twemoji Mozilla', 'Noto Color Emoji', 'Android Emoji'; /* cSpell:disable-line */
234
-
229
+ 'Twemoji Mozilla', 'Noto Color Emoji', 'Android Emoji'; /* cspell:disable-line */
235
230
  /* stylelint-enable font-family-no-missing-generic-family-keyword */
236
231
  }
237
232
 
@@ -1 +1 @@
1
- {"version":3,"file":"EmojiPicker.styles.js","sourceRoot":"","sources":["../../../src/components/EmojiPicker/EmojiPicker.styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AACxD,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjE,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAE/C,MAAM,iBAAiB,GAAG,MAAM,CAAC,GAAG,CAClC,CAAC,EACC,UAAU,EACV,KAAK,EAAE,EACL,IAAI,EAAE,EACJ,SAAS,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,EAC5B,WAAW,EAAE,QAAQ,EACrB,YAAY,EAAE,SAAS,EACvB,aAAa,EAAE,UAAU,EACzB,aAAa,EAAE,UAAU,EACzB,OAAO,EACP,MAAM,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE,EAC9B,OAAO,EACP,eAAe,EAAE,YAAY,EAC7B,YAAY,EACb,EACD,UAAU,EAAE,EACV,cAAc,EAAE,EAAE,eAAe,EAAE,iBAAiB,EAAE,EACvD,EACF,EACF,EAAE,EAAE;IACH,MAAM,UAAU,GAAG,cAAc,CAAC,OAAO,CAAC,oBAAoB,CAAC,CAAC,CAAC,UAAU,CAAC;IAC5E,MAAM,kBAA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AoB,CAAC;;;;;;;gCAOzB,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;UAyB7B,YAAY;;;;;;;;;;;;;;;;;;;;;;;;KAwBjB,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,iBAAiB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAElD,eAAe,iBAAiB,CAAC","sourcesContent":["import { hideVisually, transparentize } from 'polished';\nimport styled, { css } from 'styled-components';\n\nimport { getHoverColors, calculateFontSize } from '../../styles';\nimport { defaultThemeProp } from '../../theme';\n\nconst StyledEmojiPicker = styled.div<{ showFooter: boolean }>(\n ({\n showFooter,\n theme: {\n base: {\n animation: { speed, timing },\n 'font-size': fontSize,\n 'font-scale': fontScale,\n 'font-family': fontFamily,\n 'font-weight': fontWeight,\n palette,\n shadow: { focus: focusShadow },\n spacing,\n 'border-radius': borderRadius,\n transparency\n },\n components: {\n 'search-input': { 'border-radius': searchInputRadius }\n }\n }\n }) => {\n const hoverColor = getHoverColors(palette['primary-background']).background;\n const secondaryTextColor = transparentize(\n 1 - transparency['transparent-2'],\n palette['foreground-color']\n );\n\n const fontSizes = calculateFontSize(fontSize, fontScale);\n\n return css`\n border-radius: inherit;\n\n /* stylelint-disable no-descending-specificity */\n\n /* stylelint-disable no-duplicate-selectors */\n\n /* stylelint-disable selector-max-class */\n\n .emoji-mart,\n .emoji-mart * {\n box-sizing: border-box;\n line-height: 1.15;\n }\n\n .emoji-mart {\n font-family: ${fontFamily};\n font-size: ${fontSizes.l};\n display: inline-block;\n color: ${palette['foreground-color']};\n border: 0.0625rem solid ${palette['border-line']};\n border-radius: inherit;\n background: ${palette['primary-background']};\n }\n\n .emoji-mart .emoji-mart-emoji {\n padding: calc(0.75 * ${spacing});\n }\n\n .emoji-mart-bar {\n border: 0 solid ${palette['border-line']};\n }\n .emoji-mart-bar:first-child {\n border-bottom-width: 0.0625rem;\n border-top-left-radius: inherit;\n border-top-right-radius: inherit;\n }\n .emoji-mart-bar:last-child {\n border-top-width: 0.0625rem;\n border-bottom-left-radius: inherit;\n border-bottom-right-radius: inherit;\n ${!showFooter &&\n css`\n display: none;\n `}\n }\n\n .emoji-mart-anchors {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n padding: 0 calc(0.75 * ${spacing});\n line-height: 0;\n }\n\n .emoji-mart-anchor {\n position: relative;\n display: block;\n flex: 1 1 auto;\n color: ${secondaryTextColor};\n text-align: center;\n padding: calc(1.5 * ${spacing}) calc(0.5 * ${spacing});\n overflow: hidden;\n transition: color calc(0.4 * ${speed}) ${timing['ease-out']};\n margin: 0;\n box-shadow: none;\n background: none;\n border: none;\n }\n .emoji-mart-anchor:focus {\n outline: 0;\n }\n .emoji-mart-anchor:hover,\n .emoji-mart-anchor:focus,\n .emoji-mart-anchor-selected {\n color: ${palette.interactive};\n }\n\n .emoji-mart-anchor-selected .emoji-mart-anchor-bar {\n bottom: 0;\n }\n\n .emoji-mart-anchor-bar {\n position: absolute;\n bottom: calc(-0.375 * ${spacing});\n left: 0;\n width: 100%;\n height: calc(0.375 * ${spacing});\n background-color: ${palette.interactive};\n }\n\n .emoji-mart-anchors i {\n display: inline-block;\n width: 100%;\n max-width: calc(2.75 * ${spacing});\n }\n\n .emoji-mart-anchors svg,\n .emoji-mart-anchors img {\n fill: currentColor;\n height: calc(2.25 * ${spacing});\n width: calc(2.25 * ${spacing});\n }\n\n .emoji-mart-scroll {\n overflow-y: scroll;\n overflow-x: hidden;\n height: 16.875rem;\n padding: 0 calc(0.75 * ${spacing});\n will-change: transform; /* avoids \"repaints on scroll\" in mobile Chrome */\n }\n\n .emoji-mart-search {\n padding: ${spacing};\n position: relative;\n }\n\n .emoji-mart-search input {\n font-size: ${fontSizes.l};\n color: ${palette['foreground-color']};\n display: block;\n width: 100%;\n padding: calc(0.625 * ${spacing}) calc(3.125 * ${spacing}) calc(0.75 * ${spacing})\n calc(1.25 * ${spacing});\n border-radius: calc(${borderRadius} * ${searchInputRadius});\n border: 0.0625rem solid ${palette['border-line']};\n background-color: ${palette['primary-background']};\n outline: 0;\n }\n\n .emoji-mart-search input:hover {\n border-color: ${palette['foreground-color']};\n }\n\n .emoji-mart-search input,\n .emoji-mart-search input::-webkit-search-decoration,\n .emoji-mart-search input::-webkit-search-cancel-button,\n .emoji-mart-search input::-webkit-search-results-button,\n .emoji-mart-search input::-webkit-search-results-decoration {\n /*\n remove webkit/blink styles for <input type=\"search\">\n via https://stackoverflow.com/a/9422689\n */\n -webkit-appearance: none;\n }\n\n .emoji-mart-search-icon {\n position: absolute;\n top: calc(1.875 * ${spacing});\n right: calc(2.25 * ${spacing});\n z-index: 2;\n border: none;\n background: none;\n }\n\n .emoji-mart-search-icon svg {\n fill: ${secondaryTextColor};\n }\n\n .emoji-mart-category .emoji-mart-emoji span {\n z-index: 1;\n position: relative;\n text-align: center;\n cursor: default;\n }\n\n .emoji-mart-category .emoji-mart-emoji:hover::before {\n z-index: 0;\n content: '';\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: ${hoverColor};\n border-radius: 100%;\n }\n\n .emoji-mart-category-label {\n z-index: 2;\n top: 0;\n\n /* stylelint-disable declaration-block-no-duplicate-properties */\n position: relative;\n position: -webkit-sticky;\n position: sticky;\n\n /* stylelint-enable declaration-block-no-duplicate-properties */\n }\n\n .emoji-mart-category-label span {\n display: block;\n width: 100%;\n font-weight: ${fontWeight['semi-bold']};\n padding: ${spacing} calc(0.25 * ${spacing});\n background-color: ${transparentize(0.05, palette['primary-background'])};\n }\n\n .emoji-mart-category-list {\n margin: 0;\n padding: calc(0.375 * ${spacing}) 0;\n }\n\n .emoji-mart-category-list li {\n list-style: none;\n margin: 0;\n padding: 0;\n display: inline-block;\n }\n\n .emoji-mart-emoji {\n position: relative;\n display: inline-block;\n font-size: 0;\n margin: 0;\n padding: 0;\n border: none;\n background: none;\n box-shadow: none;\n }\n\n .emoji-mart-emoji-native {\n /* stylelint-disable font-family-no-missing-generic-family-keyword */\n font-family: 'Segoe UI Emoji', 'Segoe UI Symbol', 'Segoe UI', 'Apple Color Emoji',\n 'Twemoji Mozilla', 'Noto Color Emoji', 'Android Emoji'; /* cSpell:disable-line */\n\n /* stylelint-enable font-family-no-missing-generic-family-keyword */\n }\n\n .emoji-mart-category .emoji-mart-emoji:focus,\n .emoji-mart-category .emoji-mart-emoji-native:focus,\n .emoji-mart-skin:focus,\n .emoji-mart-search input:focus {\n outline: 0;\n border-color: transparent;\n box-shadow: ${focusShadow};\n }\n\n .emoji-mart-category .emoji-mart-emoji:focus,\n .emoji-mart-category .emoji-mart-emoji-native:focus {\n border-radius: 100%;\n }\n\n .emoji-mart-no-results {\n font-size: ${fontSizes.s};\n text-align: center;\n padding-top: 4.375rem;\n color: ${secondaryTextColor};\n }\n .emoji-mart-no-results-img {\n display: block;\n margin-left: auto;\n margin-right: auto;\n width: 50%;\n }\n .emoji-mart-no-results .emoji-mart-category-label {\n display: none;\n }\n .emoji-mart-no-results .emoji-mart-no-results-label {\n margin-top: 0.2em;\n }\n .emoji-mart-no-results .emoji-mart-emoji:hover::before {\n content: none;\n }\n\n .emoji-mart-preview {\n position: relative;\n min-height: 2.5rem;\n height: fit-content;\n display: flex;\n flex-direction: row;\n align-items: center;\n }\n\n .emoji-mart-preview-emoji {\n left: calc(1.5 * ${spacing});\n }\n\n .emoji-mart-preview-data {\n left: calc(8.5 * ${spacing});\n right: calc(1.5 * ${spacing});\n word-break: break-all;\n flex: 1;\n }\n\n .emoji-mart-preview-skins {\n position: absolute;\n right: calc(3.75 * ${spacing});\n text-align: right;\n }\n\n .emoji-mart-preview-skins.custom {\n right: calc(1.25 * ${spacing});\n text-align: right;\n }\n\n .emoji-mart-preview-name {\n font-size: ${fontSizes.s};\n }\n\n .emoji-mart-preview-shortname {\n font-size: ${fontSizes.xxs};\n color: ${secondaryTextColor};\n }\n .emoji-mart-preview-shortname + .emoji-mart-preview-shortname,\n .emoji-mart-preview-shortname + .emoji-mart-preview-emoticon,\n .emoji-mart-preview-emoticon + .emoji-mart-preview-emoticon {\n margin-left: 0.5em;\n }\n\n .emoji-mart-preview-emoticon {\n font-size: ${fontSizes.xxs};\n color: ${secondaryTextColor};\n }\n\n .emoji-mart-title span {\n display: inline-block;\n vertical-align: middle;\n }\n\n .emoji-mart-title .emoji-mart-emoji {\n padding: 0;\n }\n\n .emoji-mart-title-label {\n color: ${secondaryTextColor};\n font-size: ${fontSizes.xxl};\n font-weight: ${fontWeight.normal};\n }\n\n .emoji-mart-skin-swatches {\n font-size: 0;\n padding: calc(0.25 * ${spacing}) 0;\n border: 0.0625rem solid ${palette['border-line']};\n border-radius: calc(1.5 * ${spacing});\n background-color: ${palette['secondary-background']};\n }\n\n .emoji-mart-skin-swatches.custom {\n font-size: 0;\n border: none;\n background-color: ${palette['secondary-background']};\n }\n\n .emoji-mart-skin-swatches.opened .emoji-mart-skin-swatch {\n width: calc(2 * ${spacing});\n padding: 0 calc(0.25 * ${spacing});\n }\n\n .emoji-mart-skin-swatches.opened .emoji-mart-skin-swatch.selected::after {\n opacity: ${transparency['transparent-2']};\n }\n\n .emoji-mart-skin-swatch {\n display: inline-block;\n width: 0;\n vertical-align: middle;\n transition-property: width, padding;\n transition-duration: calc(0.5 * ${speed});\n transition-timing-function: ${timing['ease-out']};\n }\n\n .emoji-mart-skin-swatch:nth-child(1) {\n transition-delay: 0s;\n }\n .emoji-mart-skin-swatch:nth-child(2) {\n transition-delay: 0.03s;\n }\n .emoji-mart-skin-swatch:nth-child(3) {\n transition-delay: 0.06s;\n }\n .emoji-mart-skin-swatch:nth-child(4) {\n transition-delay: 0.09s;\n }\n .emoji-mart-skin-swatch:nth-child(5) {\n transition-delay: 0.12s;\n }\n .emoji-mart-skin-swatch:nth-child(6) {\n transition-delay: 0.15s;\n }\n\n .emoji-mart-skin-swatch.selected {\n position: relative;\n width: calc(2 * ${spacing});\n padding: 0 calc(0.25 * ${spacing});\n }\n\n .emoji-mart-skin-swatch.selected::after {\n content: '';\n position: absolute;\n top: 50%;\n left: 50%;\n width: calc(0.5 * ${spacing});\n height: calc(0.5 * ${spacing});\n margin: calc(-0.25 * ${spacing}) 0 0 calc(-0.25 * ${spacing});\n background-color: ${palette['primary-background']};\n border-radius: 100%;\n pointer-events: none;\n opacity: 0;\n transition: opacity ${speed} ${timing['ease-out']};\n }\n\n .emoji-mart-skin-swatch.custom {\n display: inline-block;\n width: 0;\n height: 2.375rem;\n overflow: hidden;\n vertical-align: middle;\n transition-property: width, height;\n transition-duration: calc(0.5 * ${speed});\n transition-timing-function: ${timing['ease-out']};\n cursor: default;\n }\n\n .emoji-mart-skin-swatch.custom.selected {\n position: relative;\n width: 2.25rem;\n height: 2.375rem;\n padding: 0 calc(0.25 * ${spacing}) 0 0;\n }\n\n .emoji-mart-skin-swatch.custom.selected::after {\n content: '';\n width: 0;\n height: 0;\n }\n\n .emoji-mart-skin-swatches.custom .emoji-mart-skin-swatch.custom:hover {\n background-color: ${palette['primary-background']};\n border-radius: 10%;\n }\n\n .emoji-mart-skin-swatches.custom.opened .emoji-mart-skin-swatch.custom {\n width: 2.25rem;\n height: 2.375rem;\n padding: 0 calc(0.25 * ${spacing}) 0 0;\n }\n\n .emoji-mart-skin-swatches.custom.opened .emoji-mart-skin-swatch.custom.selected::after {\n opacity: ${transparency['transparent-2']};\n }\n\n .emoji-mart-skin-text.opened {\n display: inline-block;\n vertical-align: middle;\n text-align: left;\n color: ${secondaryTextColor};\n font-size: ${fontSizes.xxs};\n padding: calc(0.625 * ${spacing}) calc(0.25 * ${spacing});\n width: 6rem;\n height: 2.5rem;\n border-radius: 10%;\n background-color: ${palette['primary-background']};\n }\n\n .emoji-mart-skin {\n display: inline-block;\n width: 100%;\n padding-top: 100%;\n max-width: calc(1.5 * ${spacing});\n border-radius: 100%;\n }\n\n .emoji-mart-skin-tone-1 {\n background-color: #ffc93a;\n }\n .emoji-mart-skin-tone-2 {\n background-color: #fadcbc;\n }\n .emoji-mart-skin-tone-3 {\n background-color: #e0bb95;\n }\n .emoji-mart-skin-tone-4 {\n background-color: #bf8f68;\n }\n .emoji-mart-skin-tone-5 {\n background-color: #9b643d;\n }\n .emoji-mart-skin-tone-6 {\n background-color: #594539;\n }\n\n /* For screen readers only */\n .emoji-mart-sr-only {\n ${hideVisually}\n }\n\n /*\n https://github.com/missive/emoji-mart/issues/319\n https://github.com/missive/emoji-mart/pull/442\n */\n .emoji-mart-emoji-native {\n height: var(--emoji-size);\n width: var(--emoji-size);\n position: relative;\n display: inline-block;\n box-sizing: content-box;\n vertical-align: bottom;\n }\n\n .emoji-mart-emoji-native > span {\n position: absolute !important;\n top: 50%;\n left: 50%;\n height: initial !important;\n width: initial !important;\n transform: translate(-50%, -50%);\n }\n `;\n }\n);\n\nStyledEmojiPicker.defaultProps = defaultThemeProp;\n\nexport default StyledEmojiPicker;\n"]}
1
+ {"version":3,"file":"EmojiPicker.styles.js","sourceRoot":"","sources":["../../../src/components/EmojiPicker/EmojiPicker.styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AACxD,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjE,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAE/C,MAAM,iBAAiB,GAAG,MAAM,CAAC,GAAG,CAClC,CAAC,EACC,UAAU,EACV,KAAK,EAAE,EACL,IAAI,EAAE,EACJ,SAAS,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,EAC5B,WAAW,EAAE,QAAQ,EACrB,YAAY,EAAE,SAAS,EACvB,aAAa,EAAE,UAAU,EACzB,aAAa,EAAE,UAAU,EACzB,OAAO,EACP,MAAM,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE,EAC9B,OAAO,EACP,eAAe,EAAE,YAAY,EAC7B,YAAY,EACb,EACD,UAAU,EAAE,EACV,cAAc,EAAE,EAAE,eAAe,EAAE,iBAAiB,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IrB,YAAY,CAAC,eAAe,CAAC;;;;;;;iBAO/B,kBAAkB;qBACd,SAAS,CAAC,GAAG;gCACF,OAAO,iBAAiB,OAAO;;;;4BAInC,OAAO,CAAC,oBAAoB,CAAC;;;;;;;gCAOzB,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;UAyB7B,YAAY;;;;;;;;;;;;;;;;;;;;;;;;KAwBjB,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,iBAAiB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAElD,eAAe,iBAAiB,CAAC","sourcesContent":["import { hideVisually, transparentize } from 'polished';\nimport styled, { css } from 'styled-components';\n\nimport { getHoverColors, calculateFontSize } from '../../styles';\nimport { defaultThemeProp } from '../../theme';\n\nconst StyledEmojiPicker = styled.div<{ showFooter: boolean }>(\n ({\n showFooter,\n theme: {\n base: {\n animation: { speed, timing },\n 'font-size': fontSize,\n 'font-scale': fontScale,\n 'font-family': fontFamily,\n 'font-weight': fontWeight,\n palette,\n shadow: { focus: focusShadow },\n spacing,\n 'border-radius': borderRadius,\n transparency\n },\n components: {\n 'search-input': { 'border-radius': searchInputRadius }\n }\n }\n }) => {\n const hoverColor = getHoverColors(palette['primary-background']).background;\n const secondaryTextColor = transparentize(\n 1 - transparency['transparent-2'],\n palette['foreground-color']\n );\n\n const fontSizes = calculateFontSize(fontSize, fontScale);\n\n return css`\n /* stylelint-disable no-descending-specificity */\n /* stylelint-disable no-duplicate-selectors */\n /* stylelint-disable selector-max-class */\n border-radius: inherit;\n\n .emoji-mart,\n .emoji-mart * {\n box-sizing: border-box;\n line-height: 1.15;\n }\n\n .emoji-mart {\n font-family: ${fontFamily};\n font-size: ${fontSizes.l};\n display: inline-block;\n color: ${palette['foreground-color']};\n border: 0.0625rem solid ${palette['border-line']};\n border-radius: inherit;\n background: ${palette['primary-background']};\n }\n\n .emoji-mart .emoji-mart-emoji {\n padding: calc(0.75 * ${spacing});\n }\n\n .emoji-mart-bar {\n border: 0 solid ${palette['border-line']};\n }\n .emoji-mart-bar:first-child {\n border-bottom-width: 0.0625rem;\n border-top-left-radius: inherit;\n border-top-right-radius: inherit;\n }\n .emoji-mart-bar:last-child {\n border-top-width: 0.0625rem;\n border-bottom-left-radius: inherit;\n border-bottom-right-radius: inherit;\n ${!showFooter &&\n css`\n display: none;\n `}\n }\n\n .emoji-mart-anchors {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n padding: 0 calc(0.75 * ${spacing});\n line-height: 0;\n }\n\n .emoji-mart-anchor {\n position: relative;\n display: block;\n flex: 1 1 auto;\n color: ${secondaryTextColor};\n text-align: center;\n padding: calc(1.5 * ${spacing}) calc(0.5 * ${spacing});\n overflow: hidden;\n transition: color calc(0.4 * ${speed}) ${timing['ease-out']};\n margin: 0;\n box-shadow: none;\n background: none;\n border: none;\n }\n .emoji-mart-anchor:focus {\n outline: 0;\n }\n .emoji-mart-anchor:hover,\n .emoji-mart-anchor:focus,\n .emoji-mart-anchor-selected {\n color: ${palette.interactive};\n }\n\n .emoji-mart-anchor-selected .emoji-mart-anchor-bar {\n bottom: 0;\n }\n\n .emoji-mart-anchor-bar {\n position: absolute;\n bottom: calc(-0.375 * ${spacing});\n left: 0;\n width: 100%;\n height: calc(0.375 * ${spacing});\n background-color: ${palette.interactive};\n }\n\n .emoji-mart-anchors i {\n display: inline-block;\n width: 100%;\n max-width: calc(2.75 * ${spacing});\n }\n\n .emoji-mart-anchors svg,\n .emoji-mart-anchors img {\n fill: currentColor;\n height: calc(2.25 * ${spacing});\n width: calc(2.25 * ${spacing});\n }\n\n .emoji-mart-scroll {\n overflow-y: scroll;\n overflow-x: hidden;\n height: 16.875rem;\n padding: 0 calc(0.75 * ${spacing});\n will-change: transform; /* avoids \"repaints on scroll\" in mobile Chrome */\n }\n\n .emoji-mart-search {\n padding: ${spacing};\n position: relative;\n }\n\n .emoji-mart-search input {\n font-size: ${fontSizes.l};\n color: ${palette['foreground-color']};\n display: block;\n width: 100%;\n padding: calc(0.625 * ${spacing}) calc(3.125 * ${spacing}) calc(0.75 * ${spacing})\n calc(1.25 * ${spacing});\n border-radius: calc(${borderRadius} * ${searchInputRadius});\n border: 0.0625rem solid ${palette['border-line']};\n background-color: ${palette['primary-background']};\n outline: 0;\n }\n\n .emoji-mart-search input:hover {\n border-color: ${palette['foreground-color']};\n }\n\n .emoji-mart-search input,\n .emoji-mart-search input::-webkit-search-decoration,\n .emoji-mart-search input::-webkit-search-cancel-button,\n .emoji-mart-search input::-webkit-search-results-button,\n .emoji-mart-search input::-webkit-search-results-decoration {\n /*\n remove webkit/blink styles for <input type=\"search\">\n via https://stackoverflow.com/a/9422689\n */\n -webkit-appearance: none;\n }\n\n .emoji-mart-search-icon {\n position: absolute;\n top: calc(1.875 * ${spacing});\n right: calc(2.25 * ${spacing});\n z-index: 2;\n border: none;\n background: none;\n }\n\n .emoji-mart-search-icon svg {\n fill: ${secondaryTextColor};\n }\n\n .emoji-mart-category .emoji-mart-emoji span {\n z-index: 1;\n position: relative;\n text-align: center;\n cursor: default;\n }\n\n .emoji-mart-category .emoji-mart-emoji:hover::before {\n z-index: 0;\n content: '';\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background-color: ${hoverColor};\n border-radius: 100%;\n }\n\n .emoji-mart-category-label {\n z-index: 2;\n top: 0;\n\n /* stylelint-disable declaration-block-no-duplicate-properties */\n position: relative;\n position: -webkit-sticky;\n position: sticky;\n /* stylelint-enable declaration-block-no-duplicate-properties */\n }\n\n .emoji-mart-category-label span {\n display: block;\n width: 100%;\n font-weight: ${fontWeight['semi-bold']};\n padding: ${spacing} calc(0.25 * ${spacing});\n background-color: ${transparentize(0.05, palette['primary-background'])};\n }\n\n .emoji-mart-category-list {\n margin: 0;\n padding: calc(0.375 * ${spacing}) 0;\n }\n\n .emoji-mart-category-list li {\n list-style: none;\n margin: 0;\n padding: 0;\n display: inline-block;\n }\n\n .emoji-mart-emoji {\n position: relative;\n display: inline-block;\n font-size: 0;\n margin: 0;\n padding: 0;\n border: none;\n background: none;\n box-shadow: none;\n }\n\n .emoji-mart-emoji-native {\n /* stylelint-disable font-family-no-missing-generic-family-keyword */\n font-family: 'Segoe UI Emoji', 'Segoe UI Symbol', 'Segoe UI', 'Apple Color Emoji',\n 'Twemoji Mozilla', 'Noto Color Emoji', 'Android Emoji'; /* cspell:disable-line */\n /* stylelint-enable font-family-no-missing-generic-family-keyword */\n }\n\n .emoji-mart-category .emoji-mart-emoji:focus,\n .emoji-mart-category .emoji-mart-emoji-native:focus,\n .emoji-mart-skin:focus,\n .emoji-mart-search input:focus {\n outline: 0;\n border-color: transparent;\n box-shadow: ${focusShadow};\n }\n\n .emoji-mart-category .emoji-mart-emoji:focus,\n .emoji-mart-category .emoji-mart-emoji-native:focus {\n border-radius: 100%;\n }\n\n .emoji-mart-no-results {\n font-size: ${fontSizes.s};\n text-align: center;\n padding-top: 4.375rem;\n color: ${secondaryTextColor};\n }\n .emoji-mart-no-results-img {\n display: block;\n margin-left: auto;\n margin-right: auto;\n width: 50%;\n }\n .emoji-mart-no-results .emoji-mart-category-label {\n display: none;\n }\n .emoji-mart-no-results .emoji-mart-no-results-label {\n margin-top: 0.2em;\n }\n .emoji-mart-no-results .emoji-mart-emoji:hover::before {\n content: none;\n }\n\n .emoji-mart-preview {\n position: relative;\n min-height: 2.5rem;\n height: fit-content;\n display: flex;\n flex-direction: row;\n align-items: center;\n }\n\n .emoji-mart-preview-emoji {\n left: calc(1.5 * ${spacing});\n }\n\n .emoji-mart-preview-data {\n left: calc(8.5 * ${spacing});\n right: calc(1.5 * ${spacing});\n word-break: break-all;\n flex: 1;\n }\n\n .emoji-mart-preview-skins {\n position: absolute;\n right: calc(3.75 * ${spacing});\n text-align: right;\n }\n\n .emoji-mart-preview-skins.custom {\n right: calc(1.25 * ${spacing});\n text-align: right;\n }\n\n .emoji-mart-preview-name {\n font-size: ${fontSizes.s};\n }\n\n .emoji-mart-preview-shortname {\n font-size: ${fontSizes.xxs};\n color: ${secondaryTextColor};\n }\n .emoji-mart-preview-shortname + .emoji-mart-preview-shortname,\n .emoji-mart-preview-shortname + .emoji-mart-preview-emoticon,\n .emoji-mart-preview-emoticon + .emoji-mart-preview-emoticon {\n margin-left: 0.5em;\n }\n\n .emoji-mart-preview-emoticon {\n font-size: ${fontSizes.xxs};\n color: ${secondaryTextColor};\n }\n\n .emoji-mart-title span {\n display: inline-block;\n vertical-align: middle;\n }\n\n .emoji-mart-title .emoji-mart-emoji {\n padding: 0;\n }\n\n .emoji-mart-title-label {\n color: ${secondaryTextColor};\n font-size: ${fontSizes.xxl};\n font-weight: ${fontWeight.normal};\n }\n\n .emoji-mart-skin-swatches {\n font-size: 0;\n padding: calc(0.25 * ${spacing}) 0;\n border: 0.0625rem solid ${palette['border-line']};\n border-radius: calc(1.5 * ${spacing});\n background-color: ${palette['secondary-background']};\n }\n\n .emoji-mart-skin-swatches.custom {\n font-size: 0;\n border: none;\n background-color: ${palette['secondary-background']};\n }\n\n .emoji-mart-skin-swatches.opened .emoji-mart-skin-swatch {\n width: calc(2 * ${spacing});\n padding: 0 calc(0.25 * ${spacing});\n }\n\n .emoji-mart-skin-swatches.opened .emoji-mart-skin-swatch.selected::after {\n opacity: ${transparency['transparent-2']};\n }\n\n .emoji-mart-skin-swatch {\n display: inline-block;\n width: 0;\n vertical-align: middle;\n transition-property: width, padding;\n transition-duration: calc(0.5 * ${speed});\n transition-timing-function: ${timing['ease-out']};\n }\n\n .emoji-mart-skin-swatch:nth-child(1) {\n transition-delay: 0s;\n }\n .emoji-mart-skin-swatch:nth-child(2) {\n transition-delay: 0.03s;\n }\n .emoji-mart-skin-swatch:nth-child(3) {\n transition-delay: 0.06s;\n }\n .emoji-mart-skin-swatch:nth-child(4) {\n transition-delay: 0.09s;\n }\n .emoji-mart-skin-swatch:nth-child(5) {\n transition-delay: 0.12s;\n }\n .emoji-mart-skin-swatch:nth-child(6) {\n transition-delay: 0.15s;\n }\n\n .emoji-mart-skin-swatch.selected {\n position: relative;\n width: calc(2 * ${spacing});\n padding: 0 calc(0.25 * ${spacing});\n }\n\n .emoji-mart-skin-swatch.selected::after {\n content: '';\n position: absolute;\n top: 50%;\n left: 50%;\n width: calc(0.5 * ${spacing});\n height: calc(0.5 * ${spacing});\n margin: calc(-0.25 * ${spacing}) 0 0 calc(-0.25 * ${spacing});\n background-color: ${palette['primary-background']};\n border-radius: 100%;\n pointer-events: none;\n opacity: 0;\n transition: opacity ${speed} ${timing['ease-out']};\n }\n\n .emoji-mart-skin-swatch.custom {\n display: inline-block;\n width: 0;\n height: 2.375rem;\n overflow: hidden;\n vertical-align: middle;\n transition-property: width, height;\n transition-duration: calc(0.5 * ${speed});\n transition-timing-function: ${timing['ease-out']};\n cursor: default;\n }\n\n .emoji-mart-skin-swatch.custom.selected {\n position: relative;\n width: 2.25rem;\n height: 2.375rem;\n padding: 0 calc(0.25 * ${spacing}) 0 0;\n }\n\n .emoji-mart-skin-swatch.custom.selected::after {\n content: '';\n width: 0;\n height: 0;\n }\n\n .emoji-mart-skin-swatches.custom .emoji-mart-skin-swatch.custom:hover {\n background-color: ${palette['primary-background']};\n border-radius: 10%;\n }\n\n .emoji-mart-skin-swatches.custom.opened .emoji-mart-skin-swatch.custom {\n width: 2.25rem;\n height: 2.375rem;\n padding: 0 calc(0.25 * ${spacing}) 0 0;\n }\n\n .emoji-mart-skin-swatches.custom.opened .emoji-mart-skin-swatch.custom.selected::after {\n opacity: ${transparency['transparent-2']};\n }\n\n .emoji-mart-skin-text.opened {\n display: inline-block;\n vertical-align: middle;\n text-align: left;\n color: ${secondaryTextColor};\n font-size: ${fontSizes.xxs};\n padding: calc(0.625 * ${spacing}) calc(0.25 * ${spacing});\n width: 6rem;\n height: 2.5rem;\n border-radius: 10%;\n background-color: ${palette['primary-background']};\n }\n\n .emoji-mart-skin {\n display: inline-block;\n width: 100%;\n padding-top: 100%;\n max-width: calc(1.5 * ${spacing});\n border-radius: 100%;\n }\n\n .emoji-mart-skin-tone-1 {\n background-color: #ffc93a;\n }\n .emoji-mart-skin-tone-2 {\n background-color: #fadcbc;\n }\n .emoji-mart-skin-tone-3 {\n background-color: #e0bb95;\n }\n .emoji-mart-skin-tone-4 {\n background-color: #bf8f68;\n }\n .emoji-mart-skin-tone-5 {\n background-color: #9b643d;\n }\n .emoji-mart-skin-tone-6 {\n background-color: #594539;\n }\n\n /* For screen readers only */\n .emoji-mart-sr-only {\n ${hideVisually}\n }\n\n /*\n https://github.com/missive/emoji-mart/issues/319\n https://github.com/missive/emoji-mart/pull/442\n */\n .emoji-mart-emoji-native {\n height: var(--emoji-size);\n width: var(--emoji-size);\n position: relative;\n display: inline-block;\n box-sizing: content-box;\n vertical-align: bottom;\n }\n\n .emoji-mart-emoji-native > span {\n position: absolute !important;\n top: 50%;\n left: 50%;\n height: initial !important;\n width: initial !important;\n transform: translate(-50%, -50%);\n }\n `;\n }\n);\n\nStyledEmojiPicker.defaultProps = defaultThemeProp;\n\nexport default StyledEmojiPicker;\n"]}
@@ -10,24 +10,24 @@ export interface ExpandCollapseProps extends AsProp, BaseProps {
10
10
  collapsed?: boolean;
11
11
  /**
12
12
  * Used to determine the transition property.
13
- * @default "height"
13
+ * @default 'height'
14
14
  */
15
15
  dimension?: 'height' | 'width';
16
16
  /** Minimum height/width to collapse to. This will set the starting collapsed size as well. */
17
17
  min?: string;
18
18
  /** Maximum height/width to expand to. Expanded state will expanded up until, but not beyond, the natural height/width of the element. */
19
19
  max?: string;
20
- /** Callback fired after content collapsed. */
20
+ /** Callback fired after content collapsed. */
21
21
  onAfterCollapse?: () => void;
22
- /** Callback fired after content expanded. */
22
+ /** Callback fired after content expanded. */
23
23
  onAfterExpand?: () => void;
24
- /** Callback fired before content collapsed. */
24
+ /** Callback fired before content collapsed. */
25
25
  onBeforeCollapse?: () => void;
26
- /** Callback fired before content expanded. */
26
+ /** Callback fired before content expanded. */
27
27
  onBeforeExpand?: () => void;
28
28
  /**
29
29
  * Determine the speed of animation. This value comes from `theme.base.animation.speed`.
30
- * @default "0.25s"
30
+ * @default '0.25s'
31
31
  */
32
32
  transitionSpeed?: string;
33
33
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"ExpandCollapse.d.ts","sourceRoot":"","sources":["../../../src/components/ExpandCollapse/ExpandCollapse.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EAGjB,SAAS,EAMV,MAAM,OAAO,CAAC;AAEf,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,EAAqB,MAAM,aAAa,CAAC;AAGjF,MAAM,WAAW,mBAAoB,SAAQ,MAAM,EAAE,SAAS;IAC5D,kCAAkC;IAClC,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;OAGG;IACH,SAAS,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC;IAC/B,8FAA8F;IAC9F,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,yIAAyI;IACzI,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,gDAAgD;IAChD,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;IAC7B,+CAA+C;IAC/C,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B,iDAAiD;IACjD,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC9B,+CAA+C;IAC/C,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;IAC5B;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB;;;OAGG;IACH,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B;AAmED,QAAA,MAAM,cAAc,EAAE,iBAAiB,CAAC,mBAAmB,GAAG,YAAY,CA0FzE,CAAC;AAEF,eAAe,cAAc,CAAC"}
1
+ {"version":3,"file":"ExpandCollapse.d.ts","sourceRoot":"","sources":["../../../src/components/ExpandCollapse/ExpandCollapse.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EAGjB,SAAS,EAMV,MAAM,OAAO,CAAC;AAE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C;YACf,SAAS;YACT,GAAG;YACH,GAAG;YACH,eAAe;YACf,iBAAiB;YACjB,MAAM,EAAE,MAAM,KAAK,WAAW,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,WAAW;YAC3D,EAAE,EAAE,GAAG,CAAC,OAAO;YACf,wBAAwB,EAAE,cAAc,CAAC,MAAM,CAAC,IAAI;SACrD,CAAC,CAAC;KACJ;IAED,OAAO,MAAM,KAAK,WAAW,IAAI,iBAAiB,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAClE,KAAC,GAAG,IAAC,GAAG,EAAE,GAAG,EAAE,eAAe,EAAE,eAAe,KAAM,SAAS,EAAE,KAAK,EAAE,KAAK,YACzE,QAAQ,GACL,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,cAAc,CAAC","sourcesContent":["import {\n FunctionComponent,\n Ref,\n forwardRef,\n ReactNode,\n PropsWithoutRef,\n useState,\n useLayoutEffect,\n useCallback,\n CSSProperties\n} from 'react';\n\nimport { ForwardProps, BaseProps, AsProp, PropsWithDefaults } from '../../types';\nimport { useConsolidatedRef, usePrevious, useTheme } from '../../hooks';\n\nexport interface ExpandCollapseProps extends AsProp, BaseProps {\n /** Content to expand/collapse. */\n children?: ReactNode;\n /**\n * If true,the content will be hidden.\n * @default false\n */\n collapsed?: boolean;\n /**\n * Used to determine the transition property.\n * @default \"height\"\n */\n dimension?: 'height' | 'width';\n /** Minimum height/width to collapse to. This will set the starting collapsed size as well. */\n min?: string;\n /** Maximum height/width to expand to. Expanded state will expanded up until, but not beyond, the natural height/width of the element. */\n max?: string;\n /** Callback fired after content collapsed. */\n onAfterCollapse?: () => void;\n /** Callback fired after content expanded. */\n onAfterExpand?: () => void;\n /** Callback fired before content collapsed. */\n onBeforeCollapse?: () => void;\n /** Callback fired before content expanded. */\n onBeforeExpand?: () => void;\n /**\n * Determine the speed of animation. This value comes from `theme.base.animation.speed`.\n * @default \"0.25s\"\n */\n transitionSpeed?: string;\n /**\n * If true, removes the component from the real DOM when collapsed. For full virtual DOM unmount(if necessary), perform at a parent level.\n * @default false\n */\n nullWhenCollapsed?: boolean;\n}\n\ntype ExpandCollapsePropsWithDefaults = PropsWithDefaults<\n ExpandCollapseProps,\n 'collapsed' | 'dimension' | 'transitionSpeed' | 'nullWhenCollapsed'\n>;\n\ntype Statuses = 'collapsed' | 'collapsing' | 'expanded' | 'expanding';\n\ninterface GetStyleProps\n extends Pick<\n ExpandCollapsePropsWithDefaults,\n 'dimension' | 'transitionSpeed' | 'min' | 'max' | 'nullWhenCollapsed'\n > {\n status: Statuses;\n el?: HTMLElement | null;\n transitionTimingFunction?: string;\n}\n\nconst getScrollSize = (\n el: HTMLElement,\n dimension: ExpandCollapsePropsWithDefaults['dimension']\n): string => {\n if (!el) return '';\n return dimension === 'height' ? `${el.scrollHeight}px` : `${el.scrollWidth}px`;\n};\n\nconst getStyle = (props: GetStyleProps): CSSProperties => {\n const {\n status,\n dimension,\n transitionSpeed,\n transitionTimingFunction,\n min,\n max,\n nullWhenCollapsed,\n el\n } = props;\n const style: CSSProperties = {};\n let maxSize = max;\n\n if (el && !max) {\n maxSize = getScrollSize(el, dimension!);\n }\n\n if (status === 'expanded' || status === 'collapsed') {\n if (max || min) {\n style[dimension as 'height' | 'width'] = status === 'expanded' ? maxSize : min || 0;\n style[`overflow${dimension === 'width' ? 'X' : 'Y'}`] = 'hidden';\n }\n\n if (status === 'collapsed' && !nullWhenCollapsed && !min) {\n style.display = 'none';\n }\n }\n\n if (status === 'expanding' || status === 'collapsing') {\n style[dimension as 'height' | 'width'] = status === 'expanding' ? maxSize : min || 0;\n style.overflow = 'hidden';\n style.transitionProperty = dimension;\n style.transitionDuration = `max(${transitionSpeed}, 0.01ms)`;\n style.transitionTimingFunction = transitionTimingFunction;\n }\n\n return style;\n};\n\nconst ExpandCollapse: FunctionComponent<ExpandCollapseProps & ForwardProps> = forwardRef(\n (props: PropsWithoutRef<ExpandCollapseProps>, refArg: Ref<HTMLElement>) => {\n const {\n base: { animation: themeAnimation }\n } = useTheme();\n\n const {\n children,\n dimension = 'height',\n collapsed = false,\n onBeforeExpand,\n onAfterExpand,\n onBeforeCollapse,\n onAfterCollapse,\n transitionSpeed = themeAnimation.speed,\n min,\n max,\n nullWhenCollapsed = false,\n as: Tag = 'div',\n ...restProps\n } = props;\n\n const [status, setStatus] = useState<Statuses>(collapsed ? 'collapsed' : 'expanded');\n const styleStateHook = useState<CSSProperties>();\n const setStyle = styleStateHook[1];\n let style = styleStateHook[0];\n const previousStatus = usePrevious(status);\n const ref = useConsolidatedRef(refArg);\n\n const onTransitionEnd = useCallback(\n (e: TransitionEvent) => {\n if (e.target !== ref.current || e.propertyName !== dimension) return;\n setStatus(status === 'expanding' ? 'expanded' : 'collapsed');\n },\n [ref.current, status]\n );\n\n useLayoutEffect(() => {\n const wantsToCollapse = collapsed;\n const wantsToExpand = !collapsed;\n const canCollapse = ['expanded', 'expanding'].includes(status);\n const canExpand = ['collapsed', 'collapsing'].includes(status);\n\n if (wantsToExpand && canExpand) {\n onBeforeExpand?.();\n setStatus('expanding');\n } else if (wantsToCollapse && canCollapse) {\n onBeforeCollapse?.();\n setStatus('collapsing');\n }\n\n if (status === 'expanded' && previousStatus !== 'expanded') {\n onAfterExpand?.();\n } else if (status === 'collapsed' && previousStatus !== 'collapsed') {\n onAfterCollapse?.();\n }\n\n setStyle(\n getStyle({\n dimension,\n min,\n max,\n transitionSpeed,\n nullWhenCollapsed,\n status,\n el: ref.current,\n transitionTimingFunction: themeAnimation.timing.ease\n })\n );\n }, [collapsed, status, min, max]);\n\n if (status !== previousStatus && ['expanded', 'collapsed'].includes(previousStatus!)) {\n style = getStyle({\n dimension,\n min,\n max,\n transitionSpeed,\n nullWhenCollapsed,\n status: status === 'expanding' ? 'collapsing' : 'expanding',\n el: ref.current,\n transitionTimingFunction: themeAnimation.timing.ease\n });\n }\n\n return status === 'collapsed' && nullWhenCollapsed && !min ? null : (\n <Tag ref={ref} onTransitionEnd={onTransitionEnd} {...restProps} style={style}>\n {children}\n </Tag>\n );\n }\n);\n\nexport default ExpandCollapse;\n"]}
1
+ {"version":3,"file":"ExpandCollapse.js","sourceRoot":"","sources":["../../../src/components/ExpandCollapse/ExpandCollapse.tsx"],"names":[],"mappings":";AAAA,OAAO,EAGL,UAAU,EAGV,QAAQ,EACR,eAAe,EACf,WAAW,EAEZ,MAAM,OAAO,CAAC;AAGf,OAAO,EAAE,kBAAkB,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAwDxE,MAAM,aAAa,GAAG,CACpB,EAAe,EACf,SAAuD,EAC/C,EAAE;IACV,IAAI,CAAC,EAAE;QAAE,OAAO,EAAE,CAAC;IACnB,OAAO,SAAS,KAAK,QAAQ,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC,YAAY,IAAI,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC,WAAW,IAAI,CAAC;AACjF,CAAC,CAAC;AAEF,MAAM,QAAQ,GAAG,CAAC,KAAoB,EAAiB,EAAE;IACvD,MAAM,EACJ,MAAM,EACN,SAAS,EACT,eAAe,EACf,wBAAwB,EACxB,GAAG,EACH,GAAG,EACH,iBAAiB,EACjB,EAAE,EACH,GAAG,KAAK,CAAC;IACV,MAAM,KAAK,GAAkB,EAAE,CAAC;IAChC,IAAI,OAAO,GAAG,GAAG,CAAC;IAElB,IAAI,EAAE,IAAI,CAAC,GAAG,EAAE;QACd,OAAO,GAAG,aAAa,CAAC,EAAE,EAAE,SAAU,CAAC,CAAC;KACzC;IAED,IAAI,MAAM,KAAK,UAAU,IAAI,MAAM,KAAK,WAAW,EAAE;QACnD,IAAI,GAAG,IAAI,GAAG,EAAE;YACd,KAAK,CAAC,SAA+B,CAAC,GAAG,MAAM,KAAK,UAAU,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC;YACpF,KAAK,CAAC,WAAW,SAAS,KAAK,OAAO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AAK,WAAW,EAAE;YACnE,eAAe,EAAE,EAAE,CAAC;SACrB;QAED,QAAQ,CACN,QAAQ,CAAC;YACP,SAAS;YACT,GAAG;YACH,GAAG;YACH,eAAe;YACf,iBAAiB;YACjB,MAAM;YACN,EAAE,EAAE,GAAG,CAAC,OAAO;YACf,wBAAwB,EAAE,cAAc,CAAC,MAAM,CAAC,IAAI;SACrD,CAAC,CACH,CAAC;IACJ,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC,CAAC;IAElC,IAAI,MAAM,KAAK,cAAc,IAAI,CAAC,UAAU,EAAE,WAAW,CAAC,CAAC,QAAQ,CAAC,cAAe,CAAC,EAAE;QACpF,KAAK,GAAG,QAAQ,CAAC;YACf,SAAS;YACT,GAAG;YACH,GAAG;YACH,eAAe;YACf,iBAAiB;YACjB,MAAM,EAAE,MAAM,KAAK,WAAW,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,WAAW;YAC3D,EAAE,EAAE,GAAG,CAAC,OAAO;YACf,wBAAwB,EAAE,cAAc,CAAC,MAAM,CAAC,IAAI;SACrD,CAAC,CAAC;KACJ;IAED,OAAO,MAAM,KAAK,WAAW,IAAI,iBAAiB,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAClE,KAAC,GAAG,IAAC,GAAG,EAAE,GAAG,EAAE,eAAe,EAAE,eAAe,KAAM,SAAS,EAAE,KAAK,EAAE,KAAK,YACzE,QAAQ,GACL,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,cAAc,CAAC","sourcesContent":["import {\n FunctionComponent,\n Ref,\n forwardRef,\n ReactNode,\n PropsWithoutRef,\n useState,\n useLayoutEffect,\n useCallback,\n CSSProperties\n} from 'react';\n\nimport { ForwardProps, BaseProps, AsProp, PropsWithDefaults } from '../../types';\nimport { useConsolidatedRef, usePrevious, useTheme } from '../../hooks';\n\nexport interface ExpandCollapseProps extends AsProp, BaseProps {\n /** Content to expand/collapse. */\n children?: ReactNode;\n /**\n * If true,the content will be hidden.\n * @default false\n */\n collapsed?: boolean;\n /**\n * Used to determine the transition property.\n * @default 'height'\n */\n dimension?: 'height' | 'width';\n /** Minimum height/width to collapse to. This will set the starting collapsed size as well. */\n min?: string;\n /** Maximum height/width to expand to. Expanded state will expanded up until, but not beyond, the natural height/width of the element. */\n max?: string;\n /** Callback fired after content collapsed. */\n onAfterCollapse?: () => void;\n /** Callback fired after content expanded. */\n onAfterExpand?: () => void;\n /** Callback fired before content collapsed. */\n onBeforeCollapse?: () => void;\n /** Callback fired before content expanded. */\n onBeforeExpand?: () => void;\n /**\n * Determine the speed of animation. This value comes from `theme.base.animation.speed`.\n * @default '0.25s'\n */\n transitionSpeed?: string;\n /**\n * If true, removes the component from the real DOM when collapsed. For full virtual DOM unmount(if necessary), perform at a parent level.\n * @default false\n */\n nullWhenCollapsed?: boolean;\n}\n\ntype ExpandCollapsePropsWithDefaults = PropsWithDefaults<\n ExpandCollapseProps,\n 'collapsed' | 'dimension' | 'transitionSpeed' | 'nullWhenCollapsed'\n>;\n\ntype Statuses = 'collapsed' | 'collapsing' | 'expanded' | 'expanding';\n\ninterface GetStyleProps\n extends Pick<\n ExpandCollapsePropsWithDefaults,\n 'dimension' | 'transitionSpeed' | 'min' | 'max' | 'nullWhenCollapsed'\n > {\n status: Statuses;\n el?: HTMLElement | null;\n transitionTimingFunction?: string;\n}\n\nconst getScrollSize = (\n el: HTMLElement,\n dimension: ExpandCollapsePropsWithDefaults['dimension']\n): string => {\n if (!el) return '';\n return dimension === 'height' ? `${el.scrollHeight}px` : `${el.scrollWidth}px`;\n};\n\nconst getStyle = (props: GetStyleProps): CSSProperties => {\n const {\n status,\n dimension,\n transitionSpeed,\n transitionTimingFunction,\n min,\n max,\n nullWhenCollapsed,\n el\n } = props;\n const style: CSSProperties = {};\n let maxSize = max;\n\n if (el && !max) {\n maxSize = getScrollSize(el, dimension!);\n }\n\n if (status === 'expanded' || status === 'collapsed') {\n if (max || min) {\n style[dimension as 'height' | 'width'] = status === 'expanded' ? maxSize : min || 0;\n style[`overflow${dimension === 'width' ? 'X' : 'Y'}`] = 'hidden';\n }\n\n if (status === 'collapsed' && !nullWhenCollapsed && !min) {\n style.display = 'none';\n }\n }\n\n if (status === 'expanding' || status === 'collapsing') {\n style[dimension as 'height' | 'width'] = status === 'expanding' ? maxSize : min || 0;\n style.overflow = 'hidden';\n style.transitionProperty = dimension;\n style.transitionDuration = `max(${transitionSpeed}, 0.01ms)`;\n style.transitionTimingFunction = transitionTimingFunction;\n }\n\n return style;\n};\n\nconst ExpandCollapse: FunctionComponent<ExpandCollapseProps & ForwardProps> = forwardRef(\n (props: PropsWithoutRef<ExpandCollapseProps>, refArg: Ref<HTMLElement>) => {\n const {\n base: { animation: themeAnimation }\n } = useTheme();\n\n const {\n children,\n dimension = 'height',\n collapsed = false,\n onBeforeExpand,\n onAfterExpand,\n onBeforeCollapse,\n onAfterCollapse,\n transitionSpeed = themeAnimation.speed,\n min,\n max,\n nullWhenCollapsed = false,\n as: Tag = 'div',\n ...restProps\n } = props;\n\n const [status, setStatus] = useState<Statuses>(collapsed ? 'collapsed' : 'expanded');\n const styleStateHook = useState<CSSProperties>();\n const setStyle = styleStateHook[1];\n let style = styleStateHook[0];\n const previousStatus = usePrevious(status);\n const ref = useConsolidatedRef(refArg);\n\n const onTransitionEnd = useCallback(\n (e: TransitionEvent) => {\n if (e.target !== ref.current || e.propertyName !== dimension) return;\n setStatus(status === 'expanding' ? 'expanded' : 'collapsed');\n },\n [ref.current, status]\n );\n\n useLayoutEffect(() => {\n const wantsToCollapse = collapsed;\n const wantsToExpand = !collapsed;\n const canCollapse = ['expanded', 'expanding'].includes(status);\n const canExpand = ['collapsed', 'collapsing'].includes(status);\n\n if (wantsToExpand && canExpand) {\n onBeforeExpand?.();\n setStatus('expanding');\n } else if (wantsToCollapse && canCollapse) {\n onBeforeCollapse?.();\n setStatus('collapsing');\n }\n\n if (status === 'expanded' && previousStatus !== 'expanded') {\n onAfterExpand?.();\n } else if (status === 'collapsed' && previousStatus !== 'collapsed') {\n onAfterCollapse?.();\n }\n\n setStyle(\n getStyle({\n dimension,\n min,\n max,\n transitionSpeed,\n nullWhenCollapsed,\n status,\n el: ref.current,\n transitionTimingFunction: themeAnimation.timing.ease\n })\n );\n }, [collapsed, status, min, max]);\n\n if (status !== previousStatus && ['expanded', 'collapsed'].includes(previousStatus!)) {\n style = getStyle({\n dimension,\n min,\n max,\n transitionSpeed,\n nullWhenCollapsed,\n status: status === 'expanding' ? 'collapsing' : 'expanding',\n el: ref.current,\n transitionTimingFunction: themeAnimation.timing.ease\n });\n }\n\n return status === 'collapsed' && nullWhenCollapsed && !min ? null : (\n <Tag ref={ref} onTransitionEnd={onTransitionEnd} {...restProps} style={style}>\n {children}\n </Tag>\n );\n }\n);\n\nexport default ExpandCollapse;\n"]}
@@ -17,9 +17,7 @@ export interface FieldGroupProps extends BaseProps {
17
17
  * @default false
18
18
  */
19
19
  defaultCollapsed?: boolean;
20
- /**
21
- * Select the heading tag for header
22
- */
20
+ /** Select the heading tag for header */
23
21
  headingTag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
24
22
  /** The name associated with the Field Group. */
25
23
  name?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"FieldGroup.d.ts","sourceRoot":"","sources":["../../../src/components/FieldGroup/FieldGroup.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAwB,iBAAiB,EAAmB,GAAG,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAWjG,OAAgB,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAEnD,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAGtD,OAAuB,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAIxE,MAAM,WAAW,eAAgB,SAAQ,SAAS;IAChD,sCAAsC;IACtC,QAAQ,EAAE,SAAS,CA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AAC,CACF,KAAC,oBAAoB,cAAE,IAAI,GAAwB,CACpD,GACA,CACJ,GACgB,CACpB,EACA,WAAW,CAAC,CAAC,CAAC,CACb,KAAC,cAAc,IAAC,SAAS,EAAE,CAAC,IAAI,YAAG,eAAe,GAAkB,CACrE,CAAC,CAAC,CAAC,CACF,eAAe,CAChB,IACgB,CACpB,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,UAAU,CAAC","sourcesContent":["import { forwardRef, useState, FunctionComponent, PropsWithoutRef, Ref, ReactNode } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport Text from '../Text';\nimport Button from '../Button';\nimport ExpandCollapse from '../ExpandCollapse';\nimport Flex from '../Flex';\nimport Grid from '../Grid';\nimport HTML from '../HTML';\nimport Icon, { StyledIcon, registerIcon } from '../Icon';\nimport * as caretRightIcon from '../Icon/icons/caret-right.icon';\nimport Actions, { ActionsProps } from '../Actions';\nimport { defaultThemeProp } from '../../theme';\nimport { BaseProps, ForwardProps } from '../../types';\nimport { useDirection, useI18n, useUID } from '../../hooks';\nimport { calculateFontSize, FontSize, omitProps } from '../../styles';\nimport AdditionalInfo, { AdditionalInfoProps } from '../AdditionalInfo';\n\nregisterIcon(caretRightIcon);\n\nexport interface FieldGroupProps extends BaseProps {\n /** The content of the Field Group. */\n children: ReactNode;\n /** A description of the field group to be displayed above the controls. */\n description?: string;\n /**\n * If true, the Field Group will be able to collapse the content of its children by clicking on the name.\n * @default false\n */\n collapsible?: boolean;\n /**\n * If true, the Field Group will be collapsed on the first render.\n * @default false\n */\n defaultCollapsed?: boolean;\n /**\n * Select the heading tag for header\n */\n headingTag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';\n /** The name associated with the Field Group. */\n name?: string;\n /** Provides additional info relevant to the field group. */\n additionalInfo?: {\n heading: AdditionalInfoProps['heading'];\n content: AdditionalInfoProps['children'];\n };\n /** An array of actions to add to the header. */\n actions?: ActionsProps['items'];\n /** A reference to the wrapping element. */\n ref?: Ref<HTMLFieldSetElement>;\n}\n\ninterface FieldGroupLegendProps {\n open: boolean;\n actions?: ActionsProps['items'];\n children?: ReactNode;\n additionalInfo?: FieldGroupProps['additionalInfo'];\n}\n\nconst StyledExpandButton = styled(Button)(\n ({\n theme: {\n base: { animation }\n }\n }) => {\n const { rtl } = useDirection();\n return css`\n ${StyledIcon} {\n transition: transform ${animation.speed} ${animation.timing.ease};\n }\n &[aria-expanded='true'] ${StyledIcon} {\n transform: rotate(90deg);\n }\n &[aria-expanded='false'] ${StyledIcon} {\n transform: rotate(${rtl ? 180 : 0}deg);\n }\n `;\n }\n);\n\nStyledExpandButton.defaultProps = defaultThemeProp;\n\nexport const StyledFieldGroupName = styled.span``;\n\nexport const StyledFieldGroupLegend = styled.legend.withConfig<{ open: boolean }>(\n omitProps('open')\n)(\n ({\n open,\n theme: {\n base: {\n spacing,\n animation,\n 'hit-area': { 'mouse-min': hitAreaMouse, 'finger-min': hitAreaFinger }\n }\n }\n }) => {\n return css`\n width: 100%;\n margin-bottom: 0;\n ${open &&\n css`\n margin-block-end: calc(1.5 * ${spacing});\n `}\n transition: margin-block-end ${animation.speed} ${animation.timing.ease};\n\n > ${StyledExpandButton} {\n min-height: ${hitAreaMouse};\n\n @media (pointer: 'coarse') {\n min-height: ${hitAreaFinger};\n }\n }\n `;\n }\n);\n\nStyledFieldGroupLegend.defaultProps = defaultThemeProp;\n\nexport const StyledFieldGroup = styled.fieldset(\n ({\n theme: {\n base: { 'font-size': fontSize, 'font-scale': fontScale },\n components: { text }\n }\n }) => {\n const fontSizes = calculateFontSize(fontSize, fontScale);\n\n return css`\n border: none;\n\n & ${StyledFieldGroupName} {\n font-size: ${fontSizes[text.h3['font-size'] as FontSize]};\n font-weight: ${text.h3['font-weight']};\n }\n\n & & ${StyledFieldGroupName} {\n font-size: ${fontSizes[text.h4['font-size'] as FontSize]};\n font-weight: ${text.h4['font-weight']};\n }\n\n & & & ${StyledFieldGroupName} {\n font-size: ${fontSizes[text.h5['font-size'] as FontSize]};\n font-weight: ${text.h5['font-weight']};\n }\n\n & & & & ${StyledFieldGroupName} {\n font-size: ${fontSizes[text.h6['font-size'] as FontSize]};\n font-weight: ${text.h6['font-weight']};\n }\n `;\n }\n);\n\nStyledFieldGroup.defaultProps = defaultThemeProp;\n\nconst FieldGroupLegend: FunctionComponent<FieldGroupLegendProps> = ({\n children,\n open,\n actions,\n additionalInfo,\n ...restProps\n}) => {\n return (\n <StyledFieldGroupLegend open={open} {...restProps}>\n <Flex container={{ alignItems: 'center', justify: 'between', gap: 0.5 }}>\n <Flex container={{ alignItems: 'center', gap: 0.5 }}>\n {children}\n {additionalInfo && (\n <AdditionalInfo heading={additionalInfo.heading}>\n {additionalInfo.content}\n </AdditionalInfo>\n )}\n </Flex>\n {actions && <Actions items={actions} />}\n </Flex>\n </StyledFieldGroupLegend>\n );\n};\n\nconst FieldGroup: FunctionComponent<FieldGroupProps & ForwardProps> = forwardRef(\n (\n {\n children,\n description,\n name,\n additionalInfo,\n actions,\n collapsible = false,\n defaultCollapsed = false,\n headingTag,\n ...restProps\n }: PropsWithoutRef<FieldGroupProps>,\n ref: FieldGroupProps['ref']\n ) => {\n const [open, setOpen] = useState(!defaultCollapsed);\n const t = useI18n();\n const uid = useUID();\n\n const descAndChildren = (\n <Grid container={{ cols: 'minmax(0, 1fr)', gap: 3 }}>\n {description && <HTML id={`${uid}-description`} as='p' content={description} />}\n <div>{children}</div>\n </Grid>\n );\n\n return (\n <StyledFieldGroup\n aria-label={name}\n aria-describedby={description ? `${uid}-description` : undefined}\n {...restProps}\n ref={ref}\n >\n {name && (\n <FieldGroupLegend open={open} actions={actions} additionalInfo={additionalInfo}>\n {collapsible ? (\n <StyledExpandButton\n type='button'\n variant='text'\n onClick={() => {\n setOpen(cur => !cur);\n }}\n aria-expanded={open ? 'true' : 'false'}\n aria-label={t(open ? 'collapse_noun' : 'expand_noun', [name])}\n >\n <Flex\n container={{ direction: 'row', alignItems: 'center', gap: 0.5 }}\n forwardedAs='span'\n >\n <Icon name='caret-right' />\n {headingTag ? (\n <Text variant={headingTag}>{name}</Text>\n ) : (\n <StyledFieldGroupName>{name}</StyledFieldGroupName>\n )}\n </Flex>\n </StyledExpandButton>\n ) : (\n <>\n {headingTag ? (\n <Text variant={headingTag}>{name}</Text>\n ) : (\n <StyledFieldGroupName>{name}</StyledFieldGroupName>\n )}\n </>\n )}\n </FieldGroupLegend>\n )}\n {collapsible ? (\n <ExpandCollapse collapsed={!open}>{descAndChildren}</ExpandCollapse>\n ) : (\n descAndChildren\n )}\n </StyledFieldGroup>\n );\n }\n);\n\nexport default FieldGroup;\n"]}
1
+ {"version":3,"file":"FieldGroup.js","sourceRoot":"","sources":["../../../src/components/FieldGroup/FieldGroup.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAsD,MAAM,OAAO,CAAC;AACjG,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,IAAI,MAAM,SAAS,CAAC;AAC3B,OAAO,MAAM,MAAM,WAAW,CAAC;AAC/B,OAAO,cAAc,MAAM,mBAAmB,CAAC;AAC/C,OAAO,IAAI,MAAM,SAAS,CAAC;AAC3B,OAAO,IAAI,MAAM,SAAS,CAAC;AAC3B,OAAO,IAAI,MAAM,SAAS,CAAC;AAC3B,OAAO,IAAI,EAAE,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACzD,OAAO,KAAK,cAAc,MAAM,gCAAgC,CAAC;AACjE,OAAO,OAAyB,MAAM,YAAY,CAAC;AACnD,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAE/C,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,iBAAiB,EAAY,SAAS,EAAE,MAAM,cAAc,CAAC;AACtE,OAAO,cAAuC,MAAM,mBAAmB,CAAC;AAExE,YAAY,CAAC,cAAc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AC,CAAC,GAAG,CAAC,CAAC;oBACvB,CAAC,mBACc,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,OAAO,gBAC1B,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,CAAC,aAAa,EAAE,CAAC,IAAI,CAAC,CAAC,YAE7D,MAAC,IAAI,IACH,SAAS,EAAE,EAAE,SAAS,EAAE,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,GAAG,EAAE,GAAG,EAAE,EAC/D,WAAW,EAAC,MAAM,aAElB,KAAC,IAAI,IAAC,IAAI,EAAC,aAAa,GAAG,EAC1B,UAAU,CAAC,CAAC,CAAC,CACZ,KAAC,IAAI,IAAC,OAAO,EAAE,UAAU,YAAG,IAAI,GAAQ,CACzC,CAAC,CAAC,CAAC,CACF,KAAC,oBAAoB,cAAE,IAAI,GAAwB,CACpD,IACI,GACY,CACtB,CAAC,CAAC,CAAC,CACF,4BACG,UAAU,CAAC,CAAC,CAAC,CACZ,KAAC,IAAI,IAAC,OAAO,EAAE,UAAU,YAAG,IAAI,GAAQ,CACzC,CAAC,CAAC,CAAC,CACF,KAAC,oBAAoB,cAAE,IAAI,GAAwB,CACpD,GACA,CACJ,GACgB,CACpB,EACA,WAAW,CAAC,CAAC,CAAC,CACb,KAAC,cAAc,IAAC,SAAS,EAAE,CAAC,IAAI,YAAG,eAAe,GAAkB,CACrE,CAAC,CAAC,CAAC,CACF,eAAe,CAChB,IACgB,CACpB,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,UAAU,CAAC","sourcesContent":["import { forwardRef, useState, FunctionComponent, PropsWithoutRef, Ref, ReactNode } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport Text from '../Text';\nimport Button from '../Button';\nimport ExpandCollapse from '../ExpandCollapse';\nimport Flex from '../Flex';\nimport Grid from '../Grid';\nimport HTML from '../HTML';\nimport Icon, { StyledIcon, registerIcon } from '../Icon';\nimport * as caretRightIcon from '../Icon/icons/caret-right.icon';\nimport Actions, { ActionsProps } from '../Actions';\nimport { defaultThemeProp } from '../../theme';\nimport { BaseProps, ForwardProps } from '../../types';\nimport { useDirection, useI18n, useUID } from '../../hooks';\nimport { calculateFontSize, FontSize, omitProps } from '../../styles';\nimport AdditionalInfo, { AdditionalInfoProps } from '../AdditionalInfo';\n\nregisterIcon(caretRightIcon);\n\nexport interface FieldGroupProps extends BaseProps {\n /** The content of the Field Group. */\n children: ReactNode;\n /** A description of the field group to be displayed above the controls. */\n description?: string;\n /**\n * If true, the Field Group will be able to collapse the content of its children by clicking on the name.\n * @default false\n */\n collapsible?: boolean;\n /**\n * If true, the Field Group will be collapsed on the first render.\n * @default false\n */\n defaultCollapsed?: boolean;\n /** Select the heading tag for header */\n headingTag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';\n /** The name associated with the Field Group. */\n name?: string;\n /** Provides additional info relevant to the field group. */\n additionalInfo?: {\n heading: AdditionalInfoProps['heading'];\n content: AdditionalInfoProps['children'];\n };\n /** An array of actions to add to the header. */\n actions?: ActionsProps['items'];\n /** A reference to the wrapping element. */\n ref?: Ref<HTMLFieldSetElement>;\n}\n\ninterface FieldGroupLegendProps {\n open: boolean;\n actions?: ActionsProps['items'];\n children?: ReactNode;\n additionalInfo?: FieldGroupProps['additionalInfo'];\n}\n\nconst StyledExpandButton = styled(Button)(\n ({\n theme: {\n base: { animation }\n }\n }) => {\n const { rtl } = useDirection();\n return css`\n ${StyledIcon} {\n transition: transform ${animation.speed} ${animation.timing.ease};\n }\n &[aria-expanded='true'] ${StyledIcon} {\n transform: rotate(90deg);\n }\n &[aria-expanded='false'] ${StyledIcon} {\n transform: rotate(${rtl ? 180 : 0}deg);\n }\n `;\n }\n);\n\nStyledExpandButton.defaultProps = defaultThemeProp;\n\nexport const StyledFieldGroupName = styled.span``;\n\nexport const StyledFieldGroupLegend = styled.legend.withConfig<{ open: boolean }>(\n omitProps('open')\n)(\n ({\n open,\n theme: {\n base: {\n spacing,\n animation,\n 'hit-area': { 'mouse-min': hitAreaMouse, 'finger-min': hitAreaFinger }\n }\n }\n }) => {\n return css`\n width: 100%;\n margin-bottom: 0;\n ${open &&\n css`\n margin-block-end: calc(1.5 * ${spacing});\n `}\n transition: margin-block-end ${animation.speed} ${animation.timing.ease};\n\n > ${StyledExpandButton} {\n min-height: ${hitAreaMouse};\n\n @media (pointer: 'coarse') {\n min-height: ${hitAreaFinger};\n }\n }\n `;\n }\n);\n\nStyledFieldGroupLegend.defaultProps = defaultThemeProp;\n\nexport const StyledFieldGroup = styled.fieldset(\n ({\n theme: {\n base: { 'font-size': fontSize, 'font-scale': fontScale },\n components: { text }\n }\n }) => {\n const fontSizes = calculateFontSize(fontSize, fontScale);\n\n return css`\n border: none;\n\n & ${StyledFieldGroupName} {\n font-size: ${fontSizes[text.h3['font-size'] as FontSize]};\n font-weight: ${text.h3['font-weight']};\n }\n\n & & ${StyledFieldGroupName} {\n font-size: ${fontSizes[text.h4['font-size'] as FontSize]};\n font-weight: ${text.h4['font-weight']};\n }\n\n & & & ${StyledFieldGroupName} {\n font-size: ${fontSizes[text.h5['font-size'] as FontSize]};\n font-weight: ${text.h5['font-weight']};\n }\n\n & & & & ${StyledFieldGroupName} {\n font-size: ${fontSizes[text.h6['font-size'] as FontSize]};\n font-weight: ${text.h6['font-weight']};\n }\n `;\n }\n);\n\nStyledFieldGroup.defaultProps = defaultThemeProp;\n\nconst FieldGroupLegend: FunctionComponent<FieldGroupLegendProps> = ({\n children,\n open,\n actions,\n additionalInfo,\n ...restProps\n}) => {\n return (\n <StyledFieldGroupLegend open={open} {...restProps}>\n <Flex container={{ alignItems: 'center', justify: 'between', gap: 0.5 }}>\n <Flex container={{ alignItems: 'center', gap: 0.5 }}>\n {children}\n {additionalInfo && (\n <AdditionalInfo heading={additionalInfo.heading}>\n {additionalInfo.content}\n </AdditionalInfo>\n )}\n </Flex>\n {actions && <Actions items={actions} />}\n </Flex>\n </StyledFieldGroupLegend>\n );\n};\n\nconst FieldGroup: FunctionComponent<FieldGroupProps & ForwardProps> = forwardRef(\n (\n {\n children,\n description,\n name,\n additionalInfo,\n actions,\n collapsible = false,\n defaultCollapsed = false,\n headingTag,\n ...restProps\n }: PropsWithoutRef<FieldGroupProps>,\n ref: FieldGroupProps['ref']\n ) => {\n const [open, setOpen] = useState(!defaultCollapsed);\n const t = useI18n();\n const uid = useUID();\n\n const descAndChildren = (\n <Grid container={{ cols: 'minmax(0, 1fr)', gap: 3 }}>\n {description && <HTML id={`${uid}-description`} as='p' content={description} />}\n <div>{children}</div>\n </Grid>\n );\n\n return (\n <StyledFieldGroup\n aria-label={name}\n aria-describedby={description ? `${uid}-description` : undefined}\n {...restProps}\n ref={ref}\n >\n {name && (\n <FieldGroupLegend open={open} actions={actions} additionalInfo={additionalInfo}>\n {collapsible ? (\n <StyledExpandButton\n type='button'\n variant='text'\n onClick={() => {\n setOpen(cur => !cur);\n }}\n aria-expanded={open ? 'true' : 'false'}\n aria-label={t(open ? 'collapse_noun' : 'expand_noun', [name])}\n >\n <Flex\n container={{ direction: 'row', alignItems: 'center', gap: 0.5 }}\n forwardedAs='span'\n >\n <Icon name='caret-right' />\n {headingTag ? (\n <Text variant={headingTag}>{name}</Text>\n ) : (\n <StyledFieldGroupName>{name}</StyledFieldGroupName>\n )}\n </Flex>\n </StyledExpandButton>\n ) : (\n <>\n {headingTag ? (\n <Text variant={headingTag}>{name}</Text>\n ) : (\n <StyledFieldGroupName>{name}</StyledFieldGroupName>\n )}\n </>\n )}\n </FieldGroupLegend>\n )}\n {collapsible ? (\n <ExpandCollapse collapsed={!open}>{descAndChildren}</ExpandCollapse>\n ) : (\n descAndChildren\n )}\n </StyledFieldGroup>\n );\n }\n);\n\nexport default FieldGroup;\n"]}
@@ -2,17 +2,19 @@ import { ReactNode, FunctionComponent } from 'react';
2
2
  import { BaseProps, ForwardProps, NoChildrenProp, TestIdProp } from '../../types';
3
3
  export type FieldValueVariant = 'inline' | 'stacked';
4
4
  export interface FieldValueListItemProps extends TestIdProp {
5
- id?: string;
6
5
  name: string;
7
6
  value?: ReactNode;
8
7
  variant?: FieldValueVariant;
9
8
  }
9
+ export interface FieldValueListItem extends FieldValueListItemProps {
10
+ id?: string;
11
+ }
10
12
  export interface FieldValueListProps extends BaseProps, NoChildrenProp, TestIdProp {
11
13
  /** The set of field values to render in the list. */
12
- fields: FieldValueListItemProps[];
14
+ fields: FieldValueListItem[];
13
15
  /**
14
16
  * Determines if the field and values should be displayed on the same line, or stacked with the field above the value.
15
- * @default "inline"
17
+ * @default 'inline'
16
18
  */
17
19
  variant?: FieldValueVariant | 'value-comparison';
18
20
  }
@@ -1 +1 @@
1
- {"version":3,"file":"FieldValueList.d.ts","sourceRoot":"","sources":["../../../src/components/FieldValueList/FieldValueList.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAY,iBAAiB,EAAmB,MAAM,OAAO,CAAC;AAGhF,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AASlF,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,SAAS,CAAC;AAErD,MAAM,WAAW,uBAAwB,SAAQ,UAAU;IACzD,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,OAAO,CAAC,EAAE,iBAAiB,CAAC;CAC7B;AAED,MAAM,WAAW,mBAAoB,SAAQ,SAAS,EAAE,cAAc,EAAE,UAAU;IAChF,qDAAqD;IACrD,MAAM,EAAE,uBAAuB,EAAE,CAAC;IAClC;;;OAGG;IACH,OAAO,CAAC,EAAE,iBAAiB,GAAG,kBAAkB,CAAC;CAClD;AAED,eAAO,MAAM,eAAe,wGAE3B,CAAC;AAEF,eAAO,MAAM,gBAAgB,wGAE5B,CAAC;AAEF,MAAM,MAAM,yBAAyB,GAAG,IAAI,CAAC,mBAAmB,EAAE,SAAS,CAAC,C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EAAE,iBAAiB;QAChC,SAAS,EAAE,eAAe;KAC3B,CAAC,CAAC;IAEH,OAAO,CACL,KAAC,IAAI,mBACU,OAAO,CAAC,IAAI,KACrB,SAAS,EACb,GAAG,EAAE,iBAAiB,EACtB,SAAS,EAAE;YACT,IAAI,EACF,CAAC,QAAQ,EAAE,kBAAkB,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,IAAI,uBAAuB;gBACzE,CAAC,CAAC,qBAAqB;gBACvB,CAAC,CAAC,gBAAgB;YACtB,MAAM,EAAE,OAAO,KAAK,kBAAkB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;YAC9C,MAAM,EAAE,OAAO,KAAK,kBAAkB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG;SACjD,EACD,EAAE,EAAE,oBAAoB,EACxB,OAAO,EAAE,OAAO,YAEf,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,YAAY,EAAE,EAAE,EAAE;YACzD,OAAO,CACL,KAAC,cAAc,IACb,IAAI,EAAE,IAAI,EACV,KAAK,EAAE,KAAK,EACZ,OAAO,EACL,CAAC,YAAY,IAAI,OAAO,CAAC,KAAK,SAAS,IAAI,CAAC,uBAAuB;oBACjE,CAAC,CAAC,SAAS;oBACX,CAAC,CAAC,QAAQ,IAET,EAAE,IAAI,IAAI,CACf,CACH,CAAC;QACJ,CAAC,CAAC,GACG,CACR,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,cAAc,CAAC","sourcesContent":["import { ReactNode, Fragment, FunctionComponent, Ref, forwardRef } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport { BaseProps, ForwardProps, NoChildrenProp, TestIdProp } from '../../types';\nimport Grid from '../Grid';\nimport { StyledLabel } from '../Label';\nimport { useBreakpoint, useConsolidatedRef, useTestIds } from '../../hooks';\nimport { defaultThemeProp } from '../../theme';\nimport ShowMoreLess from '../ShowMoreLess';\n\nimport { getFieldValueListTestIds, getFieldValueItemTestIds } from './FieldValueList.test-ids';\n\nexport type FieldValueVariant = 'inline' | 'stacked';\n\nexport interface FieldValueListItemProps extends TestIdProp {\n id?: string;\n name: string;\n value?: ReactNode;\n variant?: FieldValueVariant;\n}\n\nexport interface FieldValueListProps extends BaseProps, NoChildrenProp, TestIdProp {\n /** The set of field values to render in the list. */\n fields: FieldValueListItemProps[];\n /**\n * Determines if the field and values should be displayed on the same line, or stacked with the field above the value.\n * @default \"inline\"\n */\n variant?: FieldValueVariant | 'value-comparison';\n}\n\nexport const StyledFieldName = styled.dt`\n word-break: break-word;\n`;\n\nexport const StyledFieldValue = styled.dd`\n word-break: break-word;\n`;\n\nexport type StyledFieldValueListProps = Pick<FieldValueListProps, 'variant'>;\n\nexport const StyledFieldValueList = styled.dl<StyledFieldValueListProps>(({ variant, theme }) => {\n return css`\n width: 100%;\n\n ${variant === 'value-comparison' &&\n css`\n dt {\n width: 100%;\n }\n dd {\n text-align: end;\n padding-inline-start: calc(2 * ${theme.base.spacing});\n }\n ${StyledLabel} {\n max-width: unset;\n }\n dd:not(:last-of-type),\n dt:not(:last-of-type) {\n border-bottom: 0.0625rem solid ${theme.base.palette['border-line']};\n padding-bottom: calc(0.5 * ${theme.base.spacing});\n }\n `}\n `;\n});\n\nStyledFieldValueList.defaultProps = defaultThemeProp;\n\nexport const StyledStackedFieldValue = styled.div``;\n\nexport const FieldValueItem = ({\n testId,\n name,\n value,\n variant = 'inline'\n}: FieldValueListItemProps) => {\n const testIds = useTestIds(testId, getFieldValueItemTestIds);\n\n const displayValue =\n typeof value === 'string' ? <ShowMoreLess lines={3}>{value}</ShowMoreLess> : value;\n\n const labelAndValue = (\n <>\n <StyledLabel data-testid={testIds.name} as={StyledFieldName}>\n {name}\n </StyledLabel>\n <StyledFieldValue data-testid={testIds.value}>\n {value ? displayValue : <span aria-hidden='true'>&ndash;&ndash;</span>}\n </StyledFieldValue>\n </>\n );\n\n return variant === 'stacked' ? (\n <StyledStackedFieldValue data-testid={testIds.root}>{labelAndValue}</StyledStackedFieldValue>\n ) : (\n <>{labelAndValue}</>\n );\n};\n\nconst FieldValueList: FunctionComponent<FieldValueListProps & ForwardProps> = forwardRef(\n (\n { testId, fields, variant = 'inline', ...restProps }: FieldValueListProps,\n ref: Ref<HTMLDivElement>\n ) => {\n const testIds = useTestIds(testId, getFieldValueListTestIds);\n\n const fieldValueListRef = useConsolidatedRef<HTMLDivElement>(ref);\n\n const isXSContentWidthOrAbove = useBreakpoint('xs', {\n breakpointRef: fieldValueListRef,\n themeProp: 'content-width'\n });\n\n return (\n <Grid\n data-testid={testIds.root}\n {...restProps}\n ref={fieldValueListRef}\n container={{\n cols:\n ['inline', 'value-comparison'].includes(variant) && isXSContentWidthOrAbove\n ? '16ch minmax(0, 1fr)'\n : 'minmax(0, 1fr)',\n colGap: variant !== 'value-comparison' ? 2 : 0,\n rowGap: variant !== 'value-comparison' ? 1 : 0.5\n }}\n as={StyledFieldValueList}\n variant={variant}\n >\n {fields.map(({ id, name, value, variant: fieldVariant }) => {\n return (\n <FieldValueItem\n name={name}\n value={value}\n variant={\n (fieldVariant ?? variant) === 'stacked' || !isXSContentWidthOrAbove\n ? 'stacked'\n : 'inline'\n }\n key={id ?? name}\n />\n );\n })}\n </Grid>\n );\n }\n);\n\nexport default FieldValueList;\n"]}
1
+ {"version":3,"file":"FieldValueList.js","sourceRoot":"","sources":["../../../src/components/FieldValueList/FieldValueList.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAqC,UAAU,EAAE,MAAM,OAAO,CAAC;AACtE,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAGhD,OAAO,IAAI,MAAM,SAAS,CAAC;AAC3B,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAC5E,OAAO,EAAE,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EAAE,OAAO,YAEf,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,YAAY,EAAE,EAAE,EAAE;YACzD,OAAO,CACL,KAAC,cAAc,IACb,IAAI,EAAE,IAAI,EACV,KAAK,EAAE,KAAK,EACZ,OAAO,EACL,CAAC,YAAY,IAAI,OAAO,CAAC,KAAK,SAAS,IAAI,CAAC,uBAAuB;oBACjE,CAAC,CAAC,SAAS;oBACX,CAAC,CAAC,QAAQ,IAET,EAAE,IAAI,IAAI,CACf,CACH,CAAC;QACJ,CAAC,CAAC,GACG,CACR,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,cAAc,CAAC","sourcesContent":["import { ReactNode, FunctionComponent, Ref, forwardRef } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport { BaseProps, ForwardProps, NoChildrenProp, TestIdProp } from '../../types';\nimport Grid from '../Grid';\nimport { StyledLabel } from '../Label';\nimport { useBreakpoint, useConsolidatedRef, useTestIds } from '../../hooks';\nimport { defaultThemeProp } from '../../theme';\nimport ShowMoreLess from '../ShowMoreLess';\n\nimport { getFieldValueListTestIds, getFieldValueItemTestIds } from './FieldValueList.test-ids';\n\nexport type FieldValueVariant = 'inline' | 'stacked';\n\nexport interface FieldValueListItemProps extends TestIdProp {\n name: string;\n value?: ReactNode;\n variant?: FieldValueVariant;\n}\n\nexport interface FieldValueListItem extends FieldValueListItemProps {\n id?: string;\n}\n\nexport interface FieldValueListProps extends BaseProps, NoChildrenProp, TestIdProp {\n /** The set of field values to render in the list. */\n fields: FieldValueListItem[];\n /**\n * Determines if the field and values should be displayed on the same line, or stacked with the field above the value.\n * @default 'inline'\n */\n variant?: FieldValueVariant | 'value-comparison';\n}\n\nexport const StyledFieldName = styled.dt`\n word-break: break-word;\n`;\n\nexport const StyledFieldValue = styled.dd`\n word-break: break-word;\n`;\n\nexport type StyledFieldValueListProps = Pick<FieldValueListProps, 'variant'>;\n\nexport const StyledFieldValueList = styled.dl<StyledFieldValueListProps>(({ variant, theme }) => {\n return css`\n width: 100%;\n\n ${variant === 'value-comparison' &&\n css`\n dt {\n width: 100%;\n }\n dd {\n text-align: end;\n padding-inline-start: calc(2 * ${theme.base.spacing});\n }\n ${StyledLabel} {\n max-width: unset;\n }\n dd:not(:last-of-type),\n dt:not(:last-of-type) {\n border-bottom: 0.0625rem solid ${theme.base.palette['border-line']};\n padding-bottom: calc(0.5 * ${theme.base.spacing});\n }\n `}\n `;\n});\n\nStyledFieldValueList.defaultProps = defaultThemeProp;\n\nexport const StyledStackedFieldValue = styled.div``;\n\nexport const FieldValueItem = ({\n testId,\n name,\n value,\n variant = 'inline'\n}: FieldValueListItemProps) => {\n const testIds = useTestIds(testId, getFieldValueItemTestIds);\n\n const displayValue =\n typeof value === 'string' ? <ShowMoreLess lines={3}>{value}</ShowMoreLess> : value;\n\n const labelAndValue = (\n <>\n <StyledLabel data-testid={testIds.name} as={StyledFieldName}>\n {name}\n </StyledLabel>\n <StyledFieldValue data-testid={testIds.value}>\n {value ? displayValue : <span aria-hidden='true'>&ndash;&ndash;</span>}\n </StyledFieldValue>\n </>\n );\n\n return variant === 'stacked' ? (\n <StyledStackedFieldValue data-testid={testIds.root}>{labelAndValue}</StyledStackedFieldValue>\n ) : (\n <>{labelAndValue}</>\n );\n};\n\nconst FieldValueList: FunctionComponent<FieldValueListProps & ForwardProps> = forwardRef(\n (\n { testId, fields, variant = 'inline', ...restProps }: FieldValueListProps,\n ref: Ref<HTMLDivElement>\n ) => {\n const testIds = useTestIds(testId, getFieldValueListTestIds);\n\n const fieldValueListRef = useConsolidatedRef<HTMLDivElement>(ref);\n\n const isXSContentWidthOrAbove = useBreakpoint('xs', {\n breakpointRef: fieldValueListRef,\n themeProp: 'content-width'\n });\n\n return (\n <Grid\n data-testid={testIds.root}\n {...restProps}\n ref={fieldValueListRef}\n container={{\n cols:\n ['inline', 'value-comparison'].includes(variant) && isXSContentWidthOrAbove\n ? '16ch minmax(0, 1fr)'\n : 'minmax(0, 1fr)',\n colGap: variant !== 'value-comparison' ? 2 : 0,\n rowGap: variant !== 'value-comparison' ? 1 : 0.5\n }}\n as={StyledFieldValueList}\n variant={variant}\n >\n {fields.map(({ id, name, value, variant: fieldVariant }) => {\n return (\n <FieldValueItem\n name={name}\n value={value}\n variant={\n (fieldVariant ?? variant) === 'stacked' || !isXSContentWidthOrAbove\n ? 'stacked'\n : 'inline'\n }\n key={id ?? name}\n />\n );\n })}\n </Grid>\n );\n }\n);\n\nexport default FieldValueList;\n"]}
@@ -1,3 +1,3 @@
1
- export declare const getFieldValueListTestIds: (testIdProp?: string | undefined) => import("../../utils").TestIdsRecord<readonly []>;
2
- export declare const getFieldValueItemTestIds: (testIdProp?: string | undefined) => import("../../utils").TestIdsRecord<readonly ["name", "value"]>;
1
+ export declare const getFieldValueListTestIds: (testIdProp?: string | undefined) => import("../..").TestIdsRecord<readonly []>;
2
+ export declare const getFieldValueItemTestIds: (testIdProp?: string | undefined) => import("../..").TestIdsRecord<readonly ["name", "value"]>;
3
3
  //# sourceMappingURL=FieldValueList.test-ids.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"FieldValueList.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/FieldValueList/FieldValueList.test-ids.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,wBAAwB,uFAAiD,CAAC;AAEvF,eAAO,MAAM,wBAAwB,sGAG1B,CAAC"}
1
+ {"version":3,"file":"FieldValueList.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/FieldValueList/FieldValueList.test-ids.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,wBAAwB,iFAAiD,CAAC;AAEvF,eAAO,MAAM,wBAAwB,gGAG1B,CAAC"}
@@ -1,4 +1,4 @@
1
1
  export { default, FieldValueItem } from './FieldValueList';
2
- export { FieldValueListProps, FieldValueListItemProps, StyledFieldValueListProps } from './FieldValueList';
2
+ export { FieldValueListProps, FieldValueListItem, FieldValueListItemProps, StyledFieldValueListProps } from './FieldValueList';
3
3
  export { StyledFieldValueList, StyledFieldName, StyledFieldValue, StyledStackedFieldValue } from './FieldValueList';
4
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/FieldValueList/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAC3D,OAAO,EACL,mBAAmB,EACnB,uBAAuB,EACvB,yBAAyB,EAC1B,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,uBAAuB,EACxB,MAAM,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/FieldValueList/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAC3D,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,uBAAuB,EACvB,yBAAyB,EAC1B,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,uBAAuB,EACxB,MAAM,kBAAkB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/FieldValueList/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAM3D,OAAO,EACL,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,uBAAuB,EACxB,MAAM,kBAAkB,CAAC","sourcesContent":["export { default, FieldValueItem } from './FieldValueList';\nexport {\n FieldValueListProps,\n FieldValueListItemProps,\n StyledFieldValueListProps\n} from './FieldValueList';\nexport {\n StyledFieldValueList,\n StyledFieldName,\n StyledFieldValue,\n StyledStackedFieldValue\n} from './FieldValueList';\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/FieldValueList/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAO3D,OAAO,EACL,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,uBAAuB,EACxB,MAAM,kBAAkB,CAAC","sourcesContent":["export { default, FieldValueItem } from './FieldValueList';\nexport {\n FieldValueListProps,\n FieldValueListItem,\n FieldValueListItemProps,\n StyledFieldValueListProps\n} from './FieldValueList';\nexport {\n StyledFieldValueList,\n StyledFieldName,\n StyledFieldValue,\n StyledStackedFieldValue\n} from './FieldValueList';\n"]}
@@ -1,2 +1,2 @@
1
- export declare const getFileInputTestIds: (testIdProp?: string | undefined) => import("../../utils").TestIdsRecord<readonly ["control", "files"]>;
1
+ export declare const getFileInputTestIds: (testIdProp?: string | undefined) => import("../..").TestIdsRecord<readonly ["control", "files", "label", "info", "additional-info", "suggestion-accept", "suggestion-reject"]>;
2
2
  //# sourceMappingURL=File.test-ids.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"File.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/File/File.test-ids.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,mBAAmB,yGAA6D,CAAC"}
1
+ {"version":3,"file":"File.test-ids.d.ts","sourceRoot":"","sources":["../../../src/components/File/File.test-ids.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,mBAAmB,iLAIrB,CAAC"}
@@ -1,3 +1,8 @@
1
1
  import { createTestIds } from '../../utils';
2
- export const getFileInputTestIds = createTestIds('file-input', ['control', 'files']);
2
+ import { elements } from '../FormField/FormField.test-ids';
3
+ export const getFileInputTestIds = createTestIds('file-input', [
4
+ 'control',
5
+ 'files',
6
+ ...elements
7
+ ]);
3
8
  //# sourceMappingURL=File.test-ids.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"File.test-ids.js","sourceRoot":"","sources":["../../../src/components/File/File.test-ids.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAE5C,MAAM,CAAC,MAAM,mBAAmB,GAAG,aAAa,CAAC,YAAY,EAAE,CAAC,SAAS,EAAE,OAAO,CAAU,CAAC,CAAC","sourcesContent":["import { createTestIds } from '../../utils';\n\nexport const getFileInputTestIds = createTestIds('file-input', ['control', 'files'] as const);\n"]}
1
+ {"version":3,"file":"File.test-ids.js","sourceRoot":"","sources":["../../../src/components/File/File.test-ids.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,iCAAiC,CAAC;AAE3D,MAAM,CAAC,MAAM,mBAAmB,GAAG,aAAa,CAAC,YAAY,EAAE;IAC7D,SAAS;IACT,OAAO;IACP,GAAG,QAAQ;CACH,CAAC,CAAC","sourcesContent":["import { createTestIds } from '../../utils';\nimport { elements } from '../FormField/FormField.test-ids';\n\nexport const getFileInputTestIds = createTestIds('file-input', [\n 'control',\n 'files',\n ...elements\n] as const);\n"]}
@@ -8,8 +8,8 @@ export interface FileDisplayProps extends Pick<FileItemProps, 'onPreview' | 'onD
8
8
  displayText?: string;
9
9
  /**
10
10
  * Display value either as file, link only or textual representation.
11
- * @default "file"
12
- * */
11
+ * @default 'file'
12
+ */
13
13
  variant?: 'file' | 'link' | 'text';
14
14
  /** Thumbnail image. */
15
15
  thumbnail?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"FileDisplay.d.ts","sourceRoot":"","sources":["../../../src/components/File/FileDisplay.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAc,iBAAiB,EAAmB,GAAG,EAAE,MAAM,OAAO,CAAC;AAE5E,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAGtE,OAAiB,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAErD,MAAM,WAAW,gBACf,SAAQ,IAAI,CAAC,a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BAAgB,GAAG,YAAY,CA0CnE,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"FileDisplay.js","sourceRoot":"","sources":["../../../src/components/File/FileDisplay.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAA2C,MAAM,OAAO,CAAC;AAG5E,OAAO,IAAI,MAAM,SAAS,CAAC;AAE3B,OAAO,QAA2B,MAAM,YAAY,CAAC;AAqBrD,MAAM,WAAW,GAAuD,UAAU,CAChF,CACE,EACE,WAAW,EACX,KAAK,EACL,OAAO,EACP,SAAS,EACT,SAAS,EACT,UAAU,EACV,GAAG,SAAS,EACsB,EACpC,GAA4B,EAC5B,EAAE;IACF,IAAI,OAAO,KAAK,MAAM,IAAI,CAAC,KAAK,EAAE;QAChC,OAAO,CACL,eAAM,GAAG,EAAE,GAAG,KAAM,SAAS,YAC1B,KAAK,CAAC,CAAC,CAAC,WAAW,IAAI,KAAK,CAAC,CAAC,CAAC,8BAAkB,MAAM,6BAAsB,GACzE,CACR,CAAC;KACH;IAED,IAAI,OAAO,KAAK,MAAM;QACpB,OAAO,CACL,KAAC,IAAI,IAAC,GAAG,EAAE,GAA6B,KAAM,SAAS,EAAE,IAAI,EAAE,KAAK,YACjE,WAAW,IAAI,KAAK,GAChB,CACR,CAAC;IAEJ,OAAO,CACL,KAAC,QAAQ,OACH,SAAS,EACb,GAAG,EAAE,GAA6B,EAClC,IAAI,EAAE,WAAW,IAAI,KAAK,EAC1B,GAAG,EAAE,KAAK,KACN;YACF,SAAS;YACT,UAAU;YACV,SAAS;SACV,GACD,CACH,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,WAAW,CAAC","sourcesContent":["import { forwardRef, FunctionComponent, PropsWithoutRef, Ref } from 'react';\n\nimport { BaseProps, ForwardProps, NoChildrenProp } from '../../types';\nimport Link from '../Link';\n\nimport FileItem, { FileItemProps } from './FileItem';\n\nexport interface FileDisplayProps\n extends Pick<FileItemProps, 'onPreview' | 'onDownload'>,\n BaseProps,\n NoChildrenProp {\n /** URL address */\n value?: string;\n /** The text to be displayed. */\n displayText?: string;\n /**\n * Display value either as file, link only or textual representation.\n * @default \"file\"\n * */\n variant?: 'file' | 'link' | 'text';\n /** Thumbnail image. */\n thumbnail?: string;\n /** Ref for the wrapping element. */\n ref?: Ref<HTMLDivElement | HTMLAnchorElement | HTMLSpanElement>;\n}\n\nconst FileDisplay: FunctionComponent<FileDisplayProps & ForwardProps> = forwardRef(\n (\n {\n displayText,\n value,\n variant,\n thumbnail,\n onPreview,\n onDownload,\n ...restProps\n }: PropsWithoutRef<FileDisplayProps>,\n ref: FileDisplayProps['ref']\n ) => {\n if (variant === 'text' || !value) {\n return (\n <span ref={ref} {...restProps}>\n {value ? displayText || value : <span aria-hidden='true'>&ndash;&ndash;</span>}\n </span>\n );\n }\n\n if (variant === 'link')\n return (\n <Link ref={ref as Ref<HTMLAnchorElement>} {...restProps} href={value}>\n {displayText || value}\n </Link>\n );\n\n return (\n <FileItem\n {...restProps}\n ref={ref as Ref<HTMLButtonElement>}\n name={displayText || value}\n url={value}\n {...{\n thumbnail,\n onDownload,\n onPreview\n }}\n />\n );\n }\n);\n\nexport default FileDisplay;\n"]}
1
+ {"version":3,"file":"FileDisplay.js","sourceRoot":"","sources":["../../../src/components/File/FileDisplay.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAA2C,MAAM,OAAO,CAAC;AAG5E,OAAO,IAAI,MAAM,SAAS,CAAC;AAE3B,OAAO,QAA2B,MAAM,YAAY,CAAC;AAqBrD,MAAM,WAAW,GAAuD,UAAU,CAChF,CACE,EACE,WAAW,EACX,KAAK,EACL,OAAO,EACP,SAAS,EACT,SAAS,EACT,UAAU,EACV,GAAG,SAAS,EACsB,EACpC,GAA4B,EAC5B,EAAE;IACF,IAAI,OAAO,KAAK,MAAM,IAAI,CAAC,KAAK,EAAE;QAChC,OAAO,CACL,eAAM,GAAG,EAAE,GAAG,KAAM,SAAS,YAC1B,KAAK,CAAC,CAAC,CAAC,WAAW,IAAI,KAAK,CAAC,CAAC,CAAC,8BAAkB,MAAM,6BAAsB,GACzE,CACR,CAAC;KACH;IAED,IAAI,OAAO,KAAK,MAAM;QACpB,OAAO,CACL,KAAC,IAAI,IAAC,GAAG,EAAE,GAA6B,KAAM,SAAS,EAAE,IAAI,EAAE,KAAK,YACjE,WAAW,IAAI,KAAK,GAChB,CACR,CAAC;IAEJ,OAAO,CACL,KAAC,QAAQ,OACH,SAAS,EACb,GAAG,EAAE,GAA6B,EAClC,IAAI,EAAE,WAAW,IAAI,KAAK,EAC1B,GAAG,EAAE,KAAK,KACN;YACF,SAAS;YACT,UAAU;YACV,SAAS;SACV,GACD,CACH,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,WAAW,CAAC","sourcesContent":["import { forwardRef, FunctionComponent, PropsWithoutRef, Ref } from 'react';\n\nimport { BaseProps, ForwardProps, NoChildrenProp } from '../../types';\nimport Link from '../Link';\n\nimport FileItem, { FileItemProps } from './FileItem';\n\nexport interface FileDisplayProps\n extends Pick<FileItemProps, 'onPreview' | 'onDownload'>,\n BaseProps,\n NoChildrenProp {\n /** URL address */\n value?: string;\n /** The text to be displayed. */\n displayText?: string;\n /**\n * Display value either as file, link only or textual representation.\n * @default 'file'\n */\n variant?: 'file' | 'link' | 'text';\n /** Thumbnail image. */\n thumbnail?: string;\n /** Ref for the wrapping element. */\n ref?: Ref<HTMLDivElement | HTMLAnchorElement | HTMLSpanElement>;\n}\n\nconst FileDisplay: FunctionComponent<FileDisplayProps & ForwardProps> = forwardRef(\n (\n {\n displayText,\n value,\n variant,\n thumbnail,\n onPreview,\n onDownload,\n ...restProps\n }: PropsWithoutRef<FileDisplayProps>,\n ref: FileDisplayProps['ref']\n ) => {\n if (variant === 'text' || !value) {\n return (\n <span ref={ref} {...restProps}>\n {value ? displayText || value : <span aria-hidden='true'>&ndash;&ndash;</span>}\n </span>\n );\n }\n\n if (variant === 'link')\n return (\n <Link ref={ref as Ref<HTMLAnchorElement>} {...restProps} href={value}>\n {displayText || value}\n </Link>\n );\n\n return (\n <FileItem\n {...restProps}\n ref={ref as Ref<HTMLButtonElement>}\n name={displayText || value}\n url={value}\n {...{\n thumbnail,\n onDownload,\n onPreview\n }}\n />\n );\n }\n);\n\nexport default FileDisplay;\n"]}
@@ -3,9 +3,7 @@ import { BaseProps, ForwardProps, NoChildrenProp, TestIdProp } from '../../types
3
3
  import { FormControlProps } from '../FormControl';
4
4
  import { FileUploadItemProps } from './FileUploadItem';
5
5
  export interface FileInputProps extends BaseProps, NoChildrenProp, TestIdProp {
6
- /**
7
- * Called when files are added either via the input or drop zone.
8
- */
6
+ /** Called when files are added either via the input or drop zone. */
9
7
  onFilesAdded?: (files: File[]) => void;
10
8
  /**
11
9
  * Allow multiple files to be selected from the OS specific file browser.
@@ -1 +1 @@
1
- {"version":3,"file":"FileInput.d.ts","sourceRoot":"","sources":["../../../src/components/File/FileInput.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,GAAG,EAOJ,MAAM,OAAO,CAAC;AAIf,OAAO,EACL,SAAS,EACT,YAAY,EACZ,cAAc,EAEd,UAAU,EACX,MAAM,aAAa,CAAC;AAErB,OAAoB,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAS/D,OAAuB,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAOvE,MAAM,WAAW,cAAe,SAAQ,SAAS,EAAE,cAAc,EAAE,UAAU;IAC3E;;OAEG;IACH,YAAY,CAAC,EAAE,CAAC,KAAK,EAAE,IAAI,EAAE,KAAK,IAAI,CAAC;IACvC;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iDAAiD;IACjD,KAAK,CAAC,EAAE,mBAAmB,EAAE,CAAC;IAC9B;;;OAGG;IACH,EAAE,CAAC,EAAE,gBAAgB,CAAC,IAAI,CAAC,CAAC;IAC5B,oDAAoD;IACpD,MAAM,CAAC,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C;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iDAAiD;IACjD,KAAK,CAAC,EAAE,mBAAmB,EAAE,CAAC;IAC9B;;;OAGG;IACH,EAAE,CAAC,EAAE,gBAAgB,CAAC,IAAI,CAAC,CAAC;IAC5B,oDAAoD;IACpD,MAAM,CAAC,EAAE,gBAAgB,CAAC,QAAQ,CAAC,CAAC;IACpC,2DAA2D;IAC3D,KAAK,CAAC,EAAE,gBAAgB,CAAC,OAAO,CAAC,CAAC;IAClC,uCAAuC;IACvC,WAAW,CAAC,EAAE,gBAAgB,CAAC,aAAa,CAAC,CAAC;IAC9C,6GAA6G;IAC7G,IAAI,CAAC,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAChC,wEAAwE;IACxE,QAAQ,CAAC,EAAE,gBAAgB,CAAC,UAAU,CAAC,CAAC;IACxC,0DAA0D;IAC1D,QAAQ,CAAC,EAAE,gBAAgB,CAAC,UAAU,CAAC,CAAC;IACxC,+FAA+F;IAC/F,IAAI,CAAC,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAChC,sEAAsE;IACtE,GAAG,CAAC,EAAE,GAAG,CAAC,gBAAgB,CAAC,CAAC;CAC7B;AAED,eAAO,MAAM,cAAc;cAAmC,OAAO;SAYnE,CAAC;AAEH,eAAO,MAAM,eAAe,qNAkB3B,CAAC;AAYF,QAAA,MAAM,SAAS,EAAE,iBAAiB,CAAC,cAAc,GAAG,YAAY,CAkI/D,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -88,7 +88,7 @@ const FileInput = forwardRef((props, ref) => {
88
88
  _jsx(StyledInteractiveText, { children: t(multiple ? 'file_upload_text_multiple' : 'file_upload_text_one') })
89
89
  ]), "\u00A0"] }), rtl && icon] })] }));
90
90
  return (_jsxs(Grid, { container: { rowGap: 1 }, children: [label ? (_jsx(FormField, { ...{
91
- testId: testIds.root,
91
+ testId: testIds,
92
92
  label,
93
93
  labelHidden,
94
94
  id,