@ntbjs/react-components 2.0.0-rc.29 → 2.0.0-rc.30

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 (279) hide show
  1. package/build/{_rollupPluginBabelHelpers-c245b26a.js → _virtual/_rollupPluginBabelHelpers.js} +2 -1
  2. package/build/_virtual/_rollupPluginBabelHelpers.js.map +1 -0
  3. package/build/{Alert-e6847a22.js → data/Alert/Alert.js} +5 -55
  4. package/build/data/Alert/Alert.js.map +1 -0
  5. package/build/data/Alert/Alert.styled.js +56 -0
  6. package/build/data/Alert/Alert.styled.js.map +1 -0
  7. package/build/data/Alert/index.js +2 -6
  8. package/build/data/Alert/index.js.map +1 -0
  9. package/build/data/Badge/Badge.js +87 -0
  10. package/build/data/Badge/Badge.js.map +1 -0
  11. package/build/{Badge-d93586a9.js → data/Badge/Badge.styled.js} +4 -85
  12. package/build/data/Badge/Badge.styled.js.map +1 -0
  13. package/build/data/Badge/index.js +2 -5
  14. package/build/data/Badge/index.js.map +1 -0
  15. package/build/data/Popover/Popover.js +93 -0
  16. package/build/data/Popover/Popover.js.map +1 -0
  17. package/build/{Popover-20050b91.js → data/Popover/Popover.styled.js} +6 -92
  18. package/build/data/Popover/Popover.styled.js.map +1 -0
  19. package/build/data/Popover/index.js +2 -10
  20. package/build/data/Popover/index.js.map +1 -0
  21. package/build/{Tab-04d435c3.js → data/Tab/Tab.js} +5 -12
  22. package/build/data/Tab/Tab.js.map +1 -0
  23. package/build/data/Tab/Tab.styled.js +13 -0
  24. package/build/data/Tab/Tab.styled.js.map +1 -0
  25. package/build/data/Tab/index.js +2 -5
  26. package/build/data/Tab/index.js.map +1 -0
  27. package/build/{Tabs-74d1ea8a.js → data/Tabs/Tabs.js} +6 -74
  28. package/build/data/Tabs/Tabs.js.map +1 -0
  29. package/build/data/Tabs/Tabs.styled.js +74 -0
  30. package/build/data/Tabs/Tabs.styled.js.map +1 -0
  31. package/build/data/Tabs/index.js +2 -7
  32. package/build/data/Tabs/index.js.map +1 -0
  33. package/build/{Tooltip-c1d1199e.js → data/Tooltip/Tooltip.js} +5 -26
  34. package/build/data/Tooltip/Tooltip.js.map +1 -0
  35. package/build/data/Tooltip/Tooltip.styled.js +28 -0
  36. package/build/data/Tooltip/Tooltip.styled.js.map +1 -0
  37. package/build/data/Tooltip/index.js +2 -7
  38. package/build/data/Tooltip/index.js.map +1 -0
  39. package/build/data/VerificationStatusIcon/VerificationStatusIcon.js +36 -0
  40. package/build/data/VerificationStatusIcon/VerificationStatusIcon.js.map +1 -0
  41. package/build/data/VerificationStatusIcon/VerificationStatusIcon.styled.js +53 -0
  42. package/build/data/VerificationStatusIcon/VerificationStatusIcon.styled.js.map +1 -0
  43. package/build/data/index.js +8 -16
  44. package/build/data/index.js.map +1 -0
  45. package/build/hooks/useEventListner.js +21 -0
  46. package/build/hooks/useEventListner.js.map +1 -0
  47. package/build/hooks/useIsomorphicLayoutEffect.js +6 -0
  48. package/build/hooks/useIsomorphicLayoutEffect.js.map +1 -0
  49. package/build/hooks/useOnClickOutside.js +14 -0
  50. package/build/hooks/useOnClickOutside.js.map +1 -0
  51. package/build/icons/arrow-back.svg.js +16 -0
  52. package/build/icons/arrow-back.svg.js.map +1 -0
  53. package/build/{arrow-forward-ad12c5f3.js → icons/arrow-forward.svg.js} +2 -1
  54. package/build/icons/arrow-forward.svg.js.map +1 -0
  55. package/build/icons/check-rectangle-filled.svg.js +16 -0
  56. package/build/icons/check-rectangle-filled.svg.js.map +1 -0
  57. package/build/{close-a5d37608.js → icons/close.svg.js} +2 -1
  58. package/build/icons/close.svg.js.map +1 -0
  59. package/build/{edit-note-283a0e15.js → icons/edit-note.svg.js} +2 -1
  60. package/build/icons/edit-note.svg.js.map +1 -0
  61. package/build/{expand-more-c5523c46.js → icons/expand-more.svg.js} +2 -1
  62. package/build/icons/expand-more.svg.js.map +1 -0
  63. package/build/icons/headset.svg.js +16 -0
  64. package/build/icons/headset.svg.js.map +1 -0
  65. package/build/icons/layers.svg.js +16 -0
  66. package/build/icons/layers.svg.js.map +1 -0
  67. package/build/icons/link.svg.js +16 -0
  68. package/build/icons/link.svg.js.map +1 -0
  69. package/build/icons/play.svg.js +16 -0
  70. package/build/icons/play.svg.js.map +1 -0
  71. package/build/icons/search.svg.js +16 -0
  72. package/build/icons/search.svg.js.map +1 -0
  73. package/build/icons/star-filled.svg.js +16 -0
  74. package/build/icons/star-filled.svg.js.map +1 -0
  75. package/build/icons/star.svg.js +16 -0
  76. package/build/icons/star.svg.js.map +1 -0
  77. package/build/icons/triangle-right.svg.js +16 -0
  78. package/build/icons/triangle-right.svg.js.map +1 -0
  79. package/build/icons/verification.svg.js +16 -0
  80. package/build/icons/verification.svg.js.map +1 -0
  81. package/build/{warning-circle-24f3efcd.js → icons/warning-circle.svg.js} +2 -1
  82. package/build/icons/warning-circle.svg.js.map +1 -0
  83. package/build/index.js +5 -0
  84. package/build/index.js.map +1 -0
  85. package/build/inputs/ActionButton/ActionButton.js +36 -0
  86. package/build/inputs/ActionButton/ActionButton.js.map +1 -0
  87. package/build/{ActionButton-4db754c3.js → inputs/ActionButton/ActionButton.styled.js} +4 -34
  88. package/build/inputs/ActionButton/ActionButton.styled.js.map +1 -0
  89. package/build/inputs/ActionButton/index.js +2 -6
  90. package/build/inputs/ActionButton/index.js.map +1 -0
  91. package/build/inputs/Button/Button.js +188 -0
  92. package/build/inputs/Button/Button.js.map +1 -0
  93. package/build/{Button-73eb8516.js → inputs/Button/Button.styled.js} +4 -186
  94. package/build/inputs/Button/Button.styled.js.map +1 -0
  95. package/build/inputs/Button/index.js +2 -13
  96. package/build/inputs/Button/index.js.map +1 -0
  97. package/build/inputs/Checkbox/Checkbox.js +97 -0
  98. package/build/inputs/Checkbox/Checkbox.js.map +1 -0
  99. package/build/inputs/Checkbox/Checkbox.styled.js +122 -0
  100. package/build/inputs/Checkbox/Checkbox.styled.js.map +1 -0
  101. package/build/inputs/Checkbox/index.js +2 -6
  102. package/build/inputs/Checkbox/index.js.map +1 -0
  103. package/build/inputs/CompactAutocompleteSelect/CompactAutocompleteSelect.js +267 -0
  104. package/build/inputs/CompactAutocompleteSelect/CompactAutocompleteSelect.js.map +1 -0
  105. package/build/{CompactAutocompleteSelect-52c49513.js → inputs/CompactAutocompleteSelect/CompactAutocompleteSelect.styled.js} +6 -267
  106. package/build/inputs/CompactAutocompleteSelect/CompactAutocompleteSelect.styled.js.map +1 -0
  107. package/build/inputs/CompactAutocompleteSelect/index.js +2 -23
  108. package/build/inputs/CompactAutocompleteSelect/index.js.map +1 -0
  109. package/build/inputs/CompactStarRating/CompactStarRating.js +177 -0
  110. package/build/inputs/CompactStarRating/CompactStarRating.js.map +1 -0
  111. package/build/inputs/CompactStarRating/CompactStarRating.styled.js +217 -0
  112. package/build/inputs/CompactStarRating/CompactStarRating.styled.js.map +1 -0
  113. package/build/inputs/CompactStarRating/index.js +2 -17
  114. package/build/inputs/CompactStarRating/index.js.map +1 -0
  115. package/build/inputs/CompactTextInput/CompactTextInput.js +184 -0
  116. package/build/inputs/CompactTextInput/CompactTextInput.js.map +1 -0
  117. package/build/{CompactTextInput-42ca5d42.js → inputs/CompactTextInput/CompactTextInput.styled.js} +4 -194
  118. package/build/inputs/CompactTextInput/CompactTextInput.styled.js.map +1 -0
  119. package/build/inputs/CompactTextInput/index.js +2 -19
  120. package/build/inputs/CompactTextInput/index.js.map +1 -0
  121. package/build/inputs/MultiLevelCheckbox/MultiLevelCheckbox.js +207 -0
  122. package/build/inputs/MultiLevelCheckbox/MultiLevelCheckbox.js.map +1 -0
  123. package/build/inputs/MultiLevelCheckbox/MultiLevelCheckbox.styled.js +66 -0
  124. package/build/inputs/MultiLevelCheckbox/MultiLevelCheckbox.styled.js.map +1 -0
  125. package/build/inputs/MultiLevelCheckbox/index.js +3 -0
  126. package/build/inputs/MultiLevelCheckbox/index.js.map +1 -0
  127. package/build/inputs/MultiLevelCheckbox/types.js +27 -0
  128. package/build/inputs/MultiLevelCheckbox/types.js.map +1 -0
  129. package/build/inputs/MultiLevelCheckboxSelect/MultiLevelCheckboxSelect.js +184 -26
  130. package/build/inputs/MultiLevelCheckboxSelect/MultiLevelCheckboxSelect.js.map +1 -0
  131. package/build/inputs/MultiLevelCheckboxSelect/MultiLevelCheckboxSelect.styled.js +93 -0
  132. package/build/inputs/MultiLevelCheckboxSelect/MultiLevelCheckboxSelect.styled.js.map +1 -0
  133. package/build/inputs/MultiLevelCheckboxSelect/index.js +2 -0
  134. package/build/inputs/MultiLevelCheckboxSelect/index.js.map +1 -0
  135. package/build/{MultiSelect-9f497e62.js → inputs/MultiSelect/MultiSelect.js} +6 -223
  136. package/build/inputs/MultiSelect/MultiSelect.js.map +1 -0
  137. package/build/inputs/MultiSelect/MultiSelect.styled.js +224 -0
  138. package/build/inputs/MultiSelect/MultiSelect.styled.js.map +1 -0
  139. package/build/inputs/MultiSelect/index.js +2 -10
  140. package/build/inputs/MultiSelect/index.js.map +1 -0
  141. package/build/inputs/Radio/Radio.js +60 -0
  142. package/build/inputs/Radio/Radio.js.map +1 -0
  143. package/build/{Radio-73ca3ae2.js → inputs/Radio/Radio.styled.js} +4 -58
  144. package/build/inputs/Radio/Radio.styled.js.map +1 -0
  145. package/build/inputs/Radio/index.js +2 -7
  146. package/build/inputs/Radio/index.js.map +1 -0
  147. package/build/inputs/Switch/Switch.js +64 -0
  148. package/build/inputs/Switch/Switch.js.map +1 -0
  149. package/build/{Switch-ecf3122b.js → inputs/Switch/Switch.styled.js} +4 -62
  150. package/build/inputs/Switch/Switch.styled.js.map +1 -0
  151. package/build/inputs/Switch/index.js +2 -6
  152. package/build/inputs/Switch/index.js.map +1 -0
  153. package/build/inputs/TextArea/TextArea.js +178 -0
  154. package/build/inputs/TextArea/TextArea.js.map +1 -0
  155. package/build/{TextArea-1e5b9201.js → inputs/TextArea/TextArea.styled.js} +3 -175
  156. package/build/inputs/TextArea/TextArea.styled.js.map +1 -0
  157. package/build/inputs/TextArea/index.js +2 -20
  158. package/build/inputs/TextArea/index.js.map +1 -0
  159. package/build/inputs/TextInput/TextInput.js +139 -0
  160. package/build/inputs/TextInput/TextInput.js.map +1 -0
  161. package/build/{TextInput-fab35842.js → inputs/TextInput/TextInput.styled.js} +4 -137
  162. package/build/inputs/TextInput/TextInput.styled.js.map +1 -0
  163. package/build/inputs/TextInput/index.js +2 -9
  164. package/build/inputs/TextInput/index.js.map +1 -0
  165. package/build/inputs/index.js +15 -40
  166. package/build/inputs/index.js.map +1 -0
  167. package/build/{InputGroup-1294d190.js → layout/InputGroup/InputGroup.js} +5 -8
  168. package/build/layout/InputGroup/InputGroup.js.map +1 -0
  169. package/build/layout/InputGroup/InputGroup.styled.js +9 -0
  170. package/build/layout/InputGroup/InputGroup.styled.js.map +1 -0
  171. package/build/layout/SectionSeparator/SectionSeparator.js +23 -0
  172. package/build/layout/SectionSeparator/SectionSeparator.js.map +1 -0
  173. package/build/layout/SectionSeparator/SectionSeparator.styled.js +14 -0
  174. package/build/layout/SectionSeparator/SectionSeparator.styled.js.map +1 -0
  175. package/build/layout/SectionSeparator/index.js +2 -5
  176. package/build/layout/SectionSeparator/index.js.map +1 -0
  177. package/build/layout/index.js +3 -6
  178. package/build/layout/index.js.map +1 -0
  179. package/build/ssr/index.js +1 -0
  180. package/build/ssr/index.js.map +1 -0
  181. package/build/styles/utils/colors.scss.js +4 -0
  182. package/build/styles/utils/colors.scss.js.map +1 -0
  183. package/build/utils/dateTime.js +17 -0
  184. package/build/utils/dateTime.js.map +1 -0
  185. package/build/utils/defaultTheme.js +44 -0
  186. package/build/utils/defaultTheme.js.map +1 -0
  187. package/build/{AssetAction-98d76ce0.js → widgets/AssetAction/AssetAction.js} +6 -40
  188. package/build/widgets/AssetAction/AssetAction.js.map +1 -0
  189. package/build/widgets/AssetAction/AssetAction.styled.js +41 -0
  190. package/build/widgets/AssetAction/AssetAction.styled.js.map +1 -0
  191. package/build/widgets/AssetAction/index.js +2 -7
  192. package/build/widgets/AssetAction/index.js.map +1 -0
  193. package/build/{AssetActionsBase-9e4c0735.js → widgets/AssetActionsBase/AssetActionsBase.js} +6 -15
  194. package/build/widgets/AssetActionsBase/AssetActionsBase.js.map +1 -0
  195. package/build/widgets/AssetActionsBase/AssetActionsBase.styled.js +15 -0
  196. package/build/widgets/AssetActionsBase/AssetActionsBase.styled.js.map +1 -0
  197. package/build/widgets/AssetActionsBase/index.js +2 -8
  198. package/build/widgets/AssetActionsBase/index.js.map +1 -0
  199. package/build/widgets/AssetGallery/AssetGallery.js +99 -0
  200. package/build/widgets/AssetGallery/AssetGallery.js.map +1 -0
  201. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryBase.js +385 -0
  202. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryBase.js.map +1 -0
  203. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryBase.styled.js +30 -0
  204. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryBase.styled.js.map +1 -0
  205. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryCompactCard/AssetGalleryCompactCard.js +401 -0
  206. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryCompactCard/AssetGalleryCompactCard.js.map +1 -0
  207. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryCompactCard/AssetGalleryCompactCard.styled.js +329 -0
  208. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryCompactCard/AssetGalleryCompactCard.styled.js.map +1 -0
  209. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryGridCard/AssetGalleryGridCard.js +409 -0
  210. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryGridCard/AssetGalleryGridCard.js.map +1 -0
  211. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryGridCard/AssetGalleryGridCard.styled.js +280 -0
  212. package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryGridCard/AssetGalleryGridCard.styled.js.map +1 -0
  213. package/build/widgets/AssetGallery/asset.propType.js +54 -0
  214. package/build/widgets/AssetGallery/asset.propType.js.map +1 -0
  215. package/build/widgets/AssetGallery/index.js +2 -48
  216. package/build/widgets/AssetGallery/index.js.map +1 -0
  217. package/build/widgets/AssetPreview/AssetPreviewTopBar/AssetPreviewTopBar.js +44 -0
  218. package/build/widgets/AssetPreview/AssetPreviewTopBar/AssetPreviewTopBar.js.map +1 -0
  219. package/build/widgets/AssetPreview/AssetPreviewTopBar/AssetPreviewTopBar.styled.js +77 -0
  220. package/build/widgets/AssetPreview/AssetPreviewTopBar/AssetPreviewTopBar.styled.js.map +1 -0
  221. package/build/widgets/AssetPreview/AssetPreviewTopBar/index.js +2 -6
  222. package/build/widgets/AssetPreview/AssetPreviewTopBar/index.js.map +1 -0
  223. package/build/{ContextMenu-0f7134e4.js → widgets/ContextMenu/ContextMenu.js} +5 -9
  224. package/build/widgets/ContextMenu/ContextMenu.js.map +1 -0
  225. package/build/widgets/ContextMenu/ContextMenu.styled.js +10 -0
  226. package/build/widgets/ContextMenu/ContextMenu.styled.js.map +1 -0
  227. package/build/widgets/ContextMenu/ContextMenuItem/ContextMenuItem.js +44 -0
  228. package/build/widgets/ContextMenu/ContextMenuItem/ContextMenuItem.js.map +1 -0
  229. package/build/widgets/ContextMenu/ContextMenuItem/ContextMenuItem.styled.js +77 -0
  230. package/build/widgets/ContextMenu/ContextMenuItem/ContextMenuItem.styled.js.map +1 -0
  231. package/build/widgets/ContextMenu/ContextMenuItem/index.js +2 -5
  232. package/build/widgets/ContextMenu/ContextMenuItem/index.js.map +1 -0
  233. package/build/widgets/ContextMenu/ContextMenuItemsGroup/ContextMenuItemsGroup.js +22 -0
  234. package/build/widgets/ContextMenu/ContextMenuItemsGroup/ContextMenuItemsGroup.js.map +1 -0
  235. package/build/widgets/ContextMenu/ContextMenuItemsGroup/ContextMenuItemsGroup.styled.js +21 -0
  236. package/build/widgets/ContextMenu/ContextMenuItemsGroup/ContextMenuItemsGroup.styled.js.map +1 -0
  237. package/build/widgets/ContextMenu/ContextMenuItemsGroup/index.js +2 -37
  238. package/build/widgets/ContextMenu/ContextMenuItemsGroup/index.js.map +1 -0
  239. package/build/widgets/ContextMenu/index.js +2 -5
  240. package/build/widgets/ContextMenu/index.js.map +1 -0
  241. package/build/widgets/InfoCard/InfoCard.js +40 -0
  242. package/build/widgets/InfoCard/InfoCard.js.map +1 -0
  243. package/build/{InfoCard-c98b6f5a.js → widgets/InfoCard/InfoCard.styled.js} +5 -38
  244. package/build/widgets/InfoCard/InfoCard.styled.js.map +1 -0
  245. package/build/widgets/InfoCard/index.js +2 -6
  246. package/build/widgets/InfoCard/index.js.map +1 -0
  247. package/build/{Instructions-bfd28cea.js → widgets/Instructions/Instructions.js} +8 -34
  248. package/build/widgets/Instructions/Instructions.js.map +1 -0
  249. package/build/widgets/Instructions/Instructions.styled.js +32 -0
  250. package/build/widgets/Instructions/Instructions.styled.js.map +1 -0
  251. package/build/widgets/Instructions/index.js +2 -28
  252. package/build/widgets/Instructions/index.js.map +1 -0
  253. package/build/widgets/ProgressBar/ProgressBar.js +72 -0
  254. package/build/widgets/ProgressBar/ProgressBar.js.map +1 -0
  255. package/build/{ProgressBar-bc4a4a7e.js → widgets/ProgressBar/ProgressBar.styled.js} +5 -70
  256. package/build/widgets/ProgressBar/ProgressBar.styled.js.map +1 -0
  257. package/build/widgets/ProgressBar/index.js +2 -6
  258. package/build/widgets/ProgressBar/index.js.map +1 -0
  259. package/build/widgets/SummaryCard/SummaryCard.js +92 -0
  260. package/build/widgets/SummaryCard/SummaryCard.js.map +1 -0
  261. package/build/widgets/SummaryCard/SummaryCard.styled.js +137 -0
  262. package/build/widgets/SummaryCard/SummaryCard.styled.js.map +1 -0
  263. package/build/widgets/SummaryCard/index.js +2 -19
  264. package/build/widgets/SummaryCard/index.js.map +1 -0
  265. package/build/widgets/index.js +12 -53
  266. package/build/widgets/index.js.map +1 -0
  267. package/package.json +5 -2
  268. package/build/AssetGallery-63f721ec.js +0 -1981
  269. package/build/AssetPreviewTopBar-acd6353d.js +0 -127
  270. package/build/Checkbox-4a5fd716.js +0 -213
  271. package/build/CompactStarRating-9af2f427.js +0 -411
  272. package/build/ContextMenuItem-ea411141.js +0 -127
  273. package/build/MultiLevelCheckboxSelect-d8044c88.js +0 -604
  274. package/build/SectionSeparator-f47760a2.js +0 -31
  275. package/build/SummaryCard-24040650.js +0 -223
  276. package/build/VerificationStatusIcon-49cb1c1b.js +0 -95
  277. package/build/defaultTheme-1bcc2541.js +0 -1178
  278. package/build/layout/InputGroup/index.js +0 -5
  279. package/build/shift-away-subtle-0dd94a03.js +0 -7
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MultiSelect.js","sources":["../../../src/components/inputs/MultiSelect/MultiSelect.js"],"sourcesContent":["import React, { useState, useMemo, useEffect } from 'react';\nimport PropTypes from 'prop-types';\nimport { nanoid } from 'nanoid';\nimport * as S from './MultiSelect.styled';\n\nimport { ReactComponent as CloseIcon } from '../../../icons/close.svg';\n\n/**\n * Multi-select with autocomplete and support for asynchronous fetching/filtering of\n * available options with pagination, update handling with callback,\n * and the ability for the end-user to create new options.\n *\n * The component uses [react-select](https://react-select.com/) for the main select functionality,\n * with [react-select-async-paginate](https://www.npmjs.com/package/react-select-async-paginate) for pagination.\n *\n *\n * <br />### Import\n *\n * ``` js\n * import { MultiSelect } from '@ntbjs/react-components/inputs'\n * // or\n * import MultiSelect from '@ntbjs/react-components/inputs/MultiSelect'\n * ```\n *\n * <br />## Option `object` format\n * Options are represented by an `Array` of `objects` with the following format:\n *\n * ``` js\n * {\n * value: \"Example\",\n * label: \"Example\"\n * }\n * ```\n *\n * The `label` is what will visible to the end-user. Whether `value` and `label`\n * should be different will depend on your use-case, but they are not required to.\n *\n *\n * <br />## Update handling\n * Changes from the end-user to the selected/available options can be handled with a callback function\n * passed through the `onUpdateCallback` prop, which is triggered any time the selected values change.\n *\n * The callback function will be passed two arguments:\n * * `action: string`\n * * `updatedOption: object`\n *\n * <br />#### `action`\n * A `string` indicating what kind of update was made.\n *\n * The possible values of `action` are:\n * * `create-option`: an option that didn't exist in the original list of available options were added\n * * `select-option`: an option was selected\n * * `deselect-option`: an option was de-selected by clicking the X in the dropdown menu\n * * `remove-value`: an option was de-selected by clicking the X on the option label/box\n * * `pop-value`: an option was de-selected with backspace\n * * `clear`: all options were de-selected by clicking the clear indicator (not currently in use)\n *\n * <br />#### `updatedOption`\n * Option `object`of the updated option:\n *\n * In addition to the default `value` and `label` keys, an `__isNew__` flag will be present if the option was\n * not part of the original list of available options, i.e. created by the user in the current \"session\".\n * This is the case regardless of whether the list is provided through `availableOptions` or\n * asynchronously through `loadOptions`.\n *\n *\n * <br />## Asynchronous fetching/filtering with pagination\n * The list of available options can be fetched and filtered asynchronously with a `Promise`\n * passed through the `loadOptions` prop.\n *\n * It will be passed two arguments:\n *\n * * `inputValue: string`: current input value/search\n * * `prevOptions: Array`: previously loaded options for the current search\n *\n * The function is triggered and the first page is fetched when the dropdown menu opens.\n * Whenever the user scrolls down to the bottom of the list, `loadOptions` will\n * be triggered again to fetch the next page.\n *\n * The `Promise` should return an `object` with the following keys:\n *\n * ``` js\n * {\n * options: Array,\n * hasMore: boolean\n * }\n * ```\n *\n * `options` should contain the current page of options. It will be concatenated to the previous\n * set of options automatically. The `hasMore` flag indicates whether there is another page to be fetched.\n *\n * **Example:**\n *\n * ``` js\n *\n * const availableOptions = [\n * { value: \"Example 1\", label: \"Example 1\" },\n * ...\n * { value: \"Example N\", label: \"Example N\" }\n * ];\n *\n * const filterOptions = inputValue => {\n * return availableOptions.filter(option => {\n * return option.label.toLowerCase().includes(inputValue.toLowerCase());\n * });\n * };\n *\n * const loadOptionsFunc = (inputValue, prevOptions) => {\n * const currentLength = prevOptions.length;\n * const pageLength = 10;\n *\n * let filteredOptions;\n *\n * if (inputValue) {\n * filteredOptions = filterOptions(inputValue);\n * } else {\n * filteredOptions = availableOptions;\n * }\n *\n * const hasMore = filteredOptions.length > currentLength + pageLength;\n * const slicedOptions = filteredOptions.slice(currentLength, currentLength + pageLength);\n *\n * return {\n * options: slicedOptions,\n * hasMore\n * };\n * };\n *\n * const loadOptions = (inputValue, prevOptions) => {\n * return new Promise(resolve => {\n * resolve(loadOptionsFunc(inputValue, prevOptions));\n * });\n * };\n * ```\n *\n * While waiting for the `Promise` to resolve, the component will be in a loading state.\n * The loading state is showcased in the \"Primary With Fetching Timeout\" Story.\n *\n * <br />#### Without asynchronous fetching/filtering\n * If you wish to not use asynchronous fetching/filtering, leave the `loadOptions` prop undefined\n * and pass the `Array` of all available options to the `availableOptions` prop instead.\n * The component will use the built-in filtering on `label` from `react-select`, and the options\n * will not be paginated.\n *\n *\n * <br />## \"Show more\" overlay\n * The \"Show more\" overlay must be set manually with the `showMore` prop.\n *\n * By default, the total number\n * of selected options will be displayed in parenthesis after the \"Show more\" text. This can be\n * disabled with the `displayTotalOnShowMore` prop.\n *\n * **Note:**\n * <br />The component has been given a max-width in these Stories.\n * This is because the \"Show more\" overlay does not work well visually when there are\n * fewer than three rows of selected options. The component itself does not have\n * a max-width, so keep this in mind when using it.\n *\n * <br />\n */\nconst MultiSelect = React.forwardRef(function MultiSelect(\n {\n label,\n selectedOptions,\n availableOptions,\n loadOptions,\n loadingMessageFunc,\n onUpdateCallback,\n editText,\n createNewOptionMessageFunc,\n noOptionsMessageFunc,\n onMultiValueClick,\n showMore,\n showMoreText,\n displayTotalOnShowMore,\n creatable,\n readOnly,\n hidden,\n disabled,\n error,\n warning,\n ...props\n },\n forwardedRef\n) {\n const [uniqueId] = useState(nanoid());\n const [selected, setSelected] = useState(selectedOptions);\n const [focused, setFocused] = useState(false);\n const [displayShowMore, setDisplayShowMore] = useState(error || warning ? false : showMore);\n const [cacheUnique, setCacheUnique] = useState(0);\n\n useEffect(() => {\n setSelected(selectedOptions);\n }, [selectedOptions]);\n\n const handleShowMoreClick = () => {\n setDisplayShowMore(false);\n };\n\n /**\n * Inner components to replace the default components of 'react-select'.\n * This is to add classnames, custom styling and functionality.\n *\n * Some of these are defined here, inside of the main MultiSelect,\n * because they use our props for custom styling/functionality.\n * The ones that don't are defined outside of (below) the main component.\n */\n const Control = useMemo(() => {\n const ControlWrapper = innerProps => {\n return <S.Control className=\"multi-select-control\" readOnly={readOnly} {...innerProps} />;\n };\n ControlWrapper.displayName = 'ControlWrapper';\n return ControlWrapper;\n }, []);\n\n const ValueContainer = useMemo(() => {\n const ValueContainerWrapper = innerProps => {\n return (\n <>\n {label && <S.Label htmlFor={uniqueId}>{label}</S.Label>}\n <S.ValueContainer\n showMore={displayShowMore}\n error={error}\n warning={warning}\n className=\"multi-select-values-container\"\n {...innerProps}\n />\n </>\n );\n };\n ValueContainerWrapper.displayName = 'ValueContainerWrapper';\n return ValueContainerWrapper;\n }, [displayShowMore, error, warning]);\n\n const MultiValue = innerProps => {\n return (\n <S.MultiValueWrapper\n className=\"multi-value-wrapper\"\n onMouseDown={e => {\n e.stopPropagation();\n\n if (\n onMultiValueClick &&\n innerProps.data &&\n !(e.target.role === 'button' || e.target instanceof SVGElement)\n ) {\n onMultiValueClick(innerProps.data);\n }\n }}\n >\n <S.MultiValue className=\"multi-value\" readOnly={readOnly} {...innerProps} />\n </S.MultiValueWrapper>\n );\n };\n\n const Input = useMemo(() => {\n const InputWrapper = innerProps => {\n return (\n <S.Input\n className=\"multi-select-input\"\n $focused={focused}\n edittext={editText}\n {...innerProps}\n isDisabled={readOnly || disabled}\n />\n );\n };\n InputWrapper.displayName = 'InputWrapper';\n return InputWrapper;\n }, [focused]);\n\n /**\n * Replace inner components of 'react-select'\n */\n const innerComponents = {\n DropdownIndicator: null,\n Control,\n MultiValue,\n MultiValueRemove: innerProps => {\n return readOnly || disabled ? false : MultiValueRemove(innerProps);\n },\n ValueContainer,\n Input,\n Menu,\n Option: innerProps => {\n return innerProps.isSelected ? SelectedOption(innerProps) : Option(innerProps);\n }\n };\n\n /**\n * Props from 'react-select'/'react-select-async-paginate' shared by the different Select versions\n */\n const sharedSelectProps = {\n ref: forwardedRef,\n value: selected,\n options: loadOptions ? undefined : availableOptions,\n loadOptions: loadOptions,\n loadingMessage: loadingMessageFunc,\n editText: editText,\n formatCreateLabel: createNewOptionMessageFunc,\n showMore: displayShowMore,\n readOnly: readOnly,\n isDisabled: disabled,\n components: innerComponents,\n focused: focused,\n isMulti: true,\n isClearable: false,\n placeholder: null,\n closeMenuOnSelect: false,\n hideSelectedOptions: false,\n cacheUniqs: loadOptions ? [cacheUnique] : undefined,\n onFocus: () => setFocused(true),\n onBlur: () => setFocused(false),\n\n noOptionsMessage: input => {\n return noOptionsMessageFunc(input.inputValue);\n },\n\n onChange: (selectedOptions, actionMeta) => {\n switch (actionMeta.action) {\n case 'create-option':\n if (onUpdateCallback) {\n onUpdateCallback(actionMeta.action, actionMeta.option);\n }\n\n if (loadOptions) {\n setCacheUnique(cacheUnique + 1);\n }\n\n setSelected(selectedOptions);\n break;\n\n case 'select-option':\n if (onUpdateCallback) {\n onUpdateCallback(actionMeta.action, actionMeta.option);\n }\n\n setSelected(selectedOptions);\n break;\n\n case 'remove-value':\n if (onUpdateCallback) {\n onUpdateCallback(actionMeta.action, actionMeta.removedValue);\n }\n\n setSelected(selectedOptions);\n break;\n\n case 'pop-value':\n if (onUpdateCallback) {\n onUpdateCallback(actionMeta.action, actionMeta.removedValue);\n }\n\n setSelected(selectedOptions);\n break;\n\n case 'deselect-option':\n if (onUpdateCallback) {\n onUpdateCallback(actionMeta.action, actionMeta.option);\n }\n\n setSelected(selectedOptions);\n break;\n\n case 'clear':\n // Does currently not occur as 'isClearable' is always set to false\n break;\n\n default:\n if (onUpdateCallback) {\n onUpdateCallback(actionMeta.action, actionMeta.option);\n }\n\n setSelected(selectedOptions);\n break;\n }\n }\n };\n\n if (hidden) return null;\n\n return (\n <S.MultiSelectWrapper error={error} warning={warning}>\n {loadOptions ? (\n creatable ? (\n <S.AsyncCreatableMultiSelect {...sharedSelectProps} {...props} />\n ) : (\n <S.AsyncMultiSelect {...sharedSelectProps} {...props} />\n )\n ) : creatable ? (\n <S.CreatableMultiSelect {...sharedSelectProps} {...props} />\n ) : (\n <S.MultiSelect {...sharedSelectProps} {...props} />\n )}\n {displayShowMore && !(error || warning) && (\n <S.ShowMoreWrapper onClick={handleShowMoreClick}>\n <S.ShowMoreOverlay></S.ShowMoreOverlay>\n <S.ShowMoreText>\n {showMoreText} {displayTotalOnShowMore && '(' + selected.length + ')'}\n </S.ShowMoreText>\n </S.ShowMoreWrapper>\n )}\n {(typeof error === 'string' || typeof warning === 'string') && (\n <S.ErrorMessage error={error} warning={warning}>\n {error ? error : warning}\n </S.ErrorMessage>\n )}\n </S.MultiSelectWrapper>\n );\n});\n\nMultiSelect.propTypes = {\n /**\n *\n * The label of the input field – leave `undefined` to hide the label\n */\n label: PropTypes.string,\n /**\n * `Array` of `objects` containing the default options. This is only needed\n * when asynchronous option fetching with the `loadOptions` prop is not used.\n *\n * **Note:**\n * <br />This will be overridden by the `loadOptions` prop if both props are set.\n */\n availableOptions: PropTypes.arrayOf(PropTypes.object),\n\n /**\n * `Array` of `objects` containing the selected options.\n */\n selectedOptions: PropTypes.arrayOf(PropTypes.object),\n\n /**\n * Function with a `Promise` returning filtered options.\n *\n * See [Asynchronous fetching/filtering with pagination](#asynchronous-fetchingfiltering-with-pagination)\n * for details.\n *\n * **Note:**\n * <br />This will override the `availableOptions` prop if both props are set.\n */\n loadOptions: PropTypes.func,\n\n /**\n * Function for custom \"Loading...\" message while waiting for the first page\n * from `loadOptions` to resolve. Defaults to \"Loading...\" if no function is provided.\n */\n loadingMessageFunc: PropTypes.func,\n\n /**\n * Callback function for sending updates to the backend whenever the selected values are updated.\n * See [Update handling](#update-handling) for details.\n */\n onUpdateCallback: PropTypes.func,\n\n /**\n * Text to be displayed on the input element when the component\n * is enabled and not focused – e.g. \"Add a keyword...\"\n */\n editText: PropTypes.string.isRequired,\n\n /**\n * Whether the user can create new options.\n */\n creatable: PropTypes.bool,\n\n /**\n * Callback function for formatting the message displayed in the dropdown when there\n * are no matching options, and the user has permission to create new options.\n * The callback function will be given the current input value as an argument.\n */\n createNewOptionMessageFunc: PropTypes.func,\n\n /**\n * If the list of options is empty, or if the current input value doesn't match\n * any of the available options and the user doesn't have permission to add options,\n * this function will be called and passed the current input value as an argument.\n */\n noOptionsMessageFunc: PropTypes.func,\n\n /**\n * Optional callback function to be trigger when clicking a selected option's label – e.g. opening\n * a search filtered on the given multi-value's `label`.\n *\n * The callback function will be passed the option `object` as an argument.\n */\n onMultiValueClick: PropTypes.func,\n\n /**\n * Display an overlay which the user needs to click in order to\n * show the selected options list in its entirety and edit it.\n */\n showMore: PropTypes.bool,\n\n /**\n * Text displayed on the \"Show more\" overlay.\n */\n showMoreText: PropTypes.string,\n\n /**\n * Whether to display the total number of selected options after the show more text.\n */\n displayTotalOnShowMore: PropTypes.bool,\n\n /**\n * Whether the multi-select should be displayed in read-only mode.\n * The user can still click the selected options to trigger their on-click effect.\n */\n readOnly: PropTypes.bool,\n /**\n * Whether the component is hidden or visible.\n */\n hidden: PropTypes.bool,\n\n /**\n * Whether the multi-select should be disabled.\n * The user will not be able to trigger the on-click effect of the selected options.\n */\n disabled: PropTypes.bool,\n\n /**\n * Set to `true` to display a red border indicating an error.\n * Pass in a `string` instead to also show the string underneath the input field.\n *\n * **Note:**\n * <br />This overrides the \"Show more\" overlay. Errors will be prioritized over warnings.\n */\n error: PropTypes.oneOfType([PropTypes.bool, PropTypes.string]),\n\n /**\n * Set to `true` to display an orange border.\n * Pass in a `string` instead to also show the string underneath the input field.\n *\n * **Note:**\n * <br />This overrides the \"Show more\" overlay. Errors will be prioritized over warnings.\n */\n warning: PropTypes.oneOfType([PropTypes.bool, PropTypes.string])\n};\n\nMultiSelect.defaultProps = {\n noOptionsMessageFunc: inputValue => {\n if (inputValue) {\n return `No matches for \"${inputValue}\"`;\n } else {\n return 'No available options';\n }\n },\n showMore: false,\n displayTotalOnShowMore: true,\n readOnly: false,\n disabled: false,\n creatable: false,\n error: false,\n warning: false,\n showMoreText: 'Show more',\n hidden: false\n};\n\n/**\n * Inner components to replace the default inner components of 'react-select'.\n * This is to add classnames, custom styling and functionality.\n *\n * Some are defined inside of the main MultiSelect component, as they use our props\n * for prop/state dependent functionality and styling. The ones below do not.\n */\nconst MultiValueRemove = innerProps => {\n return (\n <S.MultiValueRemove {...innerProps}>\n <CloseIcon className=\"multi-value-remove-icon\" />\n </S.MultiValueRemove>\n );\n};\n\nconst Menu = innerProps => {\n return <S.DropdownMenu {...innerProps} />;\n};\n\nconst Option = innerProps => {\n return <S.Option className=\"multi-select-dropdown-item\" {...innerProps} />;\n};\n\nconst SelectedOption = innerProps => {\n return (\n <S.SelectedOption {...innerProps}>\n {innerProps.label}\n <S.DropdownOptionDeleteIcon />\n </S.SelectedOption>\n );\n};\n\nexport default MultiSelect;\n"],"names":["MultiSelect","React","forwardRef","label","selectedOptions","availableOptions","loadOptions","loadingMessageFunc","onUpdateCallback","editText","createNewOptionMessageFunc","noOptionsMessageFunc","onMultiValueClick","showMore","showMoreText","displayTotalOnShowMore","creatable","readOnly","hidden","disabled","error","warning","props","forwardedRef","uniqueId","useState","nanoid","selected","setSelected","focused","setFocused","displayShowMore","setDisplayShowMore","cacheUnique","setCacheUnique","useEffect","handleShowMoreClick","Control","useMemo","ControlWrapper","innerProps","createElement","S","_extends","className","displayName","ValueContainer","ValueContainerWrapper","Fragment","htmlFor","MultiValue","onMouseDown","e","stopPropagation","data","target","role","SVGElement","Input","InputWrapper","$focused","edittext","isDisabled","innerComponents","DropdownIndicator","MultiValueRemove","Menu","Option","isSelected","SelectedOption","sharedSelectProps","ref","value","options","undefined","loadingMessage","formatCreateLabel","components","isMulti","isClearable","placeholder","closeMenuOnSelect","hideSelectedOptions","cacheUniqs","onFocus","onBlur","noOptionsMessage","input","inputValue","onChange","actionMeta","action","option","removedValue","onClick","length","propTypes","process","env","NODE_ENV","PropTypes","string","arrayOf","object","func","isRequired","bool","oneOfType","defaultProps","CloseIcon"],"mappings":";;;;;;;AAgKMA,MAAAA,WAAW,GAAGC,cAAK,CAACC,UAAU,CAAC,SAASF,WAAWA,CACv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A,CAACC,wBAA0B,EAAE,IAAA,CACb,CAAC,CAAA;AAEvB,CAAC;;;;"}
@@ -0,0 +1,224 @@
1
+ import styled, { css } from 'styled-components';
2
+ import { applyDefaultTheme } from '../../utils/defaultTheme.js';
3
+ import { ReactComponent as SvgClose } from '../../icons/close.svg.js';
4
+ import Select, { components } from 'react-select';
5
+ import CreatableSelect from 'react-select/creatable';
6
+ import { withAsyncPaginate, AsyncPaginate } from 'react-select-async-paginate';
7
+
8
+ const AsyncCreatableSelectPaginate = withAsyncPaginate(CreatableSelect);
9
+ const showMoreHeight = 114;
10
+ const sharedStyle = css`
11
+ font-family: ${props => props.theme.primaryFontFamily};
12
+ font-size: 12px;
13
+ font-weight: 400;
14
+ position: relative;
15
+ `;
16
+ const Label = styled.label.attrs(applyDefaultTheme)`
17
+ ${props => props.theme.themeProp('color', props.theme.getColor('white'), props.theme.getColor('gray-700'))};
18
+ flex-basis: 33.33%;
19
+ font-size: 0.875rem;
20
+ line-height: 1rem;
21
+ cursor: pointer;
22
+ height: 19px;
23
+ display: flex;
24
+ align-items: center;
25
+ `;
26
+ const MultiSelect = styled(Select).attrs(applyDefaultTheme)`
27
+ ${sharedStyle}
28
+ `;
29
+ const CreatableMultiSelect = styled(CreatableSelect).attrs(applyDefaultTheme)`
30
+ ${sharedStyle}
31
+ `;
32
+ const AsyncCreatableMultiSelect = styled(AsyncCreatableSelectPaginate).attrs(applyDefaultTheme)`
33
+ ${sharedStyle}
34
+ `;
35
+ const AsyncMultiSelect = styled(AsyncPaginate).attrs(applyDefaultTheme)`
36
+ ${sharedStyle}
37
+ `;
38
+ const MultiSelectWrapper = styled.div.attrs(applyDefaultTheme)`
39
+ position: relative;
40
+ `;
41
+ const Control = styled(components.Control).attrs(applyDefaultTheme)`
42
+ && {
43
+ align-items: flex-start;
44
+ background: transparent;
45
+ border: none;
46
+ box-shadow: none;
47
+ }
48
+
49
+ :hover {
50
+ cursor: ${props => !props.isDisabled && props.focused || props.readOnly ? 'default' : 'pointer'};
51
+ }
52
+ `;
53
+ const ValueContainer = styled(components.ValueContainer)`
54
+ && {
55
+ align-items: flex-start;
56
+ gap: 8px;
57
+ padding: 0;
58
+
59
+ max-height: ${props => {
60
+ return props.showMore ? props.error || props.warning ? '100%' : showMoreHeight + 16 + 'px' : '100%';
61
+ }} !important;
62
+
63
+ ${props => (props.error || props.warning) && css`
64
+ border: 1px solid;
65
+ border-radius: 3px;
66
+ padding: 4px;
67
+
68
+ border-color: ${props => props.error ? props.theme.getColor('red-500') : props.warning ? props.theme.getColor('orange-500') : 'inherit'};
69
+ `}
70
+ }
71
+ `;
72
+ const MultiValueWrapper = styled.div.attrs(applyDefaultTheme)`
73
+ && {
74
+ border-radius: 3px;
75
+ margin: 0;
76
+ }
77
+ `;
78
+ const MultiValue = styled(components.MultiValue).attrs(applyDefaultTheme)`
79
+ && {
80
+ border-radius: 3px;
81
+ margin: 0;
82
+
83
+ ${props => props.theme.themeProp('background-color', props.theme.getColor('gray-600'), props.theme.getColor('gray-800'))}
84
+
85
+ ${props => props.theme.themeProp('color', props.theme.getColor('gray-100'), props.theme.getColor('gray-100'))}
86
+
87
+ > div {
88
+ align-items: center;
89
+ display: flex;
90
+ font-size: 12px;
91
+ min-height: 26px;
92
+
93
+ :first-of-type {
94
+ padding: ${props => props.isDisabled || props.readOnly ? '0 8px' : '0 3px 0 8px'};
95
+ }
96
+
97
+ :last-of-type:not(:only-child) {
98
+ padding: 0 8px 0 5px;
99
+ height: 100%;
100
+ width: fit-content;
101
+ }
102
+
103
+ :last-of-type:not(:only-child):hover {
104
+ background-color: ${props => props.theme.getColor('red-500')};
105
+ border-bottom-left-radius: 0;
106
+ border-top-left-radius: 0;
107
+ cursor: pointer;
108
+ }
109
+
110
+ svg {
111
+ stroke: white;
112
+ stroke-width: 2px;
113
+ width: 8px;
114
+ }
115
+
116
+ :hover {
117
+ cursor: pointer;
118
+ }
119
+ }
120
+ `;
121
+ const MultiValueRemove = styled(components.MultiValueRemove).attrs(applyDefaultTheme)``;
122
+ const Input = styled(components.Input).attrs(applyDefaultTheme)`
123
+ align-self: center;
124
+ font-size: ${props => props.$focused ? '14px' : '12px'};
125
+ min-width: 150px;
126
+
127
+ ${props => props.theme.themeProp('color', props.theme.getColor('gray-100'), props.theme.getColor('gray-900'))}
128
+
129
+ ${props => !props.$focused && css`
130
+ ${props => props.theme.themeProp('color', props.theme.getColor('gray-400'), props.theme.getColor('gray-500'))}
131
+
132
+ :before {
133
+ height: 100%;
134
+ white-space: nowrap;
135
+ width: fit-content;
136
+ content: '${props => props.edittext}';
137
+ }
138
+ `}
139
+ }
140
+ `;
141
+ const DropdownMenu = styled(components.Menu).attrs(applyDefaultTheme)`
142
+ font-size: 14px;
143
+
144
+ ${props => props.theme.themeProp('background-color', props.theme.getColor('gray-600'), props.theme.getColor('white'))}
145
+
146
+ ${props => props.theme.themeProp('color', props.theme.getColor('gray-100'), props.theme.getColor('gray-900'))}
147
+ `;
148
+ const sharedOptionStyle = css`
149
+ ${props => props.isFocused && css`
150
+ ${props.theme.themeProp('background-color', props.theme.getColor('gray-500'), props.theme.getColor('gray-200'))}
151
+ `}
152
+
153
+ ${props => props.isSelected && css`
154
+ ${props.theme.themeProp('background-color', 'transparent', 'transparent')}
155
+
156
+ ${props.theme.themeProp('color', props.theme.getColor('gray-100'), props.theme.getColor('gray-900'))}
157
+ `}
158
+
159
+ ${props => props.isFocused && props.isSelected && css`
160
+ ${props.theme.themeProp('background-color', props.theme.getColor('gray-500'), props.theme.getColor('gray-200'))}
161
+ `}
162
+
163
+ :hover {
164
+ cursor: pointer;
165
+ }
166
+ `;
167
+ const Option = styled(components.Option).attrs(applyDefaultTheme)`
168
+ ${sharedOptionStyle}
169
+ `;
170
+ const SelectedOption = styled(components.Option).attrs(applyDefaultTheme)`
171
+ ${sharedOptionStyle}
172
+
173
+ display: flex !important;
174
+ justify-content: space-between;
175
+ `;
176
+ const DropdownOptionDeleteIcon = styled(SvgClose).attrs(applyDefaultTheme)`
177
+ stroke-width: 1px;
178
+ width: 8px;
179
+
180
+ ${props => props.theme.themeProp('stroke', props.theme.getColor('gray-100'), props.theme.getColor('gray-900'))}
181
+ `;
182
+ const ShowMoreWrapper = styled.div.attrs(applyDefaultTheme)`
183
+ align-items: end;
184
+ display: flex;
185
+ flex-direction: column;
186
+ height: 100%;
187
+ left: 0;
188
+ position: absolute;
189
+ max-height: ${showMoreHeight + 16}px;
190
+ top: 0;
191
+ width: 100%;
192
+
193
+ ${props => props.theme.themeProp('color', props.theme.getColor('gray-100'), props.theme.getColor('emerald-500'))}
194
+
195
+ :hover {
196
+ cursor: pointer;
197
+ text-decoration: underline;
198
+ }
199
+ `;
200
+ const ShowMoreOverlay = styled.div.attrs(applyDefaultTheme)`
201
+ align-items: end;
202
+ display: block;
203
+ height: 100%;
204
+ max-height: ${showMoreHeight}px;
205
+ left: 0;
206
+ top: 0;
207
+ width: 100%;
208
+
209
+ ${props => props.theme.themeProp('background', 'transparent linear-gradient(180deg, #12121200 0%, #12121230 40%, #12121279 70%, #121212 95%, #121212 100%) 0% 0% no-repeat padding-box', 'transparent linear-gradient(180deg, #fefefe00 0%, #fefefe30 40%, #fefefe79 70%, #fefefe 95%, #fefefe 100%) 0% 0% no-repeat padding-box')}
210
+ `;
211
+ const ShowMoreText = styled.div.attrs(applyDefaultTheme)`
212
+ font-size: 0.875rem;
213
+ width: 100%;
214
+ ${props => props.theme.themeProp('background-color', '#121212', '#fefefe')}
215
+ `;
216
+ const ErrorMessage = styled.div.attrs(applyDefaultTheme)`
217
+ color: ${props => props.error ? props.theme.getColor('red-500') : props.warning ? props.theme.getColor('orange-500') : 'inherit'};
218
+ font-size: 0.75rem;
219
+ margin-top: 8px;
220
+ padding: 0 12px;
221
+ `;
222
+
223
+ export { AsyncCreatableMultiSelect, AsyncMultiSelect, Control, CreatableMultiSelect, DropdownMenu, DropdownOptionDeleteIcon, ErrorMessage, Input, Label, MultiSelect, MultiSelectWrapper, MultiValue, MultiValueRemove, MultiValueWrapper, Option, SelectedOption, ShowMoreOverlay, ShowMoreText, ShowMoreWrapper, ValueContainer };
224
+ //# sourceMappingURL=MultiSelect.styled.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MultiSelect.styled.js","sources":["../../../src/components/inputs/MultiSelect/MultiSelect.styled.js"],"sourcesContent":["import styled, { css } from 'styled-components';\nimport { applyDefaultTheme } from '../../../utils/defaultTheme';\n\nimport { ReactComponent as CloseIcon } from '../../../icons/close.svg';\n\nimport Select from 'react-select';\nimport CreatableSelect from 'react-select/creatable';\nimport { AsyncPaginate, withAsyncPaginate } from 'react-select-async-paginate';\nimport { components } from 'react-select';\n\nconst AsyncCreatableSelectPaginate = withAsyncPaginate(CreatableSelect);\n\nconst showMoreHeight = 114;\n\nconst sharedStyle = css`\n font-family: ${props => props.theme.primaryFontFamily};\n font-size: 12px;\n font-weight: 400;\n position: relative;\n`;\n\nexport const Label = styled.label.attrs(applyDefaultTheme)`\n ${props =>\n props.theme.themeProp(\n 'color',\n props.theme.getColor('white'),\n props.theme.getColor('gray-700')\n )};\n flex-basis: 33.33%;\n font-size: 0.875rem;\n line-height: 1rem;\n cursor: pointer;\n height: 19px;\n display: flex;\n align-items: center;\n`;\n\nexport const MultiSelect = styled(Select).attrs(applyDefaultTheme)`\n ${sharedStyle}\n`;\n\nexport const CreatableMultiSelect = styled(CreatableSelect).attrs(applyDefaultTheme)`\n ${sharedStyle}\n`;\n\nexport const AsyncCreatableMultiSelect = styled(AsyncCreatableSelectPaginate).attrs(\n applyDefaultTheme\n)`\n ${sharedStyle}\n`;\n\nexport const AsyncMultiSelect = styled(AsyncPaginate).attrs(applyDefaultTheme)`\n ${sharedStyle}\n`;\n\nexport const MultiSelectWrapper = styled.div.attrs(applyDefaultTheme)`\n position: relative;\n`;\n\nexport const Control = styled(components.Control).attrs(applyDefaultTheme)`\n && {\n align-items: flex-start;\n background: transparent;\n border: none;\n box-shadow: none;\n }\n\n :hover {\n cursor: ${props =>\n (!props.isDisabled && props.focused) || props.readOnly ? 'default' : 'pointer'};\n }\n`;\n\nexport const ValueContainer = styled(components.ValueContainer)`\n && {\n align-items: flex-start;\n gap: 8px;\n padding: 0;\n\n max-height: ${props => {\n return props.showMore\n ? props.error || props.warning\n ? '100%'\n : showMoreHeight + 16 + 'px'\n : '100%';\n }} !important;\n\n ${props =>\n (props.error || props.warning) &&\n css`\n border: 1px solid;\n border-radius: 3px;\n padding: 4px;\n\n border-color: ${props =>\n props.error\n ? props.theme.getColor('red-500')\n : props.warning\n ? props.theme.getColor('orange-500')\n : 'inherit'};\n `}\n }\n`;\n\nexport const MultiValueWrapper = styled.div.attrs(applyDefaultTheme)`\n && {\n border-radius: 3px;\n margin: 0;\n }\n`;\n\nexport const MultiValue = styled(components.MultiValue).attrs(applyDefaultTheme)`\n && {\n border-radius: 3px;\n margin: 0;\n\n ${props =>\n props.theme.themeProp(\n 'background-color',\n props.theme.getColor('gray-600'),\n props.theme.getColor('gray-800')\n )}\n\n ${props =>\n props.theme.themeProp(\n 'color',\n props.theme.getColor('gray-100'),\n props.theme.getColor('gray-100')\n )}\n\n > div {\n align-items: center;\n display: flex;\n font-size: 12px;\n min-height: 26px;\n\n :first-of-type {\n padding: ${props => (props.isDisabled || props.readOnly ? '0 8px' : '0 3px 0 8px')};\n }\n\n :last-of-type:not(:only-child) {\n padding: 0 8px 0 5px;\n height: 100%;\n width: fit-content;\n }\n\n :last-of-type:not(:only-child):hover {\n background-color: ${props => props.theme.getColor('red-500')};\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n cursor: pointer;\n }\n\n svg {\n stroke: white;\n stroke-width: 2px;\n width: 8px;\n }\n\n :hover {\n cursor: pointer;\n }\n }\n`;\n\nexport const MultiValueRemove = styled(components.MultiValueRemove).attrs(applyDefaultTheme)``;\n\nexport const Input = styled(components.Input).attrs(applyDefaultTheme)`\n align-self: center;\n font-size: ${props => (props.$focused ? '14px' : '12px')};\n min-width: 150px;\n\n ${props =>\n props.theme.themeProp(\n 'color',\n props.theme.getColor('gray-100'),\n props.theme.getColor('gray-900')\n )}\n\n ${props =>\n !props.$focused &&\n css`\n ${props =>\n props.theme.themeProp(\n 'color',\n props.theme.getColor('gray-400'),\n props.theme.getColor('gray-500')\n )}\n\n :before {\n height: 100%;\n white-space: nowrap;\n width: fit-content;\n content: '${props => props.edittext}';\n }\n `}\n }\n`;\n\nexport const DropdownMenu = styled(components.Menu).attrs(applyDefaultTheme)`\n font-size: 14px;\n\n ${props =>\n props.theme.themeProp(\n 'background-color',\n props.theme.getColor('gray-600'),\n props.theme.getColor('white')\n )}\n\n ${props =>\n props.theme.themeProp(\n 'color',\n props.theme.getColor('gray-100'),\n props.theme.getColor('gray-900')\n )}\n`;\n\nconst sharedOptionStyle = css`\n ${props =>\n props.isFocused &&\n css`\n ${props.theme.themeProp(\n 'background-color',\n props.theme.getColor('gray-500'),\n props.theme.getColor('gray-200')\n )}\n `}\n\n ${props =>\n props.isSelected &&\n css`\n ${props.theme.themeProp('background-color', 'transparent', 'transparent')}\n\n ${props.theme.themeProp(\n 'color',\n props.theme.getColor('gray-100'),\n props.theme.getColor('gray-900')\n )}\n `}\n\n ${props =>\n props.isFocused &&\n props.isSelected &&\n css`\n ${props.theme.themeProp(\n 'background-color',\n props.theme.getColor('gray-500'),\n props.theme.getColor('gray-200')\n )}\n `}\n\n :hover {\n cursor: pointer;\n }\n`;\n\nexport const Option = styled(components.Option).attrs(applyDefaultTheme)`\n ${sharedOptionStyle}\n`;\n\nexport const SelectedOption = styled(components.Option).attrs(applyDefaultTheme)`\n ${sharedOptionStyle}\n\n display: flex !important;\n justify-content: space-between;\n`;\n\nexport const DropdownOptionDeleteIcon = styled(CloseIcon).attrs(applyDefaultTheme)`\n stroke-width: 1px;\n width: 8px;\n\n ${props =>\n props.theme.themeProp(\n 'stroke',\n props.theme.getColor('gray-100'),\n props.theme.getColor('gray-900')\n )}\n`;\n\nexport const ShowMoreWrapper = styled.div.attrs(applyDefaultTheme)`\n align-items: end;\n display: flex;\n flex-direction: column;\n height: 100%;\n left: 0;\n position: absolute;\n max-height: ${showMoreHeight + 16}px;\n top: 0;\n width: 100%;\n\n ${props =>\n props.theme.themeProp(\n 'color',\n props.theme.getColor('gray-100'),\n props.theme.getColor('emerald-500')\n )}\n\n :hover {\n cursor: pointer;\n text-decoration: underline;\n }\n`;\n\nexport const ShowMoreOverlay = styled.div.attrs(applyDefaultTheme)`\n align-items: end;\n display: block;\n height: 100%;\n max-height: ${showMoreHeight}px;\n left: 0;\n top: 0;\n width: 100%;\n\n ${props =>\n props.theme.themeProp(\n 'background',\n 'transparent linear-gradient(180deg, #12121200 0%, #12121230 40%, #12121279 70%, #121212 95%, #121212 100%) 0% 0% no-repeat padding-box',\n 'transparent linear-gradient(180deg, #fefefe00 0%, #fefefe30 40%, #fefefe79 70%, #fefefe 95%, #fefefe 100%) 0% 0% no-repeat padding-box'\n )}\n`;\n\nexport const ShowMoreText = styled.div.attrs(applyDefaultTheme)`\n font-size: 0.875rem;\n width: 100%;\n ${props => props.theme.themeProp('background-color', '#121212', '#fefefe')}\n`;\n\nexport const ErrorMessage = styled.div.attrs(applyDefaultTheme)`\n color: ${props =>\n props.error\n ? props.theme.getColor('red-500')\n : props.warning\n ? props.theme.getColor('orange-500')\n : 'inherit'};\n font-size: 0.75rem;\n margin-top: 8px;\n padding: 0 12px;\n`;\n"],"names":["AsyncCreatableSelectPaginate","withAsyncPaginate","CreatableSelect","showMoreHeight","sharedStyle","css","props","theme","primaryFontFamily","Label","styled","label","attrs","applyDefaultTheme","themeProp","getColor","MultiSelect","Select","CreatableMultiSelect","AsyncCreatableMultiSelect","AsyncMultiSelect","AsyncPaginate","MultiSelectWrapper","div","Control","components","isDisabled","focused","readOnly","ValueContainer","showMore","error","warning","MultiValueWrapper","MultiValue","MultiValueRemove","Input","$focused","edittext","DropdownMenu","Menu","sharedOptionStyle","isFocused","isSelected","Option","SelectedOption","DropdownOptionDeleteIcon","CloseIcon","ShowMoreWrapper","ShowMoreOverlay","ShowMoreText","Er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,CAACa,GAAG,CAACX,KAAK,CAACC,iBAAiB,CAAC,CAAA;AAC/D,SAAA,EAAWP,KAAK,IACZA,KAAK,CAACyB,KAAK,GACPzB,KAAK,CAACC,KAAK,CAACQ,QAAQ,CAAC,SAAS,CAAC,GAC/BT,KAAK,CAAC0B,OAAO,GACb1B,KAAK,CAACC,KAAK,CAACQ,QAAQ,CAAC,YAAY,CAAC,GAClC,SAAS,CAAA;AACjB;AACA;AACA;AACA;;;;"}
@@ -1,10 +1,2 @@
1
- export { M as default } from '../../MultiSelect-9f497e62.js';
2
- import '../../_rollupPluginBabelHelpers-c245b26a.js';
3
- import 'react';
4
- import '../../defaultTheme-1bcc2541.js';
5
- import 'styled-components';
6
- import 'nanoid';
7
- import '../../close-a5d37608.js';
8
- import 'react-select';
9
- import 'react-select/creatable';
10
- import 'react-select-async-paginate';
1
+ export { default } from './MultiSelect.js';
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,60 @@
1
+ import { extends as _extends } from '../../_virtual/_rollupPluginBabelHelpers.js';
2
+ import React__default, { useState } from 'react';
3
+ import { nanoid } from 'nanoid';
4
+ import PropTypes from 'prop-types';
5
+ import { Radio as Radio$1, RadioLabel } from './Radio.styled.js';
6
+
7
+ const Radio = React__default.forwardRef(function Radio({
8
+ name,
9
+ value,
10
+ checked,
11
+ defaultChecked,
12
+ disabled,
13
+ readOnly,
14
+ label,
15
+ className,
16
+ style,
17
+ onChange,
18
+ onBlur,
19
+ ...rest
20
+ }, forwardedRef) {
21
+ const [uniqueId] = useState(nanoid());
22
+ return React__default.createElement(Radio$1, {
23
+ htmlFor: uniqueId,
24
+ disabled: disabled,
25
+ readOnly: readOnly,
26
+ className: className,
27
+ style: style
28
+ }, React__default.createElement("input", _extends({
29
+ ref: forwardedRef,
30
+ type: "radio",
31
+ name: name,
32
+ value: value,
33
+ checked: checked,
34
+ defaultChecked: defaultChecked,
35
+ disabled: disabled,
36
+ readOnly: readOnly,
37
+ id: uniqueId,
38
+ onChange: onChange,
39
+ onBlur: onBlur
40
+ }, rest)), React__default.createElement(RadioLabel, null, label));
41
+ });
42
+ Radio.propTypes = process.env.NODE_ENV !== "production" ? {
43
+ label: PropTypes.any,
44
+ name: PropTypes.string.isRequired,
45
+ value: PropTypes.any.isRequired,
46
+ checked: PropTypes.bool,
47
+ defaultChecked: PropTypes.bool,
48
+ disabled: PropTypes.bool,
49
+ readOnly: PropTypes.bool,
50
+ className: PropTypes.string,
51
+ style: PropTypes.object,
52
+ onChange: PropTypes.func,
53
+ onBlur: PropTypes.func
54
+ } : {};
55
+ Radio.defaultProps = {
56
+ disabled: false
57
+ };
58
+
59
+ export { Radio as default };
60
+ //# sourceMappingURL=Radio.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Radio.js","sources":["../../../src/components/inputs/Radio/Radio.js"],"sourcesContent":["import React, { useState } from 'react';\n\nimport { nanoid } from 'nanoid';\nimport PropTypes from 'prop-types';\n\nimport * as S from './Radio.styled';\n\n/**\n * Radio buttons allow the user to select one option from a set.\n *\n * Use radio buttons when the user needs to see all available options. If available options can be\n * collapsed, consider using a dropdown menu because it uses less space.\n *\n * Radio buttons should have the most commonly used option selected by default.\n *\n * ### Import\n *\n * ``` js\n * import { Radio } from '@ntbjs/react-components/inputs'\n * // or\n * import Radio from '@ntbjs/react-components/inputs/Radio'\n * ```\n */\nconst Radio = React.forwardRef(function Radio(\n {\n name,\n value,\n checked,\n defaultChecked,\n disabled,\n readOnly,\n label,\n className,\n style,\n onChange,\n onBlur,\n ...rest\n },\n forwardedRef\n) {\n const [uniqueId] = useState(nanoid());\n\n return (\n <S.Radio\n htmlFor={uniqueId}\n disabled={disabled}\n readOnly={readOnly}\n className={className}\n style={style}\n >\n <input\n ref={forwardedRef}\n type=\"radio\"\n name={name}\n value={value}\n checked={checked}\n defaultChecked={defaultChecked}\n disabled={disabled}\n readOnly={readOnly}\n id={uniqueId}\n onChange={onChange}\n onBlur={onBlur}\n {...rest}\n />\n <S.RadioLabel>{label}</S.RadioLabel>\n </S.Radio>\n );\n});\n\nRadio.propTypes = {\n /**\n * Text displayed by the radio button\n */\n label: PropTypes.any,\n\n /**\n * Name of the radio button (used when sending form data)\n */\n name: PropTypes.string.isRequired,\n\n /**\n * Value to be sent when the given radio button is selected\n */\n value: PropTypes.any.isRequired,\n\n /**\n * Whether the radio button is checked\n */\n checked: PropTypes.bool,\n\n /**\n * Whether the radio button is checked by default. The most commonly used option should have this set to `true`.\n */\n defaultChecked: PropTypes.bool,\n\n /**\n * Whether the radio button is disabled\n */\n disabled: PropTypes.bool,\n\n /**\n * Display the radio button as read-only\n */\n readOnly: PropTypes.bool,\n\n /**\n * Custom class names for the HTML element\n */\n className: PropTypes.string,\n\n /**\n * Custom inline CSS styling\n */\n style: PropTypes.object,\n\n /**\n * Optional callback function for the `onChange` event\n */\n onChange: PropTypes.func,\n\n /**\n * Optional callback function for the `onBlur` event\n */\n onBlur: PropTypes.func\n};\n\nRadio.defaultProps = {\n disabled: false\n};\n\nexport default Radio;\n"],"names":["Radio","React","forwardRef","name","value","checked","defaultChecked","disabled","readOnly","label","className","style","onChange","onBlur","rest","forwardedRef","uniqueId","useState","nanoid","createElement","S","htmlFor","_extends","ref","type","id","propTypes","process","env","NODE_ENV","PropTypes","any","string","isRequired","bool","object","func","defaultProps"],"mappings":";;;;;;AAuBMA,MAAAA,KAAK,GAAGC,cAAK,CAACC,UAAU,CAAC,SAASF,KAAKA,CAC3C;EACEG,IAAI;EACJC,KAAK;EACLC,OAAO;EACPC,cAAc;EACdC,QAAQ;EACRC,QAAQ;EACRC,KAAK;EACLC,SAAS;EACTC,KAAK;EACLC,QAAQ;EACRC,MAAM;EACN,GAAGC,IAAAA;AACL,CAAC,EACDC,YAAY,EACZ;EACA,MAAM,CAACC,QAAQ,CAAC,GAAGC,QAAQ,CAACC,MAAM,EAAE,CAAC,CAAA;AAErC,EAAA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AAS,EAAEoB,SAAS,CAACE,MAAM;EAK3BrB,KAAK,EAAEmB,SAAS,CAACK,MAAM;EAKvBvB,QAAQ,EAAEkB,SAAS,CAACM,IAAI;EAKxBvB,MAAM,EAAEiB,SAAS,CAACM,IAAAA;AACpB,CAAC,GAAA,EAAA,CAAA;AAEDpC,KAAK,CAACqC,YAAY,GAAG;AACnB9B,EAAAA,QAAQ,EAAE,KAAA;AACZ,CAAC;;;;"}
@@ -1,9 +1,6 @@
1
- import { _ as _extends } from './_rollupPluginBabelHelpers-c245b26a.js';
2
- import React__default, { useState } from 'react';
3
- import { nanoid } from 'nanoid';
4
- import { a as applyDefaultTheme, P as PropTypes } from './defaultTheme-1bcc2541.js';
5
1
  import { math } from 'polished';
6
2
  import styled, { css } from 'styled-components';
3
+ import { applyDefaultTheme } from '../../utils/defaultTheme.js';
7
4
 
8
5
  const radioSize = '18px';
9
6
  const RadioLabel = styled.div.attrs(applyDefaultTheme)`
@@ -13,7 +10,7 @@ const RadioLabel = styled.div.attrs(applyDefaultTheme)`
13
10
 
14
11
  ${props => props.theme.themeProp('color', props.theme.getColor('gray-300'), props.theme.getColor('gray-600'))};
15
12
  `;
16
- const Radio$1 = styled.label.attrs(applyDefaultTheme)`
13
+ const Radio = styled.label.attrs(applyDefaultTheme)`
17
14
  display: block;
18
15
  position: relative;
19
16
  cursor: pointer;
@@ -79,56 +76,5 @@ const Radio$1 = styled.label.attrs(applyDefaultTheme)`
79
76
  `}
80
77
  `;
81
78
 
82
- const Radio = React__default.forwardRef(function Radio({
83
- name,
84
- value,
85
- checked,
86
- defaultChecked,
87
- disabled,
88
- readOnly,
89
- label,
90
- className,
91
- style,
92
- onChange,
93
- onBlur,
94
- ...rest
95
- }, forwardedRef) {
96
- const [uniqueId] = useState(nanoid());
97
- return React__default.createElement(Radio$1, {
98
- htmlFor: uniqueId,
99
- disabled: disabled,
100
- readOnly: readOnly,
101
- className: className,
102
- style: style
103
- }, React__default.createElement("input", _extends({
104
- ref: forwardedRef,
105
- type: "radio",
106
- name: name,
107
- value: value,
108
- checked: checked,
109
- defaultChecked: defaultChecked,
110
- disabled: disabled,
111
- readOnly: readOnly,
112
- id: uniqueId,
113
- onChange: onChange,
114
- onBlur: onBlur
115
- }, rest)), React__default.createElement(RadioLabel, null, label));
116
- });
117
- Radio.propTypes = process.env.NODE_ENV !== "production" ? {
118
- label: PropTypes.any,
119
- name: PropTypes.string.isRequired,
120
- value: PropTypes.any.isRequired,
121
- checked: PropTypes.bool,
122
- defaultChecked: PropTypes.bool,
123
- disabled: PropTypes.bool,
124
- readOnly: PropTypes.bool,
125
- className: PropTypes.string,
126
- style: PropTypes.object,
127
- onChange: PropTypes.func,
128
- onBlur: PropTypes.func
129
- } : {};
130
- Radio.defaultProps = {
131
- disabled: false
132
- };
133
-
134
- export { Radio as R };
79
+ export { Radio, RadioLabel };
80
+ //# sourceMappingURL=Radio.styled.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Radio.styled.js","sources":["../../../src/components/inputs/Radio/Radio.styled.js"],"sourcesContent":["import { math } from 'polished';\nimport styled, { css } from 'styled-components';\nimport { applyDefaultTheme } from '../../../utils/defaultTheme';\n\nconst radioSize = '18px';\n\nexport const RadioLabel = styled.div.attrs(applyDefaultTheme)`\n padding-left: ${math(`${radioSize} + 10px`)};\n font-weight: 400;\n font-size: 0.875rem;\n\n ${props =>\n props.theme.themeProp(\n 'color',\n props.theme.getColor('gray-300'),\n props.theme.getColor('gray-600')\n )};\n`;\n\nexport const Radio = styled.label.attrs(applyDefaultTheme)`\n display: block;\n position: relative;\n cursor: pointer;\n line-height: ${radioSize};\n user-select: none;\n\n &::before {\n content: '';\n position: absolute;\n border: 2px solid ${props => props.theme.getColor('gray-300')};\n width: ${radioSize};\n height: ${radioSize};\n top: 0;\n border-radius: 50%;\n transition: all 200ms;\n box-sizing: border-box;\n }\n\n &::after {\n content: '';\n position: absolute;\n width: 8px;\n height: 8px;\n top: 5px;\n left: 5px;\n border-radius: 50%;\n transform: scale(0);\n transition: all 200ms;\n }\n\n &:has(input:checked) {\n ::before {\n border-color: ${props => props.theme.getColor('emerald-500')};\n }\n\n ::after {\n background: ${props => props.theme.getColor('emerald-500')};\n transform: scale(1);\n }\n\n ${RadioLabel} {\n opacity: 1;\n }\n }\n & {\n input[type='radio'] {\n position: absolute;\n opacity: 0;\n pointer-events: none;\n }\n }\n\n ${props =>\n props.readOnly &&\n css`\n opacity: 0.5;\n pointer-events: none;\n user-select: text;\n `}\n\n ${props =>\n props.disabled &&\n css`\n opacity: 0.5;\n cursor: not-allowed;\n user-select: text;\n `}\n`;\n"],"names":["radioSize","RadioLabel","styled","div","attrs","applyDefaultTheme","math","props","theme","themeProp","getColor","Radio","label","readOnly","css","disabled"],"mappings":";;;;AAIA,MAAMA,SAAS,GAAG,MAAM,CAAA;AAEjB,MAAMC,UAAU,GAAGC,MAAM,CAACC,GAAG,CAACC,KAAK,CAACC,iBAAiB,CAAC,CAAA;AAC7D,gBAAA,EAAkBC,IAAI,CAAC,CAAGN,EAAAA,SAAS,SAAS,CAAC,CAAA;AAC7C;AACA;AACA;AACA,EAAIO,EAAAA,KAAK,IACLA,KAAK,CAACC,KAAK,CAACC,SAAS,CACnB,OAAO,EACPF,KAAK,CAACC,KAAK,CAACE,QAAQ,CAAC,UAAU,CAAC,EAChCH,KAAK,CAACC,KAAK,CAACE,QAAQ,CAAC,UAAU,CACjC,CAAC,CAAA;AACL,EAAC;AAEM,MAAMC,KAAK,GAAGT,MAAM,CAACU,KAAK,CAACR,KAAK,CAACC,iBAAiB,CAAC,CAAA;AAC1D;AACA;AACA;AACA,eAAA,EAAiBL,SAAS,CAAA;AAC1B;AACA;AACA;AACA;AACA;AACA,sBAAwBO,EAAAA,KAAK,IAAIA,KAAK,CAACC,KAAK,CAACE,QAAQ,CAAC,UAAU,CAAC,CAAA;AACjE,WAAA,EAAaV,SAAS,CAAA;AACtB,YAAA,EAAcA,SAAS,CAAA;AACvB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,oBAAsBO,EAAAA,KAAK,IAAIA,KAAK,CAACC,KAAK,CAACE,QAAQ,CAAC,aAAa,CAAC,CAAA;AAClE;AACA;AACA;AACA,kBAAoBH,EAAAA,KAAK,IAAIA,KAAK,CAACC,KAAK,CAACE,QAAQ,CAAC,aAAa,CAAC,CAAA;AAChE;AACA;AACA;AACA,IAAA,EAAMT,UAAU,CAAA;AAChB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAA,EAAIM,KAAK,IACLA,KAAK,CAACM,QAAQ,IACdC,GAAG,CAAA;AACP;AACA;AACA;AACA,IAAK,CAAA,CAAA;AACL;AACA,EAAA,EAAIP,KAAK,IACLA,KAAK,CAACQ,QAAQ,IACdD,GAAG,CAAA;AACP;AACA;AACA;AACA,IAAK,CAAA,CAAA;AACL;;;;"}
@@ -1,7 +1,2 @@
1
- export { R as default } from '../../Radio-73ca3ae2.js';
2
- import '../../_rollupPluginBabelHelpers-c245b26a.js';
3
- import 'react';
4
- import 'nanoid';
5
- import '../../defaultTheme-1bcc2541.js';
6
- import 'styled-components';
7
- import 'polished';
1
+ export { default } from './Radio.js';
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,64 @@
1
+ import React__default, { useState } from 'react';
2
+ import { nanoid } from 'nanoid';
3
+ import PropTypes from 'prop-types';
4
+ import { Switch as Switch$1, SwitchLabel, SwitchIndicator, SwitchIndicatorButton, SwitchIndicatorLabelText, Description } from './Switch.styled.js';
5
+
6
+ const Switch = React__default.forwardRef(function Switch({
7
+ name,
8
+ checked,
9
+ defaultChecked,
10
+ label,
11
+ disabled,
12
+ readOnly,
13
+ description,
14
+ spaciousDescription,
15
+ className,
16
+ style,
17
+ onChange,
18
+ onBlur
19
+ }, forwardedRef) {
20
+ const [uniqueId] = useState(nanoid());
21
+ return React__default.createElement(Switch$1, {
22
+ disabled: disabled,
23
+ readOnly: readOnly,
24
+ className: className,
25
+ style: style
26
+ }, React__default.createElement(SwitchLabel, {
27
+ htmlFor: uniqueId
28
+ }, React__default.createElement("input", {
29
+ ref: forwardedRef,
30
+ checked: checked,
31
+ defaultChecked: defaultChecked,
32
+ disabled: disabled,
33
+ readOnly: readOnly,
34
+ id: uniqueId,
35
+ name: name,
36
+ type: "checkbox",
37
+ onBlur: onBlur,
38
+ onChange: onChange
39
+ }), React__default.createElement(SwitchIndicator, null, React__default.createElement(SwitchIndicatorButton, null)), typeof label === 'string' && label.length > 0 && React__default.createElement(SwitchIndicatorLabelText, null, label)), typeof description === 'string' && description.length > 0 && React__default.createElement(Description, {
40
+ spaciousDescription: spaciousDescription
41
+ }, description));
42
+ });
43
+ Switch.propTypes = process.env.NODE_ENV !== "production" ? {
44
+ children: PropTypes.any,
45
+ name: PropTypes.string.isRequired,
46
+ checked: PropTypes.bool,
47
+ defaultChecked: PropTypes.bool,
48
+ label: PropTypes.string,
49
+ disabled: PropTypes.bool,
50
+ readOnly: PropTypes.bool,
51
+ description: PropTypes.string,
52
+ spaciousDescription: PropTypes.bool,
53
+ className: PropTypes.string,
54
+ style: PropTypes.object,
55
+ onChange: PropTypes.func,
56
+ onBlur: PropTypes.func
57
+ } : {};
58
+ Switch.defaultProps = {
59
+ disabled: false,
60
+ readOnly: false
61
+ };
62
+
63
+ export { Switch as default };
64
+ //# sourceMappingURL=Switch.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Switch.js","sources":["../../../src/components/inputs/Switch/Switch.js"],"sourcesContent":["import React, { useState } from 'react';\n\nimport { nanoid } from 'nanoid';\nimport PropTypes from 'prop-types';\n\nimport * as S from './Switch.styled';\n\n/**\n * The Switch allows the user to toggle an option.\n *\n * ### Import\n *\n * ``` js\n * import { Switch } from '@ntbjs/react-components/inputs'\n * // or\n * import Switch from '@ntbjs/react-components/inputs/Switch'\n * ```\n */\nconst Switch = React.forwardRef(function Switch(\n {\n name,\n checked,\n defaultChecked,\n label,\n disabled,\n readOnly,\n description,\n spaciousDescription,\n className,\n style,\n onChange,\n onBlur\n },\n forwardedRef\n) {\n const [uniqueId] = useState(nanoid());\n\n return (\n <S.Switch disabled={disabled} readOnly={readOnly} className={className} style={style}>\n <S.SwitchLabel htmlFor={uniqueId}>\n <input\n ref={forwardedRef}\n checked={checked}\n defaultChecked={defaultChecked}\n disabled={disabled}\n readOnly={readOnly}\n id={uniqueId}\n name={name}\n type=\"checkbox\"\n onBlur={onBlur}\n onChange={onChange}\n />\n <S.SwitchIndicator>\n <S.SwitchIndicatorButton />\n </S.SwitchIndicator>\n {typeof label === 'string' && label.length > 0 && (\n <S.SwitchIndicatorLabelText>{label}</S.SwitchIndicatorLabelText>\n )}\n </S.SwitchLabel>\n {typeof description === 'string' && description.length > 0 && (\n <S.Description spaciousDescription={spaciousDescription}>{description}</S.Description>\n )}\n </S.Switch>\n );\n});\n\nSwitch.propTypes = {\n children: PropTypes.any,\n name: PropTypes.string.isRequired,\n\n /**\n * Whether the switch is toggled on or off\n */\n checked: PropTypes.bool,\n\n /**\n * Whether the switch is toggled on by default\n */\n defaultChecked: PropTypes.bool,\n\n /**\n * Text displayed next to the switch\n */\n label: PropTypes.string,\n\n /**\n * Whether the switch is toggled on\n */\n disabled: PropTypes.bool,\n\n /**\n * Whether the switch is displayed as read-only\n */\n readOnly: PropTypes.bool,\n\n /**\n * Text displayed underneath the switch\n */\n description: PropTypes.string,\n\n /**\n * Whether there should be extra `margin` added between the switch and the description\n */\n spaciousDescription: PropTypes.bool,\n\n /**\n * Add extra classes to the HTML element\n */\n className: PropTypes.string,\n\n /**\n * Custom CSS styling\n */\n style: PropTypes.object,\n\n /**\n * Optional callback function for the `onChange` event\n */\n onChange: PropTypes.func,\n\n /**\n * Optional callback function for the `onBlur` event\n */\n onBlur: PropTypes.func\n};\n\nSwitch.defaultProps = {\n disabled: false,\n readOnly: false\n};\n\nexport default Switch;\n"],"names":["Switch","React","forwardRef","name","checked","defaultChecked","label","disabled","readOnly","description","spaciousDescription","className","style","onChange","onBlur","forwardedRef","uniqueId","useState","nanoid","createElement","S","htmlFor","ref","id","type","length","propTypes","process","env","NODE_ENV","children","PropTypes","any","string","isRequired","bool","object","func","defaultProps"],"mappings":";;;;;AAkBMA,MAAAA,MAAM,GAAGC,cAAK,CAACC,UAAU,CAAC,SAASF,MAAMA,CAC7C;EACEG,IAAI;EACJC,OAAO;EACPC,cAAc;EACdC,KAAK;EACLC,QAAQ;EACRC,QAAQ;EACRC,WAAW;EACXC,mBAAmB;EACnBC,SAAS;EACTC,KAAK;EACLC,QAAQ;AACRC,EAAAA,MAAAA;AACF,CAAC,EACDC,YAAY,EACZ;EACA,MAAM,CAACC,QAAQ,CAAC,GAAGC,QAAQ,CAACC,MAAM,EAAE,CAAC,CAAA;AAErC,EAAA,OACEjB,cAAA,CAAAkB,aAAA,CAACC,QAAQ,EAAA;AAACb,IAAAA,QAAQ,EAAEA,QAAS;AAACC,IAAAA,QAAQ,EAAEA,QAAS;AAACG,IAAAA,SAAS,EAAEA,SAAU;AAACC,IAAAA,KAAK,EAAEA,KAAAA;AAAM,GAAA,EACnFX,cAAA,CAAAkB,aAAA,CAACC,WAAa,EAAA;AAACC,IAAAA,OAAO,EAAEL,QAAAA;GACtBf,EAAAA,cAAA,CAAAkB,aAAA,CAAA,OAAA,EAAA;AACEG,IAAAA,GAAG,EAAEP,YAAa;AAClBX,IAAAA,OAAO,EAAEA,OAAQ;AACjBC,IAAAA,cAAc,EAAEA,cAAe;AAC/BE,IAAAA,QAAQ,EAAEA,QAAS;AACnBC,IAAAA,QAAQ,EAAEA,QAAS;AACnBe,IAAAA,EAAE,EAAEP,QAAS;AACbb,IAAAA,IAAI,EAAEA,IAAK;AACXqB,IAAAA,IAAI,EAAC,UAAU;AACfV,IAAAA,MAAM,EAAEA,MAAO;AACfD,IAAAA,QAAQ,EAAEA,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