@pingux/astro 2.9.1 → 2.13.0-alpha.3

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 (318) hide show
  1. package/README.md +6 -2
  2. package/lib/README.md +6 -2
  3. package/lib/cjs/components/AccordionGridGroup/AccordionGridGroup.mdx +40 -0
  4. package/lib/cjs/components/AccordionGroup/Accordion.styles.js +1 -2
  5. package/lib/cjs/components/AccordionGroup/AccordionGroup.mdx +41 -0
  6. package/lib/cjs/components/ArrayField/ArrayField.mdx +34 -0
  7. package/lib/cjs/components/AstroWrapper/AstroWrapper.mdx +16 -0
  8. package/lib/cjs/components/Avatar/Avatar.mdx +14 -0
  9. package/lib/cjs/components/Badge/Badge.mdx +24 -0
  10. package/lib/cjs/components/Box/Box.d.ts +4 -0
  11. package/lib/cjs/components/Box/Box.js +4 -19
  12. package/lib/cjs/components/Box/Box.mdx +23 -0
  13. package/lib/cjs/components/Box/Box.styles.d.ts +6 -0
  14. package/lib/cjs/components/Box/Box.test.d.ts +1 -0
  15. package/lib/cjs/components/Box/Box.test.js +2 -6
  16. package/lib/cjs/components/Box/index.d.ts +1 -0
  17. package/lib/cjs/components/Bracket/Bracket.mdx +17 -0
  18. package/lib/cjs/components/Breadcrumbs/Breadcrumbs.mdx +40 -0
  19. package/lib/cjs/components/Button/Button.mdx +40 -0
  20. package/lib/cjs/components/Button/Button.stories.js +30 -5
  21. package/lib/cjs/components/Button/Buttons.styles.js +25 -7
  22. package/lib/cjs/components/Calendar/Calendar.mdx +39 -0
  23. package/lib/cjs/components/Callout/Callout.mdx +28 -0
  24. package/lib/cjs/components/Card/Card.mdx +32 -0
  25. package/lib/cjs/components/CheckboxField/CheckboxField.mdx +42 -0
  26. package/lib/cjs/components/CodeView/CodeView.mdx +23 -0
  27. package/lib/cjs/components/CollapsiblePanel/CollapsiblePanel.mdx +29 -0
  28. package/lib/cjs/components/ColorField/ColorField.mdx +38 -0
  29. package/lib/cjs/components/ComboBoxField/ComboBoxField.mdx +66 -0
  30. package/lib/cjs/components/CopyText/CopyText.mdx +23 -0
  31. package/lib/cjs/components/DataTable/DataTable.mdx +54 -0
  32. package/lib/cjs/components/DatePicker/DatePicker.mdx +49 -0
  33. package/lib/cjs/components/EnvironmentBreadcrumb/EnvironmentBreadcrumb.js +2 -1
  34. package/lib/cjs/components/EnvironmentBreadcrumb/EnvironmentBreadcrumb.mdx +36 -0
  35. package/lib/cjs/components/EnvironmentBreadcrumb/EnvironmentBreadcrumb.stories.js +29 -45
  36. package/lib/cjs/components/FileInputField/FileInputField.mdx +33 -0
  37. package/lib/cjs/components/HelpHint/HelpHint.mdx +32 -0
  38. package/lib/cjs/components/Icon/Icon.d.ts +4 -0
  39. package/lib/cjs/components/Icon/Icon.js +4 -27
  40. package/lib/cjs/components/Icon/Icon.mdx +49 -0
  41. package/lib/cjs/components/Icon/Icon.stories.d.ts +8 -0
  42. package/lib/cjs/components/Icon/Icon.test.d.ts +1 -0
  43. package/lib/cjs/components/Icon/index.d.ts +1 -0
  44. package/lib/cjs/components/IconBadge/IconBadge.mdx +14 -0
  45. package/lib/cjs/components/IconButton/IconButton.mdx +33 -0
  46. package/lib/cjs/components/IconButtonToggle/IconButtonToggle.mdx +31 -0
  47. package/lib/cjs/components/Image/Image.mdx +28 -0
  48. package/lib/cjs/components/ImageUploadField/ImageUploadField.mdx +38 -0
  49. package/lib/cjs/components/Link/Link.mdx +27 -0
  50. package/lib/cjs/components/LinkSelectField/LinkSelectField.mdx +47 -0
  51. package/lib/cjs/components/ListItem/ListItem.mdx +21 -0
  52. package/lib/cjs/components/ListView/ListView.mdx +44 -0
  53. package/lib/cjs/components/ListView/ListView.stories.js +93 -47
  54. package/lib/cjs/components/Loader/Loader.d.ts +4 -0
  55. package/lib/cjs/components/Loader/Loader.js +0 -14
  56. package/lib/cjs/components/Loader/Loader.mdx +29 -0
  57. package/lib/cjs/components/Loader/Loader.styles.d.ts +53 -0
  58. package/lib/cjs/components/Loader/Loader.test.d.ts +1 -0
  59. package/lib/cjs/components/Loader/index.d.ts +1 -0
  60. package/lib/cjs/components/Menu/Menu.mdx +43 -0
  61. package/lib/cjs/components/Messages/Messages.mdx +35 -0
  62. package/lib/cjs/components/Modal/Modal.mdx +59 -0
  63. package/lib/cjs/components/MultivaluesField/MultivaluesField.mdx +44 -0
  64. package/lib/cjs/components/NavBar/NavBar.mdx +42 -0
  65. package/lib/cjs/components/NumberField/NumberField.mdx +39 -0
  66. package/lib/cjs/components/OverlayPanel/OverlayPanel.mdx +39 -0
  67. package/lib/cjs/components/PasswordField/PasswordField.mdx +33 -0
  68. package/lib/cjs/components/PopoverContainer/PopoverContainer.d.ts +9 -0
  69. package/lib/cjs/components/PopoverContainer/PopoverContainer.js +7 -38
  70. package/lib/cjs/components/PopoverContainer/index.d.ts +2 -0
  71. package/lib/cjs/components/PopoverMenu/PopoverMenu.mdx +53 -0
  72. package/lib/cjs/components/RadioGroupField/RadioGroupField.mdx +41 -0
  73. package/lib/cjs/components/RequirementsList/RequirementsList.mdx +17 -0
  74. package/lib/cjs/components/RockerButtonGroup/RockerButtonGroup.mdx +36 -0
  75. package/lib/cjs/components/ScrollBox/ScrollBox.mdx +17 -0
  76. package/lib/cjs/components/SearchField/SearchField.mdx +33 -0
  77. package/lib/cjs/components/SelectField/SelectField.mdx +46 -0
  78. package/lib/cjs/components/Separator/Separator.mdx +19 -0
  79. package/lib/cjs/components/Stepper/Stepper.mdx +41 -0
  80. package/lib/cjs/components/SwitchField/SwitchField.mdx +36 -0
  81. package/lib/cjs/components/Table/Table.mdx +30 -0
  82. package/lib/cjs/components/TableCell/TableCell.d.ts +12 -0
  83. package/lib/cjs/components/TableCell/TableCell.js +0 -5
  84. package/lib/cjs/components/TableCell/TableCell.test.d.ts +1 -0
  85. package/lib/cjs/components/TableCell/index.d.ts +1 -0
  86. package/lib/cjs/components/Tabs/Tabs.mdx +40 -0
  87. package/lib/cjs/components/Text/Text.d.ts +4 -0
  88. package/lib/cjs/components/Text/Text.js +3 -7
  89. package/lib/cjs/components/Text/Text.mdx +13 -0
  90. package/lib/cjs/components/Text/Text.stories.d.ts +6 -0
  91. package/lib/cjs/components/Text/Text.styles.d.ts +286 -0
  92. package/lib/cjs/components/Text/Text.test.d.ts +1 -0
  93. package/lib/cjs/components/Text/index.d.ts +1 -0
  94. package/lib/cjs/components/TextAreaField/TextAreaField.mdx +34 -0
  95. package/lib/cjs/components/TextField/TextField.mdx +34 -0
  96. package/lib/cjs/components/TimeZonePicker/TimeZonePicker.mdx +18 -0
  97. package/lib/cjs/components/TooltipTrigger/TooltipTrigger.mdx +21 -0
  98. package/lib/cjs/docs/Props.stories.mdx +35 -0
  99. package/lib/cjs/docs/Welcome.stories.mdx +149 -0
  100. package/lib/cjs/docs/hooks/useDebounce.stories.mdx +59 -0
  101. package/lib/cjs/docs/hooks/useModalState.stories.mdx +83 -0
  102. package/lib/cjs/docs/hooks/useOverlayPanelState.stories.mdx +84 -0
  103. package/lib/cjs/docs/theme/AstroNanoTheme.stories.mdx +174 -0
  104. package/lib/cjs/docs/theme/AstroTheme.stories.mdx +20 -0
  105. package/lib/cjs/docs/theme/CustomThemes.stories.mdx +70 -0
  106. package/lib/cjs/docs/theme/StylingGuideline.stories.mdx +116 -0
  107. package/lib/cjs/docs/utils/messagesReducer.stories.mdx +64 -0
  108. package/lib/cjs/experimental/EditButton/EditButton.js +63 -0
  109. package/lib/cjs/experimental/EditButton/EditButton.mdx +9 -0
  110. package/lib/cjs/experimental/EditButton/EditButton.stories.js +91 -0
  111. package/lib/cjs/experimental/EditButton/EditButton.test.js +71 -0
  112. package/lib/cjs/experimental/EditButton/index.js +14 -0
  113. package/lib/cjs/experimental/ListView/ListView.mdx +47 -0
  114. package/lib/cjs/experimental/ListView/ListView.stories.js +742 -0
  115. package/lib/cjs/experimental/ListViewItem/ListViewItem.js +23 -5
  116. package/lib/cjs/experimental/ListViewItem/ListViewItem.mdx +36 -0
  117. package/lib/cjs/experimental/ListViewItem/ListViewItem.stories.js +31 -7
  118. package/lib/cjs/experimental/ListViewItem/ListViewItem.test.js +51 -7
  119. package/lib/cjs/experimental/ListViewItem/controls/ListViewItemEditButton.js +1 -4
  120. package/lib/cjs/experimental/ListViewItem/controls/ListViewItemEditButton.stories.js +4 -1
  121. package/lib/cjs/experimental/ListViewItem/controls/ListViewItemSwitchField.js +1 -0
  122. package/lib/cjs/experimental/ListViewItem/listViewItemAttributes.js +28 -13
  123. package/lib/cjs/experimental/PanelHeader/PanelHeader.js +88 -0
  124. package/lib/cjs/experimental/PanelHeader/PanelHeader.mdx +19 -0
  125. package/lib/cjs/experimental/PanelHeader/PanelHeader.stories.js +71 -0
  126. package/lib/cjs/experimental/PanelHeader/PanelHeader.styles.js +38 -0
  127. package/lib/cjs/experimental/PanelHeader/PanelHeader.test.js +46 -0
  128. package/lib/cjs/experimental/PanelHeader/controls/PanelHeaderCloseButton.js +34 -0
  129. package/lib/cjs/experimental/PanelHeader/controls/PanelHeaderCloseButton.stories.js +31 -0
  130. package/lib/cjs/experimental/PanelHeader/controls/PanelHeaderCloseButton.test.js +25 -0
  131. package/lib/cjs/experimental/PanelHeader/controls/PanelHeaderMenu.js +27 -0
  132. package/lib/cjs/experimental/PanelHeader/controls/PanelHeaderMenu.stories.js +36 -0
  133. package/lib/cjs/experimental/PanelHeader/controls/PanelHeaderMenu.test.js +58 -0
  134. package/lib/cjs/experimental/PanelHeader/controls/PanelHeaderSwitchField.js +27 -0
  135. package/lib/cjs/experimental/PanelHeader/controls/PanelHeaderSwitchField.stories.js +41 -0
  136. package/lib/cjs/experimental/PanelHeader/controls/PanelHeaderSwitchField.test.js +25 -0
  137. package/lib/cjs/experimental/PanelHeader/index.js +14 -0
  138. package/lib/cjs/experimental/README.stories.mdx +7 -0
  139. package/lib/cjs/experimental/SaveBar/SaveBar.mdx +13 -0
  140. package/lib/cjs/experimental/recipes/ListAndPanel.stories.js +1 -1
  141. package/lib/cjs/hooks/usePropWarning/usePropWarning.js +1 -1
  142. package/lib/cjs/hooks/useStatusClasses/useStatusClasses.js +2 -2
  143. package/lib/cjs/hooks/useTShirtSize/useTShirtSize.js +1 -1
  144. package/lib/cjs/index.d.ts +173 -0
  145. package/lib/cjs/index.js +53 -1
  146. package/lib/cjs/recipes/{AttributesAndPingOneMapping.stories.js → AttributeMapping.stories.js} +392 -132
  147. package/lib/cjs/styles/colors.js +1 -1
  148. package/lib/cjs/styles/variants/README.md +98 -0
  149. package/lib/cjs/styles/variants/variants.js +2 -0
  150. package/lib/cjs/types/box.d.ts +10 -0
  151. package/lib/cjs/types/box.js +6 -0
  152. package/lib/cjs/types/icon.d.ts +34 -0
  153. package/lib/cjs/types/icon.js +6 -0
  154. package/lib/cjs/types/index.d.ts +7 -0
  155. package/lib/cjs/types/index.js +86 -0
  156. package/lib/cjs/types/loader.d.ts +14 -0
  157. package/lib/cjs/types/loader.js +6 -0
  158. package/lib/cjs/types/mdx.d.js +1 -0
  159. package/lib/cjs/types/popoverContainer.d.ts +23 -0
  160. package/lib/cjs/types/popoverContainer.js +6 -0
  161. package/lib/cjs/types/shared/dom.d.ts +9 -0
  162. package/lib/cjs/types/shared/dom.js +6 -0
  163. package/lib/cjs/types/shared/index.d.ts +3 -0
  164. package/lib/cjs/types/shared/index.js +42 -0
  165. package/lib/cjs/types/shared/style.d.ts +11 -0
  166. package/lib/cjs/types/shared/style.js +6 -0
  167. package/lib/cjs/types/shared/test.d.ts +3 -0
  168. package/lib/cjs/types/shared/test.js +6 -0
  169. package/lib/cjs/types/shared/utils.d.ts +1 -0
  170. package/lib/cjs/types/shared/utils.js +6 -0
  171. package/lib/cjs/types/tableCell.d.ts +5 -0
  172. package/lib/cjs/types/tableCell.js +6 -0
  173. package/lib/cjs/types/text.d.ts +3 -0
  174. package/lib/cjs/types/text.js +6 -0
  175. package/lib/components/AccordionGridGroup/AccordionGridGroup.mdx +40 -0
  176. package/lib/components/AccordionGroup/Accordion.styles.js +1 -2
  177. package/lib/components/AccordionGroup/AccordionGroup.mdx +41 -0
  178. package/lib/components/ArrayField/ArrayField.mdx +34 -0
  179. package/lib/components/AstroWrapper/AstroWrapper.mdx +16 -0
  180. package/lib/components/Avatar/Avatar.mdx +14 -0
  181. package/lib/components/Badge/Badge.mdx +24 -0
  182. package/lib/components/Box/Box.js +4 -19
  183. package/lib/components/Box/Box.mdx +23 -0
  184. package/lib/components/Box/Box.test.js +2 -6
  185. package/lib/components/Bracket/Bracket.mdx +17 -0
  186. package/lib/components/Breadcrumbs/Breadcrumbs.mdx +40 -0
  187. package/lib/components/Button/Button.mdx +40 -0
  188. package/lib/components/Button/Button.stories.js +30 -5
  189. package/lib/components/Button/Buttons.styles.js +25 -7
  190. package/lib/components/Calendar/Calendar.mdx +39 -0
  191. package/lib/components/Callout/Callout.mdx +28 -0
  192. package/lib/components/Card/Card.mdx +32 -0
  193. package/lib/components/CheckboxField/CheckboxField.mdx +42 -0
  194. package/lib/components/CodeView/CodeView.mdx +23 -0
  195. package/lib/components/CollapsiblePanel/CollapsiblePanel.mdx +29 -0
  196. package/lib/components/ColorField/ColorField.mdx +38 -0
  197. package/lib/components/ComboBoxField/ComboBoxField.mdx +66 -0
  198. package/lib/components/CopyText/CopyText.mdx +23 -0
  199. package/lib/components/DataTable/DataTable.mdx +54 -0
  200. package/lib/components/DatePicker/DatePicker.mdx +49 -0
  201. package/lib/components/EnvironmentBreadcrumb/EnvironmentBreadcrumb.js +2 -1
  202. package/lib/components/EnvironmentBreadcrumb/EnvironmentBreadcrumb.mdx +36 -0
  203. package/lib/components/EnvironmentBreadcrumb/EnvironmentBreadcrumb.stories.js +29 -45
  204. package/lib/components/FileInputField/FileInputField.mdx +33 -0
  205. package/lib/components/HelpHint/HelpHint.mdx +32 -0
  206. package/lib/components/Icon/Icon.js +2 -25
  207. package/lib/components/Icon/Icon.mdx +49 -0
  208. package/lib/components/IconBadge/IconBadge.mdx +14 -0
  209. package/lib/components/IconButton/IconButton.mdx +33 -0
  210. package/lib/components/IconButtonToggle/IconButtonToggle.mdx +31 -0
  211. package/lib/components/Image/Image.mdx +28 -0
  212. package/lib/components/ImageUploadField/ImageUploadField.mdx +38 -0
  213. package/lib/components/Link/Link.mdx +27 -0
  214. package/lib/components/LinkSelectField/LinkSelectField.mdx +47 -0
  215. package/lib/components/ListItem/ListItem.mdx +21 -0
  216. package/lib/components/ListView/ListView.mdx +44 -0
  217. package/lib/components/ListView/ListView.stories.js +94 -48
  218. package/lib/components/Loader/Loader.js +0 -14
  219. package/lib/components/Loader/Loader.mdx +29 -0
  220. package/lib/components/Menu/Menu.mdx +43 -0
  221. package/lib/components/Messages/Messages.mdx +35 -0
  222. package/lib/components/Modal/Modal.mdx +59 -0
  223. package/lib/components/MultivaluesField/MultivaluesField.mdx +44 -0
  224. package/lib/components/NavBar/NavBar.mdx +42 -0
  225. package/lib/components/NumberField/NumberField.mdx +39 -0
  226. package/lib/components/OverlayPanel/OverlayPanel.mdx +39 -0
  227. package/lib/components/PasswordField/PasswordField.mdx +33 -0
  228. package/lib/components/PopoverContainer/PopoverContainer.js +7 -38
  229. package/lib/components/PopoverMenu/PopoverMenu.mdx +53 -0
  230. package/lib/components/RadioGroupField/RadioGroupField.mdx +41 -0
  231. package/lib/components/RequirementsList/RequirementsList.mdx +17 -0
  232. package/lib/components/RockerButtonGroup/RockerButtonGroup.mdx +36 -0
  233. package/lib/components/ScrollBox/ScrollBox.mdx +17 -0
  234. package/lib/components/SearchField/SearchField.mdx +33 -0
  235. package/lib/components/SelectField/SelectField.mdx +46 -0
  236. package/lib/components/Separator/Separator.mdx +19 -0
  237. package/lib/components/Stepper/Stepper.mdx +41 -0
  238. package/lib/components/SwitchField/SwitchField.mdx +36 -0
  239. package/lib/components/Table/Table.mdx +30 -0
  240. package/lib/components/TableCell/TableCell.js +0 -5
  241. package/lib/components/Tabs/Tabs.mdx +40 -0
  242. package/lib/components/Text/Text.js +3 -7
  243. package/lib/components/Text/Text.mdx +13 -0
  244. package/lib/components/TextAreaField/TextAreaField.mdx +34 -0
  245. package/lib/components/TextField/TextField.mdx +34 -0
  246. package/lib/components/TimeZonePicker/TimeZonePicker.mdx +18 -0
  247. package/lib/components/TooltipTrigger/TooltipTrigger.mdx +21 -0
  248. package/lib/docs/Props.stories.mdx +35 -0
  249. package/lib/docs/Welcome.stories.mdx +149 -0
  250. package/lib/docs/hooks/useDebounce.stories.mdx +59 -0
  251. package/lib/docs/hooks/useModalState.stories.mdx +83 -0
  252. package/lib/docs/hooks/useOverlayPanelState.stories.mdx +84 -0
  253. package/lib/docs/theme/AstroNanoTheme.stories.mdx +174 -0
  254. package/lib/docs/theme/AstroTheme.stories.mdx +20 -0
  255. package/lib/docs/theme/CustomThemes.stories.mdx +70 -0
  256. package/lib/docs/theme/StylingGuideline.stories.mdx +116 -0
  257. package/lib/docs/utils/messagesReducer.stories.mdx +64 -0
  258. package/lib/experimental/EditButton/EditButton.js +50 -0
  259. package/lib/experimental/EditButton/EditButton.mdx +9 -0
  260. package/lib/experimental/EditButton/EditButton.stories.js +75 -0
  261. package/lib/experimental/EditButton/EditButton.test.js +68 -0
  262. package/lib/experimental/EditButton/index.js +1 -0
  263. package/lib/experimental/ListView/ListView.mdx +47 -0
  264. package/lib/experimental/ListView/ListView.stories.js +729 -0
  265. package/lib/experimental/ListViewItem/ListViewItem.js +24 -6
  266. package/lib/experimental/ListViewItem/ListViewItem.mdx +36 -0
  267. package/lib/experimental/ListViewItem/ListViewItem.stories.js +28 -5
  268. package/lib/experimental/ListViewItem/ListViewItem.test.js +45 -1
  269. package/lib/experimental/ListViewItem/controls/ListViewItemEditButton.js +1 -4
  270. package/lib/experimental/ListViewItem/controls/ListViewItemEditButton.stories.js +4 -1
  271. package/lib/experimental/ListViewItem/controls/ListViewItemSwitchField.js +1 -0
  272. package/lib/experimental/ListViewItem/listViewItemAttributes.js +25 -12
  273. package/lib/experimental/PanelHeader/PanelHeader.js +75 -0
  274. package/lib/experimental/PanelHeader/PanelHeader.mdx +19 -0
  275. package/lib/experimental/PanelHeader/PanelHeader.stories.js +59 -0
  276. package/lib/experimental/PanelHeader/PanelHeader.styles.js +30 -0
  277. package/lib/experimental/PanelHeader/PanelHeader.test.js +43 -0
  278. package/lib/experimental/PanelHeader/controls/PanelHeaderCloseButton.js +25 -0
  279. package/lib/experimental/PanelHeader/controls/PanelHeaderCloseButton.stories.js +21 -0
  280. package/lib/experimental/PanelHeader/controls/PanelHeaderCloseButton.test.js +22 -0
  281. package/lib/experimental/PanelHeader/controls/PanelHeaderMenu.js +18 -0
  282. package/lib/experimental/PanelHeader/controls/PanelHeaderMenu.stories.js +26 -0
  283. package/lib/experimental/PanelHeader/controls/PanelHeaderMenu.test.js +55 -0
  284. package/lib/experimental/PanelHeader/controls/PanelHeaderSwitchField.js +18 -0
  285. package/lib/experimental/PanelHeader/controls/PanelHeaderSwitchField.stories.js +32 -0
  286. package/lib/experimental/PanelHeader/controls/PanelHeaderSwitchField.test.js +22 -0
  287. package/lib/experimental/PanelHeader/index.js +1 -0
  288. package/lib/experimental/README.stories.mdx +7 -0
  289. package/lib/experimental/SaveBar/SaveBar.mdx +13 -0
  290. package/lib/experimental/recipes/ListAndPanel.stories.js +1 -1
  291. package/lib/hooks/usePropWarning/usePropWarning.js +1 -1
  292. package/lib/hooks/useStatusClasses/useStatusClasses.js +2 -2
  293. package/lib/hooks/useTShirtSize/useTShirtSize.js +1 -1
  294. package/lib/index.js +6 -0
  295. package/lib/recipes/AttributeMapping.stories.js +540 -0
  296. package/lib/styles/colors.js +1 -1
  297. package/lib/styles/variants/README.md +98 -0
  298. package/lib/styles/variants/variants.js +2 -0
  299. package/lib/types/box.js +1 -0
  300. package/lib/types/icon.js +1 -0
  301. package/lib/types/index.js +7 -0
  302. package/lib/types/loader.js +1 -0
  303. package/lib/types/mdx.d.js +0 -0
  304. package/lib/types/popoverContainer.js +1 -0
  305. package/lib/types/shared/dom.js +1 -0
  306. package/lib/types/shared/index.js +3 -0
  307. package/lib/types/shared/style.js +1 -0
  308. package/lib/types/shared/test.js +1 -0
  309. package/lib/types/shared/utils.js +1 -0
  310. package/lib/types/tableCell.js +1 -0
  311. package/lib/types/text.js +1 -0
  312. package/package.json +20 -6
  313. package/CHANGELOG.md +0 -2554
  314. package/NOTICE +0 -2481
  315. package/NOTICE.html +0 -9174
  316. package/lib/cjs/recipes/AttributeMappingReadOnlyField.stories.js +0 -254
  317. package/lib/recipes/AttributeMappingReadOnlyField.stories.js +0 -243
  318. package/lib/recipes/AttributesAndPingOneMapping.stories.js +0 -282
@@ -0,0 +1,38 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/ImageUploadField/ImageUploadField" />
4
+
5
+ # ImageUploadField
6
+
7
+ The ImageUploadField component is a variation of the [FileInputField](./?path=/docs/form-fileinputfield--default) used for uploading images.
8
+
9
+ ### Required components
10
+
11
+ This component requires the OverlayProvider component.
12
+
13
+ ### Accessibility
14
+
15
+ #### Keyboard Navigation
16
+
17
+ These keys provide additional functionality to the component.
18
+
19
+ | Keys | Functions |
20
+ | ---- | --------- |
21
+ | Tab | Focuses the field and follows the page tab sequence. |
22
+ | Space or Enter | When the trigger is focused, the file browser opens. When the menu item is focused, it triggers an action. |
23
+ | Down arrow | After uploading, pressing the Down arrow with a focused trigger opens the popover menu. |
24
+ | Arrow keys | Can be used to move the selection in the popover. |
25
+ | Shift + Tab | Moves focus to the previous focusable component.|
26
+ | Home(Fn + Right Arrow Key) Or Control/Command + Home | Shifts the focus to the first item in the listbox. |
27
+ | End(Fn + Left Arrow Key) Or Control/Command + End | Shifts the focus to the last item in the listbox. |
28
+ | Esc | Pressing the escape key closes the popover menu and adds focus to the trigger. |
29
+
30
+ #### Screen readers
31
+
32
+ This component uses the following attributes to assist screen readers:
33
+
34
+ - The input uses the **`aria-labelledby`** attribute to reference the label.
35
+ - The trigger button uses the **`aria-label`** attribute to provide an accessible name.
36
+ - The **`aria-expanded`** attribute is used to indicate the expansion or collapse of the popover.
37
+ - The **`aria-haspopup`** attribute indicates the type of popup content as a menu. Once expanded, **`aria-controls`** is added to the button pointing to the popover.
38
+ - The menu uses vertical **`aria-orientation`** by default, and each menu item has a “False” **`aria-disabled`** value.
@@ -0,0 +1,27 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/Link/Link" />
4
+
5
+ # Link
6
+
7
+ This basic link component is built on [Link from Theme-UI](https://theme-ui.com/components/link) and [useLink](https://react-spectrum.adobe.com/react-aria/useLink.html) from React Aria.
8
+
9
+ Links should:
10
+ - Have the same font size as surrounding text when used inline.
11
+ - Be considerate of the screen reader. Write descriptive link text and alternate text.
12
+
13
+ Link shouldn’t be used in titles, and preferably used within the body text.
14
+
15
+ ### Required Components
16
+
17
+ This component can be used independently and does not require additional components.
18
+
19
+ ### Accessibility
20
+ This component adheres to [WAI-ARIA Link](https://www.w3.org/WAI/ARIA/apg/patterns/link/) accessibility guidelines.
21
+
22
+ #### Keyboard Navigation
23
+
24
+ | Key | Functions |
25
+ | ---- | ---- |
26
+ | Space or Enter | Selects the link. |
27
+ | Tab | Focuses the link and follows the page tab sequence. |
@@ -0,0 +1,47 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/LinkSelectField/LinkSelectField" />
4
+
5
+ # LinkSelectField
6
+
7
+ The LinkSelectField component collects information from a dropdown menu of options using [useSelect](https://react-spectrum.adobe.com/react-aria/useSelect.html) from React Aria and
8
+ [useSelectState](https://react-spectrum.adobe.com/react-stately/useSelectState.html) from React Stately.
9
+ It does not rely on native browser or mobile implementations.
10
+
11
+ This component should be used to limit the options available to users.
12
+ It should not be used:
13
+ - When there are fewer than 3 options for the user to choose from:
14
+ - Use the [RadioGroupField](./?path=/docs/form-radiogroupfield--default) if users must choose 1 option.
15
+ - Use the [CheckBoxField](./?path=/docs/form-checkboxfield--default) if users can choose more than 1 option.
16
+ - If the exact input value is important to specify, use the [TextField](./?path=/docs/form-textfield--default).
17
+
18
+ ### Required components
19
+
20
+ This component requires the OverlayProvider and Item originating from [react-stately/collections](https://react-spectrum.adobe.com/react-stately/collections.html).
21
+
22
+ ### Accessibility
23
+
24
+ #### Keyboard Navigation
25
+
26
+ These keys provide additional functionality to the component.
27
+
28
+ | Keys | Functions |
29
+ | ---- | --------- |
30
+ | Tab | Focuses the field and follows the page tab sequence. |
31
+ | Space or Enter | When the trigger is focused, the menu opens or closes. When the menu item is focused, it selects the listbox option. |
32
+ | Arrow keys | Can be used to move the selection in the listbox. |
33
+ | Shift + Tab | Moves focus to the previous focusable component.|
34
+ | Home(Fn + Right Arrow Key) Or Control/Command + Home | Shifts the focus to the first item in the listbox. |
35
+ | End(Fn + Left Arrow Key) Or Control/Command + End | Shifts the focus to the last item in the listbox. |
36
+ | Esc | Pressing the escape key closes the popover menu and adds focus to the previously focused component.|
37
+
38
+ #### Screen readers
39
+
40
+ This component uses the following attributes to assist screen readers:
41
+
42
+ - The trigger button uses the **`aria-expanded`** attribute to indicate the expansion or collapse of the popover menu, the **`aria-label`** attribute to provide an accessible name, and the **`aria-labelledby`** attribute to reference the label.
43
+ - The **`aria-haspopup`** attribute indicates the type of popup content as a listbox.
44
+ - A visually hidden DismissButton is added for screen reader users to close the overlay in the absence of a dismiss button.
45
+ - The listbox in the popover uses the **`aria-labelledby`** attribute, which also references the label.
46
+ - Each option uses the **`aria-selected`** attribute to indicate the selection state, **`aria-posinset`** to give the option’s position in the current set of list items, and **`aria-setsize`** to define the current set of options.
47
+ - The **`aria-disabled`** attribute value is “False” for each option, by default.
@@ -0,0 +1,21 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/ListItem/ListItem" />
4
+
5
+ # ListItem
6
+
7
+ ListItems are items that display within the [ListView](./?path=/docs/components-listview--default) component.
8
+ This component accepts most of its styling properties from [Styled System](https://styled-system.com/table/).
9
+
10
+ ### Required Components
11
+
12
+ This component can be used independently and does not require additional components.
13
+
14
+ ### Accessibility
15
+
16
+ #### Keyboard Navigation
17
+
18
+ | Key | Functions |
19
+ | ---- | ---- |
20
+ | Space or Enter | Selects the item. |
21
+ | Tab | Focuses item and follows the page tab sequence. |
@@ -0,0 +1,44 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/ListView/ListView" />
4
+
5
+ # ListView
6
+
7
+ ListViews are used to display a list of items. Users can select, view, or edit items in this list.
8
+ This virtualized component supports asynchronous data in infinitely scrollable lists.
9
+
10
+ This component should:
11
+ - Be used to list items that contain a significant amount of information within them.
12
+ - Be able to access ListItem information.
13
+
14
+ It shouldn’t be used to list items that only have a single piece of information.
15
+
16
+ ### Required Components
17
+
18
+ This component requires [ListItem](./?path=/docs/components-listitem--default).
19
+
20
+ ### Accessibility
21
+
22
+ This component should adhere to the [WAI-ARIA ListBox](https://www.w3.org/WAI/ARIA/apg/patterns/listbox/) accessibility guidelines.
23
+
24
+ #### Keyboard Navigation
25
+
26
+ These keys provide additional functionality to the component.
27
+
28
+ | Key | Functions |
29
+ | ---- | ---- |
30
+ | Space or Enter | Selects the item. |
31
+ | Tab | Focuses item and follows the page tab sequence. |
32
+ | Shift + Tab | Moves focus to the previous focusable component. |
33
+ | Arrow keys | Can be used to move the selection in the menu. |
34
+ | Home(Fn + Right Arrow Key) Or Control/Command + Home | Shifts the focus to the first row. |
35
+ | End(Fn + Left Arrow Key) Or Control/Command + End | Shifts the focus to the last visible row. |
36
+
37
+ #### Screen Readers
38
+
39
+ This component uses the following attributes to assist screen readers:
40
+ - The **`aria-label`** attribute is used to provide an accessible name.
41
+ - The **`aria-rowcount`** and **`aria-columncount`** attributes are used to indicate the total number of rows and columns in the grid structure.
42
+ - The **`aria-multiselectable`** attribute is used to indicate that users can toggle between items in the grid.
43
+ - Each ListViewItem uses the **`aria-rowindex`** attribute, which defines a component's position in the total number of rows.
44
+ - Each item also uses the aria-label, **`aria-colindex`** attributes to indicate the component’s column position and aria-selected to indicate the currently selected state.
@@ -17,16 +17,18 @@ import _sliceInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instan
17
17
  import _includesInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/includes";
18
18
  import React from 'react';
19
19
  import { Item, useAsyncList } from 'react-stately';
20
+ import CreateIcon from '@pingux/mdi-react/CreateIcon';
20
21
  import FormSelectIcon from '@pingux/mdi-react/FormSelectIcon';
22
+ import MoreVertIcon from '@pingux/mdi-react/MoreVertIcon';
21
23
  import { action } from '@storybook/addon-actions';
22
24
  import isChromatic from 'chromatic/isChromatic';
23
25
  import DocsLayout from '../../../.storybook/storybookDocsLayout';
24
- import { Box, ListView, ListViewItem, ListViewItemMenu, ListViewItemSwitchField } from '../../index';
26
+ import { Box, Icon, IconButton, ListView, Text } from '../../index';
25
27
  import loadingStates from '../../utils/devUtils/constants/loadingStates';
26
28
  import ListViewReadme from './ListView.mdx';
27
29
  import { jsx as ___EmotionJSX } from "@emotion/react";
28
30
  export default {
29
- title: 'Experimental/ListView',
31
+ title: 'Components/ListView',
30
32
  component: ListView,
31
33
  parameters: {
32
34
  docs: {
@@ -45,20 +47,19 @@ export default {
45
47
  options: loadingStates
46
48
  }
47
49
  },
48
- disabledKeys: {},
50
+ disabledKeys: {
51
+ defaultValue: ['Snake']
52
+ },
49
53
  items: {
50
54
  control: {
51
55
  type: 'none'
52
56
  }
53
57
  },
54
58
  onSelectionChange: {
55
- control: 'none'
59
+ control: 'none',
60
+ // eslint-disable-next-line no-console
61
+ defaultValue: console.log
56
62
  }
57
- },
58
- args: {
59
- disabledKeys: ['Snake'],
60
- // eslint-disable-next-line no-console
61
- onSelectionChange: console.log
62
63
  }
63
64
  };
64
65
  var items = [{
@@ -532,33 +533,82 @@ var actions = {
532
533
  onFocus: action('onFocus'),
533
534
  onLoadMore: action('onLoadMore')
534
535
  };
535
- var Controls = function Controls() {
536
- return ___EmotionJSX(React.Fragment, null, ___EmotionJSX(ListViewItemSwitchField, null), ___EmotionJSX(ListViewItemMenu, null, ___EmotionJSX(Item, {
537
- key: "enable"
538
- }, "Enable user"), ___EmotionJSX(Item, {
539
- key: "disable"
540
- }, "Disable user"), ___EmotionJSX(Item, {
541
- key: "delete"
542
- }, "Delete user")));
536
+ var ListElement = function ListElement(_ref) {
537
+ var item = _ref.item;
538
+ return ___EmotionJSX(Box, {
539
+ isRow: true
540
+ }, ___EmotionJSX(Box, {
541
+ isRow: true,
542
+ mr: "auto",
543
+ alignSelf: "center"
544
+ }, ___EmotionJSX(Icon, {
545
+ icon: FormSelectIcon,
546
+ mr: "sm",
547
+ color: "accent.40",
548
+ size: "md"
549
+ }), ___EmotionJSX(Text, {
550
+ variant: "itemTitle",
551
+ alignSelf: "center"
552
+ }, item.name)), ___EmotionJSX(Box, {
553
+ isRow: true,
554
+ alignSelf: "center",
555
+ gap: "sm"
556
+ }, ___EmotionJSX(IconButton, {
557
+ "aria-label": "create-icon"
558
+ }, ___EmotionJSX(Icon, {
559
+ icon: CreateIcon,
560
+ size: "sm"
561
+ })), ___EmotionJSX(IconButton, {
562
+ "aria-label": "actions-icon"
563
+ }, ___EmotionJSX(Icon, {
564
+ icon: MoreVertIcon,
565
+ size: "sm"
566
+ }))));
543
567
  };
544
- export var Default = function Default(_ref) {
545
- var args = _extends({}, (_objectDestructuringEmpty(_ref), _ref));
568
+ export var Default = function Default(_ref2) {
569
+ var args = _extends({}, (_objectDestructuringEmpty(_ref2), _ref2));
546
570
  return ___EmotionJSX(ListView, _extends({}, props, args, {
547
571
  items: items
548
572
  }), function (item) {
549
573
  return ___EmotionJSX(Item, {
550
- key: item.name
551
- }, ___EmotionJSX(ListViewItem, {
552
- data: {
553
- text: item.name,
554
- icon: FormSelectIcon
555
- }
556
- }, ___EmotionJSX(Controls, null)));
574
+ key: item.name,
575
+ textValue: item.name,
576
+ "data-id": item.key
577
+ }, ___EmotionJSX(Box, {
578
+ isRow: true
579
+ }, ___EmotionJSX(Box, {
580
+ isRow: true,
581
+ mr: "auto",
582
+ alignSelf: "center"
583
+ }, ___EmotionJSX(Icon, {
584
+ icon: FormSelectIcon,
585
+ mr: "sm",
586
+ color: "accent.40",
587
+ size: "md"
588
+ }), ___EmotionJSX(Text, {
589
+ variant: "itemTitle",
590
+ alignSelf: "center"
591
+ }, item.name)), ___EmotionJSX(Box, {
592
+ isRow: true,
593
+ alignSelf: "center",
594
+ gap: "sm"
595
+ }, ___EmotionJSX(IconButton, {
596
+ "aria-label": "create-icon"
597
+ }, ___EmotionJSX(Icon, {
598
+ icon: CreateIcon,
599
+ size: "sm"
600
+ })), ___EmotionJSX(IconButton, {
601
+ "aria-label": "actions-icon",
602
+ size: "sm"
603
+ }, ___EmotionJSX(Icon, {
604
+ icon: MoreVertIcon,
605
+ size: "sm"
606
+ })))));
557
607
  });
558
608
  };
559
609
  export var InfiniteLoadingList = function InfiniteLoadingList(args) {
560
610
  var getMockData = /*#__PURE__*/function () {
561
- var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(signal, cursor) {
611
+ var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(signal, cursor) {
562
612
  var pageNumber;
563
613
  return _regeneratorRuntime().wrap(function _callee$(_context) {
564
614
  while (1) {
@@ -590,11 +640,11 @@ export var InfiniteLoadingList = function InfiniteLoadingList(args) {
590
640
  }, _callee);
591
641
  }));
592
642
  return function getMockData(_x, _x2) {
593
- return _ref2.apply(this, arguments);
643
+ return _ref3.apply(this, arguments);
594
644
  };
595
645
  }();
596
646
  var fetchApiData = /*#__PURE__*/function () {
597
- var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(signal, cursor, filterText) {
647
+ var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(signal, cursor, filterText) {
598
648
  var res, json;
599
649
  return _regeneratorRuntime().wrap(function _callee2$(_context2) {
600
650
  while (1) {
@@ -648,18 +698,18 @@ export var InfiniteLoadingList = function InfiniteLoadingList(args) {
648
698
  }, _callee2, null, [[2, 14]]);
649
699
  }));
650
700
  return function fetchApiData(_x3, _x4, _x5) {
651
- return _ref3.apply(this, arguments);
701
+ return _ref4.apply(this, arguments);
652
702
  };
653
703
  }();
654
704
  var list = useAsyncList({
655
- load: function load(_ref4) {
705
+ load: function load(_ref5) {
656
706
  return _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
657
707
  var signal, cursor, filterText;
658
708
  return _regeneratorRuntime().wrap(function _callee3$(_context3) {
659
709
  while (1) {
660
710
  switch (_context3.prev = _context3.next) {
661
711
  case 0:
662
- signal = _ref4.signal, cursor = _ref4.cursor, filterText = _ref4.filterText;
712
+ signal = _ref5.signal, cursor = _ref5.cursor, filterText = _ref5.filterText;
663
713
  if (cursor) {
664
714
  // eslint-disable-next-line
665
715
  cursor = cursor.replace(/^http:\/\//i, "https://");
@@ -692,13 +742,11 @@ export var InfiniteLoadingList = function InfiniteLoadingList(args) {
692
742
  onLoadMore: list.loadMore
693
743
  }), function (item) {
694
744
  return ___EmotionJSX(Item, {
695
- key: item.name
696
- }, ___EmotionJSX(ListViewItem, {
697
- data: {
698
- text: item.name,
699
- icon: FormSelectIcon
700
- }
701
- }, ___EmotionJSX(Controls, null)));
745
+ key: item.name,
746
+ textValue: item.name
747
+ }, ___EmotionJSX(ListElement, {
748
+ item: item
749
+ }));
702
750
  }));
703
751
  };
704
752
  InfiniteLoadingList.args = {
@@ -711,19 +759,17 @@ InfiniteLoadingList.parameters = {
711
759
  }
712
760
  }
713
761
  };
714
- export var MultipleSelection = function MultipleSelection(_ref5) {
715
- var args = _extends({}, (_objectDestructuringEmpty(_ref5), _ref5));
762
+ export var MultipleSelection = function MultipleSelection(_ref6) {
763
+ var args = _extends({}, (_objectDestructuringEmpty(_ref6), _ref6));
716
764
  return ___EmotionJSX(ListView, _extends({}, props, args, {
717
765
  items: items,
718
766
  selectionMode: "multiple"
719
767
  }), function (item) {
720
768
  return ___EmotionJSX(Item, {
721
- key: item.name
722
- }, ___EmotionJSX(ListViewItem, {
723
- data: {
724
- text: item.name,
725
- icon: FormSelectIcon
726
- }
727
- }, ___EmotionJSX(Controls, null)));
769
+ key: item.name,
770
+ textValue: item.name
771
+ }, ___EmotionJSX(ListElement, {
772
+ item: item
773
+ }));
728
774
  });
729
775
  };
@@ -2,7 +2,6 @@ import _extends from "@babel/runtime-corejs3/helpers/esm/extends";
2
2
  import _objectWithoutProperties from "@babel/runtime-corejs3/helpers/esm/objectWithoutProperties";
3
3
  var _excluded = ["size"];
4
4
  import React, { forwardRef } from 'react';
5
- import PropTypes from 'prop-types';
6
5
  import Box from '../Box';
7
6
  import { jsx as ___EmotionJSX } from "@emotion/react";
8
7
  var Loader = /*#__PURE__*/forwardRef(function (props, ref) {
@@ -24,17 +23,4 @@ var Loader = /*#__PURE__*/forwardRef(function (props, ref) {
24
23
  variant: "loader.dotRight"
25
24
  }));
26
25
  });
27
- Loader.propTypes = {
28
- /**
29
- * Color key from theme or string value.
30
- * Default color inherits the font color.
31
- */
32
- color: PropTypes.string,
33
- /**
34
- * Size as number or pixel / em / rem value.
35
- * Sizes can either be a string such as xs, sm, md, etc or numeric size with unit such as 15px.
36
- * Default size inherits the font size.
37
- */
38
- size: PropTypes.oneOfType([PropTypes.number, PropTypes.string])
39
- };
40
26
  export default Loader;
@@ -0,0 +1,29 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/Loader/Loader" />
4
+
5
+ # Loader
6
+
7
+ The Loader component provides users information about the loading or computing processes that are occurring.
8
+
9
+ This component should be:
10
+ - Used to show an indeterminate state.
11
+ - Restricted to a single use per view to avoid unnecessary disruption.
12
+
13
+ It should not be used:
14
+ - When the wait time for a process is known.
15
+ - When trying to communicate progression in steps.
16
+
17
+ The Loader component is based on the [useProgressBar](https://react-spectrum.adobe.com/react-aria/useProgressBar.html) React Aria component.
18
+
19
+ ### Required Components
20
+
21
+ This component can be used independently and does not require additional components.
22
+
23
+ ### Accessibility
24
+
25
+ #### Screen readers
26
+
27
+ This component uses the following attributes to assist screen readers:
28
+ - The **`aria-label`** attribute is used to provide an accessible name.
29
+ - The **`aria-live`** attribute is used to announce content changes in a live region.
@@ -0,0 +1,43 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/Menu/Menu" />
4
+
5
+ # Menu
6
+
7
+ The Menu component is intended to be used as a wrapper for MenuItems. It is based on the [useMenu](https://react-spectrum.adobe.com/react-aria/useMenu.html)
8
+ React Aria component, and is often used in a [PopoverMenu](./?path=/story/components-popovermenu--default).
9
+
10
+ Menus should:
11
+ - Only contain the most relevant categories for a quick scan.
12
+ - Be used to view actions and not content.
13
+
14
+ Menus shouldn’t:
15
+ - Display more than 5 items to easily interpret the scope of actions.
16
+ - Include ellipses (…) in menu item names. An ellipsis indicates that the user action prompt opens a new window.
17
+
18
+ ### Required Components
19
+
20
+ This component requires the Item component, which is exported within Astro, but originates from [react-stately/collections](https://react-spectrum.adobe.com/react-stately/collections.html).
21
+
22
+ ### Accessibility
23
+
24
+ This component should adhere to the [WAI-ARIA Menu](https://www.w3.org/WAI/tutorials/menus/) accessibility guidelines.
25
+
26
+ #### Keyboard Navigation
27
+
28
+ These keys provide additional functionality to the component.
29
+
30
+ | Key | Functions |
31
+ | ---- | ---- |
32
+ | Space or Enter | Selects the menu item. |
33
+ | Tab | Focuses the menu item and follows the page tab sequence. |
34
+ | Shift + Tab | Moves focus to the previous focusable component. |
35
+ | Home(Fn + Right Arrow Key) Or Control/Command + Home| Shifts the focus to the first row. |
36
+ | End(Fn + Left Arrow Key) Or Control/Command + End | Shifts the focus to the last visible row. |
37
+
38
+ #### Screen Readers
39
+
40
+ This component uses the following attributes to assist screen readers:
41
+ - The **`aria-label`** attribute is used to provide an accessible name.
42
+ - Each menu option has the default **`aria-disabled`** value as “False.”
43
+ - The **`aria-orientation`** attribute indicates whether the menu is horizontally or vertically oriented, or undefined.
@@ -0,0 +1,35 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/Messages/Messages" />
4
+
5
+ # Messages
6
+
7
+ Use this component to display warning or alert messages, which often highlight an imminent problem or confirm a risky action.
8
+
9
+ These messages should:
10
+ - Capture the user’s attention at the right time.
11
+ - Clearly explain the reason for the warning or alert and the actions the user needs to take.
12
+ - Explain what will happen if they don’t act, using the appropriate sense of urgency.
13
+ - Be short. Limit the number of alerts to one per component.
14
+
15
+ See our [Warning and alert messages writing guidelines](https://pingidentity.atlassian.net/wiki/spaces/CCC/pages/21137295/Warning+and+alert+messages) for additional information.
16
+
17
+ ### Required Components
18
+
19
+ This component requires the Item component, which is exported within Astro, but originates from [react-stately/collections](https://react-spectrum.adobe.com/react-stately/collections.html).
20
+
21
+ ### Accessibility
22
+
23
+ #### Keyboard Navigation
24
+
25
+ These keys provide additional functionality to the component.
26
+
27
+ | Key | Functions |
28
+ | ---- | ---- |
29
+ | Tab | Focuses the IconButton within the message and follows the page tab sequence. |
30
+ | Space or Enter | Selects the button when it is focused. |
31
+ | Shift + Tab | Moves focus to the previous focusable component. |
32
+
33
+ #### Screen Readers
34
+
35
+ The **`aria-live`** attribute is used to announce content changes in a live region.
@@ -0,0 +1,59 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/Modal/Modal" />
4
+
5
+ # Modal
6
+
7
+ Modals (also known as modal windows, overlays, and dialogs) are large UI elements that sit on top of an application's main window.
8
+ To return to the application's main interface, users must interact with the modal.
9
+
10
+ This component must be wrapped in an OverlayProvider and the first child component should be a trigger, such as a button.
11
+
12
+ If the modal is used to display an error message, it displays after users perform an action and require a response.
13
+ These messages should be short, meaningful, free of technical jargon, and follow status color guidelines.
14
+ They can also be used to educate users, but don’t try to explain complicated troubleshooting processes in error messages.
15
+
16
+ Error messages should clearly explain:
17
+ - What happened
18
+ - Why it happened, if that’s relevant
19
+ - The steps users should take to resolve the issue
20
+
21
+ See our [Error message writing guidelines](https://pingidentity.atlassian.net/wiki/spaces/CCC/pages/21137273/Error+messages) for additional information.
22
+
23
+ Modals should:
24
+ - Be used for important warnings and information requests as a way to prevent or correct critical errors.
25
+ - Be used to break down complex workflow to not overwhelm the user.
26
+ - Have all the critical information inside it to help users make decisions.
27
+
28
+ Modals should not:
29
+ - Be nested inside or replaced by another modal.
30
+ - Be overused as it disrupts the user’s workflow and requires a response.
31
+ - Have content that requires scrolling. If the content length is exceedingly large or requires complex forms, use the [OverlayPanel](./?path=/docs/components-overlaypanel--default) component.
32
+ - Be used for brief warnings and alerts, use the [Messages](./?path=/docs/components-messages--default) component instead.
33
+
34
+ ### Required Components
35
+
36
+ This component requires the OverlayProvider and [Button](./?path=/docs/components-button--default) components.
37
+
38
+ ### Accessibility
39
+
40
+ This component should adhere to the [WAI-ARIA Modal](https://www.w3.org/WAI/ARIA/apg/patterns/dialog-modal/examples/dialog/) accessibility guidelines.
41
+
42
+ #### Keyboard Navigation
43
+
44
+ These keys provide additional functionality to the component.
45
+
46
+ | Key | Functions |
47
+ | ---- | ---- |
48
+ | Tab | The trigger component and the content in the modal are focusable using the Tab key. |
49
+ | | When a modal opens, focus moves to an element contained in the modal, which is usually the first focusable element. If the first focusable element does not make sense, tabindex=”-1” should be added to a static element at the top of the modal, which could be the panel title. |
50
+ | Space or Enter | Opens the modal when the trigger is focused. Once opened, the focus is locked inside the modal. |
51
+ | Shift + Tab | Moves focus to the previous focusable component. |
52
+ | Esc | Pressing the escape key closes the modal and adds focus to the previously focused component. |
53
+
54
+ #### Screen Readers
55
+
56
+ This component uses the following attributes to assist screen readers:
57
+ - The button uses the **`aria-label`** attribute to provide an accessible name.
58
+ - The **`aria-labelledby`** attribute is supplied with label ID.
59
+ - The **`aria-modal`** attribute allows the assistive technologies to inform users that the ability to interact with or access other content on the page requires the modal dialog to be closed.
@@ -0,0 +1,44 @@
1
+ import { Meta } from '@storybook/addon-docs';
2
+
3
+ <Meta title="Components/MultivaluesField/MultivaluesField" />
4
+
5
+ # MultivaluesField
6
+
7
+ The MultivalueField component allows users to select more than one option from a list.
8
+ Using [useListState](https://react-spectrum.adobe.com/react-stately/useListState.html) from React Stately, it combines an input with a Listbox for a filterable dropdown list.
9
+
10
+ This component should:
11
+ - Be used when choosing multiple items from a list of options or filtering through items by typing.
12
+ - Allow you to add and remove custom items from the list.
13
+
14
+ It should not:
15
+ - Have fewer than 4 options. If it does, use a [CheckboxField](./?path=/docs/form-checkboxfield--default) instead.
16
+ - Be used when only 1 item can be selected.
17
+ - Have a long async loaded list, consider using useAsyncList like [ComboBoxField](./?path=/docs/form-comboboxfield--default) instead.
18
+
19
+ ### Required components
20
+
21
+ This component requires the OverlayProvider and Item originating from [react-stately/collections](https://react-spectrum.adobe.com/react-stately/collections.html).
22
+
23
+ ### Accessibility
24
+
25
+ #### Keyboard Navigation
26
+
27
+ These keys provide additional functionality to the component.
28
+
29
+ | Keys | Functions |
30
+ | ---- | --------- |
31
+ | Tab | Focuses the field and follows the page tab sequence. |
32
+ | Space or Enter | Opens or closes the menu when the input is focused. |
33
+ | Arrow keys | Moves through the list popover. |
34
+ | Shift + Tab | Moves focus to the previous focusable component.|
35
+ | | To allow multiple selections, the user making a selection does not close the menu. However, clicking outside of the listbox or pressing Tab with an open popover does. |
36
+
37
+ #### Screen readers
38
+
39
+ This component uses the following attributes to assist screen readers:
40
+
41
+ - The input uses the **`aria-expanded`** attribute to show the expansion and collapse of the popover, the **`aria-invalid`** attribute set to “True” when an incorrect value or status error occurs, and the **`aria-labelledby`** attribute is used to reference the label.
42
+ - The list box **`aria-multiselectable`** attribute is set to “True” by default.
43
+ - Each option uses the **`aria-selected`** attribute to indicate the state of selection, **`aria-posinset`** to give the option position in the current set of list items, and the **`aria-setsize`** attribute to define the current set of options.
44
+ - The **`aria-disabled`** attribute is set to “False” for each option by default.