@nypl/design-system-react-components 0.27.0 → 0.28.0

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 (298) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/dist/components/Accordion/Accordion.d.ts +1 -1
  3. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +1 -5
  4. package/dist/components/Button/Button.d.ts +2 -10
  5. package/dist/components/ButtonGroup/ButtonGroup.d.ts +22 -0
  6. package/dist/components/Card/Card.d.ts +2 -2
  7. package/dist/components/Checkbox/Checkbox.d.ts +10 -8
  8. package/dist/components/CheckboxGroup/CheckboxGroup.d.ts +1 -1
  9. package/dist/components/DatePicker/DatePicker.d.ts +1 -1
  10. package/dist/components/Form/Form.d.ts +2 -2
  11. package/dist/components/Grid/SimpleGrid.d.ts +6 -3
  12. package/dist/components/Heading/Heading.d.ts +2 -5
  13. package/dist/components/HelperErrorText/HelperErrorText.d.ts +1 -5
  14. package/dist/components/Hero/Hero.d.ts +13 -9
  15. package/dist/components/Icons/Icon.d.ts +6 -5
  16. package/dist/components/Icons/IconSvgs.d.ts +21 -21
  17. package/dist/components/Image/Image.d.ts +8 -5
  18. package/dist/components/Link/Link.d.ts +1 -9
  19. package/dist/components/List/List.d.ts +7 -11
  20. package/dist/components/Logo/Logo.d.ts +2 -5
  21. package/dist/components/Logo/LogoSvgs.d.ts +39 -39
  22. package/dist/components/Notification/Notification.d.ts +1 -1
  23. package/dist/components/ProgressIndicator/ProgressIndicator.d.ts +2 -1
  24. package/dist/components/RadioGroup/RadioGroup.d.ts +1 -1
  25. package/dist/components/SearchBar/SearchBar.d.ts +3 -2
  26. package/dist/components/Select/Select.d.ts +2 -5
  27. package/dist/components/SkeletonLoader/SkeletonLoader.d.ts +4 -4
  28. package/dist/components/SkipNavigation/SkipNavigation.d.ts +17 -0
  29. package/dist/components/StatusBadge/StatusBadge.d.ts +2 -3
  30. package/dist/components/StructuredContent/StructuredContent.d.ts +2 -2
  31. package/dist/components/Table/Table.d.ts +1 -1
  32. package/dist/components/Template/Template.d.ts +2 -0
  33. package/dist/components/Text/Text.d.ts +1 -1
  34. package/dist/components/TextInput/TextInput.d.ts +21 -9
  35. package/dist/components/Toggle/Toggle.d.ts +1 -5
  36. package/dist/components/VideoPlayer/VideoPlayer.d.ts +2 -1
  37. package/dist/design-system-react-components.cjs.development.js +856 -1155
  38. package/dist/design-system-react-components.cjs.development.js.map +1 -1
  39. package/dist/design-system-react-components.cjs.production.min.js +1 -1
  40. package/dist/design-system-react-components.cjs.production.min.js.map +1 -1
  41. package/dist/design-system-react-components.esm.js +858 -1220
  42. package/dist/design-system-react-components.esm.js.map +1 -1
  43. package/dist/helpers/types.d.ts +1 -0
  44. package/dist/index.d.ts +26 -47
  45. package/dist/theme/components/buttonGroup.d.ts +11 -0
  46. package/dist/theme/components/card.d.ts +104 -8
  47. package/dist/theme/components/componentWrapper.d.ts +4 -3
  48. package/dist/theme/components/customTable.d.ts +11 -14
  49. package/dist/theme/components/fieldset.d.ts +4 -3
  50. package/dist/theme/components/helperErrorText.d.ts +4 -3
  51. package/dist/theme/components/hero.d.ts +1 -1
  52. package/dist/theme/components/horizontalRule.d.ts +4 -3
  53. package/dist/theme/components/icon.d.ts +47743 -1
  54. package/dist/theme/components/image.d.ts +563 -10
  55. package/dist/theme/components/label.d.ts +4 -3
  56. package/dist/theme/components/list.d.ts +6 -7
  57. package/dist/theme/components/logo.d.ts +474 -1
  58. package/dist/theme/components/notification.d.ts +20 -16
  59. package/dist/theme/components/progressIndicator.d.ts +6 -4
  60. package/dist/theme/components/select.d.ts +4 -4
  61. package/dist/theme/components/skeletonLoader.d.ts +14 -10
  62. package/dist/theme/components/skipNavigation.d.ts +22 -0
  63. package/dist/theme/components/slider.d.ts +7 -6
  64. package/dist/theme/components/structuredContent.d.ts +10 -9
  65. package/dist/theme/components/text.d.ts +7 -1
  66. package/dist/theme/components/toggle.d.ts +6 -4
  67. package/dist/theme/provider.d.ts +2 -4
  68. package/dist/utils/componentCategories.d.ts +1 -1
  69. package/dist/utils/interfaces.d.ts +5 -0
  70. package/dist/utils/utils.d.ts +2 -18
  71. package/package.json +2 -2
  72. package/src/__tests__/setup.ts +3 -3
  73. package/src/__tests__/utils/utils.test.ts +1 -23
  74. package/src/components/AccessibilityGuide/SkipNavigation.stories.mdx +22 -14
  75. package/src/components/Accordion/Accordion.stories.mdx +43 -44
  76. package/src/components/Accordion/Accordion.test.tsx +5 -13
  77. package/src/components/Accordion/Accordion.tsx +14 -18
  78. package/src/components/Accordion/__snapshots__/Accordion.test.tsx.snap +6 -6
  79. package/src/components/Autosuggest/Autosuggest.stories.mdx +1 -1
  80. package/src/components/Autosuggest/Autosuggest.stories.tsx +23 -25
  81. package/src/components/Breadcrumbs/Breadcrumbs.stories.mdx +21 -37
  82. package/src/components/Breadcrumbs/Breadcrumbs.test.tsx +4 -17
  83. package/src/components/Breadcrumbs/Breadcrumbs.tsx +18 -21
  84. package/src/components/Breadcrumbs/__snapshots__/Breadcrumbs.test.tsx.snap +1 -100
  85. package/src/components/Button/Button.stories.mdx +89 -126
  86. package/src/components/Button/Button.test.tsx +16 -30
  87. package/src/components/Button/Button.tsx +14 -20
  88. package/src/components/ButtonGroup/ButtonGroup.stories.mdx +147 -0
  89. package/src/components/ButtonGroup/ButtonGroup.test.tsx +141 -0
  90. package/src/components/ButtonGroup/ButtonGroup.tsx +99 -0
  91. package/src/components/ButtonGroup/__snapshots__/ButtonGroup.test.tsx.snap +117 -0
  92. package/src/components/Card/Card.stories.mdx +143 -177
  93. package/src/components/Card/Card.test.tsx +36 -97
  94. package/src/components/Card/Card.tsx +78 -74
  95. package/src/components/Chakra/Box.stories.mdx +2 -6
  96. package/src/components/Chakra/Center.stories.mdx +5 -23
  97. package/src/components/Chakra/Flex.stories.mdx +4 -6
  98. package/src/components/Chakra/Stack.stories.mdx +9 -10
  99. package/src/components/Checkbox/Checkbox.stories.mdx +1 -1
  100. package/src/components/Checkbox/Checkbox.test.tsx +2 -2
  101. package/src/components/Checkbox/Checkbox.tsx +20 -13
  102. package/src/components/CheckboxGroup/CheckboxGroup.stories.mdx +6 -17
  103. package/src/components/CheckboxGroup/CheckboxGroup.test.tsx +1 -7
  104. package/src/components/CheckboxGroup/CheckboxGroup.tsx +33 -29
  105. package/src/components/CheckboxGroup/__snapshots__/CheckboxGroup.test.tsx.snap +0 -11
  106. package/src/components/ComponentWrapper/ComponentWrapper.tsx +3 -10
  107. package/src/components/DatePicker/DatePicker.stories.mdx +23 -37
  108. package/src/components/DatePicker/DatePicker.test.tsx +21 -19
  109. package/src/components/DatePicker/DatePicker.tsx +57 -49
  110. package/src/components/Form/Form.stories.mdx +46 -31
  111. package/src/components/Form/Form.test.tsx +1 -18
  112. package/src/components/Form/Form.tsx +7 -7
  113. package/src/components/Grid/SimpleGrid.stories.mdx +73 -49
  114. package/src/components/Grid/SimpleGrid.test.tsx +7 -9
  115. package/src/components/Grid/SimpleGrid.tsx +14 -11
  116. package/src/components/Heading/Heading.stories.mdx +27 -72
  117. package/src/components/Heading/Heading.test.tsx +18 -44
  118. package/src/components/Heading/Heading.tsx +7 -10
  119. package/src/components/HelperErrorText/HelperErrorText.stories.mdx +1 -3
  120. package/src/components/HelperErrorText/HelperErrorText.tsx +1 -5
  121. package/src/components/Hero/Hero.stories.mdx +219 -216
  122. package/src/components/Hero/Hero.test.tsx +107 -223
  123. package/src/components/Hero/Hero.tsx +63 -61
  124. package/src/components/Icons/Icon.stories.mdx +172 -118
  125. package/src/components/Icons/Icon.test.tsx +8 -16
  126. package/src/components/Icons/Icon.tsx +75 -29
  127. package/src/components/Icons/IconSvgs.tsx +42 -42
  128. package/src/components/Image/Image.stories.mdx +45 -132
  129. package/src/components/Image/Image.test.tsx +16 -31
  130. package/src/components/Image/Image.tsx +28 -12
  131. package/src/components/Link/Link.stories.mdx +30 -80
  132. package/src/components/Link/Link.test.tsx +25 -53
  133. package/src/components/Link/Link.tsx +43 -56
  134. package/src/components/Link/__snapshots__/Link.test.tsx.snap +1 -2
  135. package/src/components/List/List.stories.mdx +20 -31
  136. package/src/components/List/List.test.tsx +24 -43
  137. package/src/components/List/List.tsx +25 -36
  138. package/src/components/Logo/Logo.stories.mdx +94 -50
  139. package/src/components/Logo/Logo.test.tsx +10 -19
  140. package/src/components/Logo/Logo.tsx +50 -17
  141. package/src/components/Logo/LogoSvgs.tsx +78 -78
  142. package/src/components/Logo/__snapshots__/Logo.test.tsx.snap +4 -4
  143. package/src/components/Modal/Modal.stories.mdx +8 -9
  144. package/src/components/Modal/Modal.test.tsx +5 -10
  145. package/src/components/Modal/Modal.tsx +1 -1
  146. package/src/components/Notification/Notification.stories.mdx +10 -28
  147. package/src/components/Notification/Notification.test.tsx +9 -12
  148. package/src/components/Notification/Notification.tsx +34 -37
  149. package/src/components/Pagination/Pagination.stories.mdx +2 -2
  150. package/src/components/Pagination/Pagination.tsx +15 -10
  151. package/src/components/ProgressIndicator/ProgressIndicator.stories.mdx +27 -53
  152. package/src/components/ProgressIndicator/ProgressIndicator.test.tsx +9 -10
  153. package/src/components/ProgressIndicator/ProgressIndicator.tsx +17 -21
  154. package/src/components/ProgressIndicator/__snapshots__/ProgressIndicator.test.tsx.snap +0 -10
  155. package/src/components/Radio/Radio.stories.mdx +1 -1
  156. package/src/components/Radio/Radio.tsx +9 -6
  157. package/src/components/RadioGroup/RadioGroup.stories.mdx +15 -16
  158. package/src/components/RadioGroup/RadioGroup.test.tsx +2 -8
  159. package/src/components/RadioGroup/RadioGroup.tsx +28 -24
  160. package/src/components/SearchBar/SearchBar.stories.mdx +1 -1
  161. package/src/components/SearchBar/SearchBar.test.tsx +1 -1
  162. package/src/components/SearchBar/SearchBar.tsx +14 -22
  163. package/src/components/SearchBar/__snapshots__/SearchBar.test.tsx.snap +0 -12
  164. package/src/components/Select/Select.stories.mdx +8 -23
  165. package/src/components/Select/Select.test.tsx +6 -7
  166. package/src/components/Select/Select.tsx +13 -26
  167. package/src/components/SkeletonLoader/SkeletonLoader.stories.mdx +17 -56
  168. package/src/components/SkeletonLoader/SkeletonLoader.test.tsx +7 -21
  169. package/src/components/SkeletonLoader/SkeletonLoader.tsx +9 -8
  170. package/src/components/SkeletonLoader/__snapshots__/SkeletonLoader.test.tsx.snap +33 -33
  171. package/src/components/SkipNavigation/SkipNavigation.stories.mdx +90 -0
  172. package/src/components/SkipNavigation/SkipNavigation.test.tsx +63 -0
  173. package/src/components/SkipNavigation/SkipNavigation.tsx +51 -0
  174. package/src/components/SkipNavigation/__snapshots__/SkipNavigation.test.tsx.snap +130 -0
  175. package/src/components/Slider/Slider.stories.mdx +19 -53
  176. package/src/components/Slider/Slider.test.tsx +2 -2
  177. package/src/components/Slider/Slider.tsx +10 -12
  178. package/src/components/Slider/__snapshots__/Slider.test.tsx.snap +2 -9
  179. package/src/components/StatusBadge/StatusBadge.stories.mdx +6 -21
  180. package/src/components/StatusBadge/StatusBadge.test.tsx +2 -3
  181. package/src/components/StatusBadge/StatusBadge.tsx +3 -10
  182. package/src/components/StructuredContent/StructuredContent.stories.mdx +30 -58
  183. package/src/components/StructuredContent/StructuredContent.test.tsx +42 -44
  184. package/src/components/StructuredContent/StructuredContent.tsx +9 -18
  185. package/src/components/StyleGuide/Bidirectionality.stories.mdx +9 -23
  186. package/src/components/StyleGuide/Buttons.stories.mdx +62 -62
  187. package/src/components/StyleGuide/ColorCard.tsx +2 -4
  188. package/src/components/StyleGuide/Colors.stories.mdx +7 -8
  189. package/src/components/StyleGuide/DesignTokens.stories.mdx +5 -7
  190. package/src/components/StyleGuide/Forms.stories.mdx +0 -1
  191. package/src/components/StyleGuide/Iconography.stories.mdx +59 -77
  192. package/src/components/StyleGuide/Spacing.stories.mdx +0 -1
  193. package/src/components/StyleGuide/Typography.stories.mdx +15 -18
  194. package/src/components/Table/Table.stories.mdx +85 -1
  195. package/src/components/Table/Table.test.tsx +57 -1
  196. package/src/components/Table/Table.tsx +7 -4
  197. package/src/components/Table/__snapshots__/Table.test.tsx.snap +121 -0
  198. package/src/components/Tabs/Tabs.stories.mdx +1 -1
  199. package/src/components/Tabs/Tabs.test.tsx +2 -2
  200. package/src/components/Tabs/Tabs.tsx +26 -27
  201. package/src/components/Template/Template.stories.mdx +49 -54
  202. package/src/components/Template/Template.tsx +9 -3
  203. package/src/components/Text/Text.stories.mdx +5 -11
  204. package/src/components/Text/Text.test.tsx +3 -6
  205. package/src/components/Text/Text.tsx +3 -5
  206. package/src/components/TextInput/TextInput.stories.mdx +10 -22
  207. package/src/components/TextInput/TextInput.test.tsx +32 -62
  208. package/src/components/TextInput/TextInput.tsx +61 -30
  209. package/src/components/TextInput/__snapshots__/TextInput.test.tsx.snap +1 -0
  210. package/src/components/Toggle/Toggle.stories.mdx +5 -16
  211. package/src/components/Toggle/Toggle.test.tsx +2 -3
  212. package/src/components/Toggle/Toggle.tsx +9 -10
  213. package/src/components/VideoPlayer/VideoPlayer.stories.mdx +13 -29
  214. package/src/components/VideoPlayer/VideoPlayer.test.tsx +18 -23
  215. package/src/components/VideoPlayer/VideoPlayer.tsx +13 -10
  216. package/src/docs/Chakra.stories.mdx +14 -11
  217. package/src/docs/Welcome.stories.mdx +23 -43
  218. package/src/helpers/types.ts +1 -0
  219. package/src/hooks/tests/useNYPLTheme.test.tsx +1 -1
  220. package/src/hooks/useNYPLTheme.stories.mdx +3 -6
  221. package/src/index.ts +51 -45
  222. package/src/theme/components/buttonGroup.ts +10 -0
  223. package/src/theme/components/card.ts +50 -15
  224. package/src/theme/components/componentWrapper.ts +5 -1
  225. package/src/theme/components/customTable.ts +8 -2
  226. package/src/theme/components/fieldset.ts +5 -1
  227. package/src/theme/components/helperErrorText.ts +5 -1
  228. package/src/theme/components/hero.ts +2 -2
  229. package/src/theme/components/horizontalRule.ts +5 -1
  230. package/src/theme/components/icon.ts +7 -1
  231. package/src/theme/components/image.ts +14 -3
  232. package/src/theme/components/label.ts +5 -1
  233. package/src/theme/components/list.ts +8 -2
  234. package/src/theme/components/logo.ts +5 -1
  235. package/src/theme/components/notification.ts +38 -14
  236. package/src/theme/components/progressIndicator.ts +10 -5
  237. package/src/theme/components/select.ts +5 -2
  238. package/src/theme/components/skeletonLoader.ts +8 -2
  239. package/src/theme/components/skipNavigation.ts +26 -0
  240. package/src/theme/components/slider.ts +13 -1
  241. package/src/theme/components/structuredContent.ts +11 -1
  242. package/src/theme/components/text.ts +12 -5
  243. package/src/theme/components/toggle.ts +9 -3
  244. package/src/theme/index.ts +4 -0
  245. package/src/theme/provider.tsx +1 -1
  246. package/src/utils/componentCategories.ts +13 -5
  247. package/src/utils/interfaces.ts +5 -0
  248. package/src/utils/utils.ts +2 -32
  249. package/dist/components/Accordion/AccordionTypes.d.ts +0 -5
  250. package/dist/components/Breadcrumbs/BreadcrumbsTypes.d.ts +0 -8
  251. package/dist/components/Button/ButtonTypes.d.ts +0 -8
  252. package/dist/components/DatePicker/DatePickerTypes.d.ts +0 -5
  253. package/dist/components/Form/FormTypes.d.ts +0 -2
  254. package/dist/components/Grid/GridTypes.d.ts +0 -9
  255. package/dist/components/Heading/HeadingTypes.d.ts +0 -14
  256. package/dist/components/Hero/HeroTypes.d.ts +0 -12
  257. package/dist/components/Icons/IconTypes.d.ts +0 -77
  258. package/dist/components/Image/ImageTypes.d.ts +0 -22
  259. package/dist/components/Link/LinkTypes.d.ts +0 -8
  260. package/dist/components/List/ListTypes.d.ts +0 -5
  261. package/dist/components/Logo/LogoTypes.d.ts +0 -54
  262. package/dist/components/Notification/NotificationTypes.d.ts +0 -5
  263. package/dist/components/ProgressIndicator/ProgressIndicatorTypes.d.ts +0 -8
  264. package/dist/components/Select/SelectTypes.d.ts +0 -8
  265. package/dist/components/SkeletonLoader/SkeletonLoaderTypes.d.ts +0 -5
  266. package/dist/components/StatusBadge/StatusBadgeTypes.d.ts +0 -5
  267. package/dist/components/StructuredContent/StructuredContentTypes.d.ts +0 -5
  268. package/dist/components/Text/TextTypes.d.ts +0 -6
  269. package/dist/components/TextInput/TextInputTypes.d.ts +0 -25
  270. package/dist/components/Toggle/ToggleTypes.d.ts +0 -4
  271. package/dist/components/VideoPlayer/VideoPlayerTypes.d.ts +0 -9
  272. package/dist/helpers/enums.d.ts +0 -4
  273. package/dist/utils/siteSections.d.ts +0 -2
  274. package/src/components/Accordion/AccordionTypes.tsx +0 -5
  275. package/src/components/Breadcrumbs/BreadcrumbsTypes.tsx +0 -8
  276. package/src/components/Button/ButtonTypes.tsx +0 -8
  277. package/src/components/DatePicker/DatePickerTypes.tsx +0 -5
  278. package/src/components/Form/FormTypes.tsx +0 -3
  279. package/src/components/Grid/GridTypes.tsx +0 -9
  280. package/src/components/Heading/HeadingTypes.tsx +0 -15
  281. package/src/components/Hero/HeroTypes.tsx +0 -20
  282. package/src/components/Icons/IconTypes.tsx +0 -83
  283. package/src/components/Image/ImageTypes.ts +0 -24
  284. package/src/components/Link/LinkTypes.tsx +0 -8
  285. package/src/components/List/ListTypes.tsx +0 -5
  286. package/src/components/Logo/LogoTypes.tsx +0 -56
  287. package/src/components/Notification/NotificationTypes.tsx +0 -5
  288. package/src/components/ProgressIndicator/ProgressIndicatorTypes.ts +0 -8
  289. package/src/components/Select/SelectTypes.tsx +0 -10
  290. package/src/components/SkeletonLoader/SkeletonLoaderTypes.tsx +0 -5
  291. package/src/components/StatusBadge/StatusBadgeTypes.tsx +0 -5
  292. package/src/components/StructuredContent/StructuredContentTypes.tsx +0 -5
  293. package/src/components/Text/TextTypes.tsx +0 -6
  294. package/src/components/TextInput/TextInputTypes.tsx +0 -48
  295. package/src/components/Toggle/ToggleTypes.tsx +0 -4
  296. package/src/components/VideoPlayer/VideoPlayerTypes.tsx +0 -10
  297. package/src/helpers/enums.ts +0 -4
  298. package/src/utils/siteSections.ts +0 -10
@@ -1,82 +1,82 @@
1
1
  /* eslint-disable camelcase */
2
- import logo_bpl_black from "../../../icons/svg/logo_bpl_black.svg";
3
- import logo_bpl_white from "../../../icons/svg/logo_bpl_white.svg";
4
- import logo_clever_color from "../../../icons/svg/logo_clever_color.svg";
5
- import logo_clever_white from "../../../icons/svg/logo_clever_white.svg";
6
- import logo_firstbook_color from "../../../icons/svg/logo_firstbook_color.svg";
7
- import logo_firstbook_color_negative from "../../../icons/svg/logo_firstbook_color_negative.svg";
8
- import logo_lpa_color from "../../../icons/svg/logo_lpa_color.svg";
9
- import logo_lpa_black from "../../../icons/svg/logo_lpa_black.svg";
10
- import logo_lpa_white from "../../../icons/svg/logo_lpa_white.svg";
11
- import logo_mln_black from "../../../icons/svg/logo_mln_black.svg";
12
- import logo_mln_white from "../../../icons/svg/logo_mln_white.svg";
13
- import logo_nypl_full_black from "../../../icons/svg/logo_nypl_full_black.svg";
14
- import logo_nypl_full_white from "../../../icons/svg/logo_nypl_full_white.svg";
15
- import logo_nypl_lion_black from "../../../icons/svg/logo_nypl_lion_black.svg";
16
- import logo_nypl_lion_white from "../../../icons/svg/logo_nypl_lion_white.svg";
17
- import logo_openebooks_color from "../../../icons/svg/logo_openebooks_color.svg";
18
- import logo_openebooks_negative from "../../../icons/svg/logo_openebooks_negative.svg";
19
- import logo_openebooks_wtext_color from "../../../icons/svg/logo_openebooks_wtext_color.svg";
20
- import logo_openebooks_wtext_negative from "../../../icons/svg/logo_openebooks_wtext_negative.svg";
21
- import logo_qpl_alt_black from "../../../icons/svg/logo_qpl_alt_black.svg";
22
- import logo_qpl_alt_white from "../../../icons/svg/logo_qpl_alt_white.svg";
23
- import logo_qpl_black from "../../../icons/svg/logo_qpl_black.svg";
24
- import logo_qpl_color from "../../../icons/svg/logo_qpl_color.svg";
25
- import logo_qpl_white from "../../../icons/svg/logo_qpl_white.svg";
26
- import logo_reservoir_icon_color from "../../../icons/svg/logo_reservoir_icon_color.svg";
27
- import logo_reservoir_vertical_color from "../../../icons/svg/logo_reservoir_vertical_color.svg";
28
- import logo_schomburg_black from "../../../icons/svg/logo_schomburg_black.svg";
29
- import logo_schomburg_circle_black from "../../../icons/svg/logo_schomburg_circle_black.svg";
30
- import logo_schomburg_circle_color from "../../../icons/svg/logo_schomburg_circle_color.svg";
31
- import logo_schomburg_circle_white from "../../../icons/svg/logo_schomburg_circle_white.svg";
32
- import logo_schomburg_color from "../../../icons/svg/logo_schomburg_color.svg";
33
- import logo_schomburg_white from "../../../icons/svg/logo_schomburg_white.svg";
34
- import logo_simplye_black from "../../../icons/svg/logo_simplye_black.svg";
35
- import logo_simplye_white from "../../../icons/svg/logo_simplye_white.svg";
36
- import logo_simplye_color from "../../../icons/svg/logo_simplye_color.svg";
37
- import logo_snfl_black from "../../../icons/svg/logo_snfl_black.svg";
38
- import logo_snfl_white from "../../../icons/svg/logo_snfl_white.svg";
39
- import logo_treasures_color from "../../../icons/svg/logo_treasures_color.svg";
40
- import logo_treasures_color_negative from "../../../icons/svg/logo_treasures_color_negative.svg";
2
+ import bplBlack from "../../../icons/svg/logo-bpl-black.svg";
3
+ import bplWhite from "../../../icons/svg/logo-bpl-white.svg";
4
+ import cleverColor from "../../../icons/svg/logo-clever-color.svg";
5
+ import cleverWhite from "../../../icons/svg/logo-clever-white.svg";
6
+ import firstbookColor from "../../../icons/svg/logo-firstbook-color.svg";
7
+ import firstbookColorNegative from "../../../icons/svg/logo-firstbook-color-negative.svg";
8
+ import lpaColor from "../../../icons/svg/logo-lpa-color.svg";
9
+ import lpaBlack from "../../../icons/svg/logo-lpa-black.svg";
10
+ import lpaWhite from "../../../icons/svg/logo-lpa-white.svg";
11
+ import mlnBlack from "../../../icons/svg/logo-mln-black.svg";
12
+ import mlnWhite from "../../../icons/svg/logo-mln-white.svg";
13
+ import nyplFullBlack from "../../../icons/svg/logo-nypl-full-black.svg";
14
+ import nyplFullWhite from "../../../icons/svg/logo-nypl-full-white.svg";
15
+ import nyplLionBlack from "../../../icons/svg/logo-nypl-lion-black.svg";
16
+ import nyplLionWhite from "../../../icons/svg/logo-nypl-lion-white.svg";
17
+ import openebooksColor from "../../../icons/svg/logo-openebooks-color.svg";
18
+ import openebooksNegative from "../../../icons/svg/logo-openebooks-negative.svg";
19
+ import openebooksWithTextColor from "../../../icons/svg/logo-openebooks-with-text-color.svg";
20
+ import openebooksWithTextNegative from "../../../icons/svg/logo-openebooks-with-text-negative.svg";
21
+ import qplAltBlack from "../../../icons/svg/logo-qpl-alt-black.svg";
22
+ import qplAltWhite from "../../../icons/svg/logo-qpl-alt-white.svg";
23
+ import qplBlack from "../../../icons/svg/logo-qpl-black.svg";
24
+ import qplColor from "../../../icons/svg/logo-qpl-color.svg";
25
+ import qplWhite from "../../../icons/svg/logo-qpl-white.svg";
26
+ import reservoirIconColor from "../../../icons/svg/logo-reservoir-icon-color.svg";
27
+ import reservoirVerticalColor from "../../../icons/svg/logo-reservoir-vertical-color.svg";
28
+ import schomburgBlack from "../../../icons/svg/logo-schomburg-black.svg";
29
+ import schomburgCircleBlack from "../../../icons/svg/logo-schomburg-circle-black.svg";
30
+ import schomburgCircleColor from "../../../icons/svg/logo-schomburg-circle-color.svg";
31
+ import schomburgCircleWhite from "../../../icons/svg/logo-schomburg-circle-white.svg";
32
+ import schomburgColor from "../../../icons/svg/logo-schomburg-color.svg";
33
+ import schomburgWhite from "../../../icons/svg/logo-schomburg-white.svg";
34
+ import simplyeBlack from "../../../icons/svg/logo-simplye-black.svg";
35
+ import simplyeWhite from "../../../icons/svg/logo-simplye-white.svg";
36
+ import simplyeColor from "../../../icons/svg/logo-simplye-color.svg";
37
+ import snflBlack from "../../../icons/svg/logo-snfl-black.svg";
38
+ import snflWhite from "../../../icons/svg/logo-snfl-white.svg";
39
+ import treasuresColor from "../../../icons/svg/logo-treasures-color.svg";
40
+ import treasuresColorNegative from "../../../icons/svg/logo-treasures-color-negative.svg";
41
41
 
42
42
  export default {
43
- logo_bpl_black,
44
- logo_bpl_white,
45
- logo_clever_color,
46
- logo_clever_white,
47
- logo_firstbook_color,
48
- logo_firstbook_color_negative,
49
- logo_lpa_black,
50
- logo_lpa_color,
51
- logo_lpa_white,
52
- logo_mln_black,
53
- logo_mln_white,
54
- logo_nypl_full_black,
55
- logo_nypl_full_white,
56
- logo_nypl_lion_black,
57
- logo_nypl_lion_white,
58
- logo_openebooks_color,
59
- logo_openebooks_negative,
60
- logo_openebooks_wtext_color,
61
- logo_openebooks_wtext_negative,
62
- logo_qpl_alt_black,
63
- logo_qpl_alt_white,
64
- logo_qpl_black,
65
- logo_qpl_color,
66
- logo_qpl_white,
67
- logo_reservoir_icon_color,
68
- logo_reservoir_vertical_color,
69
- logo_schomburg_black,
70
- logo_schomburg_circle_black,
71
- logo_schomburg_circle_color,
72
- logo_schomburg_circle_white,
73
- logo_schomburg_color,
74
- logo_schomburg_white,
75
- logo_simplye_black,
76
- logo_simplye_white,
77
- logo_simplye_color,
78
- logo_snfl_black,
79
- logo_snfl_white,
80
- logo_treasures_color,
81
- logo_treasures_color_negative,
43
+ bplBlack,
44
+ bplWhite,
45
+ cleverColor,
46
+ cleverWhite,
47
+ firstbookColor,
48
+ firstbookColorNegative,
49
+ lpaBlack,
50
+ lpaColor,
51
+ lpaWhite,
52
+ mlnBlack,
53
+ mlnWhite,
54
+ nyplFullBlack,
55
+ nyplFullWhite,
56
+ nyplLionBlack,
57
+ nyplLionWhite,
58
+ openebooksColor,
59
+ openebooksNegative,
60
+ openebooksWithTextColor,
61
+ openebooksWithTextNegative,
62
+ qplAltBlack,
63
+ qplAltWhite,
64
+ qplBlack,
65
+ qplColor,
66
+ qplWhite,
67
+ reservoirIconColor,
68
+ reservoirVerticalColor,
69
+ schomburgBlack,
70
+ schomburgCircleBlack,
71
+ schomburgCircleColor,
72
+ schomburgCircleWhite,
73
+ schomburgColor,
74
+ schomburgWhite,
75
+ simplyeBlack,
76
+ simplyeWhite,
77
+ simplyeColor,
78
+ snflBlack,
79
+ snflWhite,
80
+ treasuresColor,
81
+ treasuresColorNegative,
82
82
  };
@@ -7,7 +7,7 @@ exports[`Logo renders the UI snapshot correctly 1`] = `
7
7
  focusable={false}
8
8
  id="test-logo"
9
9
  role="img"
10
- title="logo_nypl_full_black logo"
10
+ title="nyplFullBlack logo"
11
11
  viewBox="0 0 24 24"
12
12
  >
13
13
  <g
@@ -42,7 +42,7 @@ exports[`Logo renders the UI snapshot correctly 2`] = `
42
42
  focusable={false}
43
43
  id="test-logo-size"
44
44
  role="img"
45
- title="logo_nypl_full_black logo"
45
+ title="nyplFullBlack logo"
46
46
  viewBox="0 0 24 24"
47
47
  >
48
48
  <g
@@ -77,7 +77,7 @@ exports[`Logo renders the UI snapshot correctly 3`] = `
77
77
  focusable={false}
78
78
  id="chakra"
79
79
  role="img"
80
- title="logo_nypl_full_black logo"
80
+ title="nyplFullBlack logo"
81
81
  viewBox="0 0 24 24"
82
82
  >
83
83
  <g
@@ -113,7 +113,7 @@ exports[`Logo renders the UI snapshot correctly 4`] = `
113
113
  focusable={false}
114
114
  id="props"
115
115
  role="img"
116
- title="logo_nypl_full_black logo"
116
+ title="nyplFullBlack logo"
117
117
  viewBox="0 0 24 24"
118
118
  >
119
119
  <g
@@ -1,4 +1,3 @@
1
- import { ButtonGroup } from "@chakra-ui/react";
2
1
  import {
3
2
  ArgsTable,
4
3
  Canvas,
@@ -9,7 +8,7 @@ import {
9
8
  import { useState } from "react";
10
9
 
11
10
  import Button from "../Button/Button";
12
- import { ButtonTypes } from "../Button/ButtonTypes";
11
+ import ButtonGroup from "../ButtonGroup/ButtonGroup";
13
12
  import Heading from "../Heading/Heading";
14
13
  import Link from "../Link/Link";
15
14
  import { ModalTrigger, useModal } from "./Modal";
@@ -61,12 +60,12 @@ import { ModalTrigger } from "@nypl/design-system-react-components";
61
60
  buttonText="Button Text"
62
61
  id="modal-trigger"
63
62
  modalProps={{
64
- bodyContent="body text"
65
- closeButtonLabel="Close Button"
66
- headingText="Modal Heading Text"
67
- onClose={() => {
63
+ bodyContent: "body text",
64
+ closeButtonLabel: "Close Button",
65
+ headingText: "Modal Heading Text",
66
+ onClose: () => {
68
67
  console.log("custom close");
69
- }}
68
+ },
70
69
  }}
71
70
  />;
72
71
  ```
@@ -139,7 +138,7 @@ export const ModalStory = (args) => {
139
138
  <Button id="1" onClick={onOpen}>
140
139
  Open Modal
141
140
  </Button>
142
- <Button buttonType={ButtonTypes.Secondary} id="2" onClick={onOpen}>
141
+ <Button buttonType="secondary" id="2" onClick={onOpen}>
143
142
  I can open the modal, too
144
143
  </Button>
145
144
  </ButtonGroup>
@@ -180,7 +179,7 @@ export const ModalStory = (args) => {
180
179
  <Button id="1" onClick={onOpen}>
181
180
  Open Modal
182
181
  </Button>
183
- <Button buttonType={ButtonTypes.Secondary} id="2" onClick={onOpen}>
182
+ <Button buttonType="secondary" id="2" onClick={onOpen}>
184
183
  I can open the modal, too
185
184
  </Button>
186
185
  </ButtonGroup>
@@ -1,11 +1,10 @@
1
- import * as React from "react";
2
1
  import { render, screen } from "@testing-library/react";
3
2
  import { renderHook } from "@testing-library/react-hooks";
4
3
  import { axe } from "jest-axe";
4
+ import * as React from "react";
5
5
  import renderer from "react-test-renderer";
6
6
 
7
- import { Button } from "../Button/Button";
8
- import { ButtonTypes } from "../Button/ButtonTypes";
7
+ import Button from "../Button/Button";
9
8
  import { ModalTrigger, useModal } from "./Modal";
10
9
 
11
10
  describe("Modal Accessibility", () => {
@@ -37,11 +36,7 @@ describe("Modal Accessibility", () => {
37
36
  Go back
38
37
  </Button>
39
38
  <p>This is the body content.</p>
40
- <Button
41
- buttonType={ButtonTypes.NoBrand}
42
- id="custom-close2"
43
- onClick={onClose}
44
- >
39
+ <Button buttonType="noBrand" id="custom-close2" onClick={onClose}>
45
40
  This is a custom close button.
46
41
  </Button>
47
42
  </>
@@ -55,7 +50,7 @@ describe("Modal Accessibility", () => {
55
50
  };
56
51
  const { container } = render(
57
52
  <>
58
- <Button id="1" onClick={onOpen} buttonType={ButtonTypes.NoBrand}>
53
+ <Button id="1" onClick={onOpen} buttonType="noBrand">
59
54
  Open Modal
60
55
  </Button>
61
56
  <Modal {...modalProps} />
@@ -128,7 +123,7 @@ describe("useModal", () => {
128
123
  };
129
124
  const useModalComponent = (
130
125
  <>
131
- <Button id="1" onClick={onOpen} buttonType={ButtonTypes.NoBrand}>
126
+ <Button id="1" onClick={onOpen} buttonType="noBrand">
132
127
  Open Modal
133
128
  </Button>
134
129
  <Modal {...modalProps} />
@@ -8,11 +8,11 @@ import {
8
8
  ModalBody,
9
9
  ModalCloseButton,
10
10
  useDisclosure,
11
- ButtonGroup,
12
11
  } from "@chakra-ui/react";
13
12
  import * as React from "react";
14
13
 
15
14
  import Button from "../Button/Button";
15
+ import ButtonGroup from "../ButtonGroup/ButtonGroup";
16
16
  import useWindowSize from "../../hooks/useWindowSize";
17
17
 
18
18
  interface BaseModalProps {
@@ -8,18 +8,10 @@ import {
8
8
  import { withDesign } from "storybook-addon-designs";
9
9
 
10
10
  import Icon from "../Icons/Icon";
11
- import { IconColors, IconNames } from "../Icons/IconTypes";
12
11
  import Link from "../Link/Link";
13
12
  import Notification from "./Notification";
14
- import { NotificationTypes } from "./NotificationTypes";
15
13
  import { getCategory } from "../../utils/componentCategories";
16
14
  import DSProvider from "../../theme/provider";
17
- import { getStorybookEnumValues } from "../../utils/utils";
18
-
19
- export const enumValues = getStorybookEnumValues(
20
- NotificationTypes,
21
- "NotificationTypes"
22
- );
23
15
 
24
16
  <Meta
25
17
  title={getCategory("Notification")}
@@ -47,9 +39,7 @@ export const enumValues = getStorybookEnumValues(
47
39
  },
48
40
  notificationContent: { control: false },
49
41
  notificationType: {
50
- control: { type: "select" },
51
- table: { defaultValue: { summary: "NotificationTypes.Standard" } },
52
- options: enumValues.options,
42
+ table: { defaultValue: { summary: "standard" } },
53
43
  },
54
44
  }}
55
45
  />
@@ -59,7 +49,7 @@ export const enumValues = getStorybookEnumValues(
59
49
  | Component Version | DS Version |
60
50
  | ----------------- | ---------- |
61
51
  | Added | `0.23.2` |
62
- | Latest | `0.26.0` |
52
+ | Latest | `0.28.0` |
63
53
 
64
54
  ## Table of Contents
65
55
 
@@ -105,16 +95,13 @@ within a parent element.
105
95
  nisi erat porttitor ligula.
106
96
  </>
107
97
  ),
108
- notificationType: "NotificationTypes.Standard",
98
+ notificationType: "standard",
109
99
  showIcon: true,
110
100
  }}
111
101
  >
112
102
  {(args) => (
113
103
  <div style={{ border: "1px solid #ccc" }}>
114
- <Notification
115
- {...args}
116
- notificationType={enumValues.getValue(args.notificationType)}
117
- />
104
+ <Notification {...args} />
118
105
  </div>
119
106
  )}
120
107
  </Story>
@@ -172,7 +159,7 @@ Resources:
172
159
  <Canvas>
173
160
  <DSProvider>
174
161
  <Notification
175
- notificationType={NotificationTypes.Announcement}
162
+ notificationType="announcement"
176
163
  notificationHeading="Announcement Notification"
177
164
  notificationContent={
178
165
  <>
@@ -191,7 +178,7 @@ Resources:
191
178
  <Canvas>
192
179
  <DSProvider>
193
180
  <Notification
194
- notificationType={NotificationTypes.Warning}
181
+ notificationType="warning"
195
182
  notificationHeading="Warning Notification"
196
183
  notificationContent={
197
184
  <>
@@ -229,7 +216,7 @@ Resources:
229
216
  <Canvas>
230
217
  <DSProvider>
231
218
  <Notification
232
- notificationType={NotificationTypes.Announcement}
219
+ notificationType="announcement"
233
220
  notificationContent={
234
221
  <>
235
222
  This is an "announcement" Notification without a heading. Cras mattis
@@ -247,7 +234,7 @@ Resources:
247
234
  <Canvas>
248
235
  <DSProvider>
249
236
  <Notification
250
- notificationType={NotificationTypes.Warning}
237
+ notificationType="warning"
251
238
  notificationContent={
252
239
  <>
253
240
  This is a "warning" Notification without a heading. Cras mattis
@@ -330,12 +317,7 @@ The default icon can be overridden by using the `icon` prop to pass a custom `Ic
330
317
  <Canvas>
331
318
  <Story name="Custom Icons">
332
319
  <Notification
333
- icon={
334
- <Icon
335
- name={IconNames.Check}
336
- color={IconColors.SectionResearchSecondary}
337
- />
338
- }
320
+ icon={<Icon name="check" color="section.research.secondary" />}
339
321
  notificationHeading="Custom Icon"
340
322
  notificationContent={
341
323
  <>
@@ -370,7 +352,7 @@ appears once.
370
352
  nascetur ridiculus mus.
371
353
  </>
372
354
  }
373
- notificationType={NotificationTypes.Announcement}
355
+ notificationType="announcement"
374
356
  />
375
357
  </Story>
376
358
  </Canvas>
@@ -1,12 +1,10 @@
1
1
  import * as React from "react";
2
- import { render, screen } from "@testing-library/react";
2
+ import { render, RenderResult, screen } from "@testing-library/react";
3
3
  import { axe } from "jest-axe";
4
4
  import renderer from "react-test-renderer";
5
5
 
6
6
  import Notification from "./Notification";
7
- import { NotificationTypes } from "./NotificationTypes";
8
7
  import Icon from "../Icons/Icon";
9
- import { IconNames, IconColors, IconSizes } from "../Icons/IconTypes";
10
8
 
11
9
  describe("Notification Accessibility", () => {
12
10
  it("passes axe accessibility test with heading", async () => {
@@ -56,7 +54,7 @@ describe("Notification Accessibility", () => {
56
54
  });
57
55
 
58
56
  describe("Notification", () => {
59
- let utils;
57
+ let utils: RenderResult;
60
58
  beforeEach(() => {
61
59
  utils = render(
62
60
  <Notification
@@ -107,9 +105,9 @@ describe("Notification", () => {
107
105
  <Icon
108
106
  id="custom-icon"
109
107
  className="custom-icon"
110
- color={IconColors.BrandPrimary}
111
- name={IconNames.Check}
112
- size={IconSizes.Large}
108
+ color="brand.primary"
109
+ name="check"
110
+ size="large"
113
111
  />
114
112
  }
115
113
  id="notificationID"
@@ -130,7 +128,7 @@ describe("Notification", () => {
130
128
  id="notificationID"
131
129
  notificationContent={<>Notification content.</>}
132
130
  notificationHeading="Notification Heading"
133
- notificationType={NotificationTypes.Announcement}
131
+ notificationType="announcement"
134
132
  />
135
133
  );
136
134
 
@@ -146,7 +144,7 @@ describe("Notification", () => {
146
144
  id="notificationID"
147
145
  notificationContent={<>Notification content.</>}
148
146
  notificationHeading="Notification Heading"
149
- notificationType={NotificationTypes.Warning}
147
+ notificationType="warning"
150
148
  />
151
149
  );
152
150
 
@@ -170,7 +168,6 @@ describe("Notification", () => {
170
168
  id="notificationID"
171
169
  notificationContent={<>Notification content.</>}
172
170
  notificationHeading="Notification Heading"
173
- notificationType={NotificationTypes.Standard}
174
171
  />
175
172
  );
176
173
 
@@ -197,7 +194,7 @@ describe("Notification", () => {
197
194
  id="notificationID2"
198
195
  notificationContent={<>Notification content.</>}
199
196
  notificationHeading="Notification Heading"
200
- notificationType={NotificationTypes.Announcement}
197
+ notificationType="announcement"
201
198
  />
202
199
  )
203
200
  .toJSON();
@@ -207,7 +204,7 @@ describe("Notification", () => {
207
204
  id="notificationID3"
208
205
  notificationContent={<>Notification content.</>}
209
206
  notificationHeading="Notification Heading"
210
- notificationType={NotificationTypes.Warning}
207
+ notificationType="warning"
211
208
  />
212
209
  )
213
210
  .toJSON();
@@ -2,12 +2,10 @@ import { Box, chakra, useMultiStyleConfig } from "@chakra-ui/react";
2
2
  import React, { useState } from "react";
3
3
 
4
4
  import Button from "../Button/Button";
5
- import { ButtonTypes } from "../Button/ButtonTypes";
6
5
  import Heading from "../Heading/Heading";
7
- import { HeadingLevels } from "../Heading/HeadingTypes";
8
- import Icon from "../Icons/Icon";
9
- import { IconColors, IconNames, IconSizes } from "../Icons/IconTypes";
10
- import { NotificationTypes } from "./NotificationTypes";
6
+ import Icon, { IconColors, IconNames, IconSizes } from "../Icons/Icon";
7
+
8
+ export type NotificationTypes = "standard" | "announcement" | "warning";
11
9
  interface BaseProps {
12
10
  /** Optional prop to control text alignment in `NotificationContent` */
13
11
  alignText?: boolean;
@@ -61,11 +59,7 @@ export const NotificationHeading = chakra(
61
59
  return (
62
60
  <Box as="header" __css={styles} {...rest}>
63
61
  {icon}
64
- <Heading
65
- additionalStyles={styles.heading}
66
- id={`${id}-heading`}
67
- level={HeadingLevels.Four}
68
- >
62
+ <Heading id={`${id}-heading`} level="four" __css={styles.heading}>
69
63
  {children}
70
64
  </Heading>
71
65
  </Box>
@@ -108,7 +102,7 @@ export const Notification = chakra((props: NotificationProps) => {
108
102
  noMargin = false,
109
103
  notificationContent,
110
104
  notificationHeading,
111
- notificationType = NotificationTypes.Standard,
105
+ notificationType = "standard",
112
106
  showIcon = true,
113
107
  ...rest
114
108
  } = props;
@@ -122,12 +116,12 @@ export const Notification = chakra((props: NotificationProps) => {
122
116
  });
123
117
  const iconElement = () => {
124
118
  const baseIconProps = {
125
- additionalStyles: styles.icon,
126
- size: IconSizes.Large,
119
+ size: "large" as IconSizes,
120
+ __css: styles.icon,
127
121
  };
128
- // If the icon should not display, return null.
122
+ // If the icon should not display, return undefined.
129
123
  if (!showIcon) {
130
- return null;
124
+ return undefined;
131
125
  }
132
126
  // If a custom icon is passed, add specific `Notification` styles.
133
127
  if (icon)
@@ -135,45 +129,48 @@ export const Notification = chakra((props: NotificationProps) => {
135
129
  id: `${id}-custom-notification-icon`,
136
130
  ...baseIconProps,
137
131
  });
132
+ interface IconProps {
133
+ color: IconColors;
134
+ name: IconNames;
135
+ title: string;
136
+ }
138
137
  const iconProps = {
139
- [NotificationTypes.Announcement]: {
140
- color: IconColors.SectionResearchSecondary,
141
- name: IconNames.SpeakerNotes,
138
+ announcement: {
139
+ color: "section.research.secondary",
140
+ name: "speakerNotes",
142
141
  title: "Notification announcement icon",
143
- },
144
- [NotificationTypes.Standard]: {
145
- color: IconColors.UiBlack,
146
- name: IconNames.AlertNotificationImportant,
142
+ } as IconProps,
143
+ standard: {
144
+ color: "ui.black",
145
+ name: "alertNotificationImportant",
147
146
  title: "Notification standard icon",
148
- },
149
- [NotificationTypes.Warning]: {
150
- color: IconColors.BrandPrimary,
151
- name: IconNames.ErrorFilled,
147
+ } as IconProps,
148
+ warning: {
149
+ color: "brand.primary",
150
+ name: "errorFilled",
152
151
  title: "Notification warning icon",
153
- },
152
+ } as IconProps,
154
153
  };
155
154
  return (
156
155
  <Icon
157
156
  id={`${id}-notification-icon`}
158
- {...baseIconProps}
159
157
  {...iconProps[notificationType]}
158
+ {...baseIconProps}
160
159
  />
161
160
  );
162
161
  };
163
162
  const dismissibleButton = dismissible && (
164
163
  <Button
165
- additionalStyles={styles.dismissibleButton}
166
- attributes={{
167
- "aria-label": "Close the notification",
168
- }}
169
- buttonType={ButtonTypes.Link}
164
+ aria-label="Close the notification"
165
+ buttonType="link"
170
166
  id={`${id}-notification-dismissible-button`}
171
167
  onClick={handleClose}
168
+ __css={styles.dismissibleButton}
172
169
  >
173
170
  <Icon
174
171
  id={`${id}-dismissible-notification-icon`}
175
- name={IconNames.Close}
176
- size={IconSizes.Large}
172
+ name="close"
173
+ size="large"
177
174
  title="Notification close icon"
178
175
  />
179
176
  </Button>
@@ -190,11 +187,11 @@ export const Notification = chakra((props: NotificationProps) => {
190
187
  </NotificationHeading>
191
188
  );
192
189
  // Specific alignment styles for the content.
193
- const alignText = childHeading && showIcon && (!!icon || !isCentered);
190
+ const alignText = !!(childHeading && showIcon && (!!icon || !isCentered));
194
191
  const childContent = (
195
192
  <NotificationContent
196
193
  alignText={alignText}
197
- icon={!childHeading ? iconElem : null}
194
+ icon={!childHeading ? iconElem : undefined}
198
195
  notificationType={notificationType}
199
196
  >
200
197
  {notificationContent}
@@ -43,7 +43,7 @@ export const hrefProps = getStorybookHrefProps(10);
43
43
  | Component Version | DS Version |
44
44
  | ----------------- | ---------- |
45
45
  | Added | `0.0.10` |
46
- | Latest | `0.26.0` |
46
+ | Latest | `0.28.0` |
47
47
 
48
48
  ## Table of Contents
49
49
 
@@ -170,7 +170,7 @@ export function CurrentPagePaginationExample() {
170
170
  currentPage={page}
171
171
  onPageChange={(selectedPage) => handleSelection(selectedPage)}
172
172
  />
173
- <Button type="button" buttonType="primary" onClick={handleClick}>
173
+ <Button type="button" onClick={handleClick}>
174
174
  Go to Page 1
175
175
  </Button>
176
176
  </VStack>