@primer/components 32.0.2-rc.859381a1 → 32.1.1-rc.b4502a34

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 (155) hide show
  1. package/CHANGELOG.md +13 -1
  2. package/dist/browser.esm.js +9 -2
  3. package/dist/browser.esm.js.map +1 -1
  4. package/dist/browser.umd.js +9 -2
  5. package/dist/browser.umd.js.map +1 -1
  6. package/docs/content/ActionList2.mdx +23 -3
  7. package/docs/content/Avatar.mdx +21 -1
  8. package/docs/content/AvatarStack.mdx +23 -3
  9. package/docs/content/BranchName.md +24 -4
  10. package/docs/content/Breadcrumbs.md +22 -1
  11. package/docs/content/Buttons.md +2 -1
  12. package/docs/content/Checkbox.md +118 -0
  13. package/docs/content/CircleBadge.md +1 -0
  14. package/docs/content/CircleOcticon.md +2 -1
  15. package/docs/content/CounterLabel.md +1 -1
  16. package/docs/content/Details.md +2 -1
  17. package/docs/content/Dialog.md +1 -0
  18. package/docs/content/Dialog2.mdx +1 -0
  19. package/docs/content/Dropdown.md +1 -0
  20. package/docs/content/DropdownMenu.mdx +1 -0
  21. package/docs/content/FilterList.md +1 -0
  22. package/docs/content/FilteredSearch.md +1 -0
  23. package/docs/content/Flash.md +1 -0
  24. package/docs/content/FormGroup.md +1 -0
  25. package/docs/content/Header.md +1 -0
  26. package/docs/content/Heading.md +8 -4
  27. package/docs/content/Label.md +1 -0
  28. package/docs/content/LabelGroup.md +1 -0
  29. package/docs/content/Link.md +1 -0
  30. package/docs/content/Overlay.mdx +1 -0
  31. package/docs/content/Pagehead.md +1 -0
  32. package/docs/content/Pagination.md +1 -0
  33. package/docs/content/PointerBox.md +1 -0
  34. package/docs/content/Popover.md +1 -0
  35. package/docs/content/Portal.mdx +1 -0
  36. package/docs/content/Position.md +2 -9
  37. package/docs/content/ProgressBar.mdx +1 -0
  38. package/docs/content/SelectMenu.md +1 -0
  39. package/docs/content/SideNav.md +1 -0
  40. package/docs/content/StateLabel.md +1 -0
  41. package/docs/content/StyledOcticon.md +1 -1
  42. package/docs/content/SubNav.md +1 -0
  43. package/docs/content/TabNav.md +1 -0
  44. package/docs/content/Text.md +10 -3
  45. package/docs/content/TextInput.md +9 -1
  46. package/docs/content/Timeline.md +1 -0
  47. package/docs/content/Tooltip.md +1 -0
  48. package/docs/content/Truncate.md +1 -0
  49. package/docs/content/UnderlineNav.md +1 -0
  50. package/docs/content/status.mdx +10 -0
  51. package/docs/src/@primer/gatsby-theme-doctocat/mdx-components.js +9 -0
  52. package/docs/src/@primer/gatsby-theme-doctocat/nav.yml +4 -0
  53. package/docs/src/component-statuses.js +74 -0
  54. package/lib/ActionList/Item.js +3 -3
  55. package/lib/ActionList2/Item.js +3 -1
  56. package/lib/ActionList2/List.js +1 -2
  57. package/lib/ActionList2/Selection.js +3 -1
  58. package/lib/Autocomplete/Autocomplete.d.ts +1 -0
  59. package/lib/Autocomplete/AutocompleteInput.d.ts +1 -0
  60. package/lib/Button/Button.d.ts +1 -0
  61. package/lib/Button/ButtonClose.d.ts +2 -1
  62. package/lib/Button/ButtonDanger.d.ts +1 -0
  63. package/lib/Button/ButtonInvisible.d.ts +1 -0
  64. package/lib/Button/ButtonOutline.d.ts +1 -0
  65. package/lib/Button/ButtonPrimary.d.ts +1 -0
  66. package/lib/Checkbox.d.ts +29 -0
  67. package/lib/Checkbox.js +64 -0
  68. package/lib/CircleOcticon.d.ts +1 -0
  69. package/lib/Dialog.d.ts +3 -2
  70. package/lib/Dropdown.d.ts +4 -0
  71. package/lib/DropdownMenu/DropdownButton.d.ts +2 -1
  72. package/lib/FilterList.d.ts +1 -0
  73. package/lib/Position.d.ts +4 -4
  74. package/lib/SelectMenu/SelectMenu.d.ts +10 -4
  75. package/lib/SelectMenu/SelectMenuItem.d.ts +1 -1
  76. package/lib/SelectMenu/SelectMenuModal.d.ts +1 -1
  77. package/lib/TextInputWithTokens.d.ts +1 -0
  78. package/lib/Token/AvatarToken.d.ts +1 -1
  79. package/lib/Token/IssueLabelToken.d.ts +1 -1
  80. package/lib/Token/Token.d.ts +1 -1
  81. package/lib/__tests__/ActionList2.test.d.ts +1 -0
  82. package/lib/__tests__/ActionList2.test.js +117 -0
  83. package/lib/__tests__/Checkbox.test.d.ts +2 -0
  84. package/lib/__tests__/Checkbox.test.js +189 -0
  85. package/lib/__tests__/themePreval.test.d.ts +1 -0
  86. package/lib/__tests__/themePreval.test.js +14 -0
  87. package/lib/index.d.ts +2 -0
  88. package/lib/index.js +8 -0
  89. package/lib/stories/ActionList2.stories.js +20 -6
  90. package/lib/stories/Checkbox.stories.js +227 -0
  91. package/lib/utils/testing.d.ts +1 -0
  92. package/lib/utils/testing.js +29 -0
  93. package/lib-esm/ActionList/Item.js +3 -3
  94. package/lib-esm/ActionList2/Item.js +3 -1
  95. package/lib-esm/ActionList2/List.js +1 -2
  96. package/lib-esm/ActionList2/Selection.js +3 -1
  97. package/lib-esm/Autocomplete/Autocomplete.d.ts +1 -0
  98. package/lib-esm/Autocomplete/AutocompleteInput.d.ts +1 -0
  99. package/lib-esm/Button/Button.d.ts +1 -0
  100. package/lib-esm/Button/ButtonClose.d.ts +2 -1
  101. package/lib-esm/Button/ButtonDanger.d.ts +1 -0
  102. package/lib-esm/Button/ButtonInvisible.d.ts +1 -0
  103. package/lib-esm/Button/ButtonOutline.d.ts +1 -0
  104. package/lib-esm/Button/ButtonPrimary.d.ts +1 -0
  105. package/lib-esm/Checkbox.d.ts +29 -0
  106. package/lib-esm/Checkbox.js +44 -0
  107. package/lib-esm/CircleOcticon.d.ts +1 -0
  108. package/lib-esm/Dialog.d.ts +3 -2
  109. package/lib-esm/Dropdown.d.ts +4 -0
  110. package/lib-esm/DropdownMenu/DropdownButton.d.ts +2 -1
  111. package/lib-esm/FilterList.d.ts +1 -0
  112. package/lib-esm/Position.d.ts +4 -4
  113. package/lib-esm/SelectMenu/SelectMenu.d.ts +10 -4
  114. package/lib-esm/SelectMenu/SelectMenuItem.d.ts +1 -1
  115. package/lib-esm/SelectMenu/SelectMenuModal.d.ts +1 -1
  116. package/lib-esm/TextInputWithTokens.d.ts +1 -0
  117. package/lib-esm/Token/AvatarToken.d.ts +1 -1
  118. package/lib-esm/Token/IssueLabelToken.d.ts +1 -1
  119. package/lib-esm/Token/Token.d.ts +1 -1
  120. package/lib-esm/__tests__/ActionList2.test.d.ts +1 -0
  121. package/lib-esm/__tests__/ActionList2.test.js +105 -2
  122. package/lib-esm/__tests__/Checkbox.test.d.ts +2 -0
  123. package/lib-esm/__tests__/Checkbox.test.js +169 -0
  124. package/lib-esm/__tests__/themePreval.test.d.ts +1 -0
  125. package/lib-esm/__tests__/themePreval.test.js +7 -0
  126. package/lib-esm/index.d.ts +2 -0
  127. package/lib-esm/index.js +1 -0
  128. package/lib-esm/stories/ActionList2.stories.js +20 -6
  129. package/lib-esm/stories/Checkbox.stories.js +197 -0
  130. package/lib-esm/utils/testing.d.ts +1 -0
  131. package/lib-esm/utils/testing.js +24 -0
  132. package/package-lock.json +179 -20
  133. package/package.json +2 -2
  134. package/src/ActionList/Item.tsx +2 -1
  135. package/src/ActionList2/Item.tsx +3 -2
  136. package/src/ActionList2/List.tsx +1 -6
  137. package/src/ActionList2/Selection.tsx +2 -1
  138. package/src/Checkbox.tsx +75 -0
  139. package/src/__tests__/ActionList2.test.tsx +111 -2
  140. package/src/__tests__/Checkbox.test.tsx +155 -0
  141. package/src/__tests__/__snapshots__/Autocomplete.test.tsx.snap +13 -0
  142. package/src/__tests__/__snapshots__/Checkbox.test.tsx.snap +16 -0
  143. package/src/__tests__/__snapshots__/themePreval.test.ts.snap +3176 -0
  144. package/src/__tests__/themePreval.test.ts +8 -0
  145. package/src/index.ts +3 -0
  146. package/src/stories/ActionList2.stories.tsx +22 -8
  147. package/src/stories/Checkbox.stories.tsx +164 -0
  148. package/src/utils/testing.tsx +22 -0
  149. package/stats.html +1 -1
  150. package/docs/content/TextInputTokens.mdx +0 -89
  151. package/lib/ActionList2/Header.d.ts +0 -26
  152. package/lib/ActionList2/Header.js +0 -55
  153. package/lib-esm/ActionList2/Header.d.ts +0 -26
  154. package/lib-esm/ActionList2/Header.js +0 -44
  155. package/src/ActionList2/Header.tsx +0 -58
@@ -1,14 +1,14 @@
1
1
  ---
2
- title: ActionList
2
+ title: ActionList v2
3
3
  status: Alpha
4
4
  source: https://github.com/primer/react/tree/main/src/ActionList2
5
5
  storybook: '/react/storybook?path=/story/composite-components-actionlist2'
6
- description: An ActionList is a list of items which can be activated or selected. ActionList is the base component for many of our menu-type components, including DropdownMenu and ActionMenu.
6
+ description: An ActionList is a list of items that can be activated or selected. ActionList is the base component for many menu-type components, including DropdownMenu and ActionMenu.
7
7
  ---
8
8
 
9
9
  import {BorderBox, Avatar} from '@primer/components'
10
10
  import {ActionList} from '@primer/components/drafts'
11
- import {Props} from '../src/props'
11
+ import {ComponentChecklist} from '../src/component-checklist'
12
12
 
13
13
  import {ImageContainer} from '@primer/gatsby-theme-doctocat'
14
14
  import {LinkIcon, AlertIcon, ArrowRightIcon} from '@primer/octicons-react'
@@ -357,3 +357,23 @@ render(<SelectFields />)
357
357
 
358
358
  - [ActionMenu](/ActionMenu)
359
359
  - [SelectPanel](/SelectPanel)
360
+
361
+ ## Component status
362
+
363
+ <ComponentChecklist
364
+ items={{
365
+ propsDocumented: true,
366
+ noUnnecessaryDeps: true,
367
+ adaptsToThemes: true,
368
+ adaptsToScreenSizes: true,
369
+ fullTestCoverage: false,
370
+ usedInProduction: false,
371
+ usageExamplesDocumented: true,
372
+ designReviewed: false,
373
+ a11yReviewed: false,
374
+ stableApi: false,
375
+ addressedApiFeedback: false,
376
+ hasDesignGuidelines: true,
377
+ hasFigmaComponent: true
378
+ }}
379
+ />
@@ -1,10 +1,10 @@
1
1
  ---
2
2
  title: Avatar
3
+ status: Alpha
3
4
  componentId: avatar
4
5
  source: https://github.com/primer/react/blob/main/src/Avatar.tsx
5
6
  ---
6
7
 
7
- import {Props} from '../src/props'
8
8
  import {Avatar} from '@primer/components'
9
9
 
10
10
  ```jsx live
@@ -31,3 +31,23 @@ import {Avatar} from '@primer/components'
31
31
  <Avatar src="https://avatars.githubusercontent.com/primer" />
32
32
  </AvatarPair>
33
33
  ```
34
+
35
+ ## Component status
36
+
37
+ <ComponentChecklist
38
+ items={{
39
+ propsDocumented: true,
40
+ noUnnecessaryDeps: true,
41
+ adaptsToThemes: true,
42
+ adaptsToScreenSizes: true,
43
+ fullTestCoverage: false,
44
+ usedInProduction: true,
45
+ usageExamplesDocumented: true,
46
+ designReviewed: false,
47
+ a11yReviewed: false,
48
+ stableApi: false,
49
+ addressedApiFeedback: false,
50
+ hasDesignGuidelines: false,
51
+ hasFigmaComponent: false
52
+ }}
53
+ />
@@ -1,12 +1,12 @@
1
1
  ---
2
2
  title: AvatarStack
3
+ status: Alpha
4
+ description: Use an avatar stack to display two or more avatars in an inline stack.
5
+ source: https://github.com/primer/react/blob/main/src/AvatarStack.tsx
3
6
  ---
4
7
 
5
- import {Props} from '../src/props'
6
8
  import {AvatarStack} from '@primer/components'
7
9
 
8
- AvatarStack is used to display more than one Avatar in an inline stack.
9
-
10
10
  ### Default example
11
11
 
12
12
  ```jsx live
@@ -35,3 +35,23 @@ AvatarStack is used to display more than one Avatar in an inline stack.
35
35
  | :--------- | :---------------- | :-----: | :----------------------------------- |
36
36
  | alignRight | Boolean | | Creates right aligned AvatarStack |
37
37
  | sx | SystemStyleObject | {} | Style to be applied to the component |
38
+
39
+ ## Component status
40
+
41
+ <ComponentChecklist
42
+ items={{
43
+ propsDocumented: true,
44
+ noUnnecessaryDeps: true,
45
+ adaptsToThemes: true,
46
+ adaptsToScreenSizes: true,
47
+ fullTestCoverage: false,
48
+ usedInProduction: true,
49
+ usageExamplesDocumented: true,
50
+ designReviewed: false,
51
+ a11yReviewed: false,
52
+ stableApi: false,
53
+ addressedApiFeedback: false,
54
+ hasDesignGuidelines: false,
55
+ hasFigmaComponent: false
56
+ }}
57
+ />
@@ -1,18 +1,38 @@
1
1
  ---
2
2
  title: BranchName
3
+ status: Alpha
4
+ source: https://github.com/primer/react/blob/main/src/BranchName.tsx
3
5
  ---
4
6
 
5
7
  BranchName is a label-type component rendered as an `<a>` tag by default with monospace font.
6
8
 
7
- ## Default example
8
-
9
- ```jsx live live
9
+ ```jsx live
10
10
  <BranchName>a_new_feature_branch</BranchName>
11
11
  ```
12
12
 
13
- ## Component props
13
+ ## Props
14
14
 
15
15
  | Name | Type | Default | Description |
16
16
  | :--- | :----- | :-----: | :---------------------------------- |
17
17
  | as | String | `<a>` | sets the HTML tag for the component |
18
18
  | href | String | | a URL to link the component to |
19
+
20
+ ## Component status
21
+
22
+ <ComponentChecklist
23
+ items={{
24
+ propsDocumented: true,
25
+ noUnnecessaryDeps: true,
26
+ adaptsToThemes: true,
27
+ adaptsToScreenSizes: true,
28
+ fullTestCoverage: true,
29
+ usedInProduction: false,
30
+ usageExamplesDocumented: true,
31
+ designReviewed: false,
32
+ a11yReviewed: false,
33
+ stableApi: false,
34
+ addressedApiFeedback: false,
35
+ hasDesignGuidelines: false,
36
+ hasFigmaComponent: false
37
+ }}
38
+ />
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  title: Breadcrumbs
3
3
  status: Alpha
4
+ description: Use breadcrumbs to show navigational context on pages that are many levels deep in a site’s hierarchy. Breadcrumbs show and link to parent, grandparent, and sometimes great-grandparent pages.
4
5
  source: https://github.com/primer/react/blob/main/src/Breadcrumbs.tsx
5
6
  ---
6
7
 
@@ -27,7 +28,7 @@ This ensures that the NavLink gets `activeClassName='selected'`
27
28
  </Breadcrumbs>
28
29
  ```
29
30
 
30
- ## Component props
31
+ ## Props
31
32
 
32
33
  ### Breadcrumbs
33
34
 
@@ -45,3 +46,23 @@ This ensures that the NavLink gets `activeClassName='selected'`
45
46
  | href | string | | URL to be used for the Link |
46
47
  | selected | boolean | `false` | Used to style the link as selected or unselected |
47
48
  | sx | SystemStyleObject | `{}` | Style to be applied to the component |
49
+
50
+ ## Component status
51
+
52
+ <ComponentChecklist
53
+ items={{
54
+ propsDocumented: true,
55
+ noUnnecessaryDeps: true,
56
+ adaptsToThemes: true,
57
+ adaptsToScreenSizes: false,
58
+ fullTestCoverage: false,
59
+ usedInProduction: true,
60
+ usageExamplesDocumented: true,
61
+ designReviewed: false,
62
+ a11yReviewed: false,
63
+ stableApi: false,
64
+ addressedApiFeedback: false,
65
+ hasDesignGuidelines: false,
66
+ hasFigmaComponent: false
67
+ }}
68
+ />
@@ -1,5 +1,6 @@
1
1
  ---
2
- title: Buttons
2
+ title: Button
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  `Button` is used for actions, like in forms, while `Link` is used for destinations, or moving from one page to another.
@@ -0,0 +1,118 @@
1
+ ---
2
+ title: Checkbox
3
+ description: Use checkboxes to toggle between checked and unchecked states in a list or as a standalone form field
4
+ status: Alpha
5
+ source: https://github.com/primer/react/blob/main/src/Checklist.tsx
6
+ storybook: '/react/storybook?path=/story/forms-checkbox--default'
7
+ ---
8
+
9
+ import {ComponentChecklist} from '../src/component-checklist'
10
+
11
+ ## Default example
12
+
13
+ The `Checkbox` component can be used in controlled and uncontrolled modes.
14
+
15
+ ```jsx live
16
+ <>
17
+ <Box as="form" sx={{p: 3, pt: 0, display: 'flex', alignItems: 'center'}}>
18
+ <Checkbox id="default-checkbox" />
19
+ <Text as="label" htmlFor="default-checkbox" sx={{fontSize: 2, fontWeight: 'bold', marginLeft: 1}}>
20
+ Default checkbox
21
+ </Text>
22
+ </Box>
23
+ <Box as="form" sx={{p: 3, display: 'flex', alignItems: 'center'}}>
24
+ <Checkbox id="always-checked-checkbox" checked={true} />
25
+ <Text as="label" htmlFor="always-checked-checkbox" sx={{fontSize: 2, fontWeight: 'bold', marginLeft: 1}}>
26
+ Always checked
27
+ </Text>
28
+ </Box>
29
+ <Box as="form" sx={{p: 3, display: 'flex', alignItems: 'center'}}>
30
+ <Checkbox id="always-unchecked-checkbox" checked={false} />
31
+ <Text as="label" htmlFor="always-unchecked-checkbox" sx={{fontSize: 2, fontWeight: 'bold', marginLeft: 1}}>
32
+ Always unchecked
33
+ </Text>
34
+ </Box>
35
+
36
+ <Box as="form" sx={{p: 3, display: 'flex', alignItems: 'center'}}>
37
+ <Checkbox id="inactive-checkbox" checked={true} disabled />
38
+ <Text as="label" htmlFor="inactive-checkbox" sx={{fontSize: 2, fontWeight: 'bold', marginLeft: 1}}>
39
+ Inactive
40
+ </Text>
41
+ </Box>
42
+ </>
43
+ ```
44
+
45
+ <Note variant="warning">
46
+ Checkbox components should always be accompanied by a corresponding label to improve support for assistive technologies.
47
+ </Note>
48
+
49
+ ## Indeterminate example
50
+
51
+ An `indeterminate` checkbox state should be used if the input value is neither true nor false. This can be useful in situations where you are required to display an incomplete state, or one that is dependent on other input selections to determine a value.
52
+
53
+ ```jsx live
54
+ <>
55
+ <Box as="form" sx={{p: 3, pt: 0, pb: 1, display: 'flex', alignItems: 'center'}}>
56
+ <Checkbox id="indeterminate-checkbox" onChange={() => {}} indeterminate={true} />
57
+ <Text as="label" sx={{fontSize: 2, fontWeight: 'bold', marginLeft: 1}} htmlFor="controlled-checkbox">
58
+ <Text sx={{display: 'block'}}>Default checkbox</Text>
59
+ </Text>
60
+ </Box>
61
+ <Box key={`sub-checkbox-0`} as="form" sx={{p: 1, pl: 6, display: 'flex', alignItems: 'center'}}>
62
+ <Checkbox id={`sub-checkbox-0`} checked={true} onChange={() => {}} />
63
+ <Text as="label" sx={{fontSize: 2, fontWeight: 'bold', marginLeft: 1}} htmlFor={`sub-checkbox-0`}>
64
+ <Text sx={{display: 'block'}}>Checkbox 1</Text>
65
+ </Text>
66
+ </Box>
67
+ <Box key={`sub-checkbox-1`} as="form" sx={{p: 1, pl: 6, display: 'flex', alignItems: 'center'}}>
68
+ <Checkbox id={`sub-checkbox-1`} checked={false} onChange={() => {}} />
69
+ <Text as="label" sx={{fontSize: 2, fontWeight: 'bold', marginLeft: 1}} htmlFor={`sub-checkbox-1`}>
70
+ <Text sx={{display: 'block'}}>Checkbox 2</Text>
71
+ </Text>
72
+ </Box>
73
+ <Box key={`sub-checkbox-2`} as="form" sx={{p: 1, pl: 6, display: 'flex', alignItems: 'center'}}>
74
+ <Checkbox id={`sub-checkbox-2`} checked={false} onChange={() => {}} />
75
+ <Text as="label" sx={{fontSize: 2, fontWeight: 'bold', marginLeft: 1}} htmlFor={`sub-checkbox-2`}>
76
+ <Text sx={{display: 'block'}}>Checkbox 3</Text>
77
+ </Text>
78
+ </Box>
79
+ <Box key={`sub-checkbox-3`} as="form" sx={{p: 1, pl: 6, display: 'flex', alignItems: 'center'}}>
80
+ <Checkbox id={`sub-checkbox-3`} checked={false} onChange={() => {}} />
81
+ <Text as="label" sx={{fontSize: 2, fontWeight: 'bold', marginLeft: 1}} htmlFor={`sub-checkbox-3`}>
82
+ <Text sx={{display: 'block'}}>Checkbox 4</Text>
83
+ </Text>
84
+ </Box>
85
+ </>
86
+ ```
87
+
88
+ ## Component props
89
+
90
+ Native `<input>` attributes are forwarded to the underlying React `input` component and are not listed below.
91
+
92
+ | Name | Type | Default | Description |
93
+ | :------------- | :---------- | :-------: | :------------------------------------------------------------------------------------------------------------------------------------------------------ |
94
+ | checked | Boolean | undefined | Optional. Modifies true/false value of the native checkbox |
95
+ | defaultChecked | Boolean | undefined | Optional. Checks the input by default in uncontrolled mode |
96
+ | onChange | ChangeEvent | undefined | Optional. A callback function that is triggered when the checked state has been changed. |
97
+ | disabled | Boolean | undefined | Optional. Modifies the native disabled state of the native checkbox |
98
+ | indeterminate | Boolean | undefined | Optional. Applies an [indeterminate](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/checkbox#attr-indeterminate) state to the checkbox |
99
+
100
+ ## Component status
101
+
102
+ <ComponentChecklist
103
+ items={{
104
+ propsDocumented: true,
105
+ noUnnecessaryDeps: true,
106
+ adaptsToThemes: true,
107
+ adaptsToScreenSizes: true,
108
+ fullTestCoverage: true,
109
+ usedInProduction: false,
110
+ usageExamplesDocumented: false,
111
+ designReviewed: false,
112
+ a11yReviewed: false,
113
+ stableApi: false,
114
+ addressedApiFeedback: false,
115
+ hasDesignGuidelines: false,
116
+ hasFigmaComponent: false
117
+ }}
118
+ />
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: CircleBadge
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  Use CircleBadge to visually connect logos of third party services like in marketplace. Use CircleBadge.Icon to add an Octicon to the CircleBadge.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: CircleOcticon
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  CircleOcticon renders any Octicon with a circle background. CircleOcticons are most commonly used to represent the status of a pull request in the comment timeline.
@@ -7,7 +8,7 @@ CircleOcticon renders any Octicon with a circle background. CircleOcticons are m
7
8
  ## Default example
8
9
 
9
10
  ```jsx live
10
- <CircleOcticon icon={CheckIcon} size={32} sx={{bg: "success.fg", color: "fg.onEmphasis"}} />
11
+ <CircleOcticon icon={CheckIcon} size={32} sx={{bg: 'success.fg', color: 'fg.onEmphasis'}} />
11
12
  ```
12
13
 
13
14
  ## Component props
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  title: CounterLabel
3
- tags: pill
3
+ status: Alpha
4
4
  ---
5
5
 
6
6
  Use the CounterLabel component to add a count to navigational elements and buttons.
@@ -1,5 +1,6 @@
1
1
  ---
2
- title: Details & useDetails hook
2
+ title: Details
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  `Details` is a styled `details` element for use with the `useDetails` hook. The `useDetails` hook returns the `open` state, a `setOpen` function to manually change the open state, and **`getDetailsProps` which must be spread onto your `Details` element in order for `Details` to get receive the proper behaviors provided by the hook**. See Kent Dodd's article on this pattern [here](https://kentcdodds.com/blog/how-to-give-rendering-control-to-users-with-prop-getters).
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Dialog
3
+ status: Deprecated
3
4
  ---
4
5
 
5
6
  import State from '../components/State'
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Dialog v2
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  import State from '../components/State'
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Dropdown
3
+ status: Deprecated
3
4
  ---
4
5
 
5
6
  The Dropdown component is a lightweight context menu for housing navigation and actions.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: DropdownMenu
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  A `DropdownMenu` provides an anchor (button by default) that will open a floating menu of selectable items. The menu can be opened and navigated using keyboard or mouse. When an item is selected, the menu will close and the `onChange` callback will be called. If the default anchor button is used, the anchor contents will be updated with the selection.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: FilterList
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  The FilterList component is a menu with filter options that filter the main content of the page.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: FilteredSearch
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  The FilteredSearch component helps style a Dropdown and a TextInput side-by-side.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Flash
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  The Flash component informs users of successful or pending actions.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: FormGroup
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  Adds styles for multiple form elements used together.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Header
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  Use the `Header` component to create a header that has all of its items aligned vertically with consistent horizontal spacing.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Heading
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  The Heading component will render an html `h2` tag without any default styling. Other heading level elements `h1-h6` are available through use of the `as` prop (see [System Props](/system-props) for additional explanation). Please reference the [w3 recommendations for headings](https://www.w3.org/WAI/tutorials/page-structure/headings/) to ensure your headings provide an accessible experience for screen reader users.
@@ -7,8 +8,11 @@ The Heading component will render an html `h2` tag without any default styling.
7
8
  **Attention:** Make sure to include a valid heading element to render a Heading component other than `h2` (`<Heading as="h1">H1 Element</Heading>`).
8
9
 
9
10
  ## Default example
11
+
10
12
  ```jsx live
11
- <Heading fontSize={1} mb={2}>H2 heading with fontSize={1}</Heading>
13
+ <Heading fontSize={1} mb={2}>
14
+ H2 heading with fontSize={1}
15
+ </Heading>
12
16
  ```
13
17
 
14
18
  ## System props
@@ -17,6 +21,6 @@ Heading components get `TYPOGRAPHY` and `COMMON` system props. Read our [System
17
21
 
18
22
  ## Component props
19
23
 
20
- | Prop name | Type | Description |
21
- | :-------- | :------ | :----------------------------------------------- |
22
- | as | String or React element | sets the HTML tag for the component |
24
+ | Prop name | Type | Description |
25
+ | :-------- | :---------------------- | :---------------------------------- |
26
+ | as | String or React element | sets the HTML tag for the component |
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Label
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  The Label component is used to add contextual metadata to a design. Visually it styles text, adds padding, and rounded corners.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: LabelGroup
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  The LabelGroup component is used to add commonly used margins and wrapping for groups of Labels.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Link
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  The Link component styles anchor tags with default hyperlink color cues and hover text decoration. `Link` is used for destinations, or moving from one page to another.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Overlay
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  An `Overlay` is a flexible floating surface, used to display transient content such as menus, selection options, dialogs, and more. Overlays use shadows to express elevation. The `Overlay` component handles all behaviors needed by overlay UIs as well as the common styles that all overlays should have. `Overlay` is the base component for many of our overlay-type components.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Pagehead
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  Give a page a clear, separated title and optional top nav by using Pagehead.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Pagination
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  import State from '../components/State'
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: PointerBox
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  PointerBox is a [BorderBox](./BorderBox) component with a caret added to it.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Popover
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  Popovers are used to bring attention to specific user interface elements, typically to suggest an action or to guide users through a new experience.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Portal
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  Portals allow you to create a separation between the logical React component hierarchy and the physical DOM. See the [React documentation on portals](https://reactjs.org/docs/portals.html) for an in-depth explanation.
@@ -1,5 +1,5 @@
1
1
  ---
2
- title: Position Components
2
+ title: Position
3
3
  status: Deprecated
4
4
  ---
5
5
 
@@ -69,14 +69,7 @@ Use [Box](/Box) instead.
69
69
 
70
70
  <Heading my={2}>Sticky</Heading>
71
71
 
72
- <Box
73
- borderWidth="1px"
74
- borderStyle="solid"
75
- borderColor="success.emphasis"
76
- borderRadius={2}
77
- border={1}
78
- height={500}
79
- >
72
+ <Box borderWidth="1px" borderStyle="solid" borderColor="success.emphasis" borderRadius={2} border={1} height={500}>
80
73
  <Sticky top={0} bg="success.subtle" p={6}>
81
74
  I'm sticky!
82
75
  </Sticky>
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  title: ProgressBar
3
3
  componentId: progress_bar
4
+ status: Alpha
4
5
  source: https://github.com/primer/react/blob/main/src/ProgressBar.tsx
5
6
  ---
6
7
 
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: SelectMenu
3
+ status: Deprecated
3
4
  ---
4
5
 
5
6
  The `SelectMenu` components are a suite of components which can be combined together to make several different variations of our GitHub select menu. At it's most basic form, a select menu is comprised of a `SelectMenu` wrapper, which contains a `summary` component of your choice and a `Select.Modal` which contains the select menu content. Use `SelectMenu.List` to wrap items in the select menu, and `SelectMenu.Item` to wrap each item.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: SideNav
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  The Side Nav is a vertical list of navigational links, typically used on the left side of a page. For maximum flexibility, **SideNav elements have no default width or positioning.**
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: StateLabel
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  Use StateLabel components to show the status of an issue or pull request.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  title: StyledOcticon
3
- tags: icon
3
+ status: Alpha
4
4
  ---
5
5
 
6
6
  StyledOcticon renders an [Octicon](https://octicons.github.com) with common system props, including `color`, margin, and padding.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: SubNav
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  Use the SubNav component for navigation on a dashboard-type interface with another set of navigation components above it. This helps distinguish navigation hierarchy.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: TabNav
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  Use the TabNav component to style navigation with a tab-based selected state, typically used for navigation placed at the top of the page.
@@ -1,5 +1,6 @@
1
1
  ---
2
2
  title: Text
3
+ status: Alpha
3
4
  ---
4
5
 
5
6
  The Text component is a wrapper component that will apply typography styles to the text inside.
@@ -8,9 +9,15 @@ The Text component is a wrapper component that will apply typography styles to t
8
9
 
9
10
  ```jsx live
10
11
  <>
11
- <Text as='p' fontWeight="bold">bold</Text>
12
- <Text as='p' color="danger.fg">danger color</Text>
13
- <Text as='p' color="fg.onEmphasis" bg="neutral.emphasis" p={2}>inverse colors</Text>
12
+ <Text as="p" fontWeight="bold">
13
+ bold
14
+ </Text>
15
+ <Text as="p" color="danger.fg">
16
+ danger color
17
+ </Text>
18
+ <Text as="p" color="fg.onEmphasis" bg="neutral.emphasis" p={2}>
19
+ inverse colors
20
+ </Text>
14
21
  </>
15
22
  ```
16
23