@procore/core-react 11.25.1 → 11.25.2

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 (204) hide show
  1. package/babel.config.js +1 -1
  2. package/dist/Avatar/Avatar.styles.js +5 -5
  3. package/dist/AvatarStack/AvatarStack.styles.js +7 -7
  4. package/dist/Badge/Badge.styles.js +2 -2
  5. package/dist/Banner/Banner.styles.js +10 -10
  6. package/dist/Box/Box.styles.js +1 -1
  7. package/dist/Breadcrumbs/Breadcrumbs.styles.js +4 -4
  8. package/dist/Button/Button.styles.js +5 -5
  9. package/dist/Calendar/Calendar.styles.js +8 -8
  10. package/dist/Card/Card.styles.js +1 -1
  11. package/dist/Checkbox/Checkbox.styles.js +6 -6
  12. package/dist/ContactItem/ContactItem.styles.js +5 -5
  13. package/dist/Content/Content.styles.js +2 -2
  14. package/dist/DateInput/DateInput.styles.js +6 -6
  15. package/dist/DetailPage/DetailPage.styles.js +7 -7
  16. package/dist/Dropdown/Dropdown.styles.js +3 -3
  17. package/dist/DropdownFlyout/DropdownFlyout.styles.js +4 -4
  18. package/dist/Dropzone/Dropzone.js +1 -1
  19. package/dist/Dropzone/Dropzone.styles.js +9 -9
  20. package/dist/EmptyState/EmptyState.styles.js +6 -6
  21. package/dist/Field/Field.styles.js +3 -3
  22. package/dist/FileList/FileList.styles.js +4 -4
  23. package/dist/FileSelect/FileExplorer/FileExplorer.styles.js +9 -9
  24. package/dist/FileSelect/FileExplorer/FileExplorerSidebar.styles.js +3 -3
  25. package/dist/FileSelect/FileSelect.styles.js +2 -2
  26. package/dist/FileSelect/FileSelectDropzone/FileSelectDropzone.styles.js +3 -3
  27. package/dist/FileSelect/FileTokenList/FileTokenList.styles.js +2 -2
  28. package/dist/FileSelect/GridSource/GridSource.styles.js +6 -6
  29. package/dist/FileSelect/LocalSource/LocalSource.styles.js +4 -4
  30. package/dist/FileSelect/SourceItem/SourceItem.styles.js +3 -3
  31. package/dist/FileSelect/ThumbnailList/ThumbnailList.styles.js +6 -6
  32. package/dist/FileSelect/TreeSource/TreeSource.styles.js +1 -1
  33. package/dist/FileToken/FileToken.styles.js +4 -4
  34. package/dist/FilterToken/FilterToken.styles.js +2 -2
  35. package/dist/FlexList/FlexList.styles.js +1 -1
  36. package/dist/Form/Form.styles.js +16 -16
  37. package/dist/Grid/Grid.styles.js +2 -2
  38. package/dist/GroupSelect/GroupSelect.styles.js +1 -1
  39. package/dist/Input/Input.styles.js +1 -1
  40. package/dist/Link/Link.styles.js +1 -1
  41. package/dist/ListPage/ListPage.styles.js +8 -8
  42. package/dist/Loader/Loader.styles.js +2 -2
  43. package/dist/MenuImperative/MenuImperative.styles.js +10 -10
  44. package/dist/Modal/Modal.styles.js +13 -13
  45. package/dist/MultiSelect/MultiSelect.styles.js +6 -6
  46. package/dist/NextMenu/NextMenu.styles.js +3 -3
  47. package/dist/Notation/Notation.js +1 -1
  48. package/dist/NumberInput/NumberInput.styles.js +7 -7
  49. package/dist/Overlay/OverlayArrow.styles.js +1 -1
  50. package/dist/PageLayout/PageLayout.styles.js +13 -13
  51. package/dist/Pagination/Pagination.styles.js +5 -5
  52. package/dist/Panel/Panel.styles.js +11 -11
  53. package/dist/Pill/Pill.styles.js +2 -2
  54. package/dist/PillSelect/PillSelect.styles.js +4 -4
  55. package/dist/Popover/Popover.styles.js +2 -2
  56. package/dist/Portal/Portal.styles.js +1 -1
  57. package/dist/ProgressBar/ProgressBar.styles.js +2 -2
  58. package/dist/RadioButton/RadioButton.styles.js +3 -3
  59. package/dist/Required/Required.styles.js +3 -3
  60. package/dist/Search/Search.styles.js +5 -5
  61. package/dist/Section/Section.styles.js +6 -6
  62. package/dist/SegmentedController/SegmentedController.styles.js +4 -4
  63. package/dist/Select/Select.styles.js +7 -7
  64. package/dist/Semantic/Semantic.d.ts +6 -1
  65. package/dist/Semantic/Semantic.js +7 -1
  66. package/dist/Semantic/Semantic.js.map +1 -1
  67. package/dist/Semantic/Semantic.styles.d.ts +14 -4
  68. package/dist/Semantic/Semantic.styles.js +20 -10
  69. package/dist/Semantic/Semantic.styles.js.map +1 -1
  70. package/dist/Semantic/index.d.ts +1 -1
  71. package/dist/Semantic/index.js +1 -1
  72. package/dist/Semantic/index.js.map +1 -1
  73. package/dist/Sidebar/Sidebar.styles.js +7 -7
  74. package/dist/Slider/Slider.styles.js +5 -5
  75. package/dist/Spinner/Spinner.styles.js +7 -7
  76. package/dist/SuperSelect/SuperSelect.presets.styles.js +1 -1
  77. package/dist/SuperSelect/SuperSelect.styles.js +37 -37
  78. package/dist/Switch/Switch.styles.js +4 -4
  79. package/dist/Table/Table.styles.js +28 -28
  80. package/dist/TableShelf/TableShelf.styles.js +5 -5
  81. package/dist/Tabs/Tabs.styles.js +8 -8
  82. package/dist/Tearsheet/Tearsheet.styles.js +5 -5
  83. package/dist/TextArea/TextArea.styles.js +1 -1
  84. package/dist/TextEditorOutput/TextEditorOutput.styles.js +1 -1
  85. package/dist/Thumbnail/Thumbnail.styles.js +17 -17
  86. package/dist/ThumbnailGrid/ThumbnailGrid.styles.js +7 -7
  87. package/dist/TieredSelect/TieredSelect.styles.js +9 -9
  88. package/dist/Tile/Tile.styles.js +8 -8
  89. package/dist/Title/Title.styles.js +7 -7
  90. package/dist/Toast/Toast.styles.js +3 -3
  91. package/dist/ToggleButton/ToggleButton.styles.js +1 -1
  92. package/dist/Token/Token.styles.js +3 -3
  93. package/dist/ToolHeader/ToolHeader.styles.js +6 -6
  94. package/dist/Tooltip/Tooltip.styles.js +2 -2
  95. package/dist/Tree/Tree.styles.js +9 -9
  96. package/dist/Typeahead/Typeahead.styles.js +3 -3
  97. package/dist/Typography/Typography.styles.js +1 -1
  98. package/dist/Typography/Typography.table.story.js +2 -2
  99. package/dist/_typedoc/Avatar/Avatar.types.json +20 -20
  100. package/dist/_typedoc/AvatarStack/AvatarStack.types.json +23 -23
  101. package/dist/_typedoc/Badge/Badge.types.json +6 -6
  102. package/dist/_typedoc/Banner/Banner.types.json +13 -13
  103. package/dist/_typedoc/Box/Box.types.json +68 -68
  104. package/dist/_typedoc/Breadcrumbs/Breadcrumbs.types.json +10 -10
  105. package/dist/_typedoc/Button/Button.types.json +11 -11
  106. package/dist/_typedoc/Calendar/Calendar.types.json +80 -80
  107. package/dist/_typedoc/Card/Card.types.json +6 -6
  108. package/dist/_typedoc/Checkbox/Checkbox.types.json +9 -9
  109. package/dist/_typedoc/ContactItem/ContactItem.types.json +9 -9
  110. package/dist/_typedoc/DateInput/DateInput.types.json +35 -35
  111. package/dist/_typedoc/DateSelect/DateSelect.types.json +13 -13
  112. package/dist/_typedoc/DetailPage/DetailPage.types.json +4 -4
  113. package/dist/_typedoc/Dropdown/Dropdown.types.json +37 -37
  114. package/dist/_typedoc/DropdownFlyout/DropdownFlyout.types.json +29 -29
  115. package/dist/_typedoc/Dropzone/Dropzone.types.json +41 -41
  116. package/dist/_typedoc/EmptyState/EmptyState.types.json +14 -14
  117. package/dist/_typedoc/FileList/FileList.types.json +9 -9
  118. package/dist/_typedoc/FileSelect/FileSelect.types.json +26 -26
  119. package/dist/_typedoc/FileSelect/GridSource/GridSource.types.json +20 -20
  120. package/dist/_typedoc/FileSelect/LocalSource/LocalSource.types.json +14 -14
  121. package/dist/_typedoc/FileSelect/TreeSource/TreeSource.types.json +9 -9
  122. package/dist/_typedoc/Flex/Flex.types.json +27 -27
  123. package/dist/_typedoc/FlexList/FlexList.types.json +30 -30
  124. package/dist/_typedoc/Form/Form.types.json +726 -726
  125. package/dist/_typedoc/Grid/Grid.types.json +8 -8
  126. package/dist/_typedoc/GroupSelect/GroupSelect.types.json +52 -52
  127. package/dist/_typedoc/Input/Input.types.json +2 -2
  128. package/dist/_typedoc/Link/Link.types.json +4 -4
  129. package/dist/_typedoc/ListPage/ListPage.types.json +13 -13
  130. package/dist/_typedoc/Menu/Menu.types.json +62 -62
  131. package/dist/_typedoc/MenuImperative/MenuImperative.types.json +74 -74
  132. package/dist/_typedoc/Modal/Modal.types.json +41 -41
  133. package/dist/_typedoc/MultiSelect/MultiSelect.types.json +31 -31
  134. package/dist/_typedoc/Notation/Notation.types.json +4 -4
  135. package/dist/_typedoc/NumberInput/NumberInput.types.json +38 -38
  136. package/dist/_typedoc/OverlayTrigger/OverlayTrigger.types.json +31 -31
  137. package/dist/_typedoc/PageLayout/PageLayout.types.json +22 -22
  138. package/dist/_typedoc/Pagination/Pagination.types.json +7 -7
  139. package/dist/_typedoc/Panel/Panel.types.json +27 -27
  140. package/dist/_typedoc/Pill/Pill.types.json +2 -2
  141. package/dist/_typedoc/PillSelect/PillSelect.types.json +47 -47
  142. package/dist/_typedoc/Popover/Popover.types.json +14 -14
  143. package/dist/_typedoc/ProgressBar/ProgressBar.types.json +6 -6
  144. package/dist/_typedoc/RadioButton/RadioButton.types.json +6 -6
  145. package/dist/_typedoc/Required/Required.types.json +5 -5
  146. package/dist/_typedoc/Search/Search.types.json +18 -18
  147. package/dist/_typedoc/Section/Section.types.json +14 -14
  148. package/dist/_typedoc/SegmentedController/SegmentedController.types.json +20 -20
  149. package/dist/_typedoc/Select/Select.types.json +57 -57
  150. package/dist/_typedoc/Slider/Slider.types.json +6 -6
  151. package/dist/_typedoc/Spinner/Spinner.types.json +9 -9
  152. package/dist/_typedoc/Switch/Switch.types.json +3 -3
  153. package/dist/_typedoc/Table/Table.types.json +97 -97
  154. package/dist/_typedoc/Tabs/Tabs.types.json +17 -17
  155. package/dist/_typedoc/Tearsheet/Tearsheet.types.json +16 -16
  156. package/dist/_typedoc/TextArea/TextArea.types.json +3 -3
  157. package/dist/_typedoc/TextEditor/TextEditor.types.json +9 -9
  158. package/dist/_typedoc/TextEditorOutput/TextEditorOutput.types.json +4 -4
  159. package/dist/_typedoc/Thumbnail/Thumbnail.types.json +19 -19
  160. package/dist/_typedoc/TieredDropdown/TieredDropdown.types.json +42 -42
  161. package/dist/_typedoc/TieredSelect/TieredSelect.types.json +28 -28
  162. package/dist/_typedoc/Tile/Tile.types.json +30 -30
  163. package/dist/_typedoc/Toast/Toast.types.json +4 -4
  164. package/dist/_typedoc/ToggleButton/ToggleButton.types.json +3 -3
  165. package/dist/_typedoc/Token/Token.types.json +4 -4
  166. package/dist/_typedoc/ToolHeader/ToolHeader.types.json +10 -10
  167. package/dist/_typedoc/Tooltip/Tooltip.types.json +13 -13
  168. package/dist/_typedoc/Tree/Tree.types.json +86 -86
  169. package/dist/_typedoc/Typeahead/Typeahead.types.json +2 -2
  170. package/dist/_typedoc/Typography/Typography.types.json +8 -8
  171. package/dist/_typedoc/_utils/types.json +3 -3
  172. package/dist/index.d.ts +1 -0
  173. package/dist/index.js +1 -0
  174. package/dist/index.js.map +1 -1
  175. package/package.json +2 -2
  176. package/tsconfig.prod.json +7 -1
  177. package/dist/FileSelect/SourceItem/SourceItem.test.js +0 -53
  178. package/dist/MultiSelect/MultiSelect.test.js +0 -250
  179. package/dist/OverlayTrigger/OverlayTrigger.test.js +0 -483
  180. package/dist/SuperSelect/SuperSelect.utils.test.js +0 -717
  181. package/dist/SuperSelect/useSuperSelect.test.js +0 -1284
  182. package/dist/_hooks/OverflowObserver/OverflowObserver.test.js +0 -110
  183. package/dist/_hooks/__tests__/Anchor.test.js +0 -109
  184. package/dist/_hooks/__tests__/BoundingRect.test.js +0 -85
  185. package/dist/_hooks/__tests__/Buffer.test.js +0 -76
  186. package/dist/_hooks/__tests__/DateTime.test.js +0 -136
  187. package/dist/_hooks/__tests__/DelayedCallback.test.js +0 -119
  188. package/dist/_hooks/__tests__/DelayedToggle.test.js +0 -50
  189. package/dist/_hooks/__tests__/Deprecation.test.js +0 -58
  190. package/dist/_hooks/__tests__/Event.test.js +0 -46
  191. package/dist/_hooks/__tests__/EventListener.test.js +0 -124
  192. package/dist/_hooks/__tests__/Hotkey.test.js +0 -18
  193. package/dist/_hooks/__tests__/InjectedScript.test.js +0 -80
  194. package/dist/_hooks/__tests__/ListNavigation.test.js +0 -101
  195. package/dist/_hooks/__tests__/TextEntry.test.js +0 -92
  196. package/dist/_hooks/__tests__/Timer.test.js +0 -60
  197. package/dist/_hooks/__tests__/Trigger.test.js +0 -52
  198. package/dist/_hooks/__tests__/Visibility.test.js +0 -86
  199. package/dist/_hooks/__tests__/ZIndex.test.js +0 -76
  200. package/dist/_utils/__tests__/CalendarHelpers.test.js +0 -64
  201. package/dist/_utils/__tests__/filename.test.js +0 -27
  202. package/dist/_utils/__tests__/getAnchorPosition.test.js +0 -250
  203. package/dist/_utils/__tests__/mergeRefs.test.js +0 -58
  204. package/dist/_utils/__tests__/slotify.test.js +0 -152
@@ -10,7 +10,7 @@
10
10
  "description": "",
11
11
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><dl class=\"tsd-comment-tags\"><dt>since</dt><dd><p>10.19.0</p>\n</dd></dl></div>",
12
12
  "sourceFile": "packages/core-react/src/Typeahead/Typeahead.types.ts",
13
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/Typeahead/Typeahead.types.ts#L15"
13
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/Typeahead/Typeahead.types.ts#L15"
14
14
  },
15
15
  {
16
16
  "name": "onChange",
@@ -20,7 +20,7 @@
20
20
  "description": "",
21
21
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><dl class=\"tsd-comment-tags\"><dt>since</dt><dd><p>10.19.0</p>\n</dd></dl></div>",
22
22
  "sourceFile": "packages/core-react/src/Typeahead/Typeahead.types.ts",
23
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/Typeahead/Typeahead.types.ts#L19"
23
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/Typeahead/Typeahead.types.ts#L19"
24
24
  }
25
25
  ],
26
26
  "description": ""
@@ -10,7 +10,7 @@
10
10
  "description": "<span>\n Change the HTML tag. This{' '}\n <Link href=\"https://styled-components.com/docs/api#as-polymorphic-prop\">\n prop is from styled-components\n </Link>\n .<em>WARNING</em>: If using TypeScript, it will not switch types and\n some props may error. You can add <Code>// @ts-expect-error</Code>.\n See{' '}\n <Link href=\"https://github.com/DefinitelyTyped/DefinitelyTyped/issues/30117\">\n styled-components issue\n </Link>\n .\n</span>",
11
11
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<span>\n Change the HTML tag. This{' '}\n <Link href=\"https://styled-components.com/docs/api#as-polymorphic-prop\">\n prop is from styled-components\n </Link>\n .<em>WARNING</em>: If using TypeScript, it will not switch types and\n some props may error. You can add <Code>// @ts-expect-error</Code>.\n See{' '}\n <Link href=\"https://github.com/DefinitelyTyped/DefinitelyTyped/issues/30117\">\n styled-components issue\n </Link>\n .\n</span></div><dl class=\"tsd-comment-tags\"><dt>since</dt><dd><p>10.19.0</p>\n</dd></dl></div>",
12
12
  "sourceFile": "packages/core-react/src/Typography/Typography.types.ts",
13
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/Typography/Typography.types.ts#L35"
13
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/Typography/Typography.types.ts#L35"
14
14
  },
15
15
  {
16
16
  "name": "children",
@@ -20,7 +20,7 @@
20
20
  "description": "<span>\n When children are a string or multiple elements, they will be wrapped\n by a <Code>span</Code>. When it is a single element, classnames will\n be added to it instead\n</span>",
21
21
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<span>\n When children are a string or multiple elements, they will be wrapped\n by a <Code>span</Code>. When it is a single element, classnames will\n be added to it instead\n</span></div><dl class=\"tsd-comment-tags\"><dt>since</dt><dd><p>10.19.0</p>\n</dd></dl></div>",
22
22
  "sourceFile": "packages/core-react/src/Typography/Typography.types.ts",
23
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/Typography/Typography.types.ts#L17"
23
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/Typography/Typography.types.ts#L17"
24
24
  },
25
25
  {
26
26
  "name": "className",
@@ -30,7 +30,7 @@
30
30
  "description": "Additional classNames",
31
31
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<p>Additional classNames</p>\n</div></div>",
32
32
  "sourceFile": "packages/core-react/src/_utils/types.ts",
33
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/_utils/types.ts#L47"
33
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/_utils/types.ts#L47"
34
34
  },
35
35
  {
36
36
  "name": "color",
@@ -40,7 +40,7 @@
40
40
  "description": "<span>\n Changes font color, can be any of the{' '}\n <Link to=\"/web/style/colors/#hsl-palette\">HSL Palette</Link> css\n strings\n</span>",
41
41
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<span>\n Changes font color, can be any of the{' '}\n <Link to=\"/web/style/colors/#hsl-palette\">HSL Palette</Link> css\n strings\n</span></div><dl class=\"tsd-comment-tags\"><dt>default</dt><dd><p>&#39;gray15&#39;</p>\n</dd><dt>since</dt><dd><p>10.19.0</p>\n</dd></dl></div>",
42
42
  "sourceFile": "packages/core-react/src/Typography/Typography.types.ts",
43
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/Typography/Typography.types.ts#L46"
43
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/Typography/Typography.types.ts#L46"
44
44
  },
45
45
  {
46
46
  "name": "intent",
@@ -50,7 +50,7 @@
50
50
  "description": "Changes the size of the font",
51
51
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<p>Changes the size of the font</p>\n</div><dl class=\"tsd-comment-tags\"><dt>since</dt><dd><p>10.19.0</p>\n</dd></dl></div>",
52
52
  "sourceFile": "packages/core-react/src/Typography/Typography.types.ts",
53
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/Typography/Typography.types.ts#L52"
53
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/Typography/Typography.types.ts#L52"
54
54
  },
55
55
  {
56
56
  "name": "italic",
@@ -60,7 +60,7 @@
60
60
  "description": "Applies `font-style: italic` if enabled",
61
61
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<p>Applies <code>font-style: italic</code> if enabled</p>\n</div><dl class=\"tsd-comment-tags\"><dt>since</dt><dd><p>10.19.0</p>\n</dd></dl></div>",
62
62
  "sourceFile": "packages/core-react/src/Typography/Typography.types.ts",
63
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/Typography/Typography.types.ts#L58"
63
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/Typography/Typography.types.ts#L58"
64
64
  },
65
65
  {
66
66
  "name": "style",
@@ -70,7 +70,7 @@
70
70
  "description": "Additional CSS styles",
71
71
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<p>Additional CSS styles</p>\n</div></div>",
72
72
  "sourceFile": "packages/core-react/src/_utils/types.ts",
73
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/_utils/types.ts#L52"
73
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/_utils/types.ts#L52"
74
74
  },
75
75
  {
76
76
  "name": "weight",
@@ -80,7 +80,7 @@
80
80
  "description": "Changes font weight if it is supported in the design system",
81
81
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<p>Changes font weight if it is supported in the design system</p>\n</div><dl class=\"tsd-comment-tags\"><dt>since</dt><dd><p>10.19.0</p>\n</dd></dl></div>",
82
82
  "sourceFile": "packages/core-react/src/Typography/Typography.types.ts",
83
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/Typography/Typography.types.ts#L64"
83
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/Typography/Typography.types.ts#L64"
84
84
  }
85
85
  ],
86
86
  "description": ""
@@ -10,7 +10,7 @@
10
10
  "description": "",
11
11
  "descriptionHtml": "",
12
12
  "sourceFile": "packages/core-react/src/_utils/types.ts",
13
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/_utils/types.ts#L42"
13
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/_utils/types.ts#L42"
14
14
  },
15
15
  {
16
16
  "name": "className",
@@ -20,7 +20,7 @@
20
20
  "description": "Additional classNames",
21
21
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<p>Additional classNames</p>\n</div></div>",
22
22
  "sourceFile": "packages/core-react/src/_utils/types.ts",
23
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/_utils/types.ts#L47"
23
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/_utils/types.ts#L47"
24
24
  },
25
25
  {
26
26
  "name": "style",
@@ -30,7 +30,7 @@
30
30
  "description": "Additional CSS styles",
31
31
  "descriptionHtml": "<div class=\"tsd-comment tsd-typography\"><div class=\"lead\">\n<p>Additional CSS styles</p>\n</div></div>",
32
32
  "sourceFile": "packages/core-react/src/_utils/types.ts",
33
- "sourceUrl": "https://github.com/procore/core/blob/77efc9a/packages/core-react/src/_utils/types.ts#L52"
33
+ "sourceUrl": "https://github.com/procore/core/blob/7a5d0cd/packages/core-react/src/_utils/types.ts#L52"
34
34
  }
35
35
  ],
36
36
  "description": ""
package/dist/index.d.ts CHANGED
@@ -101,6 +101,7 @@ export * from './_hooks/Timer';
101
101
  export * from './_hooks/Trigger';
102
102
  export * from './_hooks/Visibility';
103
103
  export * from './_hooks/ZIndex';
104
+ export { borderRadius, getBorderRadius as UNSAFE_getBorderRadius, } from './_styles/borderRadius';
104
105
  export * from './_styles/colors';
105
106
  export * from './_styles/spacing';
106
107
  export { docsProps as UNSAFE_props } from './_utils/props';
package/dist/index.js CHANGED
@@ -112,6 +112,7 @@ export * from './_hooks/Trigger';
112
112
  export * from './_hooks/Visibility';
113
113
  export * from './_hooks/ZIndex';
114
114
  // Style Stuff
115
+ export { borderRadius, getBorderRadius as UNSAFE_getBorderRadius } from './_styles/borderRadius';
115
116
  export * from './_styles/colors';
116
117
  /**
117
118
  * @internal
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["BETA_makeField","getEllipsis","UNSAFE_getEllipsis","getFocus","UNSAFE_getFocus","getLineClamp","UNSAFE_getLineClamp","addSubcomponents","UNSAFE_addSubcomponents","intlDateTimeFormat","parseFilename","UNSAFE_parseFilename","mergeRefs","UNSAFE_mergeRefs","docsProps","UNSAFE_props"],"sources":["../src/index.ts"],"sourcesContent":["// export const version = process.env.VERSION\nexport * from './Avatar'\nexport * from './AvatarStack'\nexport * from './Badge'\nexport * from './Banner'\nexport * from './Box'\nexport * from './Breadcrumbs'\nexport * from './Button'\nexport * from './Calendar'\nexport * from './Card'\nexport * from './Checkbox'\nexport * from './ClickOutside'\nexport * from './ContactItem'\nexport * from './Content'\nexport * from './DateInput'\nexport * from './DateSelect'\nexport * from './DetailPage'\nexport * from './Dropdown'\nexport * from './DropdownFlyout'\nexport * from './Dropzone'\nexport * from './EmptyState'\nexport * from './FileList'\nexport * from './FileSelect'\nexport * from './FileToken'\nexport * from './FilterToken'\nexport * from './Flex'\nexport * from './FlexList'\nexport * from './Form'\n/**\n * @internal\n * Will require extending types FormFieldProps and FormFieldValueComponentProps\n */\nexport { BETA_makeField } from './Form'\nexport * from './Grid'\nexport * from './GroupSelect'\nexport * from './Input'\nexport * from './Link'\nexport * from './ListPage'\nexport * from './Menu'\nexport * from './MenuImperative'\nexport * from './Modal'\nexport * from './MultiSelect'\nexport * from './Notation'\nexport * from './NumberInput'\nexport * from './Overlay'\nexport * from './OverlayTrigger'\nexport * from './PageLayout'\nexport * from './Pagination'\nexport * from './Panel'\nexport * from './Pill'\nexport * from './PillSelect'\nexport * from './Popover'\nexport * from './Portal'\nexport * from './ProgressBar'\nexport * from './RadioButton'\nexport * from './Required'\nexport * from './Search'\nexport * from './SegmentedController'\nexport * from './Select'\nexport * from './Semantic'\nexport * from './Sidebar'\nexport * from './Slider'\nexport * from './Spinner'\nexport * from './SuperSelect'\nexport * from './Switch'\nexport * from './Table'\nexport * from './TableShelf'\nexport * from './Tabs'\nexport * from './Tearsheet'\nexport * from './TextArea'\nexport * from './TextEditor'\nexport * from './TextEditorOutput'\nexport * from './Thumbnail'\nexport * from './TieredDropdown'\nexport * from './TieredSelect'\nexport * from './Tile'\nexport * from './Title'\nexport * from './Toast'\nexport * from './ToggleButton'\nexport * from './Token'\nexport * from './ToolHeader'\nexport * from './Tooltip'\nexport * from './Tree'\nexport * from './Typeahead'\nexport * from './Typography'\nexport * from './_hooks/Analytics'\nexport * from './_hooks/Anchor'\nexport * from './_hooks/Autofocus'\nexport * from './_hooks/BoundingRect'\nexport * from './_hooks/Buffer'\nexport * from './_hooks/ClickOutside'\nexport * from './_hooks/DateTime'\nexport * from './_hooks/DelayedCallback'\nexport * from './_hooks/DelayedToggle'\nexport * from './_hooks/Deprecation'\nexport * from './_hooks/Event'\nexport * from './_hooks/EventListener'\nexport * from './_hooks/Hotkey'\nexport * from './_hooks/I18n'\nexport * from './_hooks/InjectedScript'\nexport * from './_hooks/ListNavigation'\nexport * from './_hooks/OverflowObserver'\nexport * from './_hooks/Resize'\nexport * from './_hooks/Scroll'\nexport * from './_hooks/TextEntry'\nexport * from './_hooks/Timer'\nexport * from './_hooks/Trigger'\n/**\n * @internal\n */\nexport {\n type UNSAFE_GetEndpoint,\n type UNSAFE_GetPayloadKey,\n type UNSAFE_UploadFile,\n} from './_hooks/useFileUploader'\nexport * from './_hooks/Visibility'\nexport * from './_hooks/ZIndex'\n// Style Stuff\nexport * from './_styles/colors'\n/**\n * @internal\n */\nexport {\n getEllipsis as UNSAFE_getEllipsis,\n getFocus as UNSAFE_getFocus,\n getLineClamp as UNSAFE_getLineClamp,\n} from './_styles/mixins'\nexport * from './_styles/spacing'\n/**\n * @internal\n */\nexport { addSubcomponents as UNSAFE_addSubcomponents } from './_utils/addSubcomponents'\n/**\n * @internal\n */\nexport { intlDateTimeFormat } from './_utils/dateTime'\n/**\n * @internal\n */\nexport { parseFilename as UNSAFE_parseFilename } from './_utils/filename'\n/**\n * @internal\n */\nexport { type IAnalytics } from './_utils/genericAnalyticsClient'\n/**\n * @internal\n */\nexport { mergeRefs as UNSAFE_mergeRefs } from './_utils/mergeRefs'\n// export { getTypographyIntent, typographyWeights } from './Typography'\n// For documentation only\nexport { docsProps as UNSAFE_props } from './_utils/props'\n"],"mappings":"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"}
1
+ {"version":3,"file":"index.js","names":["BETA_makeField","borderRadius","getBorderRadius","UNSAFE_getBorderRadius","getEllipsis","UNSAFE_getEllipsis","getFocus","UNSAFE_getFocus","getLineClamp","UNSAFE_getLineClamp","addSubcomponents","UNSAFE_addSubcomponents","intlDateTimeFormat","parseFilename","UNSAFE_parseFilename","mergeRefs","UNSAFE_mergeRefs","docsProps","UNSAFE_props"],"sources":["../src/index.ts"],"sourcesContent":["// export const version = process.env.VERSION\nexport * from './Avatar'\nexport * from './AvatarStack'\nexport * from './Badge'\nexport * from './Banner'\nexport * from './Box'\nexport * from './Breadcrumbs'\nexport * from './Button'\nexport * from './Calendar'\nexport * from './Card'\nexport * from './Checkbox'\nexport * from './ClickOutside'\nexport * from './ContactItem'\nexport * from './Content'\nexport * from './DateInput'\nexport * from './DateSelect'\nexport * from './DetailPage'\nexport * from './Dropdown'\nexport * from './DropdownFlyout'\nexport * from './Dropzone'\nexport * from './EmptyState'\nexport * from './FileList'\nexport * from './FileSelect'\nexport * from './FileToken'\nexport * from './FilterToken'\nexport * from './Flex'\nexport * from './FlexList'\nexport * from './Form'\n/**\n * @internal\n * Will require extending types FormFieldProps and FormFieldValueComponentProps\n */\nexport { BETA_makeField } from './Form'\nexport * from './Grid'\nexport * from './GroupSelect'\nexport * from './Input'\nexport * from './Link'\nexport * from './ListPage'\nexport * from './Menu'\nexport * from './MenuImperative'\nexport * from './Modal'\nexport * from './MultiSelect'\nexport * from './Notation'\nexport * from './NumberInput'\nexport * from './Overlay'\nexport * from './OverlayTrigger'\nexport * from './PageLayout'\nexport * from './Pagination'\nexport * from './Panel'\nexport * from './Pill'\nexport * from './PillSelect'\nexport * from './Popover'\nexport * from './Portal'\nexport * from './ProgressBar'\nexport * from './RadioButton'\nexport * from './Required'\nexport * from './Search'\nexport * from './SegmentedController'\nexport * from './Select'\nexport * from './Semantic'\nexport * from './Sidebar'\nexport * from './Slider'\nexport * from './Spinner'\nexport * from './SuperSelect'\nexport * from './Switch'\nexport * from './Table'\nexport * from './TableShelf'\nexport * from './Tabs'\nexport * from './Tearsheet'\nexport * from './TextArea'\nexport * from './TextEditor'\nexport * from './TextEditorOutput'\nexport * from './Thumbnail'\nexport * from './TieredDropdown'\nexport * from './TieredSelect'\nexport * from './Tile'\nexport * from './Title'\nexport * from './Toast'\nexport * from './ToggleButton'\nexport * from './Token'\nexport * from './ToolHeader'\nexport * from './Tooltip'\nexport * from './Tree'\nexport * from './Typeahead'\nexport * from './Typography'\nexport * from './_hooks/Analytics'\nexport * from './_hooks/Anchor'\nexport * from './_hooks/Autofocus'\nexport * from './_hooks/BoundingRect'\nexport * from './_hooks/Buffer'\nexport * from './_hooks/ClickOutside'\nexport * from './_hooks/DateTime'\nexport * from './_hooks/DelayedCallback'\nexport * from './_hooks/DelayedToggle'\nexport * from './_hooks/Deprecation'\nexport * from './_hooks/Event'\nexport * from './_hooks/EventListener'\nexport * from './_hooks/Hotkey'\nexport * from './_hooks/I18n'\nexport * from './_hooks/InjectedScript'\nexport * from './_hooks/ListNavigation'\nexport * from './_hooks/OverflowObserver'\nexport * from './_hooks/Resize'\nexport * from './_hooks/Scroll'\nexport * from './_hooks/TextEntry'\nexport * from './_hooks/Timer'\nexport * from './_hooks/Trigger'\n/**\n * @internal\n */\nexport {\n type UNSAFE_GetEndpoint,\n type UNSAFE_GetPayloadKey,\n type UNSAFE_UploadFile,\n} from './_hooks/useFileUploader'\nexport * from './_hooks/Visibility'\nexport * from './_hooks/ZIndex'\n// Style Stuff\nexport {\n borderRadius,\n getBorderRadius as UNSAFE_getBorderRadius,\n} from './_styles/borderRadius'\nexport * from './_styles/colors'\n/**\n * @internal\n */\nexport {\n getEllipsis as UNSAFE_getEllipsis,\n getFocus as UNSAFE_getFocus,\n getLineClamp as UNSAFE_getLineClamp,\n} from './_styles/mixins'\nexport * from './_styles/spacing'\n/**\n * @internal\n */\nexport { addSubcomponents as UNSAFE_addSubcomponents } from './_utils/addSubcomponents'\n/**\n * @internal\n */\nexport { intlDateTimeFormat } from './_utils/dateTime'\n/**\n * @internal\n */\nexport { parseFilename as UNSAFE_parseFilename } from './_utils/filename'\n/**\n * @internal\n */\nexport { type IAnalytics } from './_utils/genericAnalyticsClient'\n/**\n * @internal\n */\nexport { mergeRefs as UNSAFE_mergeRefs } from './_utils/mergeRefs'\n// export { getTypographyIntent, typographyWeights } from './Typography'\n// For documentation only\nexport { docsProps as UNSAFE_props } from './_utils/props'\n"],"mappings":"AAAA;AACA,cAAc,UAAU;AACxB,cAAc,eAAe;AAC7B,cAAc,SAAS;AACvB,cAAc,UAAU;AACxB,cAAc,OAAO;AACrB,cAAc,eAAe;AAC7B,cAAc,UAAU;AACxB,cAAc,YAAY;AAC1B,cAAc,QAAQ;AACtB,cAAc,YAAY;AAC1B,cAAc,gBAAgB;AAC9B,cAAc,eAAe;AAC7B,cAAc,WAAW;AACzB,cAAc,aAAa;AAC3B,cAAc,cAAc;AAC5B,cAAc,cAAc;AAC5B,cAAc,YAAY;AAC1B,cAAc,kBAAkB;AAChC,cAAc,YAAY;AAC1B,cAAc,cAAc;AAC5B,cAAc,YAAY;AAC1B,cAAc,cAAc;AAC5B,cAAc,aAAa;AAC3B,cAAc,eAAe;AAC7B,cAAc,QAAQ;AACtB,cAAc,YAAY;AAC1B,cAAc,QAAQ;AACtB;AACA;AACA;AACA;AACA,SAASA,cAAc,QAAQ,QAAQ;AACvC,cAAc,QAAQ;AACtB,cAAc,eAAe;AAC7B,cAAc,SAAS;AACvB,cAAc,QAAQ;AACtB,cAAc,YAAY;AAC1B,cAAc,QAAQ;AACtB,cAAc,kBAAkB;AAChC,cAAc,SAAS;AACvB,cAAc,eAAe;AAC7B,cAAc,YAAY;AAC1B,cAAc,eAAe;AAC7B,cAAc,WAAW;AACzB,cAAc,kBAAkB;AAChC,cAAc,cAAc;AAC5B,cAAc,cAAc;AAC5B,cAAc,SAAS;AACvB,cAAc,QAAQ;AACtB,cAAc,cAAc;AAC5B,cAAc,WAAW;AACzB,cAAc,UAAU;AACxB,cAAc,eAAe;AAC7B,cAAc,eAAe;AAC7B,cAAc,YAAY;AAC1B,cAAc,UAAU;AACxB,cAAc,uBAAuB;AACrC,cAAc,UAAU;AACxB,cAAc,YAAY;AAC1B,cAAc,WAAW;AACzB,cAAc,UAAU;AACxB,cAAc,WAAW;AACzB,cAAc,eAAe;AAC7B,cAAc,UAAU;AACxB,cAAc,SAAS;AACvB,cAAc,cAAc;AAC5B,cAAc,QAAQ;AACtB,cAAc,aAAa;AAC3B,cAAc,YAAY;AAC1B,cAAc,cAAc;AAC5B,cAAc,oBAAoB;AAClC,cAAc,aAAa;AAC3B,cAAc,kBAAkB;AAChC,cAAc,gBAAgB;AAC9B,cAAc,QAAQ;AACtB,cAAc,SAAS;AACvB,cAAc,SAAS;AACvB,cAAc,gBAAgB;AAC9B,cAAc,SAAS;AACvB,cAAc,cAAc;AAC5B,cAAc,WAAW;AACzB,cAAc,QAAQ;AACtB,cAAc,aAAa;AAC3B,cAAc,cAAc;AAC5B,cAAc,oBAAoB;AAClC,cAAc,iBAAiB;AAC/B,cAAc,oBAAoB;AAClC,cAAc,uBAAuB;AACrC,cAAc,iBAAiB;AAC/B,cAAc,uBAAuB;AACrC,cAAc,mBAAmB;AACjC,cAAc,0BAA0B;AACxC,cAAc,wBAAwB;AACtC,cAAc,sBAAsB;AACpC,cAAc,gBAAgB;AAC9B,cAAc,wBAAwB;AACtC,cAAc,iBAAiB;AAC/B,cAAc,eAAe;AAC7B,cAAc,yBAAyB;AACvC,cAAc,yBAAyB;AACvC,cAAc,2BAA2B;AACzC,cAAc,iBAAiB;AAC/B,cAAc,iBAAiB;AAC/B,cAAc,oBAAoB;AAClC,cAAc,gBAAgB;AAC9B,cAAc,kBAAkB;AAChC;AACA;AACA;;AAMA,cAAc,qBAAqB;AACnC,cAAc,iBAAiB;AAC/B;AACA,SACEC,YAAY,EACZC,eAAe,IAAIC,sBAAsB,QACpC,wBAAwB;AAC/B,cAAc,kBAAkB;AAChC;AACA;AACA;AACA,SACEC,WAAW,IAAIC,kBAAkB,EACjCC,QAAQ,IAAIC,eAAe,EAC3BC,YAAY,IAAIC,mBAAmB,QAC9B,kBAAkB;AACzB,cAAc,mBAAmB;AACjC;AACA;AACA;AACA,SAASC,gBAAgB,IAAIC,uBAAuB,QAAQ,2BAA2B;AACvF;AACA;AACA;AACA,SAASC,kBAAkB,QAAQ,mBAAmB;AACtD;AACA;AACA;AACA,SAASC,aAAa,IAAIC,oBAAoB,QAAQ,mBAAmB;AACzE;AACA;AACA;;AAEA;AACA;AACA;AACA,SAASC,SAAS,IAAIC,gBAAgB,QAAQ,oBAAoB;AAClE;AACA;AACA,SAASC,SAAS,IAAIC,YAAY,QAAQ,gBAAgB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@procore/core-react",
3
- "version": "11.25.1",
3
+ "version": "11.25.2",
4
4
  "description": "React library of Procore Design Guidelines",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",
@@ -14,7 +14,7 @@
14
14
  },
15
15
  "scripts": {
16
16
  "build": "yarn run clean && yarn run build:esm & yarn run build:types & yarn run build:typedoc",
17
- "build:esm": "BUNDLING=true babel src --out-dir dist --extensions '.ts,.tsx,.snap' -s --copy-files --no-copy-ignored",
17
+ "build:esm": "BUNDLING=true babel src --out-dir dist --extensions '.ts,.tsx,.js,.snap' -s --copy-files --no-copy-ignored",
18
18
  "build:types": "tsc --declaration --emitDeclarationOnly -p tsconfig.prod.json",
19
19
  "build:typedoc": "ts-node typedoc.ts",
20
20
  "chromatic": "chromatic --project-token=cf8c48cce207",
@@ -1,4 +1,10 @@
1
1
  {
2
2
  "extends": "./tsconfig.json",
3
- "exclude": ["typedoc.ts", "dist/**/*.d.ts", "**/*.stories.*", "**/*.test.*"]
3
+ "exclude": [
4
+ "typedoc.ts",
5
+ "dist/**/*.d.ts",
6
+ "src/**/*.stories.*",
7
+ "src/**/*.test.*",
8
+ "src/**/__tests__/**"
9
+ ]
4
10
  }
@@ -1,53 +0,0 @@
1
- // failure to import matchesSnapshot
2
- import { Cog } from '@procore/core-icons/dist'
3
- import React from 'react'
4
- import { matchesSnapshot } from '../../__tests__/helpers/snapshots'
5
- import { SourceItem } from './SourceItem'
6
-
7
- describe('SourceItem', () => {
8
- it('default view', () => {
9
- matchesSnapshot(<SourceItem />)
10
- })
11
-
12
- it('DivAttributes', () => {
13
- matchesSnapshot(<SourceItem className="TEST" tabIndex={100} />)
14
- })
15
-
16
- it('error view', () => {
17
- matchesSnapshot(<SourceItem error />)
18
- })
19
-
20
- it('loading view', () => {
21
- matchesSnapshot(<SourceItem loading />)
22
- })
23
-
24
- it('selected view', () => {
25
- matchesSnapshot(<SourceItem selected />)
26
- })
27
-
28
- it('disabled view', () => {
29
- matchesSnapshot(<SourceItem disabled />)
30
- })
31
-
32
- it('icon and label', () => {
33
- matchesSnapshot(<SourceItem icon={<Cog />}>Label</SourceItem>)
34
- })
35
-
36
- describe('count', () => {
37
- it('equal to 0 should not be rendered', () => {
38
- matchesSnapshot(<SourceItem count={0} />)
39
- })
40
-
41
- it('should be rendered as is in parentheses when larger then 0 and less then 100', () => {
42
- matchesSnapshot(<SourceItem count={24} />)
43
- })
44
-
45
- it('should be rendered truncated in parentheses when larger then 99', () => {
46
- matchesSnapshot(<SourceItem count={100} />)
47
- })
48
-
49
- it('should be rendered truncated in parentheses when equal or larger then custom threshold', () => {
50
- matchesSnapshot(<SourceItem count={11} countTruncationThreshold={10} />)
51
- })
52
- })
53
- })
@@ -1,250 +0,0 @@
1
- import { configure } from '@testing-library/dom'
2
- import '@testing-library/jest-dom'
3
- import {
4
- render,
5
- screen,
6
- waitFor,
7
- waitForElementToBeRemoved,
8
- } from '@testing-library/react'
9
- import userEvent from '@testing-library/user-event'
10
- import React from 'react'
11
- import { MultiSelect } from './MultiSelect'
12
-
13
- configure({ testIdAttribute: 'data-qa' })
14
-
15
- const options = [
16
- {
17
- id: '1',
18
- label: 'blue bird is a really long item and should overflow',
19
- groupId: '1',
20
- },
21
- { id: '2', label: 'canary', groupId: '1' },
22
- { id: '3', label: 'eagle', groupId: '1' },
23
- { id: '4', label: 'falcon', groupId: '1' },
24
- { id: '5', label: 'finch', groupId: '1' },
25
- { id: '6', label: 'hawk', groupId: '2' },
26
- { id: '7', label: 'owl', groupId: '2' },
27
- { id: '8', label: 'pigeon', groupId: '2' },
28
- { id: '9', label: 'raven', groupId: '2' },
29
- { id: '10', label: 'toucan', groupId: '2' },
30
- ]
31
-
32
- const groups = [
33
- { id: '1', label: 'Group 1' },
34
- { id: '2', label: 'Group 2' },
35
- ]
36
-
37
- const qaTags = {
38
- option: (option) => `option-${option.id}`,
39
- token: (option) => `token-${option.id}`,
40
- tokenClear: (option) => `clear-token-${option.id}`,
41
- }
42
- const values = [options[0], options[5]]
43
- const clearIcon = '[data-qa="core-multiselect-clear"]'
44
- const menuItem = 'option-'
45
- const menuItems = '[data-qa^="option-"]'
46
- const menuGroup = '[data-group="true"]'
47
- const placeholder = 'Select Values'
48
- const selectArrow = 'multiselect-select-arrow'
49
- const selectedInput = '[data-qa^="token-"]'
50
- const selectedMenuItem = '[data-selected="true"]'
51
- const optRemovalIcon = '[data-qa^="clear-token-"]'
52
-
53
- const getSelectedItems = (selector) => {
54
- return getQuerySelectorAll(selector).length
55
- }
56
-
57
- const elementExists = (selector) => {
58
- return getQuerySelector(selector).length > 0
59
- }
60
-
61
- const getOptionText = (id) => {
62
- return options.find((option) => option.id === id).label
63
- }
64
-
65
- function BasicProps(props) {
66
- const [value, setValue] = React.useState(props.values || [])
67
-
68
- return (
69
- <MultiSelect
70
- onChange={setValue}
71
- options={options}
72
- value={value}
73
- qa={qaTags}
74
- {...props}
75
- />
76
- )
77
- }
78
-
79
- function click(element) {
80
- return userEvent.click(element)
81
- }
82
-
83
- function getByPlaceholderText(text) {
84
- return screen.getByPlaceholderText(text)
85
- }
86
-
87
- function getByTestId(testId) {
88
- return screen.getByTestId(testId)
89
- }
90
-
91
- function getByText(text) {
92
- return screen.getByText(text)
93
- }
94
-
95
- function getQuerySelector(selector) {
96
- return document.querySelector(selector)
97
- }
98
-
99
- function getQuerySelectorAll(selector) {
100
- return document.querySelectorAll(selector)
101
- }
102
-
103
- /**
104
- *
105
- * To get selected values in the button(input) and to omit options.
106
- * Clicking on the removal icon toggles open state,
107
- * so getByText finds two same texts sometimes
108
- * @param text
109
- * @returns {ReturnType<GetByText<HTMLElement>>}
110
- */
111
- function getByTextSelectedInput(text) {
112
- return screen.getByText(text, { selector: `${selectedInput} *` })
113
- }
114
-
115
- describe('MultiSelect', () => {
116
- it('should render with selected options', async () => {
117
- render(<BasicProps values={values} />)
118
-
119
- expect(screen.queryByText(placeholder)).not.toBeInTheDocument()
120
-
121
- await click(getByTestId(selectArrow))
122
- await waitFor(() => {
123
- expect(getSelectedItems(selectedInput)).toBe(2)
124
- expect(Boolean(screen.getAllByText(options[0].label))).toBe(true)
125
- expect(Boolean(screen.getAllByText(options[5].label))).toBe(true)
126
- expect(getSelectedItems(selectedMenuItem)).toBe(2)
127
- })
128
- })
129
-
130
- it('should select a single option', async () => {
131
- const optionId = '2'
132
-
133
- render(<BasicProps />)
134
-
135
- await click(getByTestId(selectArrow))
136
- await waitFor(() => getByTestId(`${menuItem}${optionId}`))
137
-
138
- await click(getByTestId(`${menuItem}${optionId}`))
139
-
140
- expect(getSelectedItems(selectedInput)).toBe(1)
141
- expect(getSelectedItems(selectedMenuItem)).toBe(1)
142
- expect(screen.getAllByText(getOptionText(optionId)).length).toBe(2)
143
- })
144
-
145
- it('should select multiple options and close menu', async () => {
146
- const ids = ['1', '2', '3']
147
-
148
- render(<BasicProps />)
149
-
150
- await click(getByTestId(selectArrow))
151
- await waitFor(() => elementExists(menuItems))
152
-
153
- await click(getByTestId(`${menuItem}${ids[0]}`))
154
- await click(getByTestId(`${menuItem}${ids[1]}`))
155
- await click(getByTestId(`${menuItem}${ids[2]}`))
156
-
157
- await click(getByTestId(selectArrow))
158
- await waitForElementToBeRemoved(getQuerySelector(menuItems))
159
-
160
- expect(getSelectedItems(selectedInput)).toBe(3)
161
- expect(Boolean(getOptionText(ids[0]))).toBe(true)
162
- expect(Boolean(getOptionText(ids[1]))).toBe(true)
163
- expect(Boolean(getOptionText(ids[2]))).toBe(true)
164
- })
165
-
166
- it('should remove a selected option clicking on option removal icon', async () => {
167
- render(<BasicProps values={values} />)
168
-
169
- await click(getQuerySelector(optRemovalIcon))
170
- expect(getSelectedItems(selectedInput)).toBe(1)
171
- expect(Boolean(getByTextSelectedInput(getOptionText('6')))).toBe(true)
172
- })
173
-
174
- it('should clear all selected options', async () => {
175
- render(<BasicProps values={values} />)
176
-
177
- await click(getQuerySelector(clearIcon))
178
- expect(Boolean(getByPlaceholderText(placeholder))).toBe(true)
179
- })
180
-
181
- it('should add to initially loaded options', async () => {
182
- render(<BasicProps values={values} />)
183
-
184
- await click(getByTestId(selectArrow))
185
- await waitFor(() => getByTestId(`${menuItem}2`))
186
- await click(getByTestId(`${menuItem}2`))
187
- await click(getByTestId(selectArrow))
188
- await waitForElementToBeRemoved(getQuerySelector(menuItems))
189
-
190
- expect(getSelectedItems(selectedInput)).toBe(3)
191
- expect(Boolean(getByText(getOptionText('1')))).toBe(true)
192
- expect(Boolean(getByText(getOptionText('2')))).toBe(true)
193
- expect(Boolean(getByText(getOptionText('6')))).toBe(true)
194
- })
195
-
196
- it('should remove multiple options', async () => {
197
- render(<BasicProps values={[options[0], options[1], options[5]]} />)
198
- await click(getQuerySelector(optRemovalIcon))
199
- await click(getQuerySelector(optRemovalIcon))
200
-
201
- expect(getSelectedItems(selectedInput)).toBe(1)
202
- expect(Boolean(getByTextSelectedInput(getOptionText('6')))).toBe(true)
203
- })
204
-
205
- it('should remove all options clicking on option removal icon', async () => {
206
- render(<BasicProps />)
207
-
208
- await Array.from(getQuerySelectorAll(optRemovalIcon)).map(async (icon) => {
209
- await click(icon)
210
- })
211
-
212
- expect(getSelectedItems(selectedInput)).toBe(0)
213
- })
214
-
215
- it('should remove selection by clicking option in the menu', async () => {
216
- render(<BasicProps values={values} />)
217
-
218
- await click(getByTestId(selectArrow))
219
- await waitFor(() => elementExists(menuItems))
220
- await click(getQuerySelector(selectedMenuItem))
221
-
222
- expect(getSelectedItems(selectedMenuItem)).toBe(1)
223
- })
224
-
225
- it('should select options from different groups', async () => {
226
- render(<BasicProps optgroups={groups} />)
227
-
228
- await click(getByTestId(selectArrow))
229
- await waitFor(() =>
230
- expect(getQuerySelectorAll(menuGroup).length).toBe(groups.length)
231
- )
232
-
233
- await click(getByText(getOptionText('2')))
234
- await click(getByText(getOptionText('6')))
235
-
236
- expect(getSelectedItems(selectedMenuItem)).toBe(2)
237
-
238
- await click(getByTestId(selectArrow))
239
- await waitForElementToBeRemoved(getQuerySelector(menuItems))
240
-
241
- expect(Boolean(getByText(getOptionText('2')))).toBe(true)
242
- expect(Boolean(getByText(getOptionText('6')))).toBe(true)
243
- })
244
-
245
- it('should render footer if defined', async () => {
246
- render(<BasicProps footer={<b>Footer</b>} />)
247
- await click(getByTestId(selectArrow))
248
- await waitFor(() => expect(Boolean(getByText('Footer'))).toBe(true))
249
- })
250
- })